Xcode 7 what is the view “semantic” storyboard setting?

血红的双手。 提交于 2019-11-30 04:16:00

There is a new internationalization support in iOS 9, which enables flipping of the interface from left to right and vice versa depending on the current system language. You can choose Arabic language to test it. Arabic is read from right to left, so the interface is flipped.

Here you can read the Apple's guide on it.

The property "Semantic" in the storyboard is a rule which allows the iOS to know if the view should be flipped or not. There are multiple options:

  • Unspecified - The default value for views. The view is flipped when switching between left-to-right and right-to-left layouts.
  • Playback - A view representing the playback controls, such as Play, Rewind, or Fast Forward buttons or playhead scrubbers. These views are not flipped when switching between left-to-right and right-to-left layouts.
  • Spatial - A view representing a directional control, for example a segment control for text alignment, or a D-pad control for a game. These views are not flipped when switching between left-to-right and right-to-left layouts.
  • Force Left-To-Right - A view that is always displayed using a left-to-right layout.
  • Force Right-To-Left - A view that is always displayed using a right-to-left layout.

Source - Apple's documentation

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!