diff options
author | albert-github <albert.tests@gmail.com> | 2018-11-17 10:42:14 (GMT) |
---|---|---|
committer | albert-github <albert.tests@gmail.com> | 2018-11-17 10:42:14 (GMT) |
commit | 8ef2c893f372d44225f9536bac379387e8d2bc44 (patch) | |
tree | d5d7bfacd785f65c2d5e4382ab55d4d509b7d9e4 /src/cite.cpp | |
parent | a7803b58cf4359b0dbf44e3c4346283cc4242b6e (diff) | |
download | Doxygen-8ef2c893f372d44225f9536bac379387e8d2bc44.zip Doxygen-8ef2c893f372d44225f9536bac379387e8d2bc44.tar.gz Doxygen-8ef2c893f372d44225f9536bac379387e8d2bc44.tar.bz2 |
Extending \cite command with '-' and '?' characters.
In the `\cite` label some extra characters are enabled, '-' and '?', as the '--' and '---' have been converted beforehand they have to be converted back and the corresponding labels also have to between double quotes (which are striped away).
Diffstat (limited to 'src/cite.cpp')
-rw-r--r-- | src/cite.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/cite.cpp b/src/cite.cpp index b17800f..4f88611 100644 --- a/src/cite.cpp +++ b/src/cite.cpp @@ -223,7 +223,6 @@ void CiteDict::generatePage() const if (line.find("<!-- BEGIN BIBLIOGRAPHY")!=-1) insideBib=TRUE; else if (line.find("<!-- END BIBLIOGRAPH")!=-1) insideBib=FALSE; - else if (insideBib) doc+=line+"\n"; int i; // determine text to use at the location of the @cite command if (insideBib && (i=line.find("name=\"CITEREF_"))!=-1) @@ -234,14 +233,17 @@ void CiteDict::generatePage() const { QCString label = line.mid(i+14,j-i-14); QCString number = line.mid(j+2,k-j-1); + label = substitute(substitute(label,"–","--"),"—","---"); CiteInfo *ci = m_entries.find(label); //printf("label='%s' number='%s' => %p\n",label.data(),number.data(),ci); + line = line.left(i+14) + label + line.right(line.length()-j); if (ci) { ci->text = number; } } } + if (insideBib) doc+=line+"\n"; } //printf("doc=[%s]\n",doc.data()); |