i want to set forward slash line inside my CGRectMake.
please help me out. Thanks in advance.
i want to set forward slash line inside my CGRectMake.
please help me out. Thanks in advance.
CGRectMake only uses numbers.. so, forward slash should not be in it. If what you want to do is create a forward slash within a region/rectangle, you might want to create a UILabel.
Basicllly not Possible
U May use
[myText drawAtPoint:CGPointMake(10,10) forWidth:150 withFont:font minFontSize:10 actualFontSize:NULL lineBreakMode:UILineBreakModeCharacterWrap baselineAdjustment:UIBaselineAdjustmentAlignBaselines];
for draw "\" at 10,10
Use Following Code For Draw "\"
UIGraphicsBeginImageContext(self.view.frame.size);
[draw.image drawInRect:CGRectMake(0, 0, draw.frame.size.width, draw.frame.size.height)];
CGContextSetLineWidth(UIGraphicsGetCurrentContext(), 5.0); // for size
CGContextRef context=UIGraphicsGetCurrentContext();
CGContextBeginPath(UIGraphicsGetCurrentContext());
UIFont *font = [UIFont systemFontOfSize:10];
NSString *myText=[NSString stringWithFormat:@"\"];
[myText drawAtPoint:CGPointMake(j,i) forWidth:150 withFont:font minFontSize:10 actualFontSize:NULL lineBreakMode:UILineBreakModeCharacterWrap baselineAdjustment:UIBaselineAdjustmentAlignBaselines];
CGContextStrokePath(context);
draw.image = UIGraphicsGetImageFromCurrentImageContext();
UIGraphicsEndImageContext();