diff options
-rw-r--r-- | src/commentscan.l | 5 | ||||
-rw-r--r-- | src/docparser.cpp | 4 | ||||
-rw-r--r-- | src/doctokenizer.l | 2 | ||||
-rw-r--r-- | testing/054/054__parblock_8cpp.xml | 103 | ||||
-rw-r--r-- | testing/054_parblock.cpp | 32 |
5 files changed, 145 insertions, 1 deletions
diff --git a/src/commentscan.l b/src/commentscan.l index 0d08e5c..2170dc2 100644 --- a/src/commentscan.l +++ b/src/commentscan.l @@ -2403,6 +2403,11 @@ static bool handleParBlock(const QCString &) warn(yyFileName,yyLineNr, "found \\parblock command while already in a parblock!"); } + if (!g_spaceBeforeCmd.isEmpty()) + { + addOutput(g_spaceBeforeCmd); + g_spaceBeforeCmd.resize(0); + } addOutput("@parblock "); g_insideParBlock = TRUE; return FALSE; diff --git a/src/docparser.cpp b/src/docparser.cpp index e1e750f..7e34ad0 100644 --- a/src/docparser.cpp +++ b/src/docparser.cpp @@ -4945,6 +4945,10 @@ int DocParamSect::parse(const QCString &cmdName,bool xmlContext, Direction d) { retval = pl->parse(cmdName); } + if (retval==RetVal_EndParBlock) + { + retval = RetVal_OK; + } DBG(("DocParamSect::parse() end retval=%d\n",retval)); DocNode *n=g_nodeStack.pop(); diff --git a/src/doctokenizer.l b/src/doctokenizer.l index 5ba1a72..6d521d9 100644 --- a/src/doctokenizer.l +++ b/src/doctokenizer.l @@ -1024,7 +1024,7 @@ REFWORD {LABELID}|{REFWORD2}|{REFWORD3}|{LNKWORD2} g_token->name = types+"#"+params.mid(i); return TK_WORD; } -<St_Param>[^ \t\n,]+ { +<St_Param>[^ \t\n,@\\]+ { g_token->name = yytext; if (g_token->name.at(yyleng-1)==':') { diff --git a/testing/054/054__parblock_8cpp.xml b/testing/054/054__parblock_8cpp.xml new file mode 100644 index 0000000..a562a6d --- /dev/null +++ b/testing/054/054__parblock_8cpp.xml @@ -0,0 +1,103 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<doxygen xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="compound.xsd" version=""> + <compounddef id="054__parblock_8cpp" kind="file"> + <compoundname>054_parblock.cpp</compoundname> + <sectiondef kind="func"> + <memberdef kind="function" id="054__parblock_8cpp_1a2dd0ac47f42a9994b91d34403be05fe9" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual"> + <type>void</type> + <definition>void function</definition> + <argsstring>(int client, int *resource, int parblock, int *test, int p)</argsstring> + <name>function</name> + <param> + <type>int</type> + <declname>client</declname> + </param> + <param> + <type>int *</type> + <declname>resource</declname> + </param> + <param> + <type>int</type> + <declname>parblock</declname> + </param> + <param> + <type>int *</type> + <declname>test</declname> + </param> + <param> + <type>int</type> + <declname>p</declname> + </param> + <briefdescription> + </briefdescription> + <detaileddescription> + <para>call by target-specific code to manage resources required by the client.</para> + <para> + <parameterlist kind="param"> + <parameteritem> + <parameternamelist> + <parametername direction="in">client</parametername> + </parameternamelist> + <parameterdescription> + <para>ID of client requesting resource. </para> + </parameterdescription> + </parameteritem> + <parameteritem> + <parameternamelist> + <parametername direction="out">resource</parametername> + </parameternamelist> + <parameterdescription> + <para>Requested resource </para> + </parameterdescription> + </parameteritem> + <parameteritem> + <parameternamelist> + <parametername direction="in">parblock</parametername> + </parameternamelist> + <parameterdescription> + <para> + <parblock> + <para>This is a test for the @parblock command.</para> + <para>A list if values for the parblock param:<itemizedlist><listitem><para>Item 1. This is short one-line description.</para></listitem><listitem><para>Item 2. This is a long bullet item; sometimes they wrap on multiple lines like this one.</para></listitem></itemizedlist> +</para> + <para>This is the second paragraph description for the @parblock parameter. Always end the text inside the @parblock command with an @endparblock command. </para> + </parblock> + </para> + </parameterdescription> + </parameteritem> + <parameteritem> + <parameternamelist> + <parametername direction="out">test</parametername> + </parameternamelist> + <parameterdescription> + <para>This is a test parameter for this function to see if it is included in the parameter table </para> + </parameterdescription> + </parameteritem> + <parameteritem> + <parameternamelist> + <parametername direction="in">p</parametername> + </parameternamelist> + <parameterdescription> + <para> + <parblock> + <para>First paragraph of the param description. <verbatim> Second paragraph of the param description. +</verbatim> </para> + </parblock> + </para> + </parameterdescription> + </parameteritem> + </parameterlist> + </para> + </detaileddescription> + <inbodydescription> + </inbodydescription> + <location file="054_parblock.cpp" line="32" column="1"/> + </memberdef> + </sectiondef> + <briefdescription> + </briefdescription> + <detaileddescription> + </detaileddescription> + <location file="054_parblock.cpp"/> + </compounddef> +</doxygen> diff --git a/testing/054_parblock.cpp b/testing/054_parblock.cpp new file mode 100644 index 0000000..186feb5 --- /dev/null +++ b/testing/054_parblock.cpp @@ -0,0 +1,32 @@ +// objective: test the \parblock command +// check: 054__parblock_8cpp.xml + +/** @file */ + +/** + call by target-specific code to manage resources required by the client. + + @param[in] client ID of client requesting resource. + @param[out] resource Requested resource + @param[in] parblock @parblock This is a test for the \@parblock + command. + + A list if values for the parblock param: + - Item 1. This is short one-line description. + - Item 2. This is a long bullet item; + sometimes they wrap on multiple lines like this + one. + + This is the second paragraph description for the + \@parblock parameter. Always end the text inside + the \@parblock command with an \@endparblock + command. + @endparblock + @param[out] test This is a test parameter for this function to see if + it is included in the parameter table + @param[in] p @parblock First paragraph of the param description. + + Second paragraph of the param description. + @endparblock + */ +void function(int client,int *resource,int parblock,int *test,int p); |