Writing a Mozilla Application with XUL and Javascript
  XUL Template Example [ << Previous | Next >> ]

  • The following example is a template written in the simple format, it is used to generate content for the ChatZilla user list... (full source)
    
    <tree id="user-list" datasources="rdf:null"
      containment="http://home.netscape.com/NC-irc#chanuser"
      container="true" flex="1">
    
      <template>
        <treechildren flex="1">
          <treeitem uri="...">
            <treerow>
              <treecell>
                <image class="op-image"
                  state="rdf:http://home.netscape.com/NC-irc#op"/>
              </treecell>
              <treecell>
                <image class="voice-image"
                  state="rdf:http://home.netscape.com/NC-irc#voice"/>
              </treecell>
              <treecell>
                <text value="rdf:http://home.netscape.com/NC-irc#nick"/>
              </treecell>
            </treerow>
          </treeitem>
        </treechildren>
      </template>
    
      <!-- treecolgroup stuff omitted -->
    
      <!-- treehead stuff omitted -->
    
    </tree>

[ Presentation Overview | Agenda | XUL Documents | Summary of XUL Elements | XUL Document Example | XUL Document Screenshot | XUL Overlays | XUL Overlay Example | XUL Overlay Screenshot | RDF Data | RDF Graph Illustration | RDF and XUL Templates | XUL Template Example | XUL Template Example, Points of Interest | Conclusions | Extra Slides | RDF Data Sources | XPCOM and XPConnect | XPConnect Objects | Instantiating an XPCOM Component | Chrome structure | Installing Chrome | Sample manifest.rdf ]