iphone:Progress-views
出自UXGuide.net
请帮助我们修订和更新本文的译文部分
本文的译文部分可能是由多个贡献者提供或从不同的渠道收集,未经过最终审阅和整理,请您帮助我们一起修订和更新本文的译文部分。
进度视图
Progress Views
A progress view shows the progress of a task or process that has a known duration. If you need to display progress for a task of unknown duration, use an activity indicator instead (see “Activity Indicators” for more information about this control).
一个进度视图显示了一个任务的进展,或者有一个已知持续时间的过程的进度。如果你需要显示一个未知时间的任务进度,请使用活动指示器(有关此控件的详细信息见“活动指示器”(第99 页))。
iPhone OS provides two styles of progress view, which are the default style and the bar style. The appearance of each style is very similar, except for height:
iPhone操作系统提供了两种风格的进度视图,这是默认样式和栏样式。除了高度外,每个风格的外观是非常相似的:
- The default style is intended for use in an application’s main content area.
- 默认风格是用于应用程序的主要内容区。
- The bar style is thinner than the default style, which makes it well-suited for use in a toolbar. For example, in Mail a bar-style progress view appears in the toolbar when users download new messages or send an email message.
- 栏风格比默认样式瘦小,因此栏风格更适合于在工具栏中使用。例如,在邮件中,当用户下载新的信息或发送电子邮件时,栏风格的进度视图就会出现在工具栏中。
The behavior of both styles of progress view is the same. As the task or process proceeds, the track of the progress view is filled from left to right. At any given time, the proportion of filled to unfilled area in the view gives the user an indication of how soon the task or process will finish. Figure 9-8 shows an example of a bar-style progress bar.
两种风格的进度视图在行为上是相同的。由于任务或进程的进行,进度视图的进度条从左到右逐渐填满。在任何特定时间,填充部分与未填充部分面积的比例给用户提供了一个要多长时间,任务或进程将结束的提示。图9-8显示了一个栏样式的进度视图。
Figure 9-8 A bar-style progress view in a toolbar
图9-8 工具栏中的一个栏样式进度视图
A progress view is a good way to provide feedback to users on tasks that have a well-defined duration, especially when it’s important to show users approximately how long the task will take. When you display a progress view, you tell the user that their task is being performed and you give them enough information to decide if they want to wait until the task is complete or cancel it.
对于那些有明确持续时间的任务,进度视图是给用户提供反馈的一种很好的办法,特别是当很有必要告知用户任务所需要的时间时。当你采用一个进度视图时,你告诉了用户任务正在执行,你给他们足够的信息来让他们决定是否要等到任务完成或取消任务。
To learn more about using a progress view in your code, see UIProgressView Class Reference.
要了解更多有关在你的代码中应用进度视图的信息,请参阅 UIProgressView 类型参考。