小编Aya*_*yaz的帖子

NSArray充满了NSDictionaries.如何找到对象的索引?

我有一个array充满了NSDictionaries.我想找到index一本字典,但我对这本字典的了解只是一个value关键@"name". 我怎么做?

iphone xcode objective-c nsarray ios

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

自定义CALayer - 无效的上下文0x0

我正在尝试构建一个使用图层的应用程序,我的应用程序结构是

UIView --> UIScrollView --> UIView --> LayersView (Custom UIView)
                                   --> UIImageView
Run Code Online (Sandbox Code Playgroud)

我想多层添加到LayersView,所以我建立一个自定义CALayer使用UIBezierPath绘制一组点.

CALayerBezierPath.h

#import <QuartzCore/QuartzCore.h>

@interface CALayerBezierPath : CALayer {
    NSMutableArray *pointsArray;
}
@property (nonatomic, retain) NSMutableArray *pointsArray;

- (void) initVariables;
- (void) addNewPoints:(CGPoint)newPoint;
@end
Run Code Online (Sandbox Code Playgroud)

CALayerBezierPath.m

#import "CALayerBezierPath.h"

@implementation CALayerBezierPath

@dynamic pointsArray;

-(void)drawInContext:(CGContextRef)ctx {
    NSLog(@"CALayerBezierPath - drawInContext");
    if ([pointsArray count] > 0) {
        UIColor *color = [UIColor redColor];
        [color set];
        UIBezierPath *path = [UIBezierPath bezierPath];
        [path moveToPoint:[[pointsArray objectAtIndex:0] CGPointValue]];
        for (int x = 1; x …
Run Code Online (Sandbox Code Playgroud)

calayer cgcontext ios5 quartz-core

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

如何在Xcode 5中向源代码控制添加新项目?

在此输入图像描述如何使用Xcode 5将新项目添加到源代码管理(SVN)?

在"源控制器"中,只有可以点击结账,所有其他都不可点击.

我有我的项目的现有副本.我想在SVN上传这个应用程序.如何在XCode 5中将现有副本添加到SVN.

在图像中,您可以看到所有其他选项都不可点击.我想将此项目添加到SVN.

iphone xcode objective-c ipad

3
推荐指数
1
解决办法
9470
查看次数

标签 统计

iphone ×2

objective-c ×2

xcode ×2

calayer ×1

cgcontext ×1

ios ×1

ios5 ×1

ipad ×1

nsarray ×1

quartz-core ×1