Both sides previous revisionPrevious revision | Next revisionBoth sides next revision |
programming:tge:controls:guimoderntextlistctrl [2011/09/19 20:42] – [Download] fixed v1.01 download link Nathan Martin | programming:tge:controls:guimoderntextlistctrl [2011/09/20 17:12] – [Methods] updated for v1.01 release, still incomplete list. Nathan Martin |
---|
|//U32//^//%minWidth//|Minimum width in pixels that the column is constrained to. Default is 10 pixels.| | |//U32//^//%minWidth//|Minimum width in pixels that the column is constrained to. Default is 10 pixels.| |
|//U32//^//%maxWidth//|Maximum width in pixels that the column is constrained to. Default is 250 pixels.| | |//U32//^//%maxWidth//|Maximum width in pixels that the column is constrained to. Default is 250 pixels.| |
|//string//^//%flags//|Column flag attributes in textual keyword and space delimited format that will be applied to the column.\\ See the column flag attributes table below for an explanation of the recognized keywords that are available for use.\\ \\ Columns are automatically applied the following keyword string equivalent attributes before processing provided flags: ''"**left active show**"''| | |//string//^//%flags//|Column flag attributes in textual keyword and space delimited format that will be applied to the column.\\ See the **Column Flag Attributes** table below for an explanation of the recognized keywords that are available for use.\\ \\ Columns are automatically applied the following keyword string equivalent attributes before processing provided flags: ''"**left active show**"''| |
| ||| | | ||| |
|//U32//^Returns|Index position of the just installed column.| | |//U32//^Returns|Index position of the just installed column.| |
<code php> | <code php> |
// insert a row into the list | // insert a row into the list |
%rowPos = %control.addRow(%key, %text, %index); | %rowPos = %control.addRow(%key, %text, %index, %flags); |
| |
// %rowPos now holds the index position of the just inserted row | // %rowPos now holds the index position of the just inserted row |
|//S32//^//%key//|Key associated with the row that is being inserted.| | |//S32//^//%key//|Key associated with the row that is being inserted.| |
|//string//^//%text//|Text content of the row that is tab delimited into columns. This content supports markup language as described in the [[#Markup Language]] section| | |//string//^//%text//|Text content of the row that is tab delimited into columns. This content supports markup language as described in the [[#Markup Language]] section| |
|//U32//^//%index//|Index position of where the row should be inserted into. Default is -1 which causes the row to be appended at the end of the list.\\ An invalid index position (//**index** >= **getRowCount()**//) will just append the row to end of the list instead of the requested insertion position.| | |//U32//^//%index//|Index position of where the row should be inserted into. Default is -1 which causes the row to be appended at the end of the list.\\ An invalid index position (//**index** >= **[[#getRowCount()]]**//) will just append the row to end of the list instead of the requested insertion position.| |
| |//string//^//%flags//|Row flag attributes in textual keyword and space delimited format that will be applied to the row.\\ See the **Row Flag Attributes** table below for an explanation of the recognized keywords that are available for use.\\ \\ Rows are automatically applied the following keyword string equivalent attributes before processing provided flags: ''"**active selectable**"''| |
| ||| | | ||| |
|//U32//^Returns|Index position of just inserted or appended row.| | |//U32//^Returns|Index position of just inserted or appended row.| |
| |
| ^ Row Flag Attributes ^^ |
| ^//active//|Whether the row will be in an active/enabled state or not. Default is active.\\ Overall this just determines which colors to use for drawing the row text cells from the control's profile:\\ Active state -- ''fillColor'', ''borderColor'', and ''fontColor''.\\ Inactive state -- ''fillColorNA'', ''borderColorNA'', and ''fontColorNA''.\\ Use the //**!**// prefix to invert the meaning of the keyword as an opposite result.| |
| ^//selectable//|Whether the row is user selectable in the list or not. Default is selectable.\\ Use the //**!**// prefix to invert the meaning of the keyword as an opposite result.| |
\\ | \\ |
| |
</code> | </code> |
^ Method Arguments ^^^ | ^ Method Arguments ^^^ |
|//U32//^//%index//|Index position of the row to be removed.\\ An invalid index position (//**index** >= **getRowCount()**//) will not cause any rows to be removed, but instead the procedure will be aborted.| | |//U32//^//%index//|Index position of the row to be removed.\\ An invalid index position (//**index** >= **[[#getRowCount()]]**//) will not cause any rows to be removed, but instead the procedure will be aborted.| |
| ||| | | ||| |
|//void//^Returns|Nothing.| | |//void//^Returns|Nothing.| |
| ||| | | ||| |
|//void//^Returns|Nothing.| | |//void//^Returns|Nothing.| |
| \\ |
| |
| |
| === getColumnFlags() === |
| <code php> |
| // get the column's textual flags |
| %colFlags = %control.getColumnFlags(%index); |
| |
| // %colFlags now holds the requested column's textual flags |
| </code> |
| ^ Method Arguments ^^^ |
| |//U32//^//%index//|Index position of the column.| |
| | ||| |
| |//string//^Returns|Column's textual flags on success. See **Column Flag Attributes** table in [[#addColumn()]] method section for details.\\ Empty (''""'') string on invalid column index.| |
\\ | \\ |
| |
| ||| | | ||| |
|//U32//^Returns|Number of rows| | |//U32//^Returns|Number of rows| |
| \\ |
| |
| |
| === getRowFlags() === |
| <code php> |
| // get the row's textual flags |
| %rowFlags = %control.getRowFlags(%index); |
| |
| // %rowFlags now holds the requested row's textual flags |
| </code> |
| ^ Method Arguments ^^^ |
| |//U32//^//%index//|Index position of the row.| |
| | ||| |
| |//string//^Returns|Row's textual flags on success. See **Row Flag Attributes** table in [[#addRow()]] method section for details.\\ Empty (''""'') string on invalid row index.| |
\\ | \\ |
| |
%control.setSelectedRow(%index); | %control.setSelectedRow(%index); |
| |
// this won't cause a OnRowSelect() callback event. | // this will not generate a [[#OnRowSelect]]() callback event. |
</code> | </code> |
^ Method Arguments ^^^ | ^ Method Arguments ^^^ |
|//U32//^//%index//|Index position of the row.| | |//U32//^//%index//|Index position of the row.\\ Valid range is ''-1'', for selecting none of the rows, to **''< [[#getRowCount()]]''**| |
| ||| | | ||| |
|//void//^Returns|Nothing.| | |//void//^Returns|Nothing.| |
\\ | \\ |
| |
| |
| === setSortOrder() === |
| <code php> |
| // add or update an existing column sort order |
| %control.setSortOrder(%sortOrder); |
| </code> |
| ^ Method Arguments ^^^ |
| |//string//^//%sortOrder//|Sort order string in the format of ''"//**key order** [**makeFirst**]//"''. See the **Sort Orders** table below for details about the space delimited fields.\\ **Note**: The square brackets **//[]//** in the format string above means an optional field and those brackets are not supposed actually exist in the string.| |
| | ||| |
| |//void//^Returns|Nothing.| |
| |
| ^ Sort Orders ^^ |
| ||| |
| ^//key//|Key associated with the column that this sort order will be tied to.| |
| ^//order//|''0'' -- Column is to be sorted by Ascending order.\\ ''1'' -- Column is to be sorted by Descending order.\\ Any other values are undefined behavior.| |
| ^//makeFirst//|Optional field that when it is a numerical value of other than zero (''0'') to indicate that the sort order will become the highest priority or most significant column sort order.| |
| \\ |
| |
==== Callbacks ==== | ==== Callbacks ==== |