android - 两行文字是用两个TextView还是用一个TextView然后文字折行啊
PHP中文网
PHP中文网 2017-04-17 17:36:21
0
1
558

两行文字是用两个TextView还是用一个TextView然后文字折行啊
是不是尽量少增加控件比较好

PHP中文网
PHP中文网

认证0级讲师

reply all(1)
小葫芦

Look at the layout, for example, if you just print multiple lines of logs, a TextView.
If you want a more flexible or complex layout, just use two TextViews for easy operation.

If it is just for a simple control like TextView, there is no difference in performance between one and two. Most of the optimizations are aimed at the order of magnitude difference. Complex controls, data and layouts are cached so they load more smoothly.

Of course, controlling the number of controls is also an art. Finding performance bottlenecks based on the actual situation is more targeted. When the user experience is acceptable, of course maintenance and other aspects must also be considered. . .

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template