小编Kru*_*nal的帖子

iOS:如何实现手写识别?

启动iOS开发,我希望在我的应用程序中实现手写识别.

我做了一个谷歌搜索,但我没有发现任何教程在目标c中实现文本手势

有没有可用的基本教程实现文本手势...

例如:当用户A在屏幕上书写时,应显示屏幕A

这个项目有没有可用的演示教程?

objective-c uigesturerecognizer ios

8
推荐指数
1
解决办法
6473
查看次数

UIAlertView委托中的UIAlertView Click事件

我是iPhone开发人员的新手,

我想一个接一个地实现2个警报视图,比如当用户按下删除按钮时,第一个警报视图会询问Are you sure want to Delete ?两个按钮yesno

现在,如果用户按下yes,则第二个警报视图将显示消息Deleted Successfully !此警报视图仅包含OK按钮,现在单击此OK按钮我想调用一个方法.

如果用户按下No则不会发生任何事情,警报应该解除.

这是我的代码片段,

-(void)DeletebtnCliked:(id)sender
{   
    UIAlertView* alertView = [[UIAlertView alloc] initWithTitle:@"Are you sure want to delete ?"
                                                        message:nil delegate:self 
                                              cancelButtonTitle:nil
                                              otherButtonTitles:@"Yes",@"No",nil];
    [alertView show];
    [alertView release];   
}

- (void)alertView:(UIAlertView *)alertView clickedButtonAtIndex:(NSInteger)buttonIndex
{ 
    if (buttonIndex == 0)
    {            
         UIAlertView* alertew = [[UIAlertView alloc] initWithTitle:@"Deleted Successfully !"
                                                           message:nil delegate:self 
                                                 cancelButtonTitle:@"OK"
                                                 otherButtonTitles:nil];
        [alertew show];
        [alertew release];

        if (buttonIndex == …
Run Code Online (Sandbox Code Playgroud)

iphone buttonclick uialertview ipad

7
推荐指数
1
解决办法
2万
查看次数

在目标c中为初学者推送通知教程

我对iPhone发展很陌生,

我想的一些教程push notificationiPhone,我在谷歌搜索,但我没有发现任何

谁能帮我吗?

提前致谢 !!

iphone push-notification ipad ios ios-simulator

6
推荐指数
1
解决办法
4万
查看次数

目标c中的epub文件错误

我是iPad开发人员的新手,我想在我的项目中创建ePub文件,

我从这里下载了示例epub文件, 我遇到了问题.

我在我的项目中得到了这个错误......

ld: warning: ignoring file /Users/krunal/Downloads/EpubReader/libz.1.2.3.dylib, missing required architecture i386 in file
Undefined symbols for architecture i386:

"_inflateEnd", referenced from:
_unzCloseCurrentFile in unzip.o

"_inflateInit2_", referenced from:
_unzOpenCurrentFile3 in unzip.o

"_get_crc_table", referenced from:
_unzOpenCurrentFile3 in unzip.o
_zipOpenNewFileInZip3 in zip.o

"_crc32", referenced from:
_unzReadCurrentFile in unzip.o
_zipWriteInFileInZip in zip.o
-[ZipArchive addFileToZip:newname:] in ZipArchive.o

"_inflate", referenced from:
_unzReadCurrentFile in unzip.o

"_deflateInit2_", referenced from:
_zipOpenNewFileInZip3 in zip.o

"_deflate", referenced from:
_zipWriteInFileInZip in zip.o
_zipCloseFileInZipRaw in zip.o

"_deflateEnd", referenced from: …
Run Code Online (Sandbox Code Playgroud)

iphone epub ipad xcode4.2

6
推荐指数
1
解决办法
2844
查看次数

将RootviewController更改为导航控制器

我是iPhone新手,

我想改变我的Rootviewcontroller新课程并将其转换为导航控制器.

这是我的代码片段,

- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {    


    UINavigationController *navigationController=[[UINavigationController alloc] initWithRootViewController:detailViewController];
    [self.window addSubview:navigationController.view];

    [self.window makeKeyAndVisible];


    return YES;
}
Run Code Online (Sandbox Code Playgroud)

SIGABRT说了'adding a root view controller <NewClass: 0x6a8dd50> as a child of view controller:

iphone uinavigationcontroller ipad ios rootview

6
推荐指数
1
解决办法
1万
查看次数

像iOS联系人应用程序索引

我想创建一个视图,iOS联系app有,

基本上我想要的是,垂直ABCDEFG....位于此图像的右侧,当用户点击角色M我想要获得角色M 我应该如何实现这一目标?是否有任何iOS控件给我这个'ABCDEF ......?

谢谢你的支持.

编辑

- (NSArray *)sectionIndexTitlesForTableView:(UITableView *)tableView
{
    return [[NSArray arrayWithObject:UITableViewIndexSearch] arrayByAddingObjectsFromArray:
            [[UILocalizedIndexedCollation currentCollation] sectionIndexTitles]];
}

- (NSInteger)tableView:(UITableView *)tableView sectionForSectionIndexTitle:(NSString *)title atIndex:(NSInteger)index
{
    if (title == UITableViewIndexSearch)
    {
        CGRect searchBarFrame = self.searchDisplayController.searchBar.frame;
        [tableView scrollRectToVisible:searchBarFrame animated:YES];

        return -1;
    }
    else {
        UILocalizedIndexedCollation *currentCollation = [UILocalizedIndexedCollation currentCollation];
        NSLog(@"selected charecter=%ld",(long)[currentCollation sectionForSectionIndexTitleAtIndex:index]);
        return [currentCollation sectionForSectionIndexTitleAtIndex:index-1];
    }
}
Run Code Online (Sandbox Code Playgroud)

iphone contacts ipad ios

6
推荐指数
1
解决办法
3661
查看次数

将UIViewController转换为UIScrollViewController

我是iPad开发人员的新手,

我在我的应用程序中创建了一个注册表单,当我在Portrait模式中看到我的应用程序时,我能够看到没有滚动的整个表单,但是当我在Landscape模式中看到相同的表单时,我无法看到位于页面底部的部分为此,滚动应该在那里看到底部.

小号:在我.h替换时的文件中

@interface ReminderPage : UIViewController{
...
...
}
Run Code Online (Sandbox Code Playgroud)

:UIViewController:UIScrollView

然后当我在我的.m文件中添加标签时,

UILabel *Lastpaidlbl = [[[UILabel alloc] initWithFrame:CGRectMake(70 ,400, 130, 50)]autorelease];
    Lastpaidlbl.backgroundColor = [UIColor greenColor];
    Lastpaidlbl.font=[UIFont systemFontOfSize:20];
    Lastpaidlbl.text = @"Lastpaid on :";
    [self.view addSubview:Lastpaidlbl];
Run Code Online (Sandbox Code Playgroud)

我在最后一行得到错误在类型classname的对象上找不到属性视图. 我无法在视图中添加标签.

任何帮助将不胜感激.

iphone uiscrollview uiviewcontroller uilabel ipad

5
推荐指数
2
解决办法
7331
查看次数

UIImage不会在iPhone中滚动

我是iPhone开发人员的新手,

我想在我的图片中滚动,

这是我的代码片段,

- (void)viewDidLoad {
UIImage *image1 = [UIImage imageWithContentsOfFile:[[[NSBundle mainBundle] resourcePath] stringByAppendingPathComponent:@"bg.png"]];
    self.imageView = [[UIImageView alloc] initWithImage:image1];
    self.imageView.frame = (CGRect){.origin=CGPointMake(0.0f, 0.0f), .size=image1.size};
    [self.scrollView addSubview:self.imageView];
    self.scrollView.contentSize = image.size;

 [self centerScrollViewContents];
}


- (void)centerScrollViewContents {
    CGSize boundsSize = self.scrollView.bounds.size;
    CGRect contentsFrame = self.imageView.frame;

    if (contentsFrame.size.width < boundsSize.width) {
        contentsFrame.origin.x = (boundsSize.width - contentsFrame.size.width) / 2.0f;
    } else {
        contentsFrame.origin.x = 0.0f;
    }

    if (contentsFrame.size.height < boundsSize.height) {
        contentsFrame.origin.y = (boundsSize.height - contentsFrame.size.height) / 2.0f;
    } else {
        contentsFrame.origin.y = 0.0f; …
Run Code Online (Sandbox Code Playgroud)

iphone uiscrollview uiimage ipad

5
推荐指数
1
解决办法
1819
查看次数

垂直对齐UILabel中的文本

我是iPhone新手,

如何在UILabel中垂直对齐文本?

这是我的代码片段,

    UILabel *lbl=[[UILabel alloc]init];
    lbl.frame=CGRectMake(10,10,100,100);
    lbl.backgroundColor=[UIColor clearColor];
    lbl.font=[UIFont systemFontOfSize:13];
    lbl.text=@"123456";
    [scrollVw addSubview:lbl];
Run Code Online (Sandbox Code Playgroud)

显示的文字格式为123456但我希望文字应垂直显示,

6
5
4
3
2
1
Run Code Online (Sandbox Code Playgroud)

任何帮助都会得到满足.

iphone uilabel ipad ios

5
推荐指数
1
解决办法
1万
查看次数

自动调整不在xib中工作

我做了简单的设计.xib,我的应用程序的部署目标是iOS 5 当我在模拟器或设备中运行我的应用程序时,我的视图没有调整大小.

这是我的.xib文件的快照..

当我尝试在模拟器中运行我的应用程序,它可以正常运行在4"模拟器,但它并没有调整大小,当我在3.5"模拟器上运行我的应用程序.检查自动调整子视图属性.

这是我的快照Simulaotrs,第一个截图是3.5",第二个是4"..

提前致谢.

iphone xib autoresize ipad ios

5
推荐指数
2
解决办法
9943
查看次数