Table of Contents

Interface ISizer

Namespace
Alternet.UI
Assembly
Alternet.UI.dll

Provides methods and properties used for laying out sub-controls in a control.

public interface ISizer : IDisposableObject, IDisposable

Methods

Add(Control, ISizerFlags)

Appends a child to the sizer.

Add(Control, int, SizerFlag, int)

Appends a child to the sizer.

Add(ISizer, ISizerFlags)

Appends a child to the sizer.

Add(ISizer, int, SizerFlag, int)

Appends a child to the sizer.

Add(ISizerItem)

Adds sizer item.

Add(int, int, ISizerFlags)

Appends a spacer child to the sizer.

Add(int, int, int, SizerFlag, int)

Appends a spacer child to the sizer.

AddSpacer(int)

Adds non-stretchable space to the sizer.

AddStretchSpacer(int)

Adds stretchable space to the sizer.

AreAnyItemsShown()

Gets whether any items are shown.

CalcMin()

Does the actual calculation of children's minimal sizes.

Clear()

Detaches all children from the sizer.

ComputeFittingClientSize(Control)

Computes client area size for control so that it matches the sizer's minimal size.

ComputeFittingWindowSize(Control)

Like ComputeFittingClientSize(Control), but converts the result into control size.

Detach(Control)

Detaches the child control from the sizer without destroying it.

Detach(ISizer)

Detaches the child sizer from the sizer without destroying it.

Detach(int)

Detaches an item at the specified position from the sizer without destroying it.

Fit(Control)

Tells the sizer to resize the control so that its client area matches the sizer's minimal size (ComputeFittingClientSize(Control) is called to determine it).

FitInside(Control)

Tell the sizer to resize the virtual size of the control to match the sizer's minimal size.

GetItem(Control, bool)

Finds the ISizerItem which holds the given control.

GetItem(ISizer, bool)

Finds the ISizerItem which holds the given subsizer.

GetItem(int)

Gets item with the specified index.

GetItemById(int, bool)

Finds the ISizerItem with the specified id.

GetItemCount()

Gets number of added sizer items.

GetMinSize()

Gets the minimal size of the sizer.

GetPosition()

Gets the current position of the sizer.

GetSize()

Gets the current size of the sizer.

Hide(Control, bool)

Hides item with the attached control.

Hide(ISizer, bool)

Hides item with the attached sizer.

Hide(int)

Hides the item at the specified index.

InformFirstDirection(int, int, int)

Inform sizer about the first direction that has been decided (by parent item).

Insert(int, Control, ISizerFlags)

Insert a child into the sizer before any existing item at the specified index.

Insert(int, Control, int, SizerFlag, int)

Insert a child into the sizer before any existing item at the specified index.

Insert(int, ISizer, ISizerFlags)

Insert a child into the sizer before any existing item at the specified index.

Insert(int, ISizer, int, SizerFlag, int)

Insert a child into the sizer before any existing item at the specified index.

Insert(int, ISizerItem)

Inserts sizer item at the specified index.

Insert(int, int, int, ISizerFlags)

Insert a child into the sizer before any existing item at the specified index.

Insert(int, int, int, int, SizerFlag, int)

Insert a child into the sizer before any existing item at the specified index.

InsertSpacer(int, int)

Inserts non-stretchable space to the sizer.

InsertStretchSpacer(int, int)

Inserts stretchable space to the sizer.

IsEmpty()

Gets whether sizer is empty and there are no items added to it.

IsShown(Control)

Gets whether item with the attached control is shown.

IsShown(ISizer)

Gets whether item with the attached sizer is shown.

IsShown(int)

Gets whether item with the specified index is shown.

Layout()

Forces layout of the children anew, e.g. after having added a child to or removed a child (control, other sizer or space) from the sizer while keeping the current dimension.

Prepend(Control, ISizerFlags)

Same as adding of the item, but prepends the items to the beginning of the list of items owned by this sizer.

Prepend(Control, int, SizerFlag, int)

Same as adding of the item, but prepends the items to the beginning of the list of items owned by this sizer.

Prepend(ISizer, ISizerFlags)

Same as adding of the item, but prepends the items to the beginning of the list of items owned by this sizer.

Prepend(ISizer, int, SizerFlag, int)

Same as adding of the item, but prepends the items to the beginning of the list of items owned by this sizer.

Prepend(ISizerItem)

Inserts sizer item at the beginning of the items list.

Prepend(int, int, ISizerFlags)

Same as adding of the item, but prepends the items to the beginning of the list of items owned by this sizer.

Prepend(int, int, int, SizerFlag, int)

Same as adding of the item, but prepends the items to the beginning of the list of items owned by this sizer.

PrependSpacer(int)

Prepends non-stretchable space to the sizer.

PrependStretchSpacer(int)

Prepends stretchable space to the sizer.

RecalcSizes()

Recalculates sizes of the items. It is better to use Layout().

Remove(ISizer)

Removes a sizer child from the sizer and destroys it.

Remove(int)

Removes a child from the sizer and destroys it if it is a sizer or a spacer, but not if it is a control (because controls are owned by their parent control, not the sizer).

Replace(Control, Control, bool)

Detaches the given oldControl from the sizer and replaces it with the given newControl.

Replace(ISizer, ISizer, bool)

Detaches the given oldsz from the sizer and replaces it with the given newsz.

Replace(int, ISizerItem)

Replaces sizer item at the specified index.

SetDimension(int, int, int, int)

Call this to force the sizer to take the given dimension and thus force the items owned by the sizer to resize themselves according to the rules defined by its parameters.

SetItemMinSize(Control, int, int)

Set an item's minimum size by its control.

SetItemMinSize(ISizer, int, int)

Set an item's minimum size by its sizer.

SetItemMinSize(int, int, int)

Set an item's minimum size by its index.

SetMinSize(int, int)

Call this to give the sizer a minimal size.

SetSizeHints(Control)

This method first calls Fit(Control) and then SetSizeHints() on the control passed to it.

Show(Control, bool, bool)

Shows or hides item with the attached control.

Show(ISizer, bool, bool)

Shows or hides item with the attached sizer.

Show(bool)

Show or hide all items managed by the sizer.

Show(int, bool)

Shows the item at the specified index.

ShowItems(bool)

Show or hide all items managed by the sizer.