UITextView /UIWebView 電話 地址等增長下劃線


給特定內容增長 下劃線 web

 UITextView *textView = [[UITextView alloc] initWithFrame:CGRectMake(20, 20, 280, 200)];
    textView.dataDetectorTypes = UIDataDetectorTypeAll;
    textView.font = [UIFont systemFontOfSize:20];
    textView.editable = NO;//必須有,不然沒有有下劃線
    textView.text = @"My phone number is 15852509846 \r\n"
    "My personal web site www.xxxxxx.com.\r\n"
    "My E-mail address is XXXXX@gmail.com.\r\n"
    "I was born in 1900-01-01.";
    [self.view addSubview:textView];
    [textView release];
it

相關文章
相關標籤/搜索