summaryrefslogtreecommitdiffstats
path: root/src/docparser.h
diff options
context:
space:
mode:
authoralbert-github <albert.tests@gmail.com>2019-02-04 18:31:01 (GMT)
committeralbert-github <albert.tests@gmail.com>2019-02-04 18:31:01 (GMT)
commit64ac36480f407145d8fe1e96ea4cf8f7e30285d5 (patch)
treec2ef84b9d62f4d097db1887691fb9ac2a4814f9e /src/docparser.h
parent8a31e77445a94277151666380860defedcc3838d (diff)
downloadDoxygen-64ac36480f407145d8fe1e96ea4cf8f7e30285d5.zip
Doxygen-64ac36480f407145d8fe1e96ea4cf8f7e30285d5.tar.gz
Doxygen-64ac36480f407145d8fe1e96ea4cf8f7e30285d5.tar.bz2
Bug 136299 - attributes to <p> tag get lost
Besides the `p` tag there were a number of other tags were also the attributes were lost: - `br` - `hr` - `a` in case of used as an anchor i.e. with the `name=` attribute In case of a `caption` with a `table` and no `id=` attribute with the `caption` there was still an anchor generated In scanner.l the warnings message was a bit unclear.
Diffstat (limited to 'src/docparser.h')
-rw-r--r--src/docparser.h23
1 files changed, 20 insertions, 3 deletions
diff --git a/src/docparser.h b/src/docparser.h
index 5d2cc89..7363232 100644
--- a/src/docparser.h
+++ b/src/docparser.h
@@ -300,37 +300,52 @@ class DocURL : public DocNode
class DocLineBreak : public DocNode
{
public:
- DocLineBreak(DocNode *parent) { m_parent=parent; }
+ DocLineBreak(DocNode *parent) { m_parent = parent; }
+ DocLineBreak(DocNode *parent,const HtmlAttribList &attribs)
+ : m_attribs(attribs) { m_parent = parent; }
Kind kind() const { return Kind_LineBreak; }
void accept(DocVisitor *v) { v->visit(this); }
+ const HtmlAttribList &attribs() const { return m_attribs; }
+
private:
+ HtmlAttribList m_attribs;
};
/** Node representing a horizontal ruler */
class DocHorRuler : public DocNode
{
public:
- DocHorRuler(DocNode *parent) { m_parent = parent; }
+ DocHorRuler(DocNode *parent,const HtmlAttribList &attribs)
+ : m_attribs(attribs) { m_parent = parent; }
Kind kind() const { return Kind_HorRuler; }
void accept(DocVisitor *v) { v->visit(this); }
+ const HtmlAttribList &attribs() const { return m_attribs; }
+
private:
+ HtmlAttribList m_attribs;
};
/** Node representing an anchor */
class DocAnchor : public DocNode
{
public:
- DocAnchor(DocNode *parent,const QCString &id,bool newAnchor);
+ DocAnchor(DocNode *parent,const QCString &id,bool newAnchor){docAnchorInit(parent,id,newAnchor);}
+ DocAnchor(DocNode *parent,const QCString &id,bool newAnchor,const HtmlAttribList &attribs) : m_attribs(attribs)
+ {docAnchorInit(parent,id,newAnchor);}
Kind kind() const { return Kind_Anchor; }
QCString anchor() const { return m_anchor; }
QCString file() const { return m_file; }
void accept(DocVisitor *v) { v->visit(this); }
+ const HtmlAttribList &attribs() const { return m_attribs; }
+
private:
QCString m_anchor;
QCString m_file;
+ HtmlAttribList m_attribs;
+ void docAnchorInit(DocNode *parent,const QCString &id,bool newAnchor);
};
/** Node representing a citation of some bibliographic reference */
@@ -1199,11 +1214,13 @@ class DocPara : public CompAccept<DocPara>
int handleHtmlHeader(const HtmlAttribList &tagHtmlAttribs,int level);
bool injectToken(int tok,const QCString &tokText);
+ const HtmlAttribList &attribs() const { return m_attribs; }
private:
QCString m_sectionId;
bool m_isFirst;
bool m_isLast;
+ HtmlAttribList m_attribs;
};
/** Node representing a parameter list. */