cross-platform-generator
All Data Structures Namespaces Functions Variables Enumerations Enumerator Properties Events
Public Member Functions | Protected Member Functions | Properties | Private Attributes
cpg.ListItemAdorner Class Reference

Adorner used to display a textbox over a listitem allowing the listitem value to be changed. More...

Inheritance diagram for cpg.ListItemAdorner:

Public Member Functions

 ListItemAdorner (UIElement adorned_element, int item_index, TextBox box)
 Constructor for the adorner. More...
 
int GetItemIndex ()
 pupblic accessor to the item index of list item that is adorned More...
 

Protected Member Functions

override Visual GetVisualChild (int index)
 overwritten method to retrieve the textbox by child index. More...
 
override Size MeasureOverride (Size constraint)
 Calculates the required space for this adorner based on the maximum constraints. More...
 
override Size ArrangeOverride (Size final_size)
 Arranges the textbox to the correct possition. More...
 

Properties

override int VisualChildrenCount [get]
 Inherited property used to retrieve the amount of visual children in this adorner.
 
TextBox text_box [get, private set]
 property used to retrieve the texbox of this adorner. More...
 

Private Attributes

TextBox text_box_
 The textbox to display over the adorned list item.
 
int item_index_
 The index of the adorned list item in the list.
 

Detailed Description

Adorner used to display a textbox over a listitem allowing the listitem value to be changed.

Author
Stan Pepels

Constructor & Destructor Documentation

◆ ListItemAdorner()

cpg.ListItemAdorner.ListItemAdorner ( UIElement  adorned_element,
int  item_index,
TextBox  box 
)
inline

Constructor for the adorner.

Parameters
[in]adorned_element(UIElement) The element to display the textbox over.
[in]item_index(int) The index into the list of the item that is adorned.
[in]box(TextBox) The textbox to display over the list item. this textbox should be setup before calling the constructor.

Member Function Documentation

◆ ArrangeOverride()

override Size cpg.ListItemAdorner.ArrangeOverride ( Size  final_size)
inlineprotected

Arranges the textbox to the correct possition.

Parameters
[in]final_size(Size) The size the textbox will be displayed as
Returns
(Size) The actual size of the textbox on screen.

◆ GetItemIndex()

int cpg.ListItemAdorner.GetItemIndex ( )
inline

pupblic accessor to the item index of list item that is adorned

Returns
(int) The index of the item into the list.

◆ GetVisualChild()

override Visual cpg.ListItemAdorner.GetVisualChild ( int  index)
inlineprotected

overwritten method to retrieve the textbox by child index.

Parameters
[in]index(int) The child to retrieve
Returns
(Visual) The child at the given index. if the index is out of bounds the returned value will be null

◆ MeasureOverride()

override Size cpg.ListItemAdorner.MeasureOverride ( Size  constraint)
inlineprotected

Calculates the required space for this adorner based on the maximum constraints.

Parameters
[in]constraint(Size) The maximum bounds the textbox can span
Returns
(Size) The size the textbox should be.

Property Documentation

◆ text_box

TextBox cpg.ListItemAdorner.text_box
getprivate set

property used to retrieve the texbox of this adorner.

Remarks
when this property is set a null check is performend and visual children will be removed / added

The documentation for this class was generated from the following file: