This article describes functionality and guidance that is in public preview and may be substantially modified before it's generally available. Microsoft makes no warranties, express or implied, with respect to the information provided here.
TabLayout is a customized TabLayout. When the application is spanned across displays on a device with a vertical folding feature, the
displayPosition parameter can be used to make the widget render on the left, right or above the folding feature.
Returns or sets a value that specifies on which screen the view will render. Can be one of the three values:
These are explained in detail below.
The same can be obtained using the
<com.microsoft.device.dualscreen.tabs.TabLayout android:id="@+id/tab_layout" android:layout_width="match_parent" android:layout_height="wrap_content" tool:tools_application_mode="dual_screen" ... app:display_position="start" />
When the application is spanned over the folding feature and the component has an odd number of buttons, the middle one could be obstructed by the hinge or fold. One way to avoid this is to arrange the buttons differently on each side of the folding feature:
This can be accomplished with the
When the application is spanned and there are no buttons on a screen, the background on that screen can be made transparent:
If set to true, the displayPosition can be set to
DisplayPosition.END with a fling gesture on the component.
The same can be obtained using the 'app:allowFlingGesture` attribute: