C# Class UniformGridForUWP.UniformGrid

Provides a way to arrange content in a grid where all the cells in the grid have the same size.
Inheritance: Windows.UI.Xaml.Controls.Panel
Afficher le fichier Open project: rickapps/UWP-UniformGrid-Control

Méthodes publiques

Свойство Type Description
ColumnsProperty Windows.UI.Xaml.DependencyProperty
FirstColumnProperty Windows.UI.Xaml.DependencyProperty
RowsProperty Windows.UI.Xaml.DependencyProperty

Méthodes publiques

Méthode Description
UniformGrid ( ) : System

Initializes a new instance of the UniformGrid.

Méthodes protégées

Méthode Description
ArrangeOverride ( Size finalSize ) : Size

Defines the layout of the System.Windows.Controls.Primitives.UniformGrid by distributing space evenly among all of the child elements.

Private Methods

Méthode Description
MeasureOverride ( Size constraint ) : Size
OnFirstColumnChanged ( DependencyObject d, DependencyPropertyChangedEventArgs e ) : void

Check that the offset is positive. This seems to be the only check in the WPF uniform grid. Might also make the offset be less than the number of items included in the grid.

OnRowsColumnsChanged ( DependencyObject d, DependencyPropertyChangedEventArgs e ) : void

Validity check on row or column. For now, just check that it is positive. This code could be much simplified.

UpdateComputedValues ( ) : void

If no row count or column count is specified, use the smallest square number that will contain all the items as our dimensions. Otherwise, calculate the number of rows or columns needed to contain all items.

Method Details

ArrangeOverride() protected méthode

Defines the layout of the System.Windows.Controls.Primitives.UniformGrid by distributing space evenly among all of the child elements.
protected ArrangeOverride ( Size finalSize ) : Size
finalSize Windows.Foundation.Size The System.Windows.Size of the area for the grid to use.
Résultat Windows.Foundation.Size

UniformGrid() public méthode

Initializes a new instance of the UniformGrid.
public UniformGrid ( ) : System
Résultat System

Property Details

ColumnsProperty public_oe static_oe property

public static DependencyProperty,Windows.UI.Xaml ColumnsProperty
Résultat Windows.UI.Xaml.DependencyProperty

FirstColumnProperty public_oe static_oe property

public static DependencyProperty,Windows.UI.Xaml FirstColumnProperty
Résultat Windows.UI.Xaml.DependencyProperty

RowsProperty public_oe static_oe property

public static DependencyProperty,Windows.UI.Xaml RowsProperty
Résultat Windows.UI.Xaml.DependencyProperty