C# Класс SIL.FieldWorks.Common.Controls.LabelNode

This override to TreeNode handles the displaying of an ObjectLabel in a custom way
Наследование: System.Windows.Forms.TreeNode
Показать файл Открыть проект Примеры использования класса

Защищенные свойства (Protected)

Свойство Тип Описание
m_stylesheet IVwStylesheet

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

Метод Описание
AddChildren ( bool recursively, IEnumerable chosenObjs ) : void

Add the children nodes of a particular node in the tree. Do this recursively if that parameter is set to true. Also set the node as Checked if is it in the set or chosenObjs.

AddChildrenAndLookForSelected ( ICmObject objToSelect, Stack ownershipStack, IEnumerable chosenObjs ) : LabelNode

Add the children nodes of a particular node in the tree. While adding nodes if a match is found for objToSelect then nodeRepresentingCurrentChoice assigned to it and is returned. Otherwise if no node in the tree matches objToSelect this method returns null.

AddSecondaryNodes ( LabelNode node, TreeNodeCollection nodes, IEnumerable chosenObjs ) : void

Adds the secondary nodes.

AddSecondaryNodesAndLookForSelected ( LabelNode node, TreeNodeCollection nodes, LabelNode nodeRepresentingCurrentChoice, ICmObject objToSelect, Stack ownershipStack, IEnumerable chosenObjs ) : LabelNode

Add secondary nodes to tree at nodes (and check any that occur in rghvoChosen), and return the one whose hvo is hvoToSelect, or nodeRepresentingCurrentChoice if none match.

LabelNode ( ObjectLabel label, IVwStylesheet stylesheet, bool displayUsage ) : System.Collections.Generic

Initializes a new instance of the LabelNode class.

ResetVernacularFont ( ILgWritingSystemFactory wsf, int wsVern, IVwStylesheet stylesheet ) : void

Resets the vernacular font.

WantNodeForLabel ( ObjectLabel label ) : bool

Wants the node for label.

Защищенные методы

Метод Описание
CheckForSelection ( ObjectLabel label, ICmObject objToSelect, LabelNode node, LabelNode nodeRepresentingCurrentChoice ) : LabelNode

Checks for selection.

CountUsages ( ) : int

Count how many references this item has. Virtual so a subclass can use a different algorithm (c.f. SemanticDomainsChooser's DomainNode).

Create ( ObjectLabel nol, IVwStylesheet stylesheet, bool displayUsage ) : LabelNode

Creates the specified LabelNode from the ObjectLabel.

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

Метод Описание
GetVernacularFont ( ILgWritingSystemFactory wsf, int wsVern, IVwStylesheet stylesheet ) : Font
HasVernacularText ( ITsString tss, IEnumerable vernWses, int &wsVern ) : bool
SetNodeText ( ) : void

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

AddChildren() публичный Метод

Add the children nodes of a particular node in the tree. Do this recursively if that parameter is set to true. Also set the node as Checked if is it in the set or chosenObjs.
public AddChildren ( bool recursively, IEnumerable chosenObjs ) : void
recursively bool
chosenObjs IEnumerable
Результат void

AddChildrenAndLookForSelected() публичный Метод

Add the children nodes of a particular node in the tree. While adding nodes if a match is found for objToSelect then nodeRepresentingCurrentChoice assigned to it and is returned. Otherwise if no node in the tree matches objToSelect this method returns null.
public AddChildrenAndLookForSelected ( ICmObject objToSelect, Stack ownershipStack, IEnumerable chosenObjs ) : LabelNode
objToSelect ICmObject
ownershipStack Stack
chosenObjs IEnumerable
Результат LabelNode

AddSecondaryNodes() публичный Метод

Adds the secondary nodes.
public AddSecondaryNodes ( LabelNode node, TreeNodeCollection nodes, IEnumerable chosenObjs ) : void
node LabelNode The node.
nodes System.Windows.Forms.TreeNodeCollection The nodes.
chosenObjs IEnumerable The chosen objects.
Результат void

AddSecondaryNodesAndLookForSelected() публичный Метод

Add secondary nodes to tree at nodes (and check any that occur in rghvoChosen), and return the one whose hvo is hvoToSelect, or nodeRepresentingCurrentChoice if none match.
public AddSecondaryNodesAndLookForSelected ( LabelNode node, TreeNodeCollection nodes, LabelNode nodeRepresentingCurrentChoice, ICmObject objToSelect, Stack ownershipStack, IEnumerable chosenObjs ) : LabelNode
node LabelNode node to be added
nodes System.Windows.Forms.TreeNodeCollection where to add it
nodeRepresentingCurrentChoice LabelNode The node representing current choice.
objToSelect ICmObject The obj to select.
ownershipStack Stack The ownership stack.
chosenObjs IEnumerable The chosen objects.
Результат LabelNode

CheckForSelection() защищенный Метод

Checks for selection.
protected CheckForSelection ( ObjectLabel label, ICmObject objToSelect, LabelNode node, LabelNode nodeRepresentingCurrentChoice ) : LabelNode
label ObjectLabel The label.
objToSelect ICmObject The obj to select.
node LabelNode The node.
nodeRepresentingCurrentChoice LabelNode The node representing current choice.
Результат LabelNode

CountUsages() защищенный Метод

Count how many references this item has. Virtual so a subclass can use a different algorithm (c.f. SemanticDomainsChooser's DomainNode).
protected CountUsages ( ) : int
Результат int

Create() защищенный Метод

Creates the specified LabelNode from the ObjectLabel.
protected Create ( ObjectLabel nol, IVwStylesheet stylesheet, bool displayUsage ) : LabelNode
nol ObjectLabel
stylesheet IVwStylesheet
displayUsage bool true if usage statistics will be displayed; otherwise, false.
Результат LabelNode

LabelNode() публичный Метод

Initializes a new instance of the LabelNode class.
public LabelNode ( ObjectLabel label, IVwStylesheet stylesheet, bool displayUsage ) : System.Collections.Generic
label ObjectLabel The label.
stylesheet IVwStylesheet The stylesheet.
displayUsage bool true if usage statistics will be displayed; otherwise, false.
Результат System.Collections.Generic

ResetVernacularFont() публичный Метод

Resets the vernacular font.
public ResetVernacularFont ( ILgWritingSystemFactory wsf, int wsVern, IVwStylesheet stylesheet ) : void
wsf ILgWritingSystemFactory The WSF.
wsVern int The ws vern.
stylesheet IVwStylesheet The stylesheet.
Результат void

WantNodeForLabel() публичный Метод

Wants the node for label.
public WantNodeForLabel ( ObjectLabel label ) : bool
label ObjectLabel The label.
Результат bool

Описание свойств

m_stylesheet защищенное свойство

protected IVwStylesheet m_stylesheet
Результат IVwStylesheet