static IControl Align(IControl self, TextAlignment alignment)
        {
            switch (alignment)
            {
            case TextAlignment.Left:
                return(self.Dock(RectangleEdge.Left));

            case TextAlignment.Right:
                return(self.Dock(RectangleEdge.Right));

            default:
                return(self.CenterHorizontally());
            }
        }
Exemple #2
0
 public static IControl DockTopLeft(this IControl dockedControl)
 {
     return(dockedControl.Dock(RectangleEdge.Left).Dock(RectangleEdge.Top));
 }
Exemple #3
0
 public static IControl DockTop(this IControl dockedControl, IControl fill = null)
 {
     return(dockedControl.Dock(RectangleEdge.Top, fill));
 }
Exemple #4
0
 public static IControl DockBottom(this IControl dockedControl, IControl fill = null)
 {
     return(dockedControl.Dock(RectangleEdge.Bottom, fill));
 }
Exemple #5
0
 public static IControl DockRight(this IControl dockedControl, IControl fill = null)
 {
     return(dockedControl.Dock(RectangleEdge.Right, fill));
 }
Exemple #6
0
 public static IControl DockBottomRight(this IControl dockedControl)
 {
     return(dockedControl.Dock(RectangleEdge.Right).Dock(RectangleEdge.Bottom));
 }