<legend id='zLNwU'><style id='zLNwU'><dir id='zLNwU'><q id='zLNwU'></q></dir></style></legend>
  • <tfoot id='zLNwU'></tfoot>

      <small id='zLNwU'></small><noframes id='zLNwU'>

          <bdo id='zLNwU'></bdo><ul id='zLNwU'></ul>
      1. <i id='zLNwU'><tr id='zLNwU'><dt id='zLNwU'><q id='zLNwU'><span id='zLNwU'><b id='zLNwU'><form id='zLNwU'><ins id='zLNwU'></ins><ul id='zLNwU'></ul><sub id='zLNwU'></sub></form><legend id='zLNwU'></legend><bdo id='zLNwU'><pre id='zLNwU'><center id='zLNwU'></center></pre></bdo></b><th id='zLNwU'></th></span></q></dt></tr></i><div id='zLNwU'><tfoot id='zLNwU'></tfoot><dl id='zLNwU'><fieldset id='zLNwU'></fieldset></dl></div>

        colorWithPatternImage 与.UIImageView

        colorWithPatternImage Vs. UIImageView(colorWithPatternImage 与.UIImageView)

          <tbody id='nVw3A'></tbody>
        • <tfoot id='nVw3A'></tfoot>
          <legend id='nVw3A'><style id='nVw3A'><dir id='nVw3A'><q id='nVw3A'></q></dir></style></legend>

          1. <i id='nVw3A'><tr id='nVw3A'><dt id='nVw3A'><q id='nVw3A'><span id='nVw3A'><b id='nVw3A'><form id='nVw3A'><ins id='nVw3A'></ins><ul id='nVw3A'></ul><sub id='nVw3A'></sub></form><legend id='nVw3A'></legend><bdo id='nVw3A'><pre id='nVw3A'><center id='nVw3A'></center></pre></bdo></b><th id='nVw3A'></th></span></q></dt></tr></i><div id='nVw3A'><tfoot id='nVw3A'></tfoot><dl id='nVw3A'><fieldset id='nVw3A'></fieldset></dl></div>

            <small id='nVw3A'></small><noframes id='nVw3A'>

              <bdo id='nVw3A'></bdo><ul id='nVw3A'></ul>

                • 本文介绍了colorWithPatternImage 与.UIImageView的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

                  问题描述

                  如果我只是想要 UIView 的背景图像,使用哪个更好?我可以使用任何一种方法来完成此操作,但哪种方法更有效?我的直觉是使用 UIViewcolorWithPaternImage 比使用 UIImageView 更有效.我将对 UITableView 中的每一行使用它.谢谢!马特

                  Which is better to use if I simply want a background image for a UIView? I can accomplish this with either method, but which is more efficient? My hunch is that using a UIView with colorWithPaternImage is more efficient than using a UIImageView. I'll be using this for each row in a UITableView. Thanks! Matt

                  推荐答案

                  完全不同意boreas.根据您的要求,使用 colorWithPatternImage 与其他策略可能会有显着差异.例如,如果您使用 UIScrollView,则使用 colorWithPatternImage 将不允许图像滚动.它通常还取决于您的视图有多大,因为对于不同的平铺策略,性能与内存占用之间存在一些权衡.

                  Completely disagree with boreas. There can be significant differences using colorWithPatternImage vs other strategies depending on your requirements. For example, if you are using a UIScrollView, using colorWithPatternImage won't allow the image to scroll. It also generally depends on how large your view is because there is some tradeoff in performance vs memory footprint for different tiling strategies.

                  查看 WWDC 2010 会议 104,其中讨论了平铺使用 CATiledLayer 的性能.这是使用内置 colorWithPatternImageCGContextDrawTiledImage 的一个很好的高性能替代方案.

                  Check out WWDC 2010 session 104 which discusses tiling performance using CATiledLayer. This is a good high-performance alternative to using either the built-in colorWithPatternImage or CGContextDrawTiledImage.

                  如果您的要求只是显示单个 320x480 静态图像,那么各种策略不会有任何显着差异,但如果您的要求更复杂,那么肯定会有.

                  If your requirement is simply to display a single 320x480 static image, then there won't be any significant differences in the various strategies, but if your requirements are more complex then there certainly are.

                  这篇关于colorWithPatternImage 与.UIImageView的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

                  本站部分内容来源互联网,如果有图片或者内容侵犯了您的权益,请联系我们,我们会在确认后第一时间进行删除!

                  相关文档推荐

                  what#39;s property copy means in Cocoa#39;s Framework?(like UITabBar#39;s items property)(Cocoa 框架中的属性副本是什么意思?(如 UITabBar 的 items 属性))
                  WebKit on th iPhone: is it possible to copy text to the clipboad with JavaScript(iPhone上的WebKit:是否可以使用JavaScript将文本复制到剪贴板)
                  Difference between retain and copy?(保留和复制的区别?)
                  When compiling for multiple targets in XCode, how do i ensure that certain files will not be included one target(在 XCode 中为多个目标编译时,我如何确保某些文件不会包含在一个目标中)
                  Automatically copy property values from one object to another of a different type but the same protocol (Objective-C)(自动将属性值从一个对象复制到另一个类型不同但协议相同的对象 (Objective-C))
                  Selecting text in mobile Safari on iPhone(在 iPhone 上的移动 Safari 中选择文本)
                    <tbody id='g8CkN'></tbody>
                    <bdo id='g8CkN'></bdo><ul id='g8CkN'></ul>

                  • <legend id='g8CkN'><style id='g8CkN'><dir id='g8CkN'><q id='g8CkN'></q></dir></style></legend>

                      1. <tfoot id='g8CkN'></tfoot>

                        <small id='g8CkN'></small><noframes id='g8CkN'>

                            <i id='g8CkN'><tr id='g8CkN'><dt id='g8CkN'><q id='g8CkN'><span id='g8CkN'><b id='g8CkN'><form id='g8CkN'><ins id='g8CkN'></ins><ul id='g8CkN'></ul><sub id='g8CkN'></sub></form><legend id='g8CkN'></legend><bdo id='g8CkN'><pre id='g8CkN'><center id='g8CkN'></center></pre></bdo></b><th id='g8CkN'></th></span></q></dt></tr></i><div id='g8CkN'><tfoot id='g8CkN'></tfoot><dl id='g8CkN'><fieldset id='g8CkN'></fieldset></dl></div>