UIProgressView:如何获取旧样式?
我正在寻找 UIProgressView 的旧样式:
替代文本 http://img.skitch。 com/20090620-dagnbt6eh2s884nfkbkqgne1re.jpg
我能够呈现的唯一 UIProgressViewStyle 是这样的:
替代文本 http://img.skitch.com/20090620-ewujnw3r62qnb91qpbdh8iktne.jpg
旧的还可用吗? 设置属性 UIProgressViewStyle
始终会导致蓝色的 UIProgressView。
I'm searching for the old style of the UIProgressView:
alt text http://img.skitch.com/20090620-dagnbt6eh2s884nfkbkqgne1re.jpg
The only UIProgressViewStyle, I'm able to present is this:
alt text http://img.skitch.com/20090620-ewujnw3r62qnb91qpbdh8iktne.jpg
Is the old one still available? Setting the property UIProgressViewStyle
always leads to the blue UIProgressView.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(4)
无论如何,访问旧式进度条的另一种方法是以通常的方式创建 UIProgressView 控件。 从 iOS 4.1 开始,您可以通过将进度视图的样式设置为未记录的值 100 来获得旧的外观。
这可以避免使用未记录的类,甚至调用未记录的方法。 然而,我确信苹果仍然不会批准.. ;-)
Dave
For what it'a worth, another way of accessing the old-style progress bar is to create a UIProgressView control in the usual way. As of iOS 4.1, you can get the old appearance by setting the progress view's style to the undocumented value of 100.
This avoids using an undocumented class, or even calling undocumented methods. However, I'm sure Apple still won't approve.. ;-)
Dave
我认为 UIProgressView 有两种样式。 默认值被引用为 UIProgressViewStyleDefault,而您所引用的默认值称为 UIProgressViewStyleBar。
这些设置如下
yourUIProgressView.ProgressViewStyle = UIProgressViewStyleBar;
或者
不设置任何默认值。
I think there are two styles for the UIProgressView. The default which is referenced as UIProgressViewStyleDefault, and the one you are referring to is called UIProgressViewStyleBar.
those are set as the following
yourUIProgressView.ProgressViewStyle = UIProgressViewStyleBar;
or
set nothing for the default.
她在 SDK 仍处于 NDA 状态、使用 IB 之前就写了这本书。 在那之后发生了很多很多的变化。
She wrote her book when the SDK was still NDA and before it used IB. Many, many changes occurred after that time.
它是UIProgressBar,UIProgressView 的私有子类。
你可以这样使用它,但Apple可能会拒绝你的应用程序:
It's UIProgressBar, a private subclass of UIProgressView.
You can use it in this way, but Apple might reject your app: