blob: 5903458e3cebc7d6e071227cffeba5a4e8352805 [file] [log] [blame]
{ "type": "class",
"qname": "mx.controls.dataGridClasses.DataGridColumn",
"baseClassname": "org.apache.royale.html.supportClasses.DataGridColumn"
,
"description": "The DataGridColumn class describes a column in a DataGrid control. There is one DataGridColumn per displayable column, even if a column is hidden or off-screen. The data provider items of a DataGrid control can contain properties that are not displayed and, therefore, do not need a DataGridColumn. A DataGridColumn allows specification of the color and font of the text in a column; what kind of component displays the data for the column; whether the column is editable, sortable, or resizable; and the text for the column header. <p><strong>Notes:</strong><ul> <li>A DataGridColumn only holds information about a column; it is not the parent of the item renderers in the column.</li> <li>If you specify a DataGridColumn class without a <code>dataField</code> property, you must specify a <code>sortCompareFunction</code> property. Otherwise, sort operations may cause run-time errors.</li></ul> </p> <p>You use the <code>&lt;mx.DataGridColumn&gt;</code> tag to configure a column of a DataGrid control. You specify the <code>&lt;mx.DataGridColumn&gt;</code> tag as a child of the columns property in MXML. The <code>&lt;mx.DataGridColumn&gt;</code> tag inherits all of the tag attributes of its superclass, and adds the following tag attributes:</p> <pre>\\n &lt;mx:DataGridColumn\\n <b>Properties </b>\\n dataField=&quot;<i>No default</i>&quot;\\n dataTipField=&quot;<i>No default</i>&quot;\\n dataTipFunction=&quot;<i>No default</i>&quot;\\n editable=&quot;true|false&quot;\\n editorDataField=&quot;text&quot;\\n editorHeightOffset=&quot;0&quot;\\n editorUsesEnterKey=&quot;false|true&quot;\\n editorWidthOffset=&quot;0&quot;\\n editorXOffset=&quot;0&quot;\\n editorYOffset=&quot;0&quot;\\n headerRenderer=&quot;DataGridItemRenderer&quot;\\n headerText=&quot;<i>No default</i>&quot;\\n headerWordWrap=&quot;undefined&quot;\\n imeMode=&quot;null&quot;\\n itemEditor=&quot;TextInput&quot;\\n itemRenderer=&quot;DataGridItemRenderer&quot;\\n labelFunction=&quot;<i>No default</i>&quot;\\n minWidth=&quot;20&quot;\\n rendererIsEditor=&quot;false|true&quot;\\n resizable=&quot;true|false&quot;\\n showDataTips=&quot;false|true&quot;\\n sortable=&quot;true|false&quot;\\n sortCompareFunction=&quot;<i>No default</i>&quot;\\n sortDescending=&quot;false|true&quot;\\n visible=&quot;true|false&quot;\\n width=&quot;100&quot;\\n wordWrap=&quot;false|true&quot;\\n \\n <b>Styles</b>\\n backgroundColor=&quot;0xFFFFFF&quot;\\n color=&quot;<i>No default.</i>&quot;\\n disabledColor=&quot;0xAAB3B3&quot;\\n fontAntiAliasType=&quot;advanced&quot;\\n fontFamily=&quot;<i>No default</i>&quot;\\n fontGridFitType=&quot;pixel&quot;\\n fontSharpness=&quot;0&quot;\\n fontSize=&quot;<i>No default</i>&quot;\\n fontStyle=&quot;normal|italic&quot;\\n fontThickness=&quot;0&quot;\\n fontWeight=&quot;normal|bold&quot;\\n headerStyleName=&quot;<i>No default</i>&quot;\\n paddingLeft=&quot;0&quot;\\n paddingRight=&quot;0&quot;\\n textAlign=&quot;right|center|left&quot;\\n textDecoration=&quot;none|underline&quot;\\n textIndent=&quot;0&quot;\\n /&gt;\\n </pre> </p>",
"tags": [
{ "tagName": "see",
"values": ["mx.controls.DataGrid", "mx.styles.CSSStyleDeclaration"]},
{ "tagName": "mxml",
"values": []},
{ "tagName": "playerversion",
"values": ["Flash 9", "AIR 1.1"]},
{ "tagName": "productversion",
"values": ["Flex 3"]},
{ "tagName": "langversion",
"values": ["3.0"]} ],
"members": [
{ "type": "accessor",
"access": "read-only",
"return": "mx.core.IFactory",
"qname": "defaultItemEditorFactory",
"namespace": "mx_internal",
"bindable": [],
"details": ["static"],
"deprecated": {}},
{ "type": "method",
"qname": "mx.controls.dataGridClasses.DataGridColumn",
"namespace": "",
"bindable": [],
"details": [],
"deprecated": {},
"description": "Constructor. associated with the column, and the text for the header cell of this column. This is equivalent to setting the <code>dataField</code> and <code>headerText</code> properties.",
"tags": [
{ "tagName": "param",
"values": ["columnName The name of the field in the data provider"]},
{ "tagName": "playerversion",
"values": ["Flash 9", "AIR 1.1"]},
{ "tagName": "productversion",
"values": ["Flex 3"]},
{ "tagName": "langversion",
"values": ["3.0"]} ],
"return": "",
"params": [{ "name": "columnName", "type": "String"}]}
,
{ "type": "accessor",
"access": "read-write",
"return": "String",
"qname": "headerText",
"namespace": "public",
"bindable": ["headerTextChanged"],
"details": [],
"deprecated": {},
"description": "Text for the header of this column. By default, the DataGrid control uses the value of the <code>dataField</code> property as the header text.",
"tags": [
{ "tagName": "playerversion",
"values": ["Flash 9", "AIR 1.1"]},
{ "tagName": "productversion",
"values": ["Flex 3"]},
{ "tagName": "langversion",
"values": ["3.0"]} ]},
{ "type": "field",
"qname": "rendererIsEditor",
"return": "Boolean",
"namespace": "public",
"bindable": [],
"details": [],
"deprecated": {},
"description": "A flag that indicates that the item renderer is also an item editor. If this property is <code>true</code>, Flex ignores the <code>itemEditor</code> property and uses the item renderer for that item as the editor.",
"tags": [
{ "tagName": "default",
"values": ["false"]},
{ "tagName": "playerversion",
"values": ["Flash 9", "AIR 1.1"]},
{ "tagName": "productversion",
"values": ["Flex 3"]},
{ "tagName": "langversion",
"values": ["3.0"]},
{ "tagName": "royalesuppresspublicvarwarning",
"values": []} ]},
{ "type": "method",
"qname": "itemToLabel",
"namespace": "public",
"bindable": [],
"details": [],
"deprecated": {},
"return": "String",
"params": [{ "name": "data", "type": "Object"}]}
,
{ "type": "accessor",
"access": "read-write",
"return": "String",
"qname": "labelField",
"namespace": "public",
"bindable": [],
"details": [],
"deprecated": {}},
{ "type": "accessor",
"access": "read-write",
"return": "Function",
"qname": "labelFunction",
"namespace": "public",
"bindable": ["labelFunctionChanged"],
"details": [],
"deprecated": {},
"description": "A function that determines the text to display in this column. By default the column displays the text for the field in the data that matches the column name. However, sometimes you want to display text based on more than one field in the data, or display something that does not have the format that you want. In such a case you specify a callback function using <code>labelFunction</code>. <p>For the DataGrid control, the method signature has the following form:</p> <pre>labelFunction(item:Object, column:DataGridColumn):String</pre> <p>Where <code>item</code> contains the DataGrid item object, and <code>column</code> specifies the DataGrid column.</p> <p>A callback function might concatenate the firstName and lastName fields in the data, or do some custom formatting on a Date, or convert a number for the month into the string for the month.</p>",
"tags": [
{ "tagName": "playerversion",
"values": ["Flash 9", "AIR 1.1"]},
{ "tagName": "productversion",
"values": ["Flex 3"]},
{ "tagName": "langversion",
"values": ["3.0"]} ]},
{ "type": "accessor",
"access": "read-write",
"return": "Number",
"qname": "width",
"namespace": "public",
"bindable": ["widthChanged"],
"details": [],
"deprecated": {},
"description": "The width of the column, in pixels. If the DataGrid's <code>horizontalScrollPolicy</code> property is <code>false</code>, all visible columns must fit in the displayable area, and the DataGrid will not always honor the width of the columns if the total width of the columns is too small or too large for the displayable area.",
"tags": [
{ "tagName": "default",
"values": ["100"]},
{ "tagName": "playerversion",
"values": ["Flash 9", "AIR 1.1"]},
{ "tagName": "productversion",
"values": ["Flex 3"]},
{ "tagName": "langversion",
"values": ["3.0"]} ]},
{ "type": "accessor",
"access": "read-write",
"return": "Number",
"qname": "minWidth",
"namespace": "public",
"bindable": [],
"details": [],
"deprecated": {},
"description": "The width of the column, in pixels. If the DataGrid's <code>horizontalScrollPolicy</code> property is <code>false</code>, all visible columns must fit in the displayable area, and the DataGrid will not always honor the width of the columns if the total width of the columns is too small or too large for the displayable area.",
"tags": [
{ "tagName": "default",
"values": ["100"]},
{ "tagName": "playerversion",
"values": ["Flash 9", "AIR 1.1"]},
{ "tagName": "productversion",
"values": ["Flex 3"]},
{ "tagName": "langversion",
"values": ["3.0"]} ]},
{ "type": "accessor",
"access": "read-write",
"return": "Object",
"qname": "textAlign",
"namespace": "public",
"bindable": [],
"details": [],
"deprecated": {}},
{ "type": "accessor",
"access": "read-write",
"return": "*",
"qname": "wordWrap",
"namespace": "public",
"bindable": [],
"details": [],
"deprecated": {},
"description": "Set to <code>false</code> to wrap the text in a row of this column because it does not fit on one line If <code>undefined</code>, the AdvancedDataGrid control's <code>wordWrap</code> property is used.",
"tags": [
{ "tagName": "default",
"values": ["undefined"]},
{ "tagName": "playerversion",
"values": ["Flash 9", "AIR 1.1"]},
{ "tagName": "productversion",
"values": ["Royale 0.9.3"]},
{ "tagName": "langversion",
"values": ["3.0"]} ]},
{ "type": "accessor",
"access": "read-write",
"return": "Boolean",
"qname": "sortDescending",
"namespace": "public",
"bindable": [],
"details": [],
"deprecated": {}},
{ "type": "accessor",
"access": "read-write",
"return": "Boolean",
"qname": "resizable",
"namespace": "public",
"bindable": [],
"details": [],
"deprecated": {}},
{ "type": "accessor",
"access": "read-write",
"return": "*",
"qname": "showDataTips",
"namespace": "public",
"bindable": [],
"details": [],
"deprecated": {},
"description": "Set to <code>true</code> to show data tips in the column. If <code>true</code>, datatips are displayed for text in the rows. Datatips are tooltips designed to show the text that is too long for the row.",
"tags": [
{ "tagName": "default",
"values": ["false"]},
{ "tagName": "playerversion",
"values": ["Flash 9", "AIR 1.1"]},
{ "tagName": "productversion",
"values": ["Royale 0.9.3"]},
{ "tagName": "langversion",
"values": ["3.0"]} ]},
{ "type": "accessor",
"access": "read-write",
"return": "Boolean",
"qname": "sortable",
"namespace": "public",
"bindable": [],
"details": [],
"deprecated": {}},
{ "type": "accessor",
"access": "read-write",
"return": "Function",
"qname": "sortCompareFunction",
"namespace": "public",
"bindable": ["sortCompareFunctionChanged"],
"details": [],
"deprecated": {},
"description": "A callback function that gets called when sorting the data in the column. If this property is not specified, the sort tries to use a basic string or number sort on the data. If the data is not a string or number or if the <code>dataField</code> property is not a valid property of the data provider, the sort does not work or will generate an exception. If you specify a value of the <code>labelFunction</code> property, you typically also provide a function to the <code>sortCompareFunction</code> property, unless sorting is not allowed on this column. That means you specify a function when the value from the column's <code>dataField</code> does not sort in the same way as the computed value from the <code>labelFunction</code> property. <p>The AdvancedDataGrid control uses this function to sort the elements of the data provider collection. The function signature of the callback function takes two parameters and has the following form:</p> <pre>mySortCompareFunction(obj1:Object, obj2:Object):int </pre> <p><code>obj1</code> &#x2014; A data element to compare.</p> <p><code>obj2</code> &#x2014; Another data element to compare with <code>obj1</code>.</p> <p>The function should return a value based on the comparison of the objects: </p> <ul> <li>-1 if obj1 should appear before obj2 in ascending order. </li> <li>0 if obj1 = obj2. </li> <li>1 if obj1 should appear after obj2 in ascending order.</li> </ul> <p><strong>Note:</strong> The <code>obj1</code> and <code>obj2</code> parameters are entire data provider elements and not just the data for the item.</p>",
"tags": [
{ "tagName": "default",
"values": ["null"]},
{ "tagName": "playerversion",
"values": ["Flash 9", "AIR 1.1"]},
{ "tagName": "productversion",
"values": ["Royale 0.9.3"]},
{ "tagName": "langversion",
"values": ["3.0"]} ]},
{ "type": "accessor",
"access": "read-write",
"return": "Boolean",
"qname": "visible",
"namespace": "public",
"bindable": [],
"details": [],
"deprecated": {},
"description": "If <code>true</code>, the column is visible. Set to <code>false</code> to hide the column.",
"tags": [
{ "tagName": "default",
"values": ["true"]},
{ "tagName": "playerversion",
"values": ["Flash 9", "AIR 1.1"]},
{ "tagName": "productversion",
"values": ["Royale 0.9.3"]},
{ "tagName": "langversion",
"values": ["3.0"]} ]}]
}