C# Class Eto.Forms.TableLayout

Inheritance: Eto.Forms.Layout
Afficher le fichier Open project: picoe/Eto Class Usage Examples

Private Properties

Свойство Type Description
Create void
InnerAdd void
InternalRemoveLogicalParent void
InternalSetLogicalParent void
OnDeserialized void
OnDeserialized void
SetCellSize void

Méthodes publiques

Méthode Description
Add ( Control control, Point location ) : void

Adds a control to the specified location.

If a control already exists in the location, it is replaced. Only one control can exist in a cell.

Add ( Control control, int x, int y ) : void

Adds a control to the specified x & y coordinates.

If a control already exists in the location, it is replaced. Only one control can exist in a cell.

Add ( Control control, int x, int y, bool xscale, bool yscale ) : void

Adds a control to the specified x & y coordinates.

If a control already exists in the location, it is replaced. Only one control can exist in a cell. The xscale and yscale parameters are to easily set the scaling for the current row/column while adding the control.

AutoSized ( Control control, Padding padding = null, bool centered = false ) : TableLayout

Creates a table layout with an auto sized control.

Since controls fill an entire cell, you can use this method to create a layout that will ensure that the specified control gets its preferred size instead of stretching to fill the container. By default, extra space will be added to the right and bottom, unless centered is true, which will add equal space to the top/bottom, and left/right.

EndInit ( ) : void

Ends the initialization when loading from xaml or other code generated scenarios

GetColumnScale ( int column ) : bool

Gets the scale for the specified column.

GetRowScale ( int row ) : bool

Gets the scale for the specified row.

Horizontal ( ) : TableLayout

Creates a horizontal table layout with the specified cells.

Since table layouts are by default vertical by defining the rows and the cells for each row, it is verbose to create nested tables when you want a horizontal table. E.g. new TableLayout(new TableRow(...)). This method is used to easily create a single row table layout with a horizontal set of cells. E.g. TableLayout.Horizontal(...)

Horizontal ( int spacing ) : TableLayout

Creates a horizontal table layout with the specified cells.

Since table layouts are by default vertical by defining the rows and the cells for each row, it is verbose to create nested tables when you want a horizontal table. E.g. new TableLayout(new TableRow(...)). This method is used to easily create a single row table layout with a horizontal set of cells. E.g. TableLayout.Horizontal(...)

HorizontalScaled ( ) : TableLayout

Creates a horizontal table layout with the specified cells scaled equally.

Since table layouts are by default vertical by defining the rows and the cells for each row, it is verbose to create nested tables when you want a horizontal table. E.g. new TableLayout(new TableRow(...)). This method is used to easily create a single row table layout with a horizontal set of cells. E.g. TableLayout.HorizontalScaled(...) The difference between Horizontal and HorizontalScaled is that this method sets ScaleWidth on each cell.

HorizontalScaled ( int spacing ) : TableLayout

Creates a horizontal table layout with the specified cells scaled equally.

Since table layouts are by default vertical by defining the rows and the cells for each row, it is verbose to create nested tables when you want a horizontal table. E.g. new TableLayout(new TableRow(...)). This method is used to easily create a single row table layout with a horizontal set of cells. E.g. TableLayout.HorizontalScaled(...) The difference between Horizontal and HorizontalScaled is that this method sets ScaleWidth on each cell.

Move ( Control control, Point location ) : void

Move the specified control to a new location.

If a control already exists in the new location, it will be replaced. Only one control can exist in a cell. The old location of the control will have an empty space.

Move ( Control control, int x, int y ) : void

Moves the specified control to the new x and y coordinates.

If a control already exists in the new location, it will be replaced. Only one control can exist in a cell. The old location of the control will have an empty space.

Remove ( Control child ) : void

Remove the specified child control.

SetColumnScale ( int column, bool scale = true ) : void

Sets the scale for the specified column.

SetRowScale ( int row, bool scale = true ) : void

Sets the scale for the specified row.

TableLayout ( ) : System

Initializes a new instance of the Eto.Forms.TableLayout class.

TableLayout ( IEnumerable rows ) : System

Initializes a new instance of the Eto.Forms.TableLayout class with the specified rows.

TableLayout ( Eto.Drawing.Size dimensions ) : System

Initializes a new instance of the Eto.Forms.TableLayout class with the specified dimensions.

TableLayout ( bool yscale ) : System

Initializes a new instance of the Eto.Forms.TableLayout class with the specified rows.

TableLayout ( int columns, int rows ) : System

Initializes a new instance of the Eto.Forms.TableLayout class with the specified number of columns and rows.

Méthodes protégées

Méthode Description
OnLoad ( EventArgs e ) : void

Raises the Control.Load event, and recursed to this container's children

OnPreLoad ( EventArgs e ) : void

Raises the Control.PreLoad event, and recurses to this container's children

Private Methods

Méthode Description
Create ( ) : void
InnerAdd ( Control control, int x, int y ) : void
InternalRemoveLogicalParent ( Control control ) : void
InternalSetLogicalParent ( Control control ) : void
OnDeserialized ( StreamingContext context ) : void
OnDeserialized ( bool direct ) : void
SetCellSize ( Eto.Drawing.Size value, bool createRows ) : void

Method Details

Add() public méthode

Adds a control to the specified location.
If a control already exists in the location, it is replaced. Only one control can exist in a cell.
public Add ( Control control, Point location ) : void
control Control Control to add.
location Point The location of the control.
Résultat void

Add() public méthode

Adds a control to the specified x & y coordinates.
If a control already exists in the location, it is replaced. Only one control can exist in a cell.
public Add ( Control control, int x, int y ) : void
control Control Control to add.
x int The x coordinate.
y int The y coordinate.
Résultat void

Add() public méthode

Adds a control to the specified x & y coordinates.
If a control already exists in the location, it is replaced. Only one control can exist in a cell. The xscale and yscale parameters are to easily set the scaling for the current row/column while adding the control.
public Add ( Control control, int x, int y, bool xscale, bool yscale ) : void
control Control Control to add.
x int The x coordinate.
y int The y coordinate.
xscale bool If set to true xscale.
yscale bool If set to true yscale.
Résultat void

AutoSized() public static méthode

Creates a table layout with an auto sized control.
Since controls fill an entire cell, you can use this method to create a layout that will ensure that the specified control gets its preferred size instead of stretching to fill the container. By default, extra space will be added to the right and bottom, unless centered is true, which will add equal space to the top/bottom, and left/right.
public static AutoSized ( Control control, Padding padding = null, bool centered = false ) : TableLayout
control Control Control to auto size.
padding Padding Padding around the control
centered bool If set to true center the control, otherwise control is upper left of the container.
Résultat TableLayout

EndInit() public méthode

Ends the initialization when loading from xaml or other code generated scenarios
public EndInit ( ) : void
Résultat void

GetColumnScale() public méthode

Gets the scale for the specified column.
public GetColumnScale ( int column ) : bool
column int Column to retrieve the scale.
Résultat bool

GetRowScale() public méthode

Gets the scale for the specified row.
public GetRowScale ( int row ) : bool
row int Row to retrieve the scale.
Résultat bool

Horizontal() public static méthode

Creates a horizontal table layout with the specified cells.
Since table layouts are by default vertical by defining the rows and the cells for each row, it is verbose to create nested tables when you want a horizontal table. E.g. new TableLayout(new TableRow(...)). This method is used to easily create a single row table layout with a horizontal set of cells. E.g. TableLayout.Horizontal(...)
public static Horizontal ( ) : TableLayout
Résultat TableLayout

Horizontal() public static méthode

Creates a horizontal table layout with the specified cells.
Since table layouts are by default vertical by defining the rows and the cells for each row, it is verbose to create nested tables when you want a horizontal table. E.g. new TableLayout(new TableRow(...)). This method is used to easily create a single row table layout with a horizontal set of cells. E.g. TableLayout.Horizontal(...)
public static Horizontal ( int spacing ) : TableLayout
spacing int Spacing between cells
Résultat TableLayout

HorizontalScaled() public static méthode

Creates a horizontal table layout with the specified cells scaled equally.
Since table layouts are by default vertical by defining the rows and the cells for each row, it is verbose to create nested tables when you want a horizontal table. E.g. new TableLayout(new TableRow(...)). This method is used to easily create a single row table layout with a horizontal set of cells. E.g. TableLayout.HorizontalScaled(...) The difference between Horizontal and HorizontalScaled is that this method sets ScaleWidth on each cell.
public static HorizontalScaled ( ) : TableLayout
Résultat TableLayout

HorizontalScaled() public static méthode

Creates a horizontal table layout with the specified cells scaled equally.
Since table layouts are by default vertical by defining the rows and the cells for each row, it is verbose to create nested tables when you want a horizontal table. E.g. new TableLayout(new TableRow(...)). This method is used to easily create a single row table layout with a horizontal set of cells. E.g. TableLayout.HorizontalScaled(...) The difference between Horizontal and HorizontalScaled is that this method sets ScaleWidth on each cell.
public static HorizontalScaled ( int spacing ) : TableLayout
spacing int Spacing between cells
Résultat TableLayout

Move() public méthode

Move the specified control to a new location.
If a control already exists in the new location, it will be replaced. Only one control can exist in a cell. The old location of the control will have an empty space.
public Move ( Control control, Point location ) : void
control Control Control to move.
location Point New location of the control.
Résultat void

Move() public méthode

Moves the specified control to the new x and y coordinates.
If a control already exists in the new location, it will be replaced. Only one control can exist in a cell. The old location of the control will have an empty space.
public Move ( Control control, int x, int y ) : void
control Control Control to move.
x int The new x coordinate.
y int The new y coordinate.
Résultat void

OnLoad() protected méthode

Raises the Control.Load event, and recursed to this container's children
protected OnLoad ( EventArgs e ) : void
e System.EventArgs Event arguments
Résultat void

OnPreLoad() protected méthode

Raises the Control.PreLoad event, and recurses to this container's children
protected OnPreLoad ( EventArgs e ) : void
e System.EventArgs Event arguments
Résultat void

Remove() public méthode

Remove the specified child control.
public Remove ( Control child ) : void
child Control Child control to remove.
Résultat void

SetColumnScale() public méthode

Sets the scale for the specified column.
public SetColumnScale ( int column, bool scale = true ) : void
column int Column to set the scale for.
scale bool If set to true scale, otherwise size to preferred size of controls in the column.
Résultat void

SetRowScale() public méthode

Sets the scale for the specified row.
public SetRowScale ( int row, bool scale = true ) : void
row int Row to set the scale for.
scale bool If set to true scale, otherwise size to preferred size of controls in the row.
Résultat void

TableLayout() public méthode

Initializes a new instance of the Eto.Forms.TableLayout class.
public TableLayout ( ) : System
Résultat System

TableLayout() public méthode

Initializes a new instance of the Eto.Forms.TableLayout class with the specified rows.
public TableLayout ( IEnumerable rows ) : System
rows IEnumerable Rows to populate the table.
Résultat System

TableLayout() public méthode

Initializes a new instance of the Eto.Forms.TableLayout class with the specified dimensions.
public TableLayout ( Eto.Drawing.Size dimensions ) : System
dimensions Eto.Drawing.Size Dimensions of the table.
Résultat System

TableLayout() public méthode

Initializes a new instance of the Eto.Forms.TableLayout class with the specified rows.
public TableLayout ( bool yscale ) : System
yscale bool Scale all rows
Résultat System

TableLayout() public méthode

Initializes a new instance of the Eto.Forms.TableLayout class with the specified number of columns and rows.
public TableLayout ( int columns, int rows ) : System
columns int Number of columns in the table.
rows int Number of rows in the table.
Résultat System