author | Jonathan Harrington <jonathan.harrington@nokia.com> |
Wed, 11 Aug 2010 14:49:30 +0100 | |
changeset 4 | 468f4c8d3d5b |
parent 3 | d8fccb2cd802 |
permissions | -rw-r--r-- |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
2 |
#include "xmldita.h" |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
3 |
#include "xmlditadocvisitor.h" |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
4 |
#include "xmlditatrace.h" |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
5 |
#include "docparser.h" |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
6 |
#include "language.h" |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
7 |
#include "doxygen.h" |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
8 |
#include "outputgen.h" |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
9 |
#include "xmlgen.h" |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
10 |
#include "dot.h" |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
11 |
#include "message.h" |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
12 |
#include "util.h" |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
13 |
#include <qfileinfo.h> |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
14 |
#include "parserintf.h" |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
15 |
|
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
16 |
// <simpletable> support |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
17 |
static const char* ELEM_SIMPLETABLE = "simpletable"; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
18 |
static const char* ELEM_SIMPLETABLEROW = "strow"; |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
19 |
|
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
20 |
//XmlDitaDocVisitor(XmlStream &s,CodeOutputInterface &ci, DocBlockContents *docBlockMaps); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
21 |
XmlDitaDocVisitor::XmlDitaDocVisitor(XmlStream &s,CodeOutputInterface &ci, DocBlockContents *docBlockMaps) |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
22 |
: DocVisitor(DocVisitor_XML), |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
23 |
xmlStream(s), |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
24 |
xmlElemStack(s), |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
25 |
m_ci(ci), |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
26 |
m_insidePre(false), |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
27 |
m_hide(false), |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
28 |
m_insideParamlist(false), |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
29 |
m_paramIsTemplate(false), |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
30 |
m_docBlockMaps(docBlockMaps), |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
31 |
m_writingDl(false), |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
32 |
m_mustInsertStrow(false), |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
33 |
m_strowOrStheadIsPending(false), |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
34 |
m_addTextToReturnDoc(false), |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
35 |
m_paraRefCount(0) |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
36 |
{ |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
37 |
//paramDict.setAutoDelete(true); |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
38 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
39 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
40 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
41 |
//-------------------------------------- |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
42 |
// visitor functions for leaf nodes |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
43 |
//-------------------------------------- |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
44 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
45 |
void XmlDitaDocVisitor::visit(DocWord *w) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
46 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
47 |
DITA_DOC_VISITOR_TRACE("XmlDitaDocVisitor::visit(DocWord*)", w) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
48 |
if (m_hide) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
49 |
return; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
50 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
51 |
// Catches normal text (text outside of a tag or command) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
52 |
// and puts it in a "p" |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
53 |
if (xmlElemStack.isEmpty()) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
54 |
visitPreDefault("p"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
55 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
56 |
write(w->word()); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
57 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
58 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
59 |
void XmlDitaDocVisitor::visit(DocLinkedWord *w) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
60 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
61 |
DITA_DOC_VISITOR_TRACE("XmlDitaDocVisitor::visit(DocLinkedWord*)", w) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
62 |
if (m_hide) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
63 |
return; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
64 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
65 |
//printf("XmlDitaDocVisitor calling startLink() DocLinkedWord=`%s'\n", w->word().data()); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
66 |
Definition *d = w->getDefinition(); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
67 |
if (0) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
68 |
QString myName; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
69 |
myName = d->qualifiedName(); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
70 |
//printf("XmlDitaDocVisitor calling startLink() DocLinkedWord [name]=`%s'\n", myName.data()); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
71 |
startLink("", myName, ""); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
72 |
} else { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
73 |
//printf("XmlDitaDocVisitor calling startLink() DocLinkedWord [file]=`%s'\n", w->file().data()); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
74 |
#if DITA_SUPRESS_NAMESPACE_LINKS |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
75 |
if (w->file().find("namespace") != 0) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
76 |
startLink(w->ref(), w->file(), w->anchor()); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
77 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
78 |
#else |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
79 |
startLink(w->ref(), w->file(), w->anchor()); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
80 |
#endif |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
81 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
82 |
write(w->word()); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
83 |
#if DITA_SUPRESS_NAMESPACE_LINKS |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
84 |
if (w->file().find("namespace") != 0) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
85 |
endLink(); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
86 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
87 |
#else |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
88 |
endLink(); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
89 |
#endif |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
90 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
91 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
92 |
void XmlDitaDocVisitor::visit(DocWhiteSpace *w) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
93 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
94 |
DITA_DOC_VISITOR_TRACE("XmlDitaDocVisitor::visit(DocWhiteSpace*)", w) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
95 |
if (m_hide) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
96 |
return; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
97 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
98 |
if (m_insidePre) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
99 |
write(w->chars()); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
100 |
} else { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
101 |
write(" "); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
102 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
103 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
104 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
105 |
void XmlDitaDocVisitor::visit(DocSymbol *s) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
106 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
107 |
DITA_DOC_VISITOR_TRACE("XmlDitaDocVisitor::visit(DocSymbol*)", s) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
108 |
if (m_hide) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
109 |
return; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
110 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
111 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
112 |
switch(s->symbol()) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
113 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
114 |
case DocSymbol::BSlash: write("\\"); break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
115 |
case DocSymbol::At: write("@"); break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
116 |
// NOTE: The XMl stream will translate entities i.e. "&" to "&" |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
117 |
case DocSymbol::Less: write("<"); break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
118 |
case DocSymbol::Greater: write(">"); break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
119 |
case DocSymbol::Amp: write("&"); break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
120 |
case DocSymbol::Dollar: write("$"); break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
121 |
case DocSymbol::Hash: write("#"); break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
122 |
case DocSymbol::Percent: write("%"); break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
123 |
case DocSymbol::Apos: write("'"); break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
124 |
case DocSymbol::Quot: write("\""); break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
125 |
case DocSymbol::Copy: xmlStream.writeUnicode("copy"); break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
126 |
case DocSymbol::Tm: xmlStream.writeUnicode("trade"); break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
127 |
case DocSymbol::Reg: xmlStream.writeUnicode("reg"); break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
128 |
case DocSymbol::Lsquo: xmlStream.writeUnicode("lsquo"); break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
129 |
case DocSymbol::Rsquo: xmlStream.writeUnicode("rsquo"); break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
130 |
case DocSymbol::Ldquo: xmlStream.writeUnicode("ldquo"); break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
131 |
case DocSymbol::Rdquo: xmlStream.writeUnicode("rdquo"); break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
132 |
case DocSymbol::Ndash: xmlStream.writeUnicode("ndash"); break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
133 |
case DocSymbol::Mdash: xmlStream.writeUnicode("mdash"); break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
134 |
case DocSymbol::Uml: xmlStream.writeUnicode((const char*)(QString(QChar(s->letter()))+"uml")); break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
135 |
case DocSymbol::Acute: xmlStream.writeUnicode((const char*)(QString(QChar(s->letter()))+"acute")); break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
136 |
case DocSymbol::Grave: xmlStream.writeUnicode((const char*)(QString(QChar(s->letter()))+"grave")); break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
137 |
case DocSymbol::Circ: xmlStream.writeUnicode((const char*)(QString(QChar(s->letter()))+"circ")); break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
138 |
case DocSymbol::Tilde: xmlStream.writeUnicode((const char*)(QString(QChar(s->letter()))+"tilde")); break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
139 |
case DocSymbol::Cedil: xmlStream.writeUnicode((const char*)(QString(QChar(s->letter()))+"cedil")); break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
140 |
case DocSymbol::Ring: xmlStream.writeUnicode((const char*)(QString(QChar(s->letter()))+"ring")); break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
141 |
case DocSymbol::Slash: xmlStream.writeUnicode((const char*)(QString(QChar(s->letter()))+"slash")); break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
142 |
case DocSymbol::Szlig: xmlStream.writeUnicode("szlig"); break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
143 |
case DocSymbol::Nbsp: xmlStream.writeUnicode("nbsp"); break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
144 |
case DocSymbol::Aelig: xmlStream.writeUnicode("aelig"); break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
145 |
case DocSymbol::AElig: xmlStream.writeUnicode("AElig"); break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
146 |
default: |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
147 |
err("Error: unknown symbol found\n"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
148 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
149 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
150 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
151 |
void XmlDitaDocVisitor::visit(DocURL *u) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
152 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
153 |
DITA_DOC_VISITOR_TRACE("XmlDitaDocVisitor::visit(DocURL*)", u) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
154 |
if (m_hide) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
155 |
return; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
156 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
157 |
if (u->isEmail()) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
158 |
startXref(QString("mailto:")+QString(u->url()), u->url()); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
159 |
} else { |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
160 |
// Need format attribute for external URLs to prevent DITA proccessing persuing |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
161 |
// external links |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
162 |
AttributeMap myMap; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
163 |
myMap["href"] = u->url(); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
164 |
myMap["format"] = "html"; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
165 |
push("xref", myMap); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
166 |
write(u->url()); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
167 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
168 |
endXref(); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
169 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
170 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
171 |
void XmlDitaDocVisitor::visit(DocLineBreak *lb) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
172 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
173 |
DITA_DOC_VISITOR_TRACE("XmlDitaDocVisitor::visit(DocLineBreak*)", lb) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
174 |
if (m_hide){ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
175 |
return; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
176 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
177 |
if (m_insidePre) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
178 |
write("\n"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
179 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
180 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
181 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
182 |
void XmlDitaDocVisitor::visit(DocHorRuler *) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
183 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
184 |
DITA_DOC_VISITOR_TRACE_NOARG("XmlDitaDocVisitor::visitPre(DocHorRuler*)") |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
185 |
if (m_hide) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
186 |
return; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
187 |
} |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
188 |
xmlStream.comment(" hruler not supported by DITA 1.1 "); |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
189 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
190 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
191 |
void XmlDitaDocVisitor::visit(DocStyleChange *s) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
192 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
193 |
DITA_DOC_VISITOR_TRACE("XmlDitaDocVisitor::visit(DocStyleChange*)", s) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
194 |
if (m_hide) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
195 |
return; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
196 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
197 |
switch (s->style()) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
198 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
199 |
case DocStyleChange::Bold: |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
200 |
if (s->enable()) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
201 |
push("b"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
202 |
} else { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
203 |
pop("b"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
204 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
205 |
break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
206 |
case DocStyleChange::Italic: |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
207 |
if (s->enable()) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
208 |
push("i"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
209 |
} else { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
210 |
pop("i"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
211 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
212 |
break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
213 |
case DocStyleChange::Code: |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
214 |
if (s->enable()) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
215 |
push("tt"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
216 |
} else { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
217 |
pop("tt"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
218 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
219 |
break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
220 |
case DocStyleChange::Subscript: |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
221 |
if (s->enable()) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
222 |
push("sub"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
223 |
} else { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
224 |
pop("sub"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
225 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
226 |
break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
227 |
case DocStyleChange::Superscript: |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
228 |
if (s->enable()) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
229 |
push("sup"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
230 |
} else { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
231 |
pop("sup"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
232 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
233 |
break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
234 |
case DocStyleChange::Center: |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
235 |
if (s->enable()) { |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
236 |
xmlStream.comment(" center not supported by DITA 1.1 "); |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
237 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
238 |
break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
239 |
case DocStyleChange::Small: |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
240 |
if (s->enable()) { |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
241 |
xmlStream.comment(" small not supported by DITA 1.1 "); |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
242 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
243 |
break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
244 |
case DocStyleChange::Preformatted: |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
245 |
if (s->enable()) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
246 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
247 |
push("pre"); |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
248 |
m_insidePre = true; |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
249 |
} else { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
250 |
pop("pre"); |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
251 |
m_insidePre = false; |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
252 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
253 |
break; |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
254 |
case DocStyleChange::Div: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
255 |
if (s->enable()) { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
256 |
xmlStream.comment(" div not supported by DITA 1.1 "); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
257 |
} |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
258 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
259 |
case DocStyleChange::Span: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
260 |
if (s->enable()) { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
261 |
xmlStream.comment(" span not supported by DITA 1.1 "); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
262 |
} |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
263 |
break; |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
264 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
265 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
266 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
267 |
void XmlDitaDocVisitor::visit(DocVerbatim *s) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
268 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
269 |
DITA_DOC_VISITOR_TRACE("XmlDitaDocVisitor::visit(DocVerbatim*)", s) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
270 |
if (m_hide) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
271 |
return; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
272 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
273 |
switch(s->type()) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
274 |
{ |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
275 |
// Note fall through |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
276 |
case DocVerbatim::Code: |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
277 |
case DocVerbatim::Verbatim: |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
278 |
case DocVerbatim::XmlOnly: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
279 |
pushpop("codeblock", s->text()); |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
280 |
break; |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
281 |
// Note fall through |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
282 |
case DocVerbatim::HtmlOnly: |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
283 |
case DocVerbatim::ManOnly: |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
284 |
case DocVerbatim::LatexOnly: |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
285 |
case DocVerbatim::Dot: |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
286 |
case DocVerbatim::Msc: |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
287 |
break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
288 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
289 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
290 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
291 |
void XmlDitaDocVisitor::visit(DocAnchor *anc) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
292 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
293 |
DITA_DOC_VISITOR_TRACE("XmlDitaDocVisitor::visit(DocAnchor*)", anc) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
294 |
if (m_hide) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
295 |
return; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
296 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
297 |
xmlElemStack.addAttribute("id", anc->file()+"_1"+anc->anchor()); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
298 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
299 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
300 |
void XmlDitaDocVisitor::visit(DocInclude *inc) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
301 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
302 |
DITA_DOC_VISITOR_TRACE("XmlDitaDocVisitor::visit(DocInclude*)", inc) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
303 |
if (m_hide) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
304 |
return; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
305 |
} |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
306 |
switch(inc->type()) { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
307 |
case DocInclude::IncWithLines: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
308 |
{ |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
309 |
push("codeblock"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
310 |
QFileInfo cfi(inc->file()); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
311 |
FileDef fd(cfi.dirPath(), cfi.fileName()); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
312 |
Doxygen::parserManager->getParser(inc->extension())->parseCode( |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
313 |
m_ci,inc->context(), |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
314 |
inc->text().latin1(), |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
315 |
inc->isExample(), |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
316 |
inc->exampleFile(), |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
317 |
&fd |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
318 |
); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
319 |
pop("codeblock"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
320 |
} |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
321 |
break; |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
322 |
case DocInclude::Include: |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
323 |
push("codeblock"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
324 |
Doxygen::parserManager->getParser(inc->extension())->parseCode( |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
325 |
m_ci,inc->context(), |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
326 |
inc->text().latin1(), |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
327 |
inc->isExample(), |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
328 |
inc->exampleFile() |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
329 |
); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
330 |
pop("codeblock"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
331 |
break; |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
332 |
case DocInclude::DontInclude: |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
333 |
break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
334 |
case DocInclude::HtmlInclude: |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
335 |
break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
336 |
case DocInclude::VerbInclude: |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
337 |
pushpop("pre", inc->text()); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
338 |
break; |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
339 |
} |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
340 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
341 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
342 |
void XmlDitaDocVisitor::visit(DocIncOperator *op) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
343 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
344 |
DITA_DOC_VISITOR_TRACE("XmlDitaDocVisitor::visit(DocIncOperator*)", op) |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
345 |
if (op->isFirst()) { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
346 |
if (!m_hide) { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
347 |
push("codeblock"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
348 |
} |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
349 |
pushEnabled(); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
350 |
m_hide = true; |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
351 |
} |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
352 |
if (op->type()!=DocIncOperator::Skip) { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
353 |
popEnabled(); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
354 |
if (!m_hide) { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
355 |
Doxygen::parserManager->getParser(m_langExt)->parseCode( |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
356 |
m_ci,op->context(), |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
357 |
op->text().latin1(), |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
358 |
op->isExample(), |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
359 |
op->exampleFile() |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
360 |
); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
361 |
} |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
362 |
pushEnabled(); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
363 |
m_hide=true; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
364 |
} |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
365 |
if (op->isLast()) { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
366 |
popEnabled(); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
367 |
if (!m_hide) { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
368 |
pop("codeblock"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
369 |
} |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
370 |
} |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
371 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
372 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
373 |
void XmlDitaDocVisitor::visit(DocFormula *f) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
374 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
375 |
DITA_DOC_VISITOR_TRACE("XmlDitaDocVisitor::visit(DocFormula*)", f) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
376 |
write(f->text()); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
377 |
#if 0 |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
378 |
if (m_hide) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
379 |
return; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
380 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
381 |
QString s; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
382 |
s.setNum(f->id()); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
383 |
push("formula", "id", s); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
384 |
write(f->text()); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
385 |
pop("formula"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
386 |
#endif |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
387 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
388 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
389 |
void XmlDitaDocVisitor::visit(DocIndexEntry *ie) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
390 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
391 |
DITA_DOC_VISITOR_TRACE("XmlDitaDocVisitor::visit(DocIndexEntry*)", ie) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
392 |
if (m_hide) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
393 |
return; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
394 |
} |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
395 |
pushpop("indexterm", ie->entry()); |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
396 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
397 |
|
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
398 |
void XmlDitaDocVisitor::visit(DocSimpleSectSep *ss) |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
399 |
{ |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
400 |
DITA_DOC_VISITOR_TRACE("XmlDitaDocVisitor::visit(DocSimpleSectSep*)", ss) |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
401 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
402 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
403 |
//-------------------------------------- |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
404 |
// visitor functions for compound nodes |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
405 |
//-------------------------------------- |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
406 |
void XmlDitaDocVisitor::visitPre(DocAutoList *l) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
407 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
408 |
DITA_DOC_VISITOR_TRACE("XmlDitaDocVisitor::visitPre(DocAutoList*)", l) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
409 |
if (l->isEnumList()) { |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
410 |
visitPreDefault("ol"); |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
411 |
} else { |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
412 |
visitPreDefault("ul"); |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
413 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
414 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
415 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
416 |
void XmlDitaDocVisitor::visitPost(DocAutoList *l) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
417 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
418 |
DITA_DOC_VISITOR_TRACE("XmlDitaDocVisitor::visitPost(DocAutoList*)", l) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
419 |
if (l->isEnumList()) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
420 |
visitPostDefault("ol"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
421 |
} else { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
422 |
visitPostDefault("ul"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
423 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
424 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
425 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
426 |
void XmlDitaDocVisitor::visitPre(DocAutoListItem *) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
427 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
428 |
DITA_DOC_VISITOR_TRACE_NOARG("XmlDitaDocVisitor::visitPre(DocAutoListItem*)") |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
429 |
visitPreDefault("li"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
430 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
431 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
432 |
void XmlDitaDocVisitor::visitPost(DocAutoListItem *) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
433 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
434 |
DITA_DOC_VISITOR_TRACE_NOARG("XmlDitaDocVisitor::visitPost(DocAutoListItem*)") |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
435 |
visitPostDefault("li"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
436 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
437 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
438 |
void XmlDitaDocVisitor::visitPre(DocPara *p) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
439 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
440 |
DITA_DOC_VISITOR_TRACE("XmlDitaDocVisitor::visitPre(DocPara*)", p) |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
441 |
if (m_writingDl) { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
442 |
// Do an asymetric pop/push for dt/dd |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
443 |
// Can not guarentee that we have a "dt" at the top of the stack so can not pop("dt") |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
444 |
pop(); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
445 |
push("dd"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
446 |
} else if (canPushPara()) { |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
447 |
visitPreDefault("p"); |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
448 |
} else if (!canPushPara()) { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
449 |
m_paraRefCount += 1; |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
450 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
451 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
452 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
453 |
void XmlDitaDocVisitor::visitPost(DocPara *) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
454 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
455 |
DITA_DOC_VISITOR_TRACE_NOARG("XmlDitaDocVisitor::visitPost(DocPara*)") |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
456 |
if (!m_writingDl && m_paraRefCount == 0 && canPopPara()) { |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
457 |
visitPostDefault("p"); |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
458 |
} else if (m_paraRefCount > 0){ |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
459 |
m_paraRefCount -= 1; |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
460 |
} |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
461 |
ASSERT(m_paraRefCount >= 0); |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
462 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
463 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
464 |
void XmlDitaDocVisitor::visitPre(DocRoot *) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
465 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
466 |
DITA_DOC_VISITOR_TRACE_NOARG("XmlDitaDocVisitor::visitPre(DocRoot*)") |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
467 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
468 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
469 |
void XmlDitaDocVisitor::visitPost(DocRoot *) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
470 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
471 |
DITA_DOC_VISITOR_TRACE_NOARG("XmlDitaDocVisitor::visitPost(DocRoot*)") |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
472 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
473 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
474 |
void XmlDitaDocVisitor::visitPre(DocSimpleSect *s) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
475 |
{ |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
476 |
#ifdef DITA_TRACE |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
477 |
// Trace stuff |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
478 |
switch(s->type()) { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
479 |
case DocSimpleSect::See: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
480 |
DITA_DOC_VISITOR_TRACE_STRING(" XmlDitaDocVisitor::visitPre(DocSimpleSect*): case DocSimpleSect::See: ") |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
481 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
482 |
case DocSimpleSect::Author: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
483 |
DITA_DOC_VISITOR_TRACE_STRING(" XmlDitaDocVisitor::visitPre(DocSimpleSect*): case DocSimpleSect::Author: ") |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
484 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
485 |
case DocSimpleSect::Authors: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
486 |
DITA_DOC_VISITOR_TRACE_STRING(" XmlDitaDocVisitor::visitPre(DocSimpleSect*): case DocSimpleSect::Authors: ") |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
487 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
488 |
case DocSimpleSect::Version: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
489 |
DITA_DOC_VISITOR_TRACE_STRING(" XmlDitaDocVisitor::visitPre(DocSimpleSect*): case DocSimpleSect::Version: ") |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
490 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
491 |
case DocSimpleSect::Since: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
492 |
DITA_DOC_VISITOR_TRACE_STRING(" XmlDitaDocVisitor::visitPre(DocSimpleSect*): case DocSimpleSect::Since: ") |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
493 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
494 |
case DocSimpleSect::Date: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
495 |
DITA_DOC_VISITOR_TRACE_STRING(" XmlDitaDocVisitor::visitPre(DocSimpleSect*): case DocSimpleSect::Date: ") |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
496 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
497 |
case DocSimpleSect::Invar: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
498 |
DITA_DOC_VISITOR_TRACE_STRING(" XmlDitaDocVisitor::visitPre(DocSimpleSect*): case DocSimpleSect::Invar: ") |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
499 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
500 |
case DocSimpleSect::Rcs: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
501 |
DITA_DOC_VISITOR_TRACE_STRING(" XmlDitaDocVisitor::visitPre(DocSimpleSect*): case DocSimpleSect::Rcs: ") |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
502 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
503 |
case DocSimpleSect::Pre: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
504 |
DITA_DOC_VISITOR_TRACE_STRING(" XmlDitaDocVisitor::visitPre(DocSimpleSect*): case DocSimpleSect::Pre: ") |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
505 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
506 |
case DocSimpleSect::Post: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
507 |
DITA_DOC_VISITOR_TRACE_STRING(" XmlDitaDocVisitor::visitPre(DocSimpleSect*): case DocSimpleSect::Post: ") |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
508 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
509 |
case DocSimpleSect::User: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
510 |
DITA_DOC_VISITOR_TRACE_STRING(" XmlDitaDocVisitor::visitPre(DocSimpleSect*): case DocSimpleSect::User: ") |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
511 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
512 |
case DocSimpleSect::Note: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
513 |
DITA_DOC_VISITOR_TRACE_STRING(" XmlDitaDocVisitor::visitPre(DocSimpleSect*): case DocSimpleSect::Note: ") |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
514 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
515 |
case DocSimpleSect::Warning: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
516 |
DITA_DOC_VISITOR_TRACE_STRING(" XmlDitaDocVisitor::visitPre(DocSimpleSect*): case DocSimpleSect::Warning: ") |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
517 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
518 |
case DocSimpleSect::Remark: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
519 |
DITA_DOC_VISITOR_TRACE_STRING(" XmlDitaDocVisitor::visitPre(DocSimpleSect*): case DocSimpleSect::Remark: ") |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
520 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
521 |
case DocSimpleSect::Attention: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
522 |
DITA_DOC_VISITOR_TRACE_STRING(" XmlDitaDocVisitor::visitPre(DocSimpleSect*): case DocSimpleSect::Attention: ") |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
523 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
524 |
case DocSimpleSect::Unknown: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
525 |
DITA_DOC_VISITOR_TRACE_STRING(" XmlDitaDocVisitor::visitPre(DocSimpleSect*): case DocSimpleSect::Unknown: ") |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
526 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
527 |
case DocSimpleSect::Return: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
528 |
DITA_DOC_VISITOR_TRACE_STRING(" XmlDitaDocVisitor::visitPre(DocSimpleSect*): case DocSimpleSect::Return: ") |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
529 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
530 |
default: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
531 |
ASSERT(0); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
532 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
533 |
} |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
534 |
#endif // DITA_TRACE |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
535 |
if (m_hide) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
536 |
return; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
537 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
538 |
switch(s->type()) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
539 |
{ |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
540 |
// Note Fall through, render as simple paragraph |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
541 |
case DocSimpleSect::See: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
542 |
case DocSimpleSect::Invar: |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
543 |
case DocSimpleSect::Rcs: |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
544 |
if (canPushPara()) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
545 |
push("p"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
546 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
547 |
break; |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
548 |
// |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
549 |
// Types that make a definition list |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
550 |
// |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
551 |
case DocSimpleSect::Author: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
552 |
pushDl("author"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
553 |
write("Author"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
554 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
555 |
case DocSimpleSect::Authors: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
556 |
pushDl("authors"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
557 |
write("Authors"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
558 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
559 |
case DocSimpleSect::Version: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
560 |
pushDl("version"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
561 |
write("Version"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
562 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
563 |
case DocSimpleSect::Since: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
564 |
pushDl("since"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
565 |
write("Since"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
566 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
567 |
case DocSimpleSect::Date: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
568 |
pushDl("date"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
569 |
write("Date"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
570 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
571 |
case DocSimpleSect::Pre: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
572 |
pushDl("precondition"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
573 |
write("Pre-condition"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
574 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
575 |
case DocSimpleSect::Post: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
576 |
pushDl("postcondition"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
577 |
write("Post-condition"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
578 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
579 |
case DocSimpleSect::User: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
580 |
// ALIAS tags are rendered as definition lists |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
581 |
pushDl("user"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
582 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
583 |
// |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
584 |
// Make a note element |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
585 |
// |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
586 |
case DocSimpleSect::Note: |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
587 |
push("note", "type", "note"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
588 |
break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
589 |
case DocSimpleSect::Warning: |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
590 |
push("note", "type", "caution"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
591 |
break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
592 |
case DocSimpleSect::Remark: |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
593 |
push("note", "type", "other"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
594 |
break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
595 |
case DocSimpleSect::Attention: |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
596 |
push("note", "type", "attention"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
597 |
break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
598 |
case DocSimpleSect::Unknown: |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
599 |
break; |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
600 |
case DocSimpleSect::Return: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
601 |
// Set flag to gather text into m_docBlockMaps->returnDoc rather than writing it out |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
602 |
//printf("Setting m_addTextToReturnDoc true\n"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
603 |
m_addTextToReturnDoc = true; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
604 |
break; |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
605 |
default: |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
606 |
ASSERT(0); |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
607 |
break; |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
608 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
609 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
610 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
611 |
void XmlDitaDocVisitor::visitPost(DocSimpleSect *s) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
612 |
{ |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
613 |
#ifdef DITA_TRACE |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
614 |
// Trace stuff |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
615 |
switch(s->type()) { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
616 |
case DocSimpleSect::See: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
617 |
DITA_DOC_VISITOR_TRACE_STRING(" XmlDitaDocVisitor::visitPost(DocSimpleSect*): case DocSimpleSect::See: ") |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
618 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
619 |
case DocSimpleSect::Author: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
620 |
DITA_DOC_VISITOR_TRACE_STRING(" XmlDitaDocVisitor::visitPost(DocSimpleSect*): case DocSimpleSect::Author: ") |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
621 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
622 |
case DocSimpleSect::Authors: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
623 |
DITA_DOC_VISITOR_TRACE_STRING(" XmlDitaDocVisitor::visitPost(DocSimpleSect*): case DocSimpleSect::Authors: ") |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
624 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
625 |
case DocSimpleSect::Version: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
626 |
DITA_DOC_VISITOR_TRACE_STRING(" XmlDitaDocVisitor::visitPost(DocSimpleSect*): case DocSimpleSect::Version: ") |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
627 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
628 |
case DocSimpleSect::Since: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
629 |
DITA_DOC_VISITOR_TRACE_STRING(" XmlDitaDocVisitor::visitPost(DocSimpleSect*): case DocSimpleSect::Since: ") |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
630 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
631 |
case DocSimpleSect::Date: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
632 |
DITA_DOC_VISITOR_TRACE_STRING(" XmlDitaDocVisitor::visitPost(DocSimpleSect*): case DocSimpleSect::Date: ") |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
633 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
634 |
case DocSimpleSect::Invar: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
635 |
DITA_DOC_VISITOR_TRACE_STRING(" XmlDitaDocVisitor::visitPost(DocSimpleSect*): case DocSimpleSect::Invar: ") |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
636 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
637 |
case DocSimpleSect::Rcs: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
638 |
DITA_DOC_VISITOR_TRACE_STRING(" XmlDitaDocVisitor::visitPost(DocSimpleSect*): case DocSimpleSect::Rcs: ") |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
639 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
640 |
case DocSimpleSect::Pre: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
641 |
DITA_DOC_VISITOR_TRACE_STRING(" XmlDitaDocVisitor::visitPost(DocSimpleSect*): case DocSimpleSect::Pre: ") |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
642 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
643 |
case DocSimpleSect::Post: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
644 |
DITA_DOC_VISITOR_TRACE_STRING(" XmlDitaDocVisitor::visitPost(DocSimpleSect*): case DocSimpleSect::Post: ") |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
645 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
646 |
case DocSimpleSect::User: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
647 |
DITA_DOC_VISITOR_TRACE_STRING(" XmlDitaDocVisitor::visitPost(DocSimpleSect*): case DocSimpleSect::User: ") |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
648 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
649 |
case DocSimpleSect::Note: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
650 |
DITA_DOC_VISITOR_TRACE_STRING(" XmlDitaDocVisitor::visitPost(DocSimpleSect*): case DocSimpleSect::Note: ") |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
651 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
652 |
case DocSimpleSect::Warning: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
653 |
DITA_DOC_VISITOR_TRACE_STRING(" XmlDitaDocVisitor::visitPost(DocSimpleSect*): case DocSimpleSect::Warning: ") |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
654 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
655 |
case DocSimpleSect::Remark: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
656 |
DITA_DOC_VISITOR_TRACE_STRING(" XmlDitaDocVisitor::visitPost(DocSimpleSect*): case DocSimpleSect::Remark: ") |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
657 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
658 |
case DocSimpleSect::Attention: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
659 |
DITA_DOC_VISITOR_TRACE_STRING(" XmlDitaDocVisitor::visitPost(DocSimpleSect*): case DocSimpleSect::Attention: ") |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
660 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
661 |
case DocSimpleSect::Unknown: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
662 |
DITA_DOC_VISITOR_TRACE_STRING(" XmlDitaDocVisitor::visitPost(DocSimpleSect*): case DocSimpleSect::Unknown: ") |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
663 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
664 |
case DocSimpleSect::Return: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
665 |
DITA_DOC_VISITOR_TRACE_STRING(" XmlDitaDocVisitor::visitPost(DocSimpleSect*): case DocSimpleSect::Return: ") |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
666 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
667 |
default: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
668 |
ASSERT(0); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
669 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
670 |
} |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
671 |
#endif // DITA_TRACE |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
672 |
if (m_hide) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
673 |
return; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
674 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
675 |
switch(s->type()) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
676 |
{ |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
677 |
case DocSimpleSect::See: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
678 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
679 |
// Note fall through |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
680 |
case DocSimpleSect::Invar: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
681 |
case DocSimpleSect::Rcs: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
682 |
if (m_paraRefCount == 0 && canPopPara()) { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
683 |
pop("p"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
684 |
} |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
685 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
686 |
// Note fall through for definiton lists |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
687 |
case DocSimpleSect::Author: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
688 |
case DocSimpleSect::Authors: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
689 |
case DocSimpleSect::Version: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
690 |
case DocSimpleSect::Since: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
691 |
case DocSimpleSect::Date: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
692 |
case DocSimpleSect::Pre: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
693 |
case DocSimpleSect::Post: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
694 |
case DocSimpleSect::User: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
695 |
popDl(); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
696 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
697 |
// Note fall through for note element |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
698 |
case DocSimpleSect::Note: |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
699 |
case DocSimpleSect::Warning: |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
700 |
case DocSimpleSect::Remark: |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
701 |
case DocSimpleSect::Attention: |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
702 |
pop("note"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
703 |
break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
704 |
case DocSimpleSect::Unknown: |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
705 |
break; |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
706 |
case DocSimpleSect::Return: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
707 |
// Unset flag to gather text into m_docBlockMaps->returnDoc |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
708 |
//printf("Setting m_addTextToReturnDoc false\n"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
709 |
m_addTextToReturnDoc = false; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
710 |
break; |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
711 |
default: |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
712 |
ASSERT(0); |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
713 |
break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
714 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
715 |
//visitPostDefault("simplesect"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
716 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
717 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
718 |
void XmlDitaDocVisitor::visitPre(DocTitle *) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
719 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
720 |
DITA_DOC_VISITOR_TRACE_NOARG("XmlDitaDocVisitor::visitPre(DocTitle*)") |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
721 |
if (!xmlElemStack.isEmpty() && xmlElemStack.peek().getElemName() == "concept") { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
722 |
visitPreDefault("title"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
723 |
} else { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
724 |
if (canPushPara()) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
725 |
visitPreDefault("p"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
726 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
727 |
visitPreDefault("b"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
728 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
729 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
730 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
731 |
void XmlDitaDocVisitor::visitPost(DocTitle *) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
732 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
733 |
DITA_DOC_VISITOR_TRACE_NOARG("XmlDitaDocVisitor::visitPost(DocTitle*)") |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
734 |
if (!xmlElemStack.isEmpty() && xmlElemStack.peek().getElemName() == "title") { |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
735 |
visitPostDefault("title"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
736 |
} else { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
737 |
visitPostDefault("b"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
738 |
if (canPopPara()) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
739 |
visitPostDefault("p"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
740 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
741 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
742 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
743 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
744 |
void XmlDitaDocVisitor::visitPre(DocSimpleList *) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
745 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
746 |
DITA_DOC_VISITOR_TRACE_NOARG("XmlDitaDocVisitor::visitPre(DocSimpleList*)") |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
747 |
visitPreDefault("ul"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
748 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
749 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
750 |
void XmlDitaDocVisitor::visitPost(DocSimpleList *) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
751 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
752 |
DITA_DOC_VISITOR_TRACE_NOARG("XmlDitaDocVisitor::visitPost(DocSimpleList*)") |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
753 |
visitPostDefault("ul"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
754 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
755 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
756 |
void XmlDitaDocVisitor::visitPre(DocSimpleListItem *) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
757 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
758 |
DITA_DOC_VISITOR_TRACE_NOARG("XmlDitaDocVisitor::visitPre(DocSimpleListItem*)") |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
759 |
visitPreDefault("li"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
760 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
761 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
762 |
void XmlDitaDocVisitor::visitPost(DocSimpleListItem *) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
763 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
764 |
DITA_DOC_VISITOR_TRACE_NOARG("XmlDitaDocVisitor::visitPost(DocSimpleListItem*)") |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
765 |
visitPostDefault("li"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
766 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
767 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
768 |
void XmlDitaDocVisitor::visitPre(DocSection *s) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
769 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
770 |
DITA_DOC_VISITOR_TRACE("XmlDitaDocVisitor::visitPre(DocSection*)", s) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
771 |
// Currently unsupported |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
772 |
xmlStream.comment(" XmlDitaDocVisitor::visitPre(DocSection*) not currently supported by DITA 1.1 "); |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
773 |
#if 0 |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
774 |
if (m_hide) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
775 |
return; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
776 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
777 |
QString sectNum; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
778 |
sectNum.setNum(s->level()); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
779 |
QString sectAnchor(s->file()); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
780 |
if (!s->anchor().isEmpty()) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
781 |
sectAnchor.append("_1"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
782 |
sectAnchor.append(s->anchor()); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
783 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
784 |
push("sect"+sectNum, "id", sectAnchor); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
785 |
pushpop("title", s->title()); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
786 |
#endif |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
787 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
788 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
789 |
void XmlDitaDocVisitor::visitPost(DocSection *s) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
790 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
791 |
DITA_DOC_VISITOR_TRACE("XmlDitaDocVisitor::visitPost(DocSection*)", s) |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
792 |
xmlStream.comment(" XmlDitaDocVisitor::visitPre(DocSection*) not currently supported by DITA 1.1 "); |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
793 |
#if 0 |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
794 |
// The original did not have the if(m_hide) test. |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
795 |
// I assume that is an error so visitPostDefault() uses it. |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
796 |
QString level; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
797 |
level.setNum(s->level()); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
798 |
visitPostDefault("sect" + level); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
799 |
#endif |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
800 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
801 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
802 |
void XmlDitaDocVisitor::visitPre(DocHtmlList *s) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
803 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
804 |
DITA_DOC_VISITOR_TRACE("XmlDitaDocVisitor::visitPre(DocHtmlList*)", s) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
805 |
if (m_hide) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
806 |
return; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
807 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
808 |
if (s->type()==DocHtmlList::Ordered) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
809 |
push("ol"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
810 |
} else { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
811 |
push("ul"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
812 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
813 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
814 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
815 |
void XmlDitaDocVisitor::visitPost(DocHtmlList *s) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
816 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
817 |
DITA_DOC_VISITOR_TRACE("XmlDitaDocVisitor::visitPost(DocHtmlList*)", s) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
818 |
if (s->type()==DocHtmlList::Ordered) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
819 |
visitPostDefault("ol"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
820 |
} else { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
821 |
visitPostDefault("ul"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
822 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
823 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
824 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
825 |
void XmlDitaDocVisitor::visitPre(DocHtmlListItem *) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
826 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
827 |
DITA_DOC_VISITOR_TRACE_NOARG("XmlDitaDocVisitor::visitPre(DocHtmlListItem*)") |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
828 |
visitPreDefault("li"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
829 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
830 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
831 |
void XmlDitaDocVisitor::visitPost(DocHtmlListItem *) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
832 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
833 |
DITA_DOC_VISITOR_TRACE_NOARG("XmlDitaDocVisitor::visitPost(DocHtmlListItem*)") |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
834 |
visitPostDefault("li"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
835 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
836 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
837 |
void XmlDitaDocVisitor::visitPre(DocHtmlDescList *) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
838 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
839 |
DITA_DOC_VISITOR_TRACE_NOARG("XmlDitaDocVisitor::visitPre(DocHtmlDescList*)") |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
840 |
visitPreDefault("dl"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
841 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
842 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
843 |
void XmlDitaDocVisitor::visitPost(DocHtmlDescList *) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
844 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
845 |
DITA_DOC_VISITOR_TRACE_NOARG("XmlDitaDocVisitor::visitPost(DocHtmlDescList*)") |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
846 |
visitPostDefault("dl"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
847 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
848 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
849 |
void XmlDitaDocVisitor::visitPre(DocHtmlDescTitle *) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
850 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
851 |
DITA_DOC_VISITOR_TRACE_NOARG("XmlDitaDocVisitor::visitPre(DocHtmlDescTitle*)") |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
852 |
if (m_hide) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
853 |
return; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
854 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
855 |
push("dlentry"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
856 |
push("dt"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
857 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
858 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
859 |
void XmlDitaDocVisitor::visitPost(DocHtmlDescTitle *) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
860 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
861 |
DITA_DOC_VISITOR_TRACE_NOARG("XmlDitaDocVisitor::visitPost(DocHtmlDescTitle*)") |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
862 |
if (m_hide) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
863 |
return; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
864 |
} |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
865 |
//printf("XmlDitaDocVisitor::visitPost(DocHtmlDescTitle *)\n"); |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
866 |
pop("dt"); |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
867 |
// Note: We have to wait until XmlDitaDocVisitor::visitPost(DocHtmlDescData *) to pop("dlentry"); |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
868 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
869 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
870 |
void XmlDitaDocVisitor::visitPre(DocHtmlDescData *) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
871 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
872 |
DITA_DOC_VISITOR_TRACE_NOARG("XmlDitaDocVisitor::visitPre(DocHtmlDescData*)") |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
873 |
push("dd"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
874 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
875 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
876 |
void XmlDitaDocVisitor::visitPost(DocHtmlDescData *) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
877 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
878 |
DITA_DOC_VISITOR_TRACE_NOARG("XmlDitaDocVisitor::visitPost(DocHtmlDescData*)") |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
879 |
pop("dd"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
880 |
pop("dlentry"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
881 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
882 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
883 |
void XmlDitaDocVisitor::visitPre(DocHtmlTable *t) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
884 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
885 |
DITA_DOC_VISITOR_TRACE("XmlDitaDocVisitor::visitPre(DocHtmlTable*)", t) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
886 |
if (m_hide) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
887 |
return; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
888 |
} |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
889 |
push(ELEM_SIMPLETABLE); |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
890 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
891 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
892 |
void XmlDitaDocVisitor::visitPost(DocHtmlTable *) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
893 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
894 |
DITA_DOC_VISITOR_TRACE_NOARG("XmlDitaDocVisitor::visitPost(DocHtmlTable*)") |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
895 |
visitPostDefault(ELEM_SIMPLETABLE); |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
896 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
897 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
898 |
void XmlDitaDocVisitor::visitPre(DocHtmlRow *) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
899 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
900 |
DITA_DOC_VISITOR_TRACE_NOARG("XmlDitaDocVisitor::visitPre(DocHtmlRow*)") |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
901 |
// Set lazy flag |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
902 |
m_strowOrStheadIsPending = true; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
903 |
// We have look ahead to first cell before deciding whether to use a "sthead" or not |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
904 |
// this is done in XmlDitaDocVisitor::visitPre(DocHtmlCell *c) |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
905 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
906 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
907 |
void XmlDitaDocVisitor::visitPost(DocHtmlRow *) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
908 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
909 |
DITA_DOC_VISITOR_TRACE_NOARG("XmlDitaDocVisitor::visitPost(DocHtmlRow*)") |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
910 |
// Note: No testing as we could be either poping a sthead or an strow but pop we must |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
911 |
// (well only if we have pushed). |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
912 |
if (!m_strowOrStheadIsPending) { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
913 |
pop(); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
914 |
} |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
915 |
m_strowOrStheadIsPending = false; |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
916 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
917 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
918 |
void XmlDitaDocVisitor::visitPre(DocHtmlCell *c) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
919 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
920 |
DITA_DOC_VISITOR_TRACE("XmlDitaDocVisitor::visitPre(DocHtmlCell*)", c) |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
921 |
if (m_strowOrStheadIsPending) { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
922 |
// Write sthead or strow for the first cell only |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
923 |
if (c->isHeading()) { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
924 |
visitPreDefault("sthead"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
925 |
} else { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
926 |
visitPreDefault(ELEM_SIMPLETABLEROW); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
927 |
} |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
928 |
m_strowOrStheadIsPending = false; |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
929 |
} |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
930 |
visitPreDefault("stentry"); |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
931 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
932 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
933 |
void XmlDitaDocVisitor::visitPost(DocHtmlCell *c) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
934 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
935 |
DITA_DOC_VISITOR_TRACE("XmlDitaDocVisitor::visitPost(DocHtmlCell*)", c) |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
936 |
visitPostDefault("stentry"); |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
937 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
938 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
939 |
void XmlDitaDocVisitor::visitPre(DocHtmlCaption *) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
940 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
941 |
DITA_DOC_VISITOR_TRACE_NOARG("XmlDitaDocVisitor::visitPre(DocHtmlCaption*)") |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
942 |
// Caption is unsupported |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
943 |
xmlStream.comment(" XmlDitaDocVisitor::visitPre(DocHtmlCaption*) not currently supported by DITA 1.1 "); |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
944 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
945 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
946 |
void XmlDitaDocVisitor::visitPost(DocHtmlCaption *) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
947 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
948 |
DITA_DOC_VISITOR_TRACE_NOARG("XmlDitaDocVisitor::visitPost(DocHtmlCaption*)") |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
949 |
// Caption is unsupported |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
950 |
xmlStream.comment(" XmlDitaDocVisitor::visitPost(DocHtmlCaption*) not currently supported by DITA 1.1 "); |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
951 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
952 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
953 |
void XmlDitaDocVisitor::visitPre(DocInternal *) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
954 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
955 |
DITA_DOC_VISITOR_TRACE_NOARG("XmlDitaDocVisitor::visitPre(DocInternal*)") |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
956 |
xmlStream.comment(" XmlDitaDocVisitor::visitPre(DocInternal*) not currently supported by DITA 1.1 "); |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
957 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
958 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
959 |
void XmlDitaDocVisitor::visitPost(DocInternal *) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
960 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
961 |
DITA_DOC_VISITOR_TRACE_NOARG("XmlDitaDocVisitor::visitPost(DocInternal*)") |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
962 |
xmlStream.comment(" XmlDitaDocVisitor::visitPost(DocInternal*) not currently supported by DITA 1.1 "); |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
963 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
964 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
965 |
void XmlDitaDocVisitor::visitPre(DocHRef *href) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
966 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
967 |
DITA_DOC_VISITOR_TRACE("XmlDitaDocVisitor::visitPre(DocHRef*)", href) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
968 |
push("xref", "href", href->url()); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
969 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
970 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
971 |
void XmlDitaDocVisitor::visitPost(DocHRef *) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
972 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
973 |
DITA_DOC_VISITOR_TRACE_NOARG("XmlDitaDocVisitor::visitPost(DocHRef*)") |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
974 |
visitPostDefault("xref"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
975 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
976 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
977 |
void XmlDitaDocVisitor::visitPre(DocHtmlHeader *header) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
978 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
979 |
DITA_DOC_VISITOR_TRACE("XmlDitaDocVisitor::visitPre(DocHtmlHeader*)", header) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
980 |
visitPreDefault("b"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
981 |
#if 0 |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
982 |
QString hdgLevel; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
983 |
hdgLevel.setNum(header->level()); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
984 |
push("heading", "level", hdgLevel); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
985 |
#endif |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
986 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
987 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
988 |
void XmlDitaDocVisitor::visitPost(DocHtmlHeader *) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
989 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
990 |
DITA_DOC_VISITOR_TRACE_NOARG("XmlDitaDocVisitor::visitPost(DocHtmlHeader*)") |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
991 |
visitPostDefault("b"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
992 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
993 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
994 |
void XmlDitaDocVisitor::visitPre(DocImage *img) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
995 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
996 |
DITA_DOC_VISITOR_TRACE("XmlDitaDocVisitor::visitPre(DocImage*)", img) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
997 |
// Currently unsupported |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
998 |
xmlStream.comment(" XmlDitaDocVisitor::visitPre(DocImage*) not currently supported by DITA 1.1 "); |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
999 |
#if 0 |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1000 |
AttributeMap imgAttrs; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1001 |
// First the image type |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1002 |
switch(img->type()) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1003 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1004 |
case DocImage::Html: |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1005 |
imgAttrs["type"] = "html"; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1006 |
break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1007 |
case DocImage::Latex: |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1008 |
imgAttrs["type"] = "latex"; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1009 |
break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1010 |
case DocImage::Rtf: |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1011 |
imgAttrs["type"] = "rtf"; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1012 |
break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1013 |
default: |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1014 |
ASSERT(0); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1015 |
break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1016 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1017 |
// Now the image name |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1018 |
QString baseName=img->name(); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1019 |
int i; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1020 |
if ((i=baseName.findRev('/'))!=-1 || (i=baseName.findRev('\\'))!=-1) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1021 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1022 |
baseName=baseName.right(baseName.length()-i-1); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1023 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1024 |
imgAttrs["name"] = baseName; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1025 |
// Image width |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1026 |
if (!img->width().isEmpty()) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1027 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1028 |
imgAttrs["width"] = img->width(); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1029 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1030 |
// Image height |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1031 |
// NOTE: In the original this was an else if. I assume that this is an error |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1032 |
if (!img->height().isEmpty()) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1033 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1034 |
imgAttrs["height"] = img->height(); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1035 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1036 |
push("image", imgAttrs); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1037 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1038 |
// copy the image to the output dir |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1039 |
QFile inImage(img->name()); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1040 |
QFile outImage(Config_getString("XML_DITA_OUTPUT")+"/"+baseName.ascii()); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1041 |
if (inImage.open(IO_ReadOnly)) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1042 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1043 |
if (outImage.open(IO_WriteOnly)) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1044 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1045 |
char *buffer = new char[inImage.size()]; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1046 |
inImage.readBlock(buffer,inImage.size()); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1047 |
outImage.writeBlock(buffer,inImage.size()); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1048 |
outImage.flush(); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1049 |
delete[] buffer; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1050 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1051 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1052 |
#endif |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1053 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1054 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1055 |
void XmlDitaDocVisitor::visitPost(DocImage *) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1056 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1057 |
DITA_DOC_VISITOR_TRACE_NOARG("XmlDitaDocVisitor::visitPost(DocImage*)") |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1058 |
xmlStream.comment(" XmlDitaDocVisitor::visitPost(DocImage*) not currently supported by DITA 1.1 "); |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1059 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1060 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1061 |
void XmlDitaDocVisitor::visitPre(DocDotFile *df) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1062 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1063 |
DITA_DOC_VISITOR_TRACE("XmlDitaDocVisitor::visitPre(DocDotFile*)", df) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1064 |
// Currently unsupported |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1065 |
xmlStream.comment(" XmlDitaDocVisitor::visitPre(DocDotFile*) not currently supported by DITA 1.1 "); |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1066 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1067 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1068 |
void XmlDitaDocVisitor::visitPost(DocDotFile *) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1069 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1070 |
DITA_DOC_VISITOR_TRACE_NOARG("XmlDitaDocVisitor::visitPost(DocDotFile*)") |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1071 |
xmlStream.comment(" XmlDitaDocVisitor::visitPost(DocDotFile*) not currently supported by DITA 1.1 "); |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1072 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1073 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1074 |
void XmlDitaDocVisitor::visitPre(DocLink *lnk) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1075 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1076 |
// The result of a \link...\endlink command |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1077 |
DITA_DOC_VISITOR_TRACE("XmlDitaDocVisitor::visitPre(DocLink*)", lnk) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1078 |
if (m_hide) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1079 |
return; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1080 |
} |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1081 |
startLink(lnk->ref(), lnk->file(), lnk->anchor()); |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1082 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1083 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1084 |
void XmlDitaDocVisitor::visitPost(DocLink *) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1085 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1086 |
// The result of a \link...\endlink command |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1087 |
DITA_DOC_VISITOR_TRACE_NOARG("XmlDitaDocVisitor::visitPost(DocLink*)") |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1088 |
if (m_hide) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1089 |
return; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1090 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1091 |
endLink(); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1092 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1093 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1094 |
void XmlDitaDocVisitor::visitPre(DocRef *ref) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1095 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1096 |
DITA_DOC_VISITOR_TRACE("XmlDitaDocVisitor::visitPre(DocRef*)", ref) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1097 |
if (m_hide) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1098 |
return; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1099 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1100 |
if (!ref->file().isEmpty()) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1101 |
if (ref->getDefinition() != 0) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1102 |
//printf("XmlDitaDocVisitor calling startLink() DocRef [name]=`%s'\n", ref->getDefinition()->qualifiedName().data()); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1103 |
startLink("", ref->getDefinition()->qualifiedName(), ""); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1104 |
} else { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1105 |
//printf("XmlDitaDocVisitor calling startLink() DocRef [file]=`%s'\n", ref->file().data()); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1106 |
startLink(ref->ref(), ref->file(), ref->anchor()); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1107 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1108 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1109 |
if (!ref->hasLinkText()) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1110 |
write(ref->targetTitle()); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1111 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1112 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1113 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1114 |
void XmlDitaDocVisitor::visitPost(DocRef *ref) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1115 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1116 |
DITA_DOC_VISITOR_TRACE("XmlDitaDocVisitor::visitPost(DocRef*)", ref) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1117 |
if (m_hide) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1118 |
return; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1119 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1120 |
if (!ref->file().isEmpty()) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1121 |
endLink(); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1122 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1123 |
write(" "); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1124 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1125 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1126 |
void XmlDitaDocVisitor::visitPre(DocSecRefItem *ref) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1127 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1128 |
DITA_DOC_VISITOR_TRACE("XmlDitaDocVisitor::visitPre(DocSecRefItem*)", ref) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1129 |
if (m_hide) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1130 |
return; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1131 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1132 |
push("li", "id", ref->file()+"_1"+ref->anchor()); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1133 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1134 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1135 |
void XmlDitaDocVisitor::visitPost(DocSecRefItem *) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1136 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1137 |
DITA_DOC_VISITOR_TRACE_NOARG("XmlDitaDocVisitor::visitPost(DocSecRefItem*)") |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1138 |
visitPostDefault("li"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1139 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1140 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1141 |
void XmlDitaDocVisitor::visitPre(DocSecRefList *) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1142 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1143 |
DITA_DOC_VISITOR_TRACE_NOARG("XmlDitaDocVisitor::visitPre(DocSecRefList*)") |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1144 |
visitPreDefault("ul"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1145 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1146 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1147 |
void XmlDitaDocVisitor::visitPost(DocSecRefList *) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1148 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1149 |
DITA_DOC_VISITOR_TRACE_NOARG("XmlDitaDocVisitor::visitPost(DocSecRefList*)") |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1150 |
visitPostDefault("ul"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1151 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1152 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1153 |
void XmlDitaDocVisitor::visitPre(DocParamSect *s) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1154 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1155 |
DITA_DOC_VISITOR_TRACE("XmlDitaDocVisitor::visitPre(DocParamSect*)", s) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1156 |
if (m_hide) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1157 |
return; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1158 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1159 |
switch(s->type()) { |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1160 |
case DocParamSect::Param: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1161 |
m_insideParamlist = true; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1162 |
m_paramIsTemplate = false; |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1163 |
push("paraml", "class", "param"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1164 |
break; |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1165 |
case DocParamSect::RetVal: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1166 |
// NOTE: This code never seems to get exercised |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1167 |
m_insideParamlist = false; |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1168 |
push("paraml", "class", "retval"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1169 |
break; |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1170 |
case DocParamSect::Exception: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1171 |
//printf("void XmlDitaDocVisitor::visitPre(DocParamSect *s) Exception\n"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1172 |
m_insideParamlist = false; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1173 |
push("dl", "outputclass", "exception"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1174 |
push("dlentry"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1175 |
pushpop("dt", "Exceptions"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1176 |
push("dd"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1177 |
push(ELEM_SIMPLETABLE); |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1178 |
break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1179 |
case DocParamSect::TemplateParam: |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1180 |
m_insideParamlist = true; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1181 |
m_paramIsTemplate = true; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1182 |
push("paraml", "class", "templateparam"); |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1183 |
break; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1184 |
default: |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1185 |
ASSERT(0); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1186 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1187 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1188 |
|
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1189 |
void XmlDitaDocVisitor::visitPost(DocParamSect *s) |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1190 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1191 |
DITA_DOC_VISITOR_TRACE_NOARG("XmlDitaDocVisitor::visitPost(DocParamSect*)") |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1192 |
if (m_hide) { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1193 |
return; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1194 |
} |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1195 |
switch(s->type()) { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1196 |
case DocParamSect::Exception: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1197 |
pop(ELEM_SIMPLETABLE); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1198 |
pop("dd"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1199 |
pop("dlentry"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1200 |
pop("dl"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1201 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1202 |
default: |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1203 |
visitPostDefault("paraml"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1204 |
break; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1205 |
} |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1206 |
m_insideParamlist = false; |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1207 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1208 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1209 |
void XmlDitaDocVisitor::visitPre(DocParamList *pl) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1210 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1211 |
DITA_DOC_VISITOR_TRACE("XmlDitaDocVisitor::visitPre(DocParamList*)", pl) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1212 |
if (m_hide) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1213 |
return; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1214 |
} |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1215 |
if (!m_insideParamlist) { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1216 |
push("strow"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1217 |
push("stentry"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1218 |
} |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1219 |
QListIterator<DocNode> li(pl->parameters()); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1220 |
DocNode *param; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1221 |
for (li.toFirst();(param=li.current());++li) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1222 |
if (param->kind() == DocNode::Kind_Word) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1223 |
currParam = ((DocWord*)param)->word(); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1224 |
} else if (param->kind() == DocNode::Kind_LinkedWord) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1225 |
currParam = ((DocLinkedWord*)param)->word(); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1226 |
} else { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1227 |
// FIXME, what should we use here |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1228 |
currParam = ""; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1229 |
} |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1230 |
if (canLoadParameterMap()) { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1231 |
if (m_paramIsTemplate) { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1232 |
m_docBlockMaps->tparamMap.insert(currParam, ""); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1233 |
} else { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1234 |
m_docBlockMaps->paramMap.insert(currParam, ""); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1235 |
} |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1236 |
} else { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1237 |
if (param->kind() == DocNode::Kind_Word) |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1238 |
{ |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1239 |
visit((DocWord*)param); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1240 |
} |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1241 |
else if (param->kind() == DocNode::Kind_LinkedWord) |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1242 |
{ |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1243 |
visit((DocLinkedWord*)param); |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1244 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1245 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1246 |
} |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1247 |
if (!m_insideParamlist) { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1248 |
pop("stentry"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1249 |
push("stentry"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1250 |
} |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1251 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1252 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1253 |
void XmlDitaDocVisitor::visitPost(DocParamList *) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1254 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1255 |
DITA_DOC_VISITOR_TRACE_NOARG("XmlDitaDocVisitor::visitPost(DocParamList*)") |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1256 |
if (m_hide) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1257 |
return; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1258 |
} |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1259 |
if (!m_insideParamlist) { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1260 |
pop("stentry"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1261 |
pop("strow"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1262 |
} |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1263 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1264 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1265 |
void XmlDitaDocVisitor::visitPre(DocXRefItem *x) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1266 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1267 |
DITA_DOC_VISITOR_TRACE("XmlDitaDocVisitor::visitPre(DocXRefItem*)", x) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1268 |
if (m_hide) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1269 |
return; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1270 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1271 |
// \deprecated commands result in DocXRefItem |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1272 |
// with "deprecated" as the filename |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1273 |
if (x->file() == "deprecated"){ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1274 |
// Fall through to start new paragraph for deprecated description |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1275 |
} else { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1276 |
QString hrefStr = x->file(); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1277 |
hrefStr.append(Config_getString("XML_DITA_EXTENSION")); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1278 |
hrefStr.append("#"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1279 |
hrefStr.append(x->file()); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1280 |
hrefStr.append("_1"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1281 |
hrefStr.append(x->anchor()); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1282 |
push("xref", "href", hrefStr); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1283 |
write(x->title()); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1284 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1285 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1286 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1287 |
void XmlDitaDocVisitor::visitPost(DocXRefItem *) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1288 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1289 |
DITA_DOC_VISITOR_TRACE_NOARG("XmlDitaDocVisitor::visitPost(DocXRefItem*)") |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1290 |
if (m_hide) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1291 |
return; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1292 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1293 |
// An xref will be top of stack unless the current |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1294 |
// DocXRefItem was caused by a \deprecated command |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1295 |
if (!xmlElemStack.isEmpty() && xmlElemStack.peek().getElemName() == "xref") { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1296 |
pop("xref"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1297 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1298 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1299 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1300 |
void XmlDitaDocVisitor::visitPre(DocInternalRef *ref) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1301 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1302 |
DITA_DOC_VISITOR_TRACE("XmlDitaDocVisitor::visitPre(DocInternalRef*)", ref) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1303 |
if (m_hide) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1304 |
return; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1305 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1306 |
startLink(0, ref->file(), ref->anchor()); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1307 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1308 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1309 |
void XmlDitaDocVisitor::visitPost(DocInternalRef *) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1310 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1311 |
DITA_DOC_VISITOR_TRACE_NOARG("XmlDitaDocVisitor::visitPost(DocXRefItem*)") |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1312 |
if (m_hide) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1313 |
return; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1314 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1315 |
endLink(); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1316 |
write(" "); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1317 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1318 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1319 |
void XmlDitaDocVisitor::visitPre(DocCopy *c) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1320 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1321 |
DITA_DOC_VISITOR_TRACE("XmlDitaDocVisitor::visitPre(DocCopy*)", c) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1322 |
// Currently unsupported |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1323 |
xmlStream.comment(" XmlDitaDocVisitor::visitPre(DocCopy*) not currently supported by DITA 1.1 "); |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1324 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1325 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1326 |
void XmlDitaDocVisitor::visitPost(DocCopy *) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1327 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1328 |
DITA_DOC_VISITOR_TRACE_NOARG("XmlDitaDocVisitor::visitPost(DocCopy*)") |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1329 |
xmlStream.comment(" XmlDitaDocVisitor::visitPost(DocCopy*) not currently supported by DITA 1.1 "); |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1330 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1331 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1332 |
void XmlDitaDocVisitor::visitPre(DocText *) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1333 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1334 |
DITA_DOC_VISITOR_TRACE_NOARG("XmlDitaDocVisitor::visitPre(DocText*)") |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1335 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1336 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1337 |
void XmlDitaDocVisitor::visitPost(DocText *) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1338 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1339 |
DITA_DOC_VISITOR_TRACE_NOARG("XmlDitaDocVisitor::visitPost(DocText*)") |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1340 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1341 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1342 |
void XmlDitaDocVisitor::startXref(const QString &href,const QString &text) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1343 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1344 |
push("xref", "href", href); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1345 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1346 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1347 |
void XmlDitaDocVisitor::endXref() |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1348 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1349 |
pop("xref"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1350 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1351 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1352 |
void XmlDitaDocVisitor::startLink(const QString &ref,const QString &file,const QString &anchor) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1353 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1354 |
AttributeMap refAttrs; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1355 |
/* |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1356 |
printf("XmlDitaDocVisitor::startLink(): ref: \"%s\", file: \"%s\", anchor: \"%s\"\n", |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1357 |
ref.data(), |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1358 |
file.data(), |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1359 |
anchor.data()); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1360 |
*/ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1361 |
if (!anchor.isEmpty()) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1362 |
refAttrs["href"] = file+".xml#"+file+"_1"+anchor; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1363 |
} else { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1364 |
refAttrs["href"] = file+".xml#"+file; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1365 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1366 |
push("xref", refAttrs); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1367 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1368 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1369 |
void XmlDitaDocVisitor::endLink() |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1370 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1371 |
visitPostDefault("xref"); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1372 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1373 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1374 |
void XmlDitaDocVisitor::pushEnabled() |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1375 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1376 |
m_enabled.push(new bool(m_hide)); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1377 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1378 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1379 |
void XmlDitaDocVisitor::popEnabled() |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1380 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1381 |
bool *v = m_enabled.pop(); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1382 |
ASSERT(v!=0); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1383 |
m_hide = *v; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1384 |
delete v; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1385 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1386 |
|
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1387 |
bool XmlDitaDocVisitor::canWriteToXmlStream() const |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1388 |
{ |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1389 |
if (m_insideParamlist || m_addTextToReturnDoc || m_docBlockMaps != 0) { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1390 |
return false; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1391 |
} else { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1392 |
return true; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1393 |
} |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1394 |
} |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1395 |
|
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1396 |
/// Returns true if I gather text into m_docBlockMaps->returnDoc? |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1397 |
bool XmlDitaDocVisitor::shouldAddTextToReturnDoc() const |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1398 |
{ |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1399 |
return (m_addTextToReturnDoc && m_docBlockMaps != 0); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1400 |
} |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1401 |
|
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1402 |
bool XmlDitaDocVisitor::canLoadParameterMap() const |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1403 |
{ |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1404 |
return m_insideParamlist && m_docBlockMaps != 0; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1405 |
} |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1406 |
|
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1407 |
/** Keeps track of state so that a simpletable has a strow. */ |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1408 |
void XmlDitaDocVisitor::checkSimpleTable(const QString &tagName) |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1409 |
{ |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1410 |
if (tagName == ELEM_SIMPLETABLE) { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1411 |
m_mustInsertStrow = true; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1412 |
} else if (m_mustInsertStrow && tagName == "strow") { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1413 |
m_mustInsertStrow = false; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1414 |
} |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1415 |
} |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1416 |
|
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1417 |
void XmlDitaDocVisitor::addStrowToSimpleTableOnPop(const QString &tagName) |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1418 |
{ |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1419 |
if (tagName == ELEM_SIMPLETABLE && m_mustInsertStrow) { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1420 |
pushpop(ELEM_SIMPLETABLEROW); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1421 |
m_mustInsertStrow = false; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1422 |
} |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1423 |
} |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1424 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1425 |
void XmlDitaDocVisitor::write(const QString &string) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1426 |
{ |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1427 |
if (canWriteToXmlStream()) { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1428 |
xmlStream << string; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1429 |
} else if (canLoadParameterMap()) { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1430 |
if (m_paramIsTemplate) { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1431 |
if (m_docBlockMaps->tparamMap.contains(currParam)) { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1432 |
m_docBlockMaps->tparamMap[currParam].append(string); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1433 |
} else { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1434 |
m_docBlockMaps->tparamMap[currParam] = string; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1435 |
} |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1436 |
} else { |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1437 |
if (m_docBlockMaps->paramMap.contains(currParam)) { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1438 |
m_docBlockMaps->paramMap[currParam].append(string); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1439 |
} else { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1440 |
m_docBlockMaps->paramMap[currParam] = string; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1441 |
} |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1442 |
} |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1443 |
} else if (shouldAddTextToReturnDoc()) { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1444 |
//printf("Adding \"%s\" to returnDoc\n", string.data()); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1445 |
m_docBlockMaps->returnDoc.append(string); |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1446 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1447 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1448 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1449 |
void XmlDitaDocVisitor::push(const QString &tagName) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1450 |
{ |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1451 |
if (canWriteToXmlStream()) { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1452 |
checkSimpleTable(tagName); |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1453 |
xmlElemStack.push(tagName); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1454 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1455 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1456 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1457 |
void XmlDitaDocVisitor::push(const QString &tagName, const QString &key, const QString &value) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1458 |
{ |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1459 |
if (canWriteToXmlStream()) { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1460 |
checkSimpleTable(tagName); |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1461 |
xmlElemStack.push(tagName, key, value); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1462 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1463 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1464 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1465 |
void XmlDitaDocVisitor::push(const QString &tagName, AttributeMap &map) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1466 |
{ |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1467 |
if (canWriteToXmlStream()) { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1468 |
checkSimpleTable(tagName); |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1469 |
xmlElemStack.push(tagName, map); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1470 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1471 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1472 |
|
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1473 |
/** pop without checking element matches. |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1474 |
This can be useful when making asymetric push/pops |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1475 |
*/ |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1476 |
void XmlDitaDocVisitor::pop() |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1477 |
{ |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1478 |
if (canWriteToXmlStream()) { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1479 |
// Note: No use of addStrowToSimpleTableOnPop() |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1480 |
xmlElemStack.pop(); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1481 |
} |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1482 |
} |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1483 |
|
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1484 |
void XmlDitaDocVisitor::pop(const QString &tagName) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1485 |
{ |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1486 |
if (canWriteToXmlStream()) { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1487 |
addStrowToSimpleTableOnPop(tagName); |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1488 |
xmlElemStack.pop(tagName); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1489 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1490 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1491 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1492 |
void XmlDitaDocVisitor::pushpop(const QString &tagName) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1493 |
{ |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1494 |
if (canWriteToXmlStream() && tagName != ELEM_SIMPLETABLE) { |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1495 |
xmlElemStack.pushpop(tagName); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1496 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1497 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1498 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1499 |
void XmlDitaDocVisitor::pushpop(const QString &tagName, const QString &text) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1500 |
{ |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1501 |
if (canWriteToXmlStream() && tagName != ELEM_SIMPLETABLE) { |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1502 |
xmlElemStack.pushpop(tagName, text); |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1503 |
} else if (canLoadParameterMap()) { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1504 |
if (m_paramIsTemplate) { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1505 |
if (m_docBlockMaps->tparamMap.contains(currParam)) { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1506 |
m_docBlockMaps->tparamMap[currParam].append(text); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1507 |
} else { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1508 |
m_docBlockMaps->tparamMap[currParam] = text; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1509 |
} |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1510 |
} else { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1511 |
if (m_docBlockMaps->paramMap.contains(currParam)) { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1512 |
m_docBlockMaps->paramMap[currParam].append(text); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1513 |
} else { |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1514 |
m_docBlockMaps->paramMap[currParam] = text; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1515 |
} |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1516 |
} |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1517 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1518 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1519 |
|
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1520 |
/** Pushes a definition list onto the stack |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1521 |
@param outputClass The value of the outputclass attribute in the dl element |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1522 |
*/ |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1523 |
void XmlDitaDocVisitor::pushDl(const QString &outputClass) |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1524 |
{ |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1525 |
|
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1526 |
// ALIAS tags are rendered as definition lists |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1527 |
push("dl", "outputclass", outputClass); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1528 |
push("dlentry"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1529 |
push("dt"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1530 |
// This state allows us to do an asymetric push/pop when writing a DocPara |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1531 |
m_writingDl = true; |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1532 |
} |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1533 |
|
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1534 |
/** Pops a definition list onto the stack |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1535 |
*/ |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1536 |
void XmlDitaDocVisitor::popDl() |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1537 |
{ |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1538 |
// ALIAS tags are rendered as definition lists |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1539 |
// Note that this is asymetric as pre pushed dt and we pop dd |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1540 |
// We don't use pop("dd"); as the swap might not have happened |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1541 |
// and we risk an assertion failure at that point. |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1542 |
pop(); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1543 |
pop("dlentry"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1544 |
pop("dl"); |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1545 |
// Unset the state variable that allows us to do an |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1546 |
// asymetric push/pop when writing a DocPara |
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1547 |
m_writingDl = false; |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1548 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1549 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1550 |
/// Returns true if it is OK to write a para element |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1551 |
bool XmlDitaDocVisitor::canPushPara() const |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1552 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1553 |
if (!xmlElemStack.isEmpty()) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1554 |
QString e = xmlElemStack.peek().getElemName(); |
4
468f4c8d3d5b
Orb version 0.2.0
Jonathan Harrington <jonathan.harrington@nokia.com>
parents:
3
diff
changeset
|
1555 |
if (e == "xref" || e == "p" || e == "dt") { |
3
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1556 |
return false; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1557 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1558 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1559 |
return true; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1560 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1561 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1562 |
bool XmlDitaDocVisitor::canPopPara() const |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1563 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1564 |
if (!xmlElemStack.isEmpty() && xmlElemStack.peek().getElemName() == "p") { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1565 |
return true; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1566 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1567 |
return false; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1568 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1569 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1570 |
/** Default treatment of a post traversal visit, this just |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1571 |
pushes a single element with no attributes. */ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1572 |
void XmlDitaDocVisitor::visitPreDefault(const QString& elem) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1573 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1574 |
if (m_hide) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1575 |
return; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1576 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1577 |
push(elem); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1578 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1579 |
|
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1580 |
/** Default treatment of a post traversal visit, this just |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1581 |
pops a single element. */ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1582 |
void XmlDitaDocVisitor::visitPostDefault(const QString& elem) |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1583 |
{ |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1584 |
if (m_hide) { |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1585 |
return; |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1586 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1587 |
pop(elem); |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1588 |
} |
d8fccb2cd802
Orb version 0.1.9. Fixes Bug 1965, Bug 2401
Michel Szarindar <Michel.Szarindar@Nokia.com>
parents:
diff
changeset
|
1589 |