小编Tig*_*ger的帖子

RTL在行尾显示数字

试图显示以数字开头的希伯来字符串,始终在字符串末尾显示数字,如下所示:1.יוםשישיבבוקר

但我需要在文字的右侧显示数字 -

任何解决方案?

它发生在UILabel和UITextField和UITextView上

并且尝试在左侧写入数字也会产生相同的数据.

使用UITextAlignment的组合将无济于事.

iphone alignment right-to-left

17
推荐指数
5
解决办法
4675
查看次数

self.delegate = self; 这样做有什么不对?

self.delegate = self; 这样做有什么不对?这样做的正确方法是什么?

谢谢,Nir.

码:

(UITextField*)initWith:(id)sender:(float)X:(float)Y:(float)width:(float)hieght:(int)textFieldTag { 
    if (self = [super initWithFrame:CGRectMake(X, Y,width, hieght)]) {
        finalText = [[NSMutableString alloc] initWithString:@""];
        senderObject = sender;
        self.textColor = [UIColor blackColor]; 
        self.font = [UIFont systemFontOfSize:17.0]; 
        self.backgroundColor = [UIColor whiteColor]; 
        self.autocorrectionType = UITextAutocorrectionTypeNo;   
        self.keyboardType = UIKeyboardTypeDefault;     
        self.returnKeyType = UIReturnKeyDone; 
        self.clearButtonMode = UITextFieldViewModeWhileEditing;    
        self.tag = textFieldTag;        
        self.delegate = self;    
        [sender addSubview:self];
    }
    return self;
} 
Run Code Online (Sandbox Code Playgroud)

注意:这是一个文本字段,当我将委托设置为另一个对象(self.delegate = mainView)时,一切正常,但是我将不得不在mainView中实现委托方法,我想将它们放入self(我创建的uiTextField类).如果我设置self.delegate = self,我会得到一个textField,但键盘没有出现.

iphone delegates self uitextfield

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

标签 统计

iphone ×2

alignment ×1

delegates ×1

right-to-left ×1

self ×1

uitextfield ×1