ios - 强制 UITextView 按需呈现文本?
问题描述
我将 aUITextView
用作UIButton
单击 a 时开始的某些操作的日志。但是, when changedtext
属性UITextView
不会在更新时呈现。整个日志文本列表仅作为IBAction
返回UIButton
值显示。
这实际上是可能的还是我应该查看其他一些 UI 对象?
编辑添加下面的示例代码:
var log: UITextView!
IBAction func runOps() {
self.log += "Starting ops..."
self.log += "Starting ops1.."
self.ops1()
self.log += "ops1 completed.."
self.log += "Starting ops2.."
self.ops2()
self.log += "ops2 completed.."
}
解决方案
推荐阅读
- html - 对齐底部栏元素
- druid - 德鲁伊可以执行嵌套查询,使得每个查询都包含一个维度和关联维度的列表吗?
- javascript - 如何更改 window.open 上的 URL?为什么这不起作用?
- javascript - 试图把这一切都集中在一条线上
- python - 如何使用python在excel工作表中插入真正的数据透视表?
- javascript - dc.js 百分比直方图 - 组的大小
- python - 大多数pythonic可调用生成True?
- sql - 对 DB2 中的所有行求和
- reactjs - Typescript + React:键入扩展给定类组件的功能包装器组件
- reactjs - (Native React)无法在 Native React 中单独为这两个项目工作