summaryrefslogtreecommitdiffstats
path: root/doc/html/xml-sax-features-walkthrough.html
diff options
context:
space:
mode:
Diffstat (limited to 'doc/html/xml-sax-features-walkthrough.html')
-rw-r--r--doc/html/xml-sax-features-walkthrough.html56
1 files changed, 28 insertions, 28 deletions
diff --git a/doc/html/xml-sax-features-walkthrough.html b/doc/html/xml-sax-features-walkthrough.html
index 51708fff9..306f4fdc7 100644
--- a/doc/html/xml-sax-features-walkthrough.html
+++ b/doc/html/xml-sax-features-walkthrough.html
@@ -59,8 +59,8 @@ part: we include all the classes we need:
#include &lt;<a href="qapplication-h.html">ntqapplication.h</a>&gt;
#include &lt;<a href="tqfile-h.html">tqfile.h</a>&gt;
#include &lt;<a href="tqxml-h.html">tqxml.h</a>&gt;
- #include &lt;<a href="qlistview-h.html">ntqlistview.h</a>&gt;
- #include &lt;<a href="qgrid-h.html">ntqgrid.h</a>&gt;
+ #include &lt;<a href="tqlistview-h.html">tqlistview.h</a>&gt;
+ #include &lt;<a href="tqgrid-h.html">tqgrid.h</a>&gt;
#include &lt;<a href="tqmainwindow-h.html">tqmainwindow.h</a>&gt;
#include &lt;<a href="tqlabel-h.html">tqlabel.h</a>&gt;
</pre>
@@ -84,7 +84,7 @@ the example directory for demonstration purposes.
</pre>
<p> ... and instantiate a <em>reader</em> object. Later we will manipulate its features
and thus influence how the XML data are read.
-<p> <pre> <a href="ntqgrid.html">TQGrid</a> * container = new <a href="ntqgrid.html">TQGrid</a>( 3 );
+<p> <pre> <a href="tqgrid.html">TQGrid</a> * container = new <a href="tqgrid.html">TQGrid</a>( 3 );
</pre>
<p> Now let's think about presenting the output: As described in the
<a href="xml.html#sax2Features">TQt SAX2 documentation</a>
@@ -93,7 +93,7 @@ and <em>http://xml.org/sax/features/namespaces</em>: TRUE/TRUE, TRUE/FALSE and
FALSE/TRUE. To show the relevant output side by side of each other
and mark them with three labels makes up for a grid layout consisting
of three columns (and thus two lines).
-<p> <pre> <a href="ntqlistview.html">TQListView</a> * nameSpace = new <a href="ntqlistview.html">TQListView</a>( container, "table_namespace" );
+<p> <pre> <a href="tqlistview.html">TQListView</a> * nameSpace = new <a href="tqlistview.html">TQListView</a>( container, "table_namespace" );
</pre>
<p> The most natural way of presenting XML elements is in a tree.
Thus we use a listview. Its name <em>nameSpace</em> indicates that this
@@ -118,12 +118,12 @@ in the parsed XML document.
<p> <pre> reader.<a href="tqxmlsimplereader.html#parse">parse</a>( source );
</pre>
<p> Finally we parse the document with the reader's default feature settings.
-<p> <pre> <a href="ntqlistview.html">TQListView</a> * namespacePrefix = new <a href="ntqlistview.html">TQListView</a>( container,
+<p> <pre> <a href="tqlistview.html">TQListView</a> * namespacePrefix = new <a href="tqlistview.html">TQListView</a>( container,
"table_namespace_prefix" );
</pre>
<p> Now we prepare for the parsing of the same XML input source with
different reader settings. The output will be presented in
-a second <a href="ntqlistview.html">TQListView</a>, <em>namespacePrefix</em>. As it is the second
+a second <a href="tqlistview.html">TQListView</a>, <em>namespacePrefix</em>. As it is the second
member of the <em>container</em> grid it will appear in the middle of
the upper grid row.
<p> <pre> handler-&gt;setListView( namespacePrefix );
@@ -145,7 +145,7 @@ beginning of the document again.
</pre>
<p> Finally we parse the XML file a second time with the changed reader
settings (TRUE/TRUE).
-<p> <pre> <a href="ntqlistview.html">TQListView</a> * prefix = new <a href="ntqlistview.html">TQListView</a>( container, "table_prefix");
+<p> <pre> <a href="tqlistview.html">TQListView</a> * prefix = new <a href="tqlistview.html">TQListView</a>( container, "table_prefix");
handler-&gt;setListView( prefix );
reader.<a href="tqxmlsimplereader.html#setFeature">setFeature</a>( "http://xml.org/sax/features/namespaces", FALSE );
source.<a href="tqxmlinputsource.html#reset">reset</a>();
@@ -203,11 +203,11 @@ the GUI's event loop.
<p> We derive it from the <a href="tqxmldefaulthandler.html">TQXmlDefaultHandler</a> class that
implements a handler that simply does nothing.
<p> <pre> public:
- StructureParser( <a href="ntqlistview.html">TQListView</a> * );
+ StructureParser( <a href="tqlistview.html">TQListView</a> * );
</pre>
<p> This makes it easy for us to implement only the functionality
we in fact need. In our case this is the constructor that
-takes a <a href="ntqlistview.html">TQListView</a> as an argument,
+takes a <a href="tqlistview.html">TQListView</a> as an argument,
<p> <pre> bool startElement( const <a href="tqstring.html">TQString</a>&amp;, const <a href="tqstring.html">TQString</a>&amp;, const <a href="tqstring.html">TQString</a>&amp; ,
const <a href="tqxmlattributes.html">TQXmlAttributes</a>&amp; );
</pre>
@@ -217,7 +217,7 @@ takes a <a href="ntqlistview.html">TQListView</a> as an argument,
</pre>
<p> the code to run when an end tag occurs.
<p> All we have to implement so far is content handling.
-<p> <pre> void setListView( <a href="ntqlistview.html">TQListView</a> * );
+<p> <pre> void setListView( <a href="tqlistview.html">TQListView</a> * );
</pre>
<p> In addition we have a function that selects a listview
for the output.
@@ -233,7 +233,7 @@ that haven't been closed yet.
of TQListItems. An element will be added to the stack when
its start tag appears and removed
as soon as its end tag is parsed.
-<p> <pre> <a href="ntqlistview.html">TQListView</a> * table;
+<p> <pre> <a href="tqlistview.html">TQListView</a> * table;
};
</pre>
<p> Apart from this we define a member variable that contains
@@ -246,9 +246,9 @@ relevant functions.
<pre> #include "structureparser.h"
#include &lt;<a href="tqstring-h.html">tqstring.h</a>&gt;
- #include &lt;<a href="qlistview-h.html">ntqlistview.h</a>&gt;
+ #include &lt;<a href="tqlistview-h.html">tqlistview.h</a>&gt;
</pre>
-<p> <pre> StructureParser::StructureParser( <a href="ntqlistview.html">TQListView</a> * t )
+<p> <pre> StructureParser::StructureParser( <a href="tqlistview.html">TQListView</a> * t )
: <a href="tqxmldefaulthandler.html">TQXmlDefaultHandler</a>()
{
</pre>
@@ -257,10 +257,10 @@ its argument.
<p> <pre> setListView( t );
}
</pre>
-<p> All we have to do here is to prepare the argument <a href="ntqlistview.html">TQListView</a>
+<p> All we have to do here is to prepare the argument <a href="tqlistview.html">TQListView</a>
before usage. This we do with the <a href="#setListView()">setListView()</a> function.
<p> <a name="setListView()"></a>
-<pre> void StructureParser::setListView( <a href="ntqlistview.html">TQListView</a> * t )
+<pre> void StructureParser::setListView( <a href="tqlistview.html">TQListView</a> * t )
{
table = t;
</pre>
@@ -295,43 +295,43 @@ namespace URIs at all <em>namespaceURI</em> contains an empty
string.
<p> Note that we don't assign a variable to the second argument --
we're simply not interested in the local name of the element.
-<p> <pre> <a href="qlistviewitem.html">TQListViewItem</a> * element;
+<p> <pre> <a href="tqlistviewitem.html">TQListViewItem</a> * element;
</pre>
<p> Whenever an element occurs we want to show it in the listview.
-Therefore we define a <a href="qlistviewitem.html">TQListViewItem</a> variable.
+Therefore we define a <a href="tqlistviewitem.html">TQListViewItem</a> variable.
<p> <pre> if ( ! stack.isEmpty() ){
- <a href="qlistviewitem.html">TQListViewItem</a> *lastChild = stack.top()-&gt;firstChild();
+ <a href="tqlistviewitem.html">TQListViewItem</a> *lastChild = stack.top()-&gt;firstChild();
</pre>
<p> As long as the element <em>stack</em> isn't empty the current element
is a child of the topmost (last unclosed) element on the stack. Thus we
-create a new <a href="qlistviewitem.html">TQListViewItem</a> as a child of TQPtrStack::stack.top() with
+create a new <a href="tqlistviewitem.html">TQListViewItem</a> as a child of TQPtrStack::stack.top() with
the new element's qualified name in the first column and the according
namespace URI (or nothing) in the second one.
-<p> The <a href="qlistviewitem.html">TQListViewItem</a> is usally inserted as the first child. This means that we
+<p> The <a href="tqlistviewitem.html">TQListViewItem</a> is usally inserted as the first child. This means that we
would get the elements in reverse order. So we first search for the last
child of the TQPtrStack::stack.top() element and insert it after this
element.
<p> In a valid XML document this applies to all elements except
the document root.
<p> <pre> if ( lastChild ) {
- while ( lastChild-&gt;<a href="qlistviewitem.html#nextSibling">nextSibling</a>() )
- lastChild = lastChild-&gt;<a href="qlistviewitem.html#nextSibling">nextSibling</a>();
+ while ( lastChild-&gt;<a href="tqlistviewitem.html#nextSibling">nextSibling</a>() )
+ lastChild = lastChild-&gt;<a href="tqlistviewitem.html#nextSibling">nextSibling</a>();
}
- element = new <a href="qlistviewitem.html">TQListViewItem</a>( stack.top(), lastChild, qName, namespaceURI );
+ element = new <a href="tqlistviewitem.html">TQListViewItem</a>( stack.top(), lastChild, qName, namespaceURI );
} else {
- element = new <a href="qlistviewitem.html">TQListViewItem</a>( table, qName, namespaceURI );
+ element = new <a href="tqlistviewitem.html">TQListViewItem</a>( table, qName, namespaceURI );
}
</pre>
<p> The root element we have to handle separately because it is
-the first element to go onto the <a href="qlistviewitem.html">TQListViewItem</a> stack.
+the first element to go onto the <a href="tqlistviewitem.html">TQListViewItem</a> stack.
Its listview item is therefore a direct child of the
<em>table</em> listview itself.
<p> <pre> stack.push( element );
</pre>
<p> Now we put the element's listview item on top of the stack.
-<p> <pre> element-&gt;<a href="qlistviewitem.html#setOpen">setOpen</a>( TRUE );
+<p> <pre> element-&gt;<a href="tqlistviewitem.html#setOpen">setOpen</a>( TRUE );
</pre>
-<p> By default a <a href="ntqlistview.html">TQListView</a> presents all of its nodes closed.
+<p> By default a <a href="tqlistview.html">TQListView</a> presents all of its nodes closed.
The user may then click on the <em>+</em> icon to see the child
entries.
<p> We however want to see the entire element tree
@@ -341,7 +341,7 @@ Therefore we open each listview item manually.
</pre>
<p> What do we do if an element has attributes?
<p> <pre> <a name="x2105"></a> for ( int i = 0 ; i &lt; attributes.<a href="tqxmlattributes.html#length">length</a>(); i++ ) {
- <a name="x2107"></a><a name="x2106"></a> new <a href="qlistviewitem.html">TQListViewItem</a>( element, attributes.<a href="tqxmlattributes.html#qName">qName</a>(i), attributes.<a href="tqxmlattributes.html#uri">uri</a>(i) );
+ <a name="x2107"></a><a name="x2106"></a> new <a href="tqlistviewitem.html">TQListViewItem</a>( element, attributes.<a href="tqxmlattributes.html#qName">qName</a>(i), attributes.<a href="tqxmlattributes.html#uri">uri</a>(i) );
}
}
</pre>