C# Класс ICSharpCode.WpfDesign.Designer.ModelTools

Static helper methods for working with the designer DOM.
Показать файл Открыть проект Примеры использования класса

Открытые методы

Метод Описание
ApplyTransform ( DesignItem designItem, Transform transform, bool relative = true ) : void
ArrangeItems ( IEnumerable items, ArrangeDirection arrangeDirection ) : void
CanDeleteComponents ( ICollection items ) : bool

Gets if the specified components can be deleted.

CanSelectComponent ( DesignItem item ) : bool
ComparePositionInModelFile ( DesignItem a, DesignItem b ) : int

Compares the positions of a and b in the model file.

CreateVisualTree ( this element ) : void
DeleteComponents ( ICollection deleteItems ) : void

Deletes the specified components from their parent containers. If the deleted components are currently selected, they are deselected before they are deleted.

GetHeight ( UIElement element ) : double
GetWidth ( UIElement element ) : double
IsInDocument ( DesignItem item ) : bool

Gets if the specified design item is in the document it belongs to.

Resize ( DesignItem item, double newWidth, double newHeight ) : void
StretchItems ( IEnumerable items, StretchDirection stretchDirection ) : void
WrapItemsNewContainer ( IEnumerable items, Type containerType, bool doInsert = true ) : Rect>.Tuple

Приватные методы

Метод Описание
GetDefaultSize ( DesignItem createdItem ) : Size
GetItemPos ( PlacementOperation operation, DesignItem designItem ) : ItemPos

Описание методов

ApplyTransform() публичный статический Метод

public static ApplyTransform ( DesignItem designItem, Transform transform, bool relative = true ) : void
designItem DesignItem
transform System.Windows.Media.Transform
relative bool
Результат void

ArrangeItems() публичный статический Метод

public static ArrangeItems ( IEnumerable items, ArrangeDirection arrangeDirection ) : void
items IEnumerable
arrangeDirection ArrangeDirection
Результат void

CanDeleteComponents() публичный статический Метод

Gets if the specified components can be deleted.
public static CanDeleteComponents ( ICollection items ) : bool
items ICollection
Результат bool

CanSelectComponent() публичный статический Метод

public static CanSelectComponent ( DesignItem item ) : bool
item DesignItem
Результат bool

ComparePositionInModelFile() публичный статический Метод

Compares the positions of a and b in the model file.
public static ComparePositionInModelFile ( DesignItem a, DesignItem b ) : int
a DesignItem
b DesignItem
Результат int

CreateVisualTree() публичный статический Метод

public static CreateVisualTree ( this element ) : void
element this
Результат void

DeleteComponents() публичный статический Метод

Deletes the specified components from their parent containers. If the deleted components are currently selected, they are deselected before they are deleted.
public static DeleteComponents ( ICollection deleteItems ) : void
deleteItems ICollection
Результат void

GetHeight() публичный статический Метод

public static GetHeight ( UIElement element ) : double
element UIElement
Результат double

GetWidth() публичный статический Метод

public static GetWidth ( UIElement element ) : double
element UIElement
Результат double

IsInDocument() публичный статический Метод

Gets if the specified design item is in the document it belongs to.
public static IsInDocument ( DesignItem item ) : bool
item DesignItem
Результат bool

Resize() публичный статический Метод

public static Resize ( DesignItem item, double newWidth, double newHeight ) : void
item DesignItem
newWidth double
newHeight double
Результат void

StretchItems() публичный статический Метод

public static StretchItems ( IEnumerable items, StretchDirection stretchDirection ) : void
items IEnumerable
stretchDirection StretchDirection
Результат void

WrapItemsNewContainer() публичный статический Метод

public static WrapItemsNewContainer ( IEnumerable items, Type containerType, bool doInsert = true ) : Rect>.Tuple
items IEnumerable
containerType System.Type
doInsert bool
Результат Rect>.Tuple