The relative panels

Relative panels are useful when you have nested panels in your application UI, but not in a fashion that uses a proper linear pattern to define the layout. In this type of panel, the elements are arranged in relation to the other panels described by various attached properties.

By default, an element positions itself at the top-left corner of the panel, but you can reposition it by defining relative panel alignment. There are three types of relative alignment possible in UWP applications:

  • Panel alignment:
    • AlignLeftWithPanel
    • AlignTopWithPanel
    • AlignRightWithPanel
    • AlignBottomWithPanel
    • AlignHorizontalCenterWithPanel
    • AlignVerticalCenterWithPanel
  • Sibling alignment:
    • AlignLeftWith
    • AlignTopWith
    • AlignRightWith
    • AlignBottomWith ...

Get Mastering Visual Studio 2017 now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.