UITextView 在换行/自动换行后显示空格
我使用 UITextView 来显示任意 NSString,具有各种字体大小(取决于字符串的长度和设备的屏幕分辨率)。我的问题是,如果空格字符是换行符上的第一个字符(在文本被换行之后), UITextView 似乎会显示这些小的“下划线”字符,而不是空格。有人知道如何关闭此功能吗?
I am using a UITextView to display arbitrary NSStrings, with various font sizes (depending on the length of the string, and the screen resolution of the device). My problem is that the UITextView seems to display these little "underscore like" characters, instead of spaces, if the space character is the first character on a newline (after the text has been wrapped). Anyone know a way to turn this off?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
好的,我认为这是我使用的字体的问题。字体的文本大小也可能很重要。也许我用斜体显示的事实就是问题所在。不管怎样,现在我有不同的字体,不同的大小,而不是斜体,我还没有注意到这个问题。
OK, I think this was a problem with the font I was using. Also possibly the text size of the font was important. Perhaps the fact that I was displaying in italic was the thing. Anyhow, now that I have a different font, different size, not italic, I haven't noticed this problem.