在UIlabel
我无法显示字符"|"
,我尝试过
[lLebel setText:[NSString stringWithFormat@"%s",[@"your_string" UTF8String]];
我在"|"
的位置使用"your_string"
,但仍然没有显示。但是当我使用"%"
时,它显示"%"
(显示正确)。
我在我的标签上方重载了自定义GLTapLabel(https://github.com/laullon/GLTapLabelDemo/blob/master/GLTapLabelDemo)。这是不能表现出特殊性格的原因吗?
请指导我正确的方向......
答案 0 :(得分:0)
myLabel.text = @"|";
工作得很好!
答案 1 :(得分:0)
使用它对我有用
UILabel *label=[[UILabel alloc]initWithFrame:CGRectMake(90, 7, 187, 30)];
label.font=[UIFont systemFontOfSize:15.0];
label.backgroundColor=[UIColor grayColor];
label.userInteractionEnabled=NO;
[label setText:
@"|"];
[self.view addSubview:label];