ColumnOptions class (Tree)

ColumnOptions()

new ColumnOptions()

The ColumnOptions type holds all options a Column can display or own.

Every option of the ColumnOptions type has associated a property of the Column object. For instance, the option:

cursor {string}, defines the mouse-cursor for individual column (column's header)
is associated with the property:
Cursor {string}, defines the mouse-cursor for individual column (column's header)
which means that the following statements are equivalent:
oColumn.Options = {cursor: "pointer"}
oColumn.SetOptions({cursor: "pointer"})
oColumn.Cursor = "pointer"
oColumn.SetCursor("pointer")
where oColumn is an object of Column type
ColumnOptions

Members

(static) allowDrag :boolean

The allowDrag field specifies whether the column is dragable.
Type:
  • boolean
Example
false {boolean}, the user can not drag the column
 true {boolean}, the column is dragable
allowDrag

(static) allowEdit :boolean

The allowEdit field specifies whether the column is editable or readonly. The values field specifies a list of predefined values that the user can choose from. The "edit" action requires to be included in the allowAction option.
Type:
  • boolean
Example
false {boolean}, specifies a readonly column
 true {boolean}, the cells within the column are editable (if "edit" action is allowed)
allowEdit

(static) allowGroupBy :boolean

The allowGroupBy field specifies whether the column can be grouped by.
Type:
  • boolean
Example
false {boolean}, the user can not group by this column
 true {boolean}, the column gets grouped-by once the column's header is dropped into the control's sortbar
allowGroupBy

(static) allowSizing :boolean

The allowSizing field indicates whether the column is resizable or fixed.
Type:
  • boolean
Example
false {boolean}, the user can not resize the column
 true {boolean}, the column is resizable
allowSizing

(static) allowSort :boolean

The allowSort field specifies whether the column is sortable.
Type:
  • boolean
Example
false {boolean}, the user can not sort the column
 true {boolean}, the column is sortable
allowSort

(static) caption :string

The caption field defines the column's caption.
Type:
  • string
Example
null {null}, indicates no caption
 "caption" {string}, declares a plain-caption
 "<b>text</b>" {string}, displays the text in bold
 "<img>logo</img>" {string}, displays the "logo" image. The image can be added using the exontrol.HTMLPicture.Add() method
caption

(static) cellCursor :string

The cellCursor field defines the cursor to show within the column's body/data/cells.
Type:
  • string
Example
"pointer" {string}, The cursor is a pointer that indicates a link (typically an image of a pointing hand)
cellCursor

(static) cellHasCheck :number

The cellHasCheck field specifies whether the cells within the column shows a check-box or radio-button. Defines whether the cell's check-box, radio-button is visible as follows:
  • 0 {number}, the column shows no check-box or radio-button
  • 1 {number}, the column displays a check-box for each cell.
  • 2 {number}, the column displays a radio-button for each cell (only a cell within the entire-column can be checked).
.
Type:
  • number
Example
0 {number}, the cell's hasCheck field specifies whether a check-box or radio-button is shown within the cell
 1 {number}, the column shows a check-box for each cell (while cell's hasCheck field is not 0)
 2 {number}, the column shows a radio-button for each cell (while cell's hasCheck field is not 0). If column's cellHasCheck field is 0, you can have multiple group of radio-cells, by using the cell's hasCheck propery on 2 (sibling cells are considered a group of radio-cells)
cellHasCheck

(static) cellShape :any

The cellShape field defines shape to apply on the column's body/data/cells. The cellShape field can be any of the following:
  • the shape's name within the exontrol.Shape.Tree or exontrol.Shape namespace
  • a CSS color
  • a JSON string-representation of an object of exontrol.Def.Shape type, for the column itself
  • an object of {normal,hover,click,disabled} type. The normal, hover, click and disabled are objects of exontrol.Def.Shape type
.
Type:
  • any
Example
null {null}, no custom shape is applied (default object's shape may be applied)
 "" {string}, no custom shape is applied (no default object's shape is be applied)
 "red" {string}, fills the object's background in red (CSS color)
 '{"fillColor": "red"}' or '{"normal":{"fillColor": "red"}}' {string}, fills the object's background in red (JSON-representation of an object of exontrol.Def.Shape type)
 "xxx" {string}, indicates that exontrol.Shapes.Tree.xxx or exontrol.Shapes.xxx is applied on the object's background. If the xxx field is missing, no custom shape is applied (no default object's shape is be applied)
 exontrol.Shapes.Button {object}, applies the "Button" shape on the object as defined into exontrol.Shapes namespace
cellShape

(static) cursor :string

The cursor field defines the mouse-cursor for individual column (column's header).
Type:
  • string
Example
"pointer" {string}, The cursor is a pointer that indicates a link (typically an image of a pointing hand)
cursor

(static) defaultSortOrder :number

The defaultSortOrder field indicates the column's sort order once the user clicks the column's header or drags it to the control's sortbar. Specifies the column's default sort-order as listed:
  • 1 {number}, sorts ascending the column
  • 2 {number}, sorts descending the column
.
Type:
  • number
Example
1 {number}, sorts ascending the column
 2 {number}, sorts descending the column
defaultSortOrder

(static) displayExpandButton :boolean

The displayExpandButton field specifies whether the column displays its expand/collapse glyphs. The displayExpandButton field has effect only if the column contains visible child-columns. The expandColumns property specifies the list of columns the current column expands or collapses.
Type:
  • boolean
Example
false {boolean}, the column hides its expand/collapse glyphs
 true {boolean}, the column shows its expand/collapse glyphs.
displayExpandButton

(static) displayFilterButton :boolean

The displayFilterButton field specifies whether the column's filter button is shown or hidden.
Type:
  • boolean
Example
false {boolean}, the column's filter button is hidden
 true {boolean}, the column's filter button is shown
displayFilterButton

(static) editOptions :EditOptions

The editOptions field specifies the options to apply on the input element while editing the cell of the current column. These options are merged with the options defined by exontrol.Tree.EditOptions object.
Type:
Since:
  • 2.4
Example
null {null}, The exontrol.Tree.EditOptions object defines the default options to apply on the input element while editing the cell of the current column.
 {inner: {type: "date"}} {EditOptions}, create an input field that let the user enter a date, either with a textbox that validates the input or a special date picker interface (<input type="date">)
 {inner: {style: {background: "white"}}} {EditOptions}, sets the editor's background to white
 {validate: function(value) { return value < 10; }} {EditOptions}, ensures that the value the user entered is always less than 10
 {change: true, selectAll: true} {EditOptions}, the cell's value is updated as soon as user changes the input field and all text gets selected once the cell enters in edit-mode
editOptions

(static) enabled :boolean

The enabled field indicates whether the column is enabled or disabled(unselectable).
Type:
  • boolean
Example
false {boolean}, disables the column
 true {boolean}, enables the column
enabled

(static) expandColumns :number|string|Column

The expandColumns field specifies the list of columns to be shown when the current column is expanded. The expandColumns field can be any of the following:
  • {number} Indicates a numeric value that defines the index of the column to request
  • {string} Specifies a list of index/identifier/key/caption/plain-caption, separated by comma character
  • {Column} specifies the object reference to be shown, once the current column is expanded
.
Type:
Example
1 {number}, specifies that the column with the index 1, is shown once the current column is expanded.
 "C1,C2" {string}, indicates that the columns C1 and C2 are being shown once the current column is expanded.
expandColumns

(static) expanded :boolean

The expanded field indicates whether the column is expanded or collapsed.
Type:
  • boolean
Example
false {boolean}, the column is collapsed
 true {boolean}, the column is expanded
expanded

(static) filter :string

The filter field defines the filter to apply to this column only. The filter depends on the filterType as explained:
  • filterType = exFilter, the filter field indicates the list (separated by "|" character) of values to filter for. For instance, filter = "Cell A", filters for items with the caption "Cell A", filter = "Cell A|Cell B", filters for items with the caption "CellA" or "CellB".
  • filterType = exPattern, the filter field defines the wild-patterns to filter for items (separated by "|" character). A pattern-filter may contain wild card characters like '?' for any single character, '*' for zero or more occurrences of any character, '#' for any digit character. For instance: "A*" filters for items that begins with "A" or "a", "A*|B*" filters for items that starts with "A", "a", "B" or "b".
  • filterType = exDate, the filter field contains alternative interval-dates to filter for (separated by "|" character). An interval-date could be of "[dateFrom] [to] [dateTo]" or "[operator] date [operator date ...]" format. The "[dateFrom] [to] [dateTo]" format filter for items that fit the interval. For instance: "2/13/2004" filter only for items with the date on 2/13/2004, "2/13/2004 to", filter for items whose date is greater or equal with 2/13/2004, "to 2/13/2004" filter for items with the date less or equal with 2/13/2004. For instance: "2/13/2004 | 2/13/2005 to" filter for items with the date on 2/13/2004 or greater or equal with 2/13/2005. The "operator date [operator date ...]" format allows to filter using multiple operators as <, <=, =, <>, !=, >= or >. For instance: "> 2/13/2004" filter for items with the date greater than 2/13/2004, "> 2/13/2004 | <= 2/13/2002" filter for dates greater than 2/13/2004 or less or greater than 2/13/2002
  • filterType = exNumeric, the filter field specifies a list of numeric-rules to filter for (separated by "|" character). The format of filter field is "[operator] number [operator number ...]", which define numeric-rule, where operator is one of <, <=, =, <>, !=, >= or >. For instance, the "> 10" filters for numbers greater than 10, "> 10 < 100" filters for numbers greater than 10 and less than 100, "10|20|>50" filters for items that include 10, 20 or any number greater than 50
  • filterType = exCheck, the filter field specifies a list of states to filter for (separated by "|" character). The cell's state is "0" (unchecked), "1" (checked) and "2" (partial-checked). For instance: "1" filters for checked items, "1|2" filters for partially and checked items
  • filterType = exImage, the filter field defines the list of images (separated by "|" character) to filter for. The cell's image property specifies the image of the cell. For instance, "Al" filters for items that displays the "Al" picture/image, "Al|Peggy" filters for items that displays the "Al" or "Peggy" images. The exontrol.HTMLPicture.Add() method adds named images to the control.
The filter field has no effect if the filterType field is exAll, exBlanks or exNonBlanks. The filter is case-sensitive, if the filterType includes the exFilterDoCaseSensitive flag.
Type:
  • string
Example
null {null}, clears the column's filter
 "" {string}, filters for empty-captions
 "Cell A|Cell B" {string}, filters for items that include "Cell A" or "Cell B" within the column
filter

(static) filterList :Tree.FilterListEnum

The filterList field specifies whether the drop down filter list includes visible or all items. The Tree.FilterListEnum type supports the following values and flags:
  • exAllItems (0), the filter's list includes all values in the column.
  • exVisibleItems (1), the filter's list includes only visible (filtered) items from the column. The visible items include child items of collapsed items.
  • exNoItems (2), the filter's list includes no item from the column.
  • exLeafItems (3), the filter's list includes the leaf items only. A leaf item is an item with no child items.
  • exRootItems (4), the filter's list includes the root items only. A root item has no parent item.
  • exSortItemsDesc (0x10), sorts descending the items of the filter's list. If none of the exSortItemsAsc or exSortItemsDesc is present, the list is built as the items are displayed in the control.
  • exSortItemsAsc (0x20), sorts ascending the items of the filter's list. If none of the exSortItemsAsc or exSortItemsDesc is present, the list is built as the items are displayed in the control.
  • exShowCheckBox (0x100), Displays a check-box for each item within the filter's list.
  • exShowExclude (0x2000), Shows or hides the Exclude field. The exFilterExclude flag excludes programmatically the selected items in the drop down filter panel.
  • exShowBlanks (0x4000), The filter's list includes (Blanks) and (NonBlanks) items
.
Type:
Example
2 or exontrol.Tree.FilterTypeEnum.exNonBlanks {number}, filters for not-blank items (a blank item is an empty item or an item that displays whitespace characters)
 6 or exontrol.Tree.FilterTypeEnum.exCheck {number}, filters for checked-items (while filter field is "1") or unchecked-items (while filter field is "0")
filterList

(static) filterOnType :boolean

The filterOnType field allows you to filter the control's data based on the typed characters.
Type:
  • boolean
Example
false {boolean}, no filter-on-type input is available for the column (excepts columns of exPattern, exDate or exNumeric type)
 true {boolean}, the column's filter-on-type input is displayed as soon as the user clicks the column's funnel glyph (no column's filter-list is displayed, if available)
filterOnType

(static) filterType :Tree.FilterTypeEnum

The filterType field defines the type of the column's filter. The Tree.FilterTypeEnum type supports the following values and flags:
  • exAll (0), no filter is applied
  • exBlanks (1), includes only blank/empty items (a blank item is an empty item or an item that displays whitespace characters)
  • exNonBlanks (2), includes only non blank/empty items (a blank item is an empty item or an item that displays whitespace characters)
  • exPattern (3), includes only items that match the pattern. The Filter property defines the pattern. A pattern may contain the wild card characters '?' for any single character, '*' for zero or more occurrences of any character, '#' for any digit character, and [chars] indicates a group of characters. If any of the *, ?, # or | characters are preceded by a \ ( escape character ) it masks the character itself. Can be combined with exFilterDoCaseSensitive flag
  • exDate (4), includes only items that fit the date interval. The Filter property of the Column object defines the interval of dates being used to filter items. The interval of dates should be as [dateFrom] to [dateTo]. If the dateFrom value is missing, the control includes only the items before the dateTo date, if the dateTo value is missing, the control includes the items after the dateFrom date. If both dates ( dateFrom and dateTo ) are present, the control includes the items between this interval of dates. For instance, the "2/13/2004 to" includes all items after 2/13/2004 inclusive, or "2/13/2004 to Feb 14 2005" includes all items between 2/13/2004 and 2/14/2004.
  • exNumeric (5), includes only items of numeric type that check the expression. The expression supports operators like <, <=, =, <>, >= or > and numbers to define rules. For instance, the "> 10 < 100" filter indicates all numbers greater than 10 and less than 100.
  • exCheck (6), includes only checked-items, while Filter property is "1" or unchecked-items if Filter is "0"
  • exImage (10), includes only items that match the images within the Filter property.
  • exFilter (240), includes only items that match the Filter property. Can be combined with exFilterDoCaseSensitive flag
  • exFilterDoCaseSensitive (0x100), By default, the column's filter is case-insensitive. Specifies a case-sensitive column's filter. Can be combined with exPattern or exFilter flag
  • exFilterExclude (0x200), The flag indicates that the Exclude field of the column is checked. The flag indicates that the items that match the filter are excluded from the list.
The filter depends on the filterType as explained:
  • filterType = exFilter, the filter field indicates the list (separated by "|" character) of values to filter for. For instance, filter = "Cell A", filters for items with the caption "Cell A", filter = "Cell A|Cell B", filters for items with the caption "CellA" or "CellB".
  • filterType = exPattern, the filter field defines the wild-patterns to filter for items (separated by "|" character). A pattern-filter may contain wild card characters like '?' for any single character, '*' for zero or more occurrences of any character, '#' for any digit character. For instance: "A*" filters for items that begins with "A" or "a", "A*|B*" filters for items that starts with "A", "a", "B" or "b".
  • filterType = exDate, the filter field contains alternative interval-dates to filter for (separated by "|" character). An interval-date could be of "[dateFrom] [to] [dateTo]" or "[operator] date [operator date ...]" format. The "[dateFrom] [to] [dateTo]" format filter for items that fit the interval. For instance: "2/13/2004" filter only for items with the date on 2/13/2004, "2/13/2004 to", filter for items whose date is greater or equal with 2/13/2004, "to 2/13/2004" filter for items with the date less or equal with 2/13/2004. For instance: "2/13/2004 | 2/13/2005 to" filter for items with the date on 2/13/2004 or greater or equal with 2/13/2005. The "operator date [operator date ...]" format allows to filter using multiple operators as <, <=, =, <>, !=, >= or >. For instance: "> 2/13/2004" filter for items with the date greater than 2/13/2004, "> 2/13/2004 | <= 2/13/2002" filter for dates greater than 2/13/2004 or less or greater than 2/13/2002
  • filterType = exNumeric, the filter field specifies a list of numeric-rules to filter for (separated by "|" character). The format of filter field is "[operator] number [operator number ...]", which define numeric-rule, where operator is one of <, <=, =, <>, !=, >= or >. For instance, the "> 10" filters for numbers greater than 10, "> 10 < 100" filters for numbers greater than 10 and less than 100, "10|20|>50" filters for items that include 10, 20 or any number greater than 50
  • filterType = exCheck, the filter field specifies a list of states to filter for (separated by "|" character). The cell's state is "0" (unchecked), "1" (checked) and "2" (partial-checked). For instance: "1" filters for checked items, "1|2" filters for partially and checked items
  • filterType = exImage, the filter field defines the list of images (separated by "|" character) to filter for. The cell's image property specifies the image of the cell. For instance, "Al" filters for items that displays the "Al" picture/image, "Al|Peggy" filters for items that displays the "Al" or "Peggy" images. The exontrol.HTMLPicture.Add() method adds named images to the control.
The filter field has no effect if the filterType field is exAll, exBlanks or exNonBlanks. The filter is case-sensitive, if the filterType includes the exFilterDoCaseSensitive flag.
Type:
Example
2 or exontrol.Tree.FilterTypeEnum.exNonBlanks {number}, filters for not-blank items (a blank item is an empty item or an item that displays whitespace characters)
 6 or exontrol.Tree.FilterTypeEnum.exCheck {number}, filters for checked-items (while filter field is "1") or unchecked-items (while filter field is "0")
filterType

(static) format :string

The format field specifies the expression to format the column The format-expression supports the following keywords:
value, indicates the value of the current cell ( "value/2 format ``", displays half of the value using current regional format )
%0, %1, %2, ... {any} specifies the value of the cell in the column with the index 0, 1 2, ... ( "currency(%0 + %1)", adds the value of first and second cell and displays it as a currency )
%C0, %C1, %C2, ... {string} specifies the caption of the cell, or the string the cell displays in the column with the index 0, 1 2, ... ( "%C0 + %C1", concatenates the caption of first and second cell )
%CD0, %CD1, %CD2, ... {any} specifies the cell's user-date in the column with the index 0, 1 2, ... ( "%CD0 ? value : ``", displays the cell's value only if the cell's data is not empty )
%CS0, %CS1, %CS2, ... {number} specifies the cell's state in the column with the index 0, 1 2, ... ( "(%CS0 ? `<b>` : ``) + value", displays the cell's value in bold only if the first cell is checked )
%CT0, %CT1, %CT2, ... {boolean} returns true if the cell displays a total field; otherwise, it returns false. The exTotalField / exTotalColumn flag specifies whether the cell displays a total field. For instance, "%CT1" refers to all cells in the second column that display totals, while "not %CT1" refers to all cells in the second column that do not display totals (@since 3.3)
%CE0, %CE1, %CE2, ... {boolean} returns true if the cell is editable; otherwise, it returns false.. For example, "%CE0" refers to all editable cells in the first column, while "not %CE1" refers to all cells in the second column that are read-only (@since 3.3)
%CC0, %CC1, %CC2, ... {number} retrieve the number of child items (this keyword consistently returns identical results for all cells since it pertains to the item that hosts each cell). The ChildCount property returns the number of child items. For example, "%CC0" identifies all parent items, while "%CC0 = 0" identifies all leaf items (@since 3.3)
%CX0, %CX1, %CX2, ... {boolean} returns true if the item hosting the cell is expanded, or false if it is collapsed (this keyword consistently returns identical results for all cells since it pertains to the item that hosts each cell). The ExpandItem property specifically indicates whether the item is expanded or collapsed. For example, "%CX0" refers to all expanded items, while "not %CX0" identifies all collapsed items (@since 3.3)
The format-expression supports the following unary-operators:
  • exp(``), checks whether the item is expanded or collapsed ( "(exp(``) ? `<b>` : ``) + value", shows expanded-items in bold )
  • get(`aggregate(list,direction,formula)`), summarizes the cell based on "aggregate(list,direction,formula)" syntax, where:
    aggregate, must be one of the following:
    • sum, performs addition of values
    • min, retrieves the minimum value
    • max, retrieves the maximum value
    • count, counts the number of items
    • avg, calculates the average of values
    • std, gets standard-deviation of numbers
    list, must be one of the following:
    • a number expression that specifies the index of the item being referred
    • all, indicates all items, so the formula is being applied to all items
    • current, refers the current item
    • parent, refers to the parent item
    • root, refers to the root item (the root item has no parent items)
    direction, must be one of the following:
    • dir, collects only direct descendents (child-items)
    • rec, collects recursivelly the leaf descendents ( leaf items ). A leaf item is an item with no child items
    • all, collects all descendents
    Currently, the following items are excluded by aggregate functions:
    not-sortable items. The SortableItem property specifies whether the item can be sorted ( a sortable item can change its position after sorting, while a not-sortable item keeps its position after sorting. not-selectable items. The SelectableItem property specifies whether the user can selects/focus the specified item. divider items. The ItemDivider property specifies whether the item displays a single cell, instead displaying whole cells.
    In conclusion, aggregate functions counts ONLY items that are sortable, selectable and not a divider-item.

    For instance:
    "get(`count(current,dir,1)`)", gets the count of child-items
    "get(`count(current,all,1)`)", gets the count of all child-items (implies recursively child items)
    "get(`count(current,rec,1)`)", counts the number of leaf items ( a leaf item is an item with no child items )
    "get(`sum(current,dir,%1 ? 1 : 0)`)", counts the number of child-items that have not-empty cells within the second-column
    "get(`sum(current,dir,value)`)", gets the total of values of child-items (direct descendent) within the same column
    "get(`sum(all,rec,value)`)", gets the total of values of leaf-items within the same column
    "get(`sum(parent,dir,dbl(%1) + dbl(%2))`)", gets the addition of all cells in the second (%1) and third (%2) column that are directly descendent of the parent item (sibling)
The format-expression supports the following binary-operators:
0 index `format`, gets the index of the item (0-based). The first added item has the index 0, the second added item has the index 1, and so on. The index of the item remains the same even if the order of the items is changed by sorting or grouping ( "1 index ``", gets the index of the item starting from 1 )
0 rindex `delimiter|format|format|...`, returns the recursive-index of the item ("1 rindex `.|A-Z`", returns values as A, A.1, A.2, B, ...)
0 pos `format`, returns the relative position of the item (the position within the parent's children collection) ( "1 pos ``", returns the position of the item (1-based) within the parent's child items collection )
0 rpos `delimiter|format|format|...`, returns the recursive relative-position of the item (the position within the parent's children collection) ( "1 rpos `.|A-Z`", returns values as A, A.1, A.2, B, ... )
0 opos `format`, returns the relative old position of the item (the position within the parent's children collection) ( "1 opos ``", returns the position of the item (1-based) within the parent's child items collection )
0 ropos `delimiter|format|format|...`, returns the recursive relative-old-position of the item (the position within the parent's children collection) ( "1 ropos `.|A-Z`", returns values as A, A.1, A.2, B, ... )
0 apos `format`, returns the absolute position of the item (the position from the first visible item) ( "1 apos ``", gets absolute position of the item )
0 rapos `delimiter|format|format|...`, returns the recursive absolute-position of the item (the position from the first visible item) ( "1 rapos `.|A-Z`", returns values as A, A.1, A.2, B, ... )
where:
  • `delimiter`, is a character to separated recursive-operators such as "rindex", "rpos", "ropos" and "rapos"
  • `format`, is a set of characters to be used for specifying the index
.
Type:
  • string
Example
"value format ``" {string}, shows the column's value formatted as a number (as in regional settings)
 "1 index ``" {string}, gets the index (1-based) of the item
 "1 rpos `.|A-Z`" {string}, displays A, B, C for root-items, and A.1, A.2, A.1.1, ... B.1, B.2, ... for child-items
 "currency(dbl(%0) + dbl(%1))" {string}, adds columns 0 and 1 and displays the result as currency
format

(static) formatImage :string

The formatImage field defines the expression to determine the images the column display.
Type:
  • string
Since:
  • 1.6
Example
"" {string} or null {null}, indicates no image is shown within the column
 "'logo'" {string}, the "logo" picture is displayed for the entire column
 "value" {string}, the picture named by the giving value is being shown
 "value case (default: 'unknown'; 'Austria': 'Austria')" {string}, shows 'Austria' image for cells with the value 'Austria', else displays 'unknown' picture
formatImage

(static) formatText :exontrol.DrawTextFormatEnum

The formatText field specifies the format to display the column's caption, as a combination of more exontrol.DrawTextFormatEnum flags. The exontrol.DrawTextFormatEnum type supports the following flags:
  • exTextAlignTop (0x00), justifies the text to the top of the rectangle
  • exTextAlignLeft (0x00), aligns text to the left
  • exTextAlignCenter (0x01), centers text horizontally in the rectangle
  • exTextAlignRight (0x02), aligns text to the right
  • exTextAlignVCenter (0x04), centers text vertically
  • exTextAlignBottom (0x08), justifies the text to the bottom of the rectangle.
  • exTextAlignMask (0x0F), specifies the mask for text's alignment.
  • exTextWordBreak (0x10), breaks words. Lines are automatically broken between words if a word would extend past the edge of the rectangle specified by the lpRect parameter. A carriage return-line feed sequence also breaks the line. If this is not specified, output is on one line.
  • exTextSingleLine (0x20), displays text on a single line only. Carriage returns and line feeds do not break the line.
  • exTextExpandTabs (0x40), expands tab characters. The default number of characters per tab is eight.
  • exPlainText (0x80), treats the text as plain text.
  • exTextNoClip (0x0100), draws without clipping.
  • exHTMLTextNoColors (0x0200), ignores the and tags.
  • exTextCalcRect (0x0400), determines the width and height of the text.
  • exHTMLTextNoTags (0x0800), ignores all HTML tags.
  • exTextPathEllipsis (0x4000), for displayed text, replaces characters in the middle of the string with ellipses so that the result fits in the specified rectangle. If the string contains backslash (\) characters, exTextPathEllipsis preserves as much as possible of the text after the last backslash.
  • exTextEndEllipsis (0x8000), for displayed text, if the end of a string does not fit in the rectangle, it is truncated and ellipses are added. If a word that is not at the end of the string goes beyond the limits of the rectangle, it is truncated without ellipses.
  • exTextWordEllipsis (0x040000), truncates any word that does not fit in the rectangle and adds ellipses.
.
Type:
  • exontrol.DrawTextFormatEnum
Example
null {null}, centers the caption
  32 or exontrol.DrawTextFormatEnum.exTextSingleLine {number}, defines a single-line caption
  0x2A or exontrol.DrawTextFormatEnum.exTextSingleLine | exontrol.DrawTextFormatEnum.exTextAlignRight | exontrol.DrawTextFormatEnum.exTextAlignBottom {number}, defines a single-line caption right/bottom-aligned
formatText

(static) groupByFormatCell :string

The groupByFormatCell field indicates the format of the cell to be displayed when the column gets grouped by The format-expression supports the following keywords:
value, indicates the value of the current cell ( "value/2 format ``", displays half of the value using current regional format )
%0, %1, %2, ... {any} specifies the value of the cell in the column with the index 0, 1 2, ... ( "currency(%0 + %1)", adds the value of first and second cell and displays it as a currency )
%C0, %C1, %C2, ... {string} specifies the caption of the cell, or the string the cell displays in the column with the index 0, 1 2, ... ( "%C0 + %C1", concatenates the caption of first and second cell )
%CD0, %CD1, %CD2, ... {any} specifies the cell's user-date in the column with the index 0, 1 2, ... ( "%CD0 ? value : ``", displays the cell's value only if the cell's data is not empty )
%CS0, %CS1, %CS2, ... {number} specifies the cell's state in the column with the index 0, 1 2, ... ( "(%CS0 ? `<b>` : ``) + value", displays the cell's value in bold only if the first cell is checked )
%CT0, %CT1, %CT2, ... {boolean} returns true if the cell displays a total field; otherwise, it returns false. The exTotalField / exTotalColumn flag specifies whether the cell displays a total field. For instance, "%CT1" refers to all cells in the second column that display totals, while "not %CT1" refers to all cells in the second column that do not display totals (@since 3.3)
%CE0, %CE1, %CE2, ... {boolean} returns true if the cell is editable; otherwise, it returns false.. For example, "%CE0" refers to all editable cells in the first column, while "not %CE1" refers to all cells in the second column that are read-only (@since 3.3)
%CC0, %CC1, %CC2, ... {number} retrieve the number of child items (this keyword consistently returns identical results for all cells since it pertains to the item that hosts each cell). The ChildCount property returns the number of child items. For example, "%CC0" identifies all parent items, while "%CC0 = 0" identifies all leaf items (@since 3.3)
%CX0, %CX1, %CX2, ... {boolean} returns true if the item hosting the cell is expanded, or false if it is collapsed (this keyword consistently returns identical results for all cells since it pertains to the item that hosts each cell). The ExpandItem property specifically indicates whether the item is expanded or collapsed. For example, "%CX0" refers to all expanded items, while "not %CX0" identifies all collapsed items (@since 3.3)
The format-expression supports the following unary-operators:
  • exp(``), checks whether the item is expanded or collapsed ( "(exp(``) ? `<b>` : ``) + value", shows expanded-items in bold )
  • get(`aggregate(list,direction,formula)`), summarizes the cell based on "aggregate(list,direction,formula)" syntax, where:
    aggregate, must be one of the following:
    • sum, performs addition of values
    • min, retrieves the minimum value
    • max, retrieves the maximum value
    • count, counts the number of items
    • avg, calculates the average of values
    • std, gets standard-deviation of numbers
    list, must be one of the following:
    • a number expression that specifies the index of the item being referred
    • all, indicates all items, so the formula is being applied to all items
    • current, refers the current item
    • parent, refers to the parent item
    • root, refers to the root item (the root item has no parent items)
    direction, must be one of the following:
    • dir, collects only direct descendents (child-items)
    • rec, collects recursivelly the leaf descendents ( leaf items ). A leaf item is an item with no child items
    • all, collects all descendents
    Currently, the following items are excluded by aggregate functions:
    not-sortable items. The SortableItem property specifies whether the item can be sorted ( a sortable item can change its position after sorting, while a not-sortable item keeps its position after sorting. not-selectable items. The SelectableItem property specifies whether the user can selects/focus the specified item. divider items. The ItemDivider property specifies whether the item displays a single cell, instead displaying whole cells.
    In conclusion, aggregate functions counts ONLY items that are sortable, selectable and not a divider-item.

    For instance:
    "get(`count(current,dir,1)`)", gets the count of child-items
    "get(`count(current,all,1)`)", gets the count of all child-items (implies recursively child items)
    "get(`count(current,rec,1)`)", counts the number of leaf items ( a leaf item is an item with no child items )
    "get(`sum(current,dir,%1 ? 1 : 0)`)", counts the number of child-items that have not-empty cells within the second-column
    "get(`sum(current,dir,value)`)", gets the total of values of child-items (direct descendent) within the same column
    "get(`sum(all,rec,value)`)", gets the total of values of leaf-items within the same column
    "get(`sum(parent,dir,dbl(%1) + dbl(%2))`)", gets the addition of all cells in the second (%1) and third (%2) column that are directly descendent of the parent item (sibling)
The format-expression supports the following binary-operators:
0 index `format`, gets the index of the item (0-based). The first added item has the index 0, the second added item has the index 1, and so on. The index of the item remains the same even if the order of the items is changed by sorting or grouping ( "1 index ``", gets the index of the item starting from 1 )
0 rindex `delimiter|format|format|...`, returns the recursive-index of the item ("1 rindex `.|A-Z`", returns values as A, A.1, A.2, B, ...)
0 pos `format`, returns the relative position of the item (the position within the parent's children collection) ( "1 pos ``", returns the position of the item (1-based) within the parent's child items collection )
0 rpos `delimiter|format|format|...`, returns the recursive relative-position of the item (the position within the parent's children collection) ( "1 rpos `.|A-Z`", returns values as A, A.1, A.2, B, ... )
0 opos `format`, returns the relative old position of the item (the position within the parent's children collection) ( "1 opos ``", returns the position of the item (1-based) within the parent's child items collection )
0 ropos `delimiter|format|format|...`, returns the recursive relative-old-position of the item (the position within the parent's children collection) ( "1 ropos `.|A-Z`", returns values as A, A.1, A.2, B, ... )
0 apos `format`, returns the absolute position of the item (the position from the first visible item) ( "1 apos ``", gets absolute position of the item )
0 rapos `delimiter|format|format|...`, returns the recursive absolute-position of the item (the position from the first visible item) ( "1 rapos `.|A-Z`", returns values as A, A.1, A.2, B, ... )
where:
  • `delimiter`, is a character to separated recursive-operators such as "rindex", "rpos", "ropos" and "rapos"
  • `format`, is a set of characters to be used for specifying the index
.
Type:
  • string
Example
null {null}, the control's groupByFormatCell option is used instead
 "" {string}, the default group-by value gets displayed once the column gets grouped by
 "upper(value)" {string}, the default group-by value (in upper case) gets displayed once the column gets grouped by
 "value + ` <fgcolor gray>` + get(`count(current,rec,1)`)" {string}, the default group-by value plus the count of items within the group gets displayed once the column gets grouped by
groupByFormatCell

(static) image :string

The image field specifies the name of the image/picture the column displays. The image can be added using the exontrol.HTMLPicture.Add() method.
Type:
  • string
image

(static) imageAlign :number

The imageAlign field defines the alignment of the image within the column. The imageAlign propery can be any of the following:
  • 0, the image is on the left of the column's caption
  • 1, the image is on the right of the column's caption
  • 2, the image is on the top of the column's caption
  • 3, the image is on the bottom of the column's caption
.
Type:
  • number
Example
null {null}, the image is aligned left to the caption (default)
 1 {number}, the image is displayed to the right of the column's caption
imageAlign

(static) imageSize :null|number|Array.<number>

The imageSize field defines the size of the column's image. The imageSize can be of one of the following types:
  • {null}, Indicates that the column's image is displayed as it is (full-sized).
  • {number}, Specifies that the column's image is displayed into a square of giving size (same width and height). If 0 the object displays no image, if negative the column's image is stretched to giving square, else the column's picture is scaled to fit the giving rectangle.
  • {number[]}, Specifies an array of [aspect-width,aspect-height] type that defines the limits for width or/and height. The aspect-width and aspect-height define the width/height of the column's picture to scale or stretch to.
.
Type:
  • null | number | Array.<number>
Example
null {null}, Indicates that the object's image is displayed as it is (full-sized).
 0 {number}, no image is displayed
 64 {number}, the image is scaled to fit a 64 x 64 rectangle
 -64 {number}, the image is strected to a 64 x 64 rectangle
 [32,64] {array}, scales the image to the largest ratio-rectangle (32 x 64) that fits the client
 [-32,-64] {array}, stretches the image to a 32 x 64 rectangle
imageSize

(static) key :string

The key field specifies the key associated with the column. Specifies the key associated with the column. If no key is provided, the column's plain-caption can be used to request an item. The plain-caption includes no ex-HTML tags, such as <b>, <fgcolor> and so on.
Type:
  • string
Example
"logo" {string}, defines the column with the giving key (logo). You can use the Column("logo") method to request the column giving its key.
key

(static) pad :number|Array.<number>|string

The pad field defines the column's padding (space between the column's content and its border), as one of the following:
  • {number} a numeric value, to pad horizontal and vertical size with the same value
  • {(string|number[])} a "x,y" or [x,y] type to specify the padding on horizontal and vertical side
.
Type:
  • number | Array.<number> | string
Example
null {null}, indicates that the default-padding field is used ([4,4])
  0 {number}, indicates no padding
  "8,4" {string}, increases the element's width with 2 * 8-pixels and element's height with 2 * 4-pixels
  [8,4] {array}, increases the element's width with 2 * 8-pixels and element's height with 2 * 4-pixels
pad

(static) partialCheck :boolean

The partialCheck field indicates whether the column supports partial-check feature.
Type:
  • boolean
Example
false {boolean}, the column supports no partial-check feature.
 true {boolean}, the column supports partial-check feature, so once a parent item is checked/unchecked all its descendents are checked/unchecked.
partialCheck

(static) position :number

The position field specifies the column's position.
Type:
  • number
Example
null {null}, the null value has no effect
 0 {number}, moves the column on the first position
position

(static) shape :any

The shape field defines the shape for individual column (column's header). The shape field can be any of the following:
  • the shape's name within the exontrol.Shape.Tree or exontrol.Shape namespace
  • a CSS color
  • a JSON string-representation of an object of exontrol.Def.Shape type, for the column itself
  • an object of {normal,hover,click,disabled} type. The normal, hover, click and disabled are objects of exontrol.Def.Shape type
.
Type:
  • any
Example
null {null}, no custom shape is applied (default object's shape may be applied)
 "" {string}, no custom shape is applied (no default object's shape is be applied)
 "red" {string}, fills the object's background in red (CSS color)
 '{"fillColor": "red"}' or '{"normal":{"fillColor": "red"}}' {string}, fills the object's background in red (JSON-representation of an object of exontrol.Def.Shape type)
 "xxx" {string}, indicates that exontrol.Shapes.Tree.xxx or exontrol.Shapes.xxx is applied on the object's background. If the xxx field is missing, no custom shape is applied (no default object's shape is be applied)
 exontrol.Shapes.Button {object}, applies the "Button" shape on the object as defined into exontrol.Shapes namespace
shape

(static) sortOrder :number

The sortOrder field specifies the column's sort order, as explained:
  • 0 {number}, indicates an unsorted column
  • 1 {number}, sorts ascending the column
  • 2 {number}, sorts descending the column
.
Type:
  • number
Example
0 {number}, unsorts the column
 2 {number}, sorts descending the column
sortOrder

(static) sortType :Tree.SortTypeEnum

The sortType field specifies whether the column gets sorted as string, number or date, or by value, state or image. By default, the column gets sorted as string (by "caption" as "string"). The Tree.SortTypeEnum type supports the following values (group A):
  • exSortString (0), the column's content is sorted as string (by default)
  • exSortNumeric (1), the column's content is sorted as numbers
  • exSortDate (2), the column's content is sorted as dates
Also, the Tree.SortTypeEnum type supports the following additional values (group B):
  • exSortByValue (0x10), the column gets sorted by cell's value rather than cell's caption (the cell's caption include formatting)
  • exSortByState (0x20), The column gets sorted by cell's state (checked, unchecked) rather than cell's caption (the cell's caption include formatting)
  • exSortByImage (0x30), The column gets sorted by cell's image rather than cell's caption (the cell's caption include formatting)
(any value of group A can be combined with any value of group B).
Type:
Example
2 or exontrol.Tree.SortTypeEnum.exSortDate {number}, sorts the columns as dates
 0x11 or exontrol.Tree.SortTypeEnum.exSortNumeric | exontrol.Tree.SortTypeEnum.exSortByValue {number}, sorts the column by "value" as numbers. For instance, column's formatColumn property formats the values within the column(cell can display number-grouping, ex-HTML format and so on), so this option sorts the column's value rather than formatted-caption it displays
sortType

(static) toolTip :string

The toolTip field defines the column's predefined tooltip.
Type:
  • string
Example
null {null}, the column's caption is shown once the mouse pointer hovers it, and it is not fully displayed
 "" {string}, no tooltip for the column is displayed
 "&lt;img>image&lt;/img> and text" {string}, the image and text is being shown once the mouse pointer hovers the column. The image can be added using the exontrol.HTMLPicture.Add() method
toolTip

(static) total :string

The total field specifies a formula in the format 'aggregate(list, direction, formula)' or a format (supports all predefined functions of the Column's Format property) that defines the total fields applied to all unformatted and non-leaf cells within the column. For instance, the formula 'sum(current,rec,%2*%3)' computes the sum by multiplying the value of the column with index 2 by the value of the column with index 3. This formula is applied to all child cells of the column that are unformatted (Items.FormatCell property is empty) and do not belong to leaf items.
aggregate, must be one of the following:
  • sum, performs addition of values
  • min, retrieves the minimum value
  • max, retrieves the maximum value
  • count, counts the number of items
  • avg, calculates the average of values
  • std, gets standard-deviation of numbers
list, must be one of the following:
  • a number expression that specifies the index of the item being referred
  • all, indicates all items, so the formula is being applied to all items
  • current, refers the current item
  • parent, refers to the parent item
  • root, refers to the root item (the root item has no parent items)
direction, must be one of the following:
  • dir, collects only direct descendents (child-items)
  • rec, collects recursivelly the leaf descendents ( leaf items ). A leaf item is an item with no child items
  • all, collects all descendents
Currently, the following items are excluded by aggregate functions:
not-sortable items. The SortableItem property specifies whether the item can be sorted ( a sortable item can change its position after sorting, while a not-sortable item keeps its position after sorting. not-selectable items. The SelectableItem property specifies whether the user can selects/focus the specified item. divider items. The ItemDivider property specifies whether the item displays a single cell, instead displaying whole cells.
In conclusion, aggregate functions counts ONLY items that are sortable, selectable and not a divider-item.
For instance, the formula 'sum(current,rec,%2*%3)' computes the sum by multiplying the value of the column with index 2 by the value of the column with index 3. This formula is applied to all child cells of the column that are unformatted (Items.FormatCell property is empty) and do not belong to leaf items.
Type:
  • string
Since:
  • 3.3
Example
"sum(all,rec,value)", {string} returns the total of values of leaf-items within the same column
 "sum(current,dir,value)", {string} returns the total of values of child-items (direct descendent) within the same column
 "count(current,dir,1)", {string} gets the count of child-items
 "`<fgcolor gray>` + (get(`sum(current,rec,%1)`) format ``)", {string} displays the sum for column 1 of leaf items in gray, formatted according to the control panel's regional settings
total

(static) values :any

The values field specifies a list of predefined values that the current column can display. While editing the column, the user can select a value from this predefined values only. The values field can be one of the following:
  • values {null}, indicates that the field is ignored
  • values {string}, holds the list of predefined values separated by comma character. The list can include the value and its associated caption, using "caption(value)" format, such as "(0),rect(1),circle(2)" which displays nothing for 0, "rect" for 1 and "circle" for value 2
  • values {array[string]}, holds a list of predefined values, as an array of [string] type
  • values {map}, holds a map of (value,caption) type that specifies the caption to display for specified value, as an object of [value => caption]
Each individual caption supports ex-HTML format, so it can include images using the ex-HTML <img> tag. The following forms of values are equivalents:
  • "Central,East,West" {string},
  • "Central(Central),East(East),West(West)" {string},
  • ["Central","East","West"] {array[string]}
  • new Map([["Central","Central"], ["East","East"], ["West","West"]]) {map}
.
Type:
  • any
Since:
  • 2.4
Example
null {null}, no effect
 ",Any,All" {string}, specifies that the column can display nothing, "Any" or "All"
 "Be Right Back(BRB),By the Way(BTW),Laugh Out Loud(LOL)" {string}, shows "Be Right Back" for "BRB" value, "By the Way" for "BTW" and so on
 "(0),<img>1st</img>(1),<img>2nd</img>(2)" {string}, specifies that the column displays nothing for 0, image with the key "1st" for the value 1, and image with the key "2nd" for the value 2
 ["","Any","All"] {array[string]}, specifies that the column can display nothing, "Any" or "All"
 new Map([["BRB", "Be Right Back"], ["BTW","By the Way"], ["LOL","Laugh Out Loud"]]) {map}, shows "Be Right Back" for "BRB" value, "By the Way" for "BTW" and so on
values

(static) visible :boolean

The visible field indicates whether the column is visible or hidden.
Type:
  • boolean
Example
false {boolean}, hides the column
 true {boolean}, shows the column
visible

(static) width :number

The width field defines the column's width.
Type:
  • number
Example
128 {number}, defines the column's width to 128 pixels.
width