Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
<?xml version="1.0" encoding="UTF-8"?>
<xs:schema attributeFormDefault="unqualified" elementFormDefault="qualified" targetNamespace="exml:ext.list" xmlns:el="exml:ext.list" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:exml="http://www.jangaroo.net/exml/0.8" xmlns:eu="exml:ext.util" xmlns:e="exml:ext" >
  <xs:import namespace="http://www.jangaroo.net/exml/0.8"/>
  <xs:import namespace="exml:ext.util"/>
  <xs:import namespace="exml:ext"/>
  <xs:complexType name='BooleanColumn_TYPE'>
    <xs:complexContent>
      <xs:extension base='el:Column_TYPE'>
        <xs:sequence>
        </xs:sequence>
        <xs:attribute type='exml:String' name='falseText'>
          <xs:annotation>
            <xs:documentation>
              The string returned by the renderer when the column value is falsey (but not undefined) (defaults to <tt>'false'</tt>).
            </xs:documentation>
          </xs:annotation>
        </xs:attribute>
        <xs:attribute type='exml:String' name='trueText'>
          <xs:annotation>
            <xs:documentation>
              The string returned by the renderer when the column value is not falsey (defaults to <tt>'true'</tt>).
            </xs:documentation>
          </xs:annotation>
        </xs:attribute>
        <xs:attribute type='exml:String' name='undefinedText'>
          <xs:annotation>
            <xs:documentation>
              The string returned by the renderer when the column value is undefined (defaults to <tt>'&amp;#160;'</tt>).
            </xs:documentation>
          </xs:annotation>
        </xs:attribute>
        <xs:anyAttribute namespace="http://www.jangaroo.net/exml/0.8 exml:untyped" processContents="skip"/>
      </xs:extension>
    </xs:complexContent>
  </xs:complexType>
  <xs:element name='BooleanColumn' type='el:BooleanColumn_TYPE' substitutionGroup='el:Column'>
    <xs:annotation>
      <xs:documentation>
        A Column definition class which renders boolean data fields. See the <a href="output/Ext.list.Column.html#Ext.list.Column-xtype">xtype</a> config option of <a href="Ext.list.Column.html">Ext.list.Column</a> for more details. <p>This class represents the xtype 'lvbooleancolumn' and serves as a typed config object for constructor of class BooleanColumn.</p> <p>Copyright &#169; 2011 Sencha Inc.</p> @see ext.list.BooleanColumn
      </xs:documentation>
    </xs:annotation>
  </xs:element>
  <xs:complexType name='Column_TYPE'>
        <xs:sequence>
        </xs:sequence>
        <xs:attribute type='exml:String' name='align'>
          <xs:annotation>
            <xs:documentation>
              Set the CSS text-align property of the column. Defaults to <tt>'left'</tt>.
            </xs:documentation>
          </xs:annotation>
        </xs:attribute>
        <xs:attribute type='exml:String' name='cls'>
          <xs:annotation>
            <xs:documentation>
              This option can be used to add a CSS class to the cell of each row for this column.
            </xs:documentation>
          </xs:annotation>
        </xs:attribute>
        <xs:attribute type='exml:String' name='dataIndex'>
          <xs:annotation>
            <xs:documentation>
              <b>Required</b>. The name of the field in the ListViews's <a href="Ext.data.Store.html">Ext.data.Store</a>'s <a href="Ext.data.Record.html">Ext.data.Record</a> definition from which to draw the column's value.
            </xs:documentation>
          </xs:annotation>
        </xs:attribute>
        <xs:attribute type='exml:String' name='header'>
          <xs:annotation>
            <xs:documentation>
              The header text to be used as innerHTML (html tags are accepted) to display in the ListView. <b>Note</b>: to have a clickable header with no text displayed use <tt>' '</tt>.
            </xs:documentation>
          </xs:annotation>
        </xs:attribute>
        <xs:attribute type='exml:Boolean' name='isColumn'>
          <xs:annotation>
            <xs:documentation>
              Used by ListView constructor method to avoid reprocessing a Column if <code>isColumn</code> is not set ListView will recreate a new Ext.list.Column Defaults to true.
            </xs:documentation>
          </xs:annotation>
        </xs:attribute>
        <xs:attribute type='exml:String' name='tpl'>
          <xs:annotation>
            <xs:documentation>
              Specify a string to pass as the configuration string for <a href="Ext.XTemplate.html">Ext.XTemplate</a>. By default an <a href="Ext.XTemplate.html">Ext.XTemplate</a> will be implicitly created using the <tt>dataIndex</tt>.
            </xs:documentation>
          </xs:annotation>
        </xs:attribute>
        <xs:attribute type='exml:Number' name='width'>
          <xs:annotation>
            <xs:documentation>
              Percentage of the container width this column should be allocated. Columns that have no width specified will be allocated with an equal percentage to fill 100% of the container width. To easily take advantage of the full container width, leave the width of at least one column undefined. Note that if you do not want to take up the full width of the container, the width of every column needs to be explicitly defined.
            </xs:documentation>
          </xs:annotation>
        </xs:attribute>
        <xs:anyAttribute namespace="http://www.jangaroo.net/exml/0.8 exml:untyped" processContents="skip"/>
  </xs:complexType>
  <xs:element name='Column' type='el:Column_TYPE'>
    <xs:annotation>
      <xs:documentation>
        This class encapsulates column configuration data to be used in the initialization of a <a href="Ext.list.ListView.html">ListView</a>. <p>While subclasses are provided to render data in different ways, this class renders a passed data field unchanged and is usually used for textual columns.</p> <p>This class represents the xtype 'lvcolumn' and serves as a typed config object for constructor of class Column.</p> <p>Copyright &#169; 2011 Sencha Inc.</p> @see ext.list.Column
      </xs:documentation>
    </xs:annotation>
  </xs:element>
  <xs:complexType name='ColumnResizer_TYPE'>
    <xs:complexContent>
      <xs:extension base='eu:Observable_TYPE'>
        <xs:sequence>
        </xs:sequence>
        <xs:attribute type='exml:Number' name='minPct'>
          <xs:annotation>
            <xs:documentation>
              The minimum percentage to allot for any column (defaults to <tt>.05</tt>)
            </xs:documentation>
          </xs:annotation>
        </xs:attribute>
        <xs:anyAttribute namespace="http://www.jangaroo.net/exml/0.8 exml:untyped" processContents="skip"/>
      </xs:extension>
    </xs:complexContent>
  </xs:complexType>
  <xs:element name='ColumnResizer' type='el:ColumnResizer_TYPE' substitutionGroup='eu:Observable'>
    <xs:annotation>
      <xs:documentation>
        Supporting Class for Ext.list.ListView <p>This class serves as a typed config object for constructor of class ColumnResizer.</p> <p>Copyright &#169; 2011 Sencha Inc.</p> @see ext.list.ColumnResizer
      </xs:documentation>
    </xs:annotation>
  </xs:element>
  <xs:complexType name='DateColumn_TYPE'>
    <xs:complexContent>
      <xs:extension base='el:Column_TYPE'>
        <xs:sequence>
        </xs:sequence>
        <xs:anyAttribute namespace="http://www.jangaroo.net/exml/0.8 exml:untyped" processContents="skip"/>
      </xs:extension>
    </xs:complexContent>
  </xs:complexType>
  <xs:element name='DateColumn' type='el:DateColumn_TYPE' substitutionGroup='el:Column'>
    <xs:annotation>
      <xs:documentation>
        A Column definition class which renders a passed date according to the default locale, or a configured <a href="output/Ext.list.DateColumn.html#Ext.list.DateColumn-format">format</a>. See the <a href="output/Ext.list.Column.html#Ext.list.Column-xtype">xtype</a> config option of <a href="Ext.list.Column.html">Ext.list.Column</a> for more details. <p>This class represents the xtype 'lvdatecolumn' and serves as a typed config object for constructor of class DateColumn.</p> <p>Copyright &#169; 2011 Sencha Inc.</p> @see ext.list.DateColumn
      </xs:documentation>
    </xs:annotation>
  </xs:element>
  <xs:complexType name='ListView_TYPE'>
    <xs:complexContent>
      <xs:extension base='e:DataView_TYPE'>
        <xs:sequence>
            <xs:element name='columnResize' minOccurs="0" maxOccurs="1">
              <xs:annotation>
                <xs:documentation>
                  Specify <tt>true</tt> or specify a configuration object for <a href="Ext.list.ListView.ColumnResizer.html">Ext.list.ListView.ColumnResizer</a> to enable the columns to be resizable (defaults to <tt>true</tt>).
                </xs:documentation>
              </xs:annotation>
              <xs:complexType>
                <xs:sequence>
                  <xs:any minOccurs="0" maxOccurs="unbounded" processContents="lax"/>
                </xs:sequence>
              </xs:complexType>
            </xs:element>
            <xs:element name='columnSort' minOccurs="0" maxOccurs="1">
              <xs:annotation>
                <xs:documentation>
                  Specify <tt>true</tt> or specify a configuration object for <a href="Ext.list.ListView.Sorter.html">Ext.list.ListView.Sorter</a> to enable the columns to be sortable (defaults to <tt>true</tt>).
                </xs:documentation>
              </xs:annotation>
              <xs:complexType>
                <xs:sequence>
                  <xs:any minOccurs="0" maxOccurs="unbounded" processContents="lax"/>
                </xs:sequence>
              </xs:complexType>
            </xs:element>
            <xs:element name='columns' minOccurs="0" maxOccurs="1">
              <xs:annotation>
                <xs:documentation>
                  An array of column configuration objects, for example: <pre><code>{ align: 'right', dataIndex: 'size', header: 'Size', tpl: '{size:fileSize}', width: .35 } </code></pre>Acceptable properties for each column configuration object are: <div class="mdetail-params"><ul><li><b><tt>align</tt></b> : String<div class="sub-desc">Set the CSS text-align property of the column. Defaults to <tt>'left'</tt>.</div></li><li><b><tt>dataIndex</tt></b> : String<div class="sub-desc">See <a href="Ext.grid.Column.html">Ext.grid.Column</a>. <a href="output/Ext.grid.Column.html#Ext.grid.Column-dataIndex">dataIndex</a> for details.</div></li><li><b><tt>header</tt></b> : String<div class="sub-desc">See <a href="Ext.grid.Column.html">Ext.grid.Column</a>. <a href="output/Ext.grid.Column.html#Ext.grid.Column-header">header</a> for details.</div></li><li><b><tt>tpl</tt></b> : String<div class="sub-desc">Specify a string to pass as the configuration string for <a href="Ext.XTemplate.html">Ext.XTemplate</a>. By default an <a href="Ext.XTemplate.html">Ext.XTemplate</a> will be implicitly created using the <tt>dataIndex</tt>.</div></li><li><b><tt>width</tt></b> : Number<div class="sub-desc">Percentage of the container width this column should be allocated. Columns that have no width specified will be allocated with an equal percentage to fill 100% of the container width. To easily take advantage of the full container width, leave the width of at least one column undefined. Note that if you do not want to take up the full width of the container, the width of every column needs to be explicitly defined.</div></li></ul></div>
                </xs:documentation>
              </xs:annotation>
              <xs:complexType>
                <xs:sequence>
                  <xs:any minOccurs="0" maxOccurs="unbounded" processContents="lax"/>
                </xs:sequence>
                <xs:attribute name="mode" type="exml:configMode"/>
              </xs:complexType>
            </xs:element>
            <xs:element name='internalTpl' minOccurs="0" maxOccurs="1">
              <xs:annotation>
                <xs:documentation>
                  The template to be used for the header row. See <a href="output/Ext.list.ListView.html#Ext.list.ListView-tpl">tpl</a> for more details.
                </xs:documentation>
              </xs:annotation>
              <xs:complexType>
                <xs:sequence>
                  <xs:any minOccurs="0" maxOccurs="unbounded" processContents="lax"/>
                </xs:sequence>
              </xs:complexType>
            </xs:element>
        </xs:sequence>
        <xs:attribute type='exml:String' name='columnResize'>
          <xs:annotation>
            <xs:documentation>
              Specify <tt>true</tt> or specify a configuration object for <a href="Ext.list.ListView.ColumnResizer.html">Ext.list.ListView.ColumnResizer</a> to enable the columns to be resizable (defaults to <tt>true</tt>).
            </xs:documentation>
          </xs:annotation>
        </xs:attribute>
        <xs:attribute type='exml:String' name='columnSort'>
          <xs:annotation>
            <xs:documentation>
              Specify <tt>true</tt> or specify a configuration object for <a href="Ext.list.ListView.Sorter.html">Ext.list.ListView.Sorter</a> to enable the columns to be sortable (defaults to <tt>true</tt>).
            </xs:documentation>
          </xs:annotation>
        </xs:attribute>
        <xs:attribute type='exml:String' name='columns'>
          <xs:annotation>
            <xs:documentation>
              An array of column configuration objects, for example: <pre><code>{ align: 'right', dataIndex: 'size', header: 'Size', tpl: '{size:fileSize}', width: .35 } </code></pre>Acceptable properties for each column configuration object are: <div class="mdetail-params"><ul><li><b><tt>align</tt></b> : String<div class="sub-desc">Set the CSS text-align property of the column. Defaults to <tt>'left'</tt>.</div></li><li><b><tt>dataIndex</tt></b> : String<div class="sub-desc">See <a href="Ext.grid.Column.html">Ext.grid.Column</a>. <a href="output/Ext.grid.Column.html#Ext.grid.Column-dataIndex">dataIndex</a> for details.</div></li><li><b><tt>header</tt></b> : String<div class="sub-desc">See <a href="Ext.grid.Column.html">Ext.grid.Column</a>. <a href="output/Ext.grid.Column.html#Ext.grid.Column-header">header</a> for details.</div></li><li><b><tt>tpl</tt></b> : String<div class="sub-desc">Specify a string to pass as the configuration string for <a href="Ext.XTemplate.html">Ext.XTemplate</a>. By default an <a href="Ext.XTemplate.html">Ext.XTemplate</a> will be implicitly created using the <tt>dataIndex</tt>.</div></li><li><b><tt>width</tt></b> : Number<div class="sub-desc">Percentage of the container width this column should be allocated. Columns that have no width specified will be allocated with an equal percentage to fill 100% of the container width. To easily take advantage of the full container width, leave the width of at least one column undefined. Note that if you do not want to take up the full width of the container, the width of every column needs to be explicitly defined.</div></li></ul></div>
            </xs:documentation>
          </xs:annotation>
        </xs:attribute>
        <xs:attribute type='exml:Boolean' name='hideHeaders'>
          <xs:annotation>
            <xs:documentation>
              <tt>true</tt> to hide the <a href="output/Ext.list.ListView.html#Ext.list.ListView-internalTpl">header row</a> (defaults to <tt>false</tt> so the <a href="output/Ext.list.ListView.html#Ext.list.ListView-internalTpl">header row</a> will be shown).
            </xs:documentation>
          </xs:annotation>
        </xs:attribute>
        <xs:attribute type='exml:String' name='internalTpl'>
          <xs:annotation>
            <xs:documentation>
              The template to be used for the header row. See <a href="output/Ext.list.ListView.html#Ext.list.ListView-tpl">tpl</a> for more details.
            </xs:documentation>
          </xs:annotation>
        </xs:attribute>
        <xs:attribute type='exml:Boolean' name='reserveScrollOffset'>
          <xs:annotation>
            <xs:documentation>
              By default will defer accounting for the configured <b><tt><a href="output/Ext.list.ListView.html#Ext.list.ListView-scrollOffset">scrollOffset</a></tt></b> for 10 milliseconds. Specify <tt>true</tt> to account for the configured <b><tt><a href="output/Ext.list.ListView.html#Ext.list.ListView-scrollOffset">scrollOffset</a></tt></b> immediately.
            </xs:documentation>
          </xs:annotation>
        </xs:attribute>
        <xs:attribute type='exml:Number' name='scrollOffset'>
          <xs:annotation>
            <xs:documentation>
              The amount of space to reserve for the scrollbar (defaults to <tt>undefined</tt>). If an explicit value isn't specified, this will be automatically calculated.
            </xs:documentation>
          </xs:annotation>
        </xs:attribute>
        <xs:anyAttribute namespace="http://www.jangaroo.net/exml/0.8 exml:untyped" processContents="skip"/>
      </xs:extension>
    </xs:complexContent>
  </xs:complexType>
  <xs:element name='ListView' type='el:ListView_TYPE' substitutionGroup='e:DataView'>
    <xs:annotation>
      <xs:documentation>
        Ext.list.ListView is a fast and light-weight implementation of a <a href="Ext.grid.GridPanel.html">Grid</a> like view. It has the following characteristics: <div class="mdetail-params"><ul><li>resizable columns</li><li>selectable</li><li>column widths are initially proportioned by percentage based on the container width and number of columns</li><li>uses templates to render the data in any required format</li><li>no horizontal scrolling</li><li>no editing</li></ul></div><p>Example usage:</p><pre><code>// consume JSON of this form: { "images":[ { "name":"dance_fever.jpg", "size":2067, "lastmod":1236974993000, "url":"images\/thumbs\/dance_fever.jpg" }, { "name":"zack_sink.jpg", "size":2303, "lastmod":1236974993000, "url":"images\/thumbs\/zack_sink.jpg" } ] } var store = new Ext.data.JsonStore({ url: 'get-images.php', root: 'images', fields: [ 'name', 'url', {name:'size', type: 'float'}, {name:'lastmod', type:'date', dateFormat:'timestamp'} ] }); store.load(); var listView = new Ext.list.ListView({ store: store, multiSelect: true, emptyText: 'No images to display', reserveScrollOffset: true, columns: [{ header: 'File', width: .5, dataIndex: 'name' },{ header: 'Last Modified', width: .35, dataIndex: 'lastmod', tpl: '{lastmod:date("m-d h:i a")}' },{ header: 'Size', dataIndex: 'size', tpl: '{size:fileSize}', // format using Ext.util.Format.fileSize() align: 'right' }] }); // put it in a Panel so it looks pretty var panel = new Ext.Panel({ id:'images-view', width:425, height:250, collapsible:true, layout:'fit', title:'Simple ListView <i>(0 items selected)</i>', items: listView }); panel.render(document.body); // little bit of feedback listView.on('selectionchange', function(view, nodes){ var l = nodes.length; var s = l != 1 ? 's' : ''; panel.setTitle('Simple ListView <i>('+l+' item'+s+' selected)</i>'); }); </code></pre> <p>This class represents the xtype 'listview' and serves as a typed config object for constructor of class ListView.</p> <p>Copyright &#169; 2011 Sencha Inc.</p> @see ext.list.ListView
      </xs:documentation>
    </xs:annotation>
  </xs:element>
  <xs:complexType name='NumberColumn_TYPE'>
    <xs:complexContent>
      <xs:extension base='el:Column_TYPE'>
        <xs:sequence>
        </xs:sequence>
        <xs:attribute type='exml:String' name='format'>
          <xs:annotation>
            <xs:documentation>
              A formatting string as used by <a href="output/Ext.util.Format.html#Ext.util.Format-number">Ext.util.Format.number</a> to format a numeric value for this Column (defaults to <tt>'0,000.00'</tt>).
            </xs:documentation>
          </xs:annotation>
        </xs:attribute>
        <xs:anyAttribute namespace="http://www.jangaroo.net/exml/0.8 exml:untyped" processContents="skip"/>
      </xs:extension>
    </xs:complexContent>
  </xs:complexType>
  <xs:element name='NumberColumn' type='el:NumberColumn_TYPE' substitutionGroup='el:Column'>
    <xs:annotation>
      <xs:documentation>
        A Column definition class which renders a numeric data field according to a <a href="output/Ext.list.NumberColumn.html#Ext.list.NumberColumn-format">format</a> string. See the <a href="output/Ext.list.Column.html#Ext.list.Column-xtype">xtype</a> config option of <a href="Ext.list.Column.html">Ext.list.Column</a> for more details. <p>This class represents the xtype 'lvnumbercolumn' and serves as a typed config object for constructor of class NumberColumn.</p> <p>Copyright &#169; 2011 Sencha Inc.</p> @see ext.list.NumberColumn
      </xs:documentation>
    </xs:annotation>
  </xs:element>
  <xs:complexType name='Sorter_TYPE'>
    <xs:complexContent>
      <xs:extension base='eu:Observable_TYPE'>
        <xs:sequence>
            <xs:element name='sortClasses' minOccurs="0" maxOccurs="1">
              <xs:annotation>
                <xs:documentation>
                  The CSS classes applied to a header when it is sorted. (defaults to <tt>["sort-asc", "sort-desc"]</tt>)
                </xs:documentation>
              </xs:annotation>
              <xs:complexType>
                <xs:sequence>
                  <xs:any minOccurs="0" maxOccurs="unbounded" processContents="lax"/>
                </xs:sequence>
                <xs:attribute name="mode" type="exml:configMode"/>
              </xs:complexType>
            </xs:element>
        </xs:sequence>
        <xs:attribute type='exml:String' name='sortClasses'>
          <xs:annotation>
            <xs:documentation>
              The CSS classes applied to a header when it is sorted. (defaults to <tt>["sort-asc", "sort-desc"]</tt>)
            </xs:documentation>
          </xs:annotation>
        </xs:attribute>
        <xs:anyAttribute namespace="http://www.jangaroo.net/exml/0.8 exml:untyped" processContents="skip"/>
      </xs:extension>
    </xs:complexContent>
  </xs:complexType>
  <xs:element name='Sorter' type='el:Sorter_TYPE' substitutionGroup='eu:Observable'>
    <xs:annotation>
      <xs:documentation>
        Supporting Class for Ext.list.ListView <p>This class serves as a typed config object for constructor of class Sorter.</p> <p>Copyright &#169; 2011 Sencha Inc.</p> @see ext.list.Sorter
      </xs:documentation>
    </xs:annotation>
  </xs:element>
</xs:schema>
New to GrepCode? Check out our FAQ X