diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/markdown.cpp | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/markdown.cpp b/src/markdown.cpp index 19c9187..eb5a2a2 100644 --- a/src/markdown.cpp +++ b/src/markdown.cpp @@ -850,9 +850,15 @@ static int processLink(GrowBuf &out,const char *data,int,int size) } else { - if (link.find("@ref ")!=-1 || link.find("\\ref ")!=-1) + SrcLangExt lang = getLanguageFromFileName(link); + int lp=-1; + if ((lp=link.find("@ref "))!=-1 || (lp=link.find("\\ref "))!=-1 || lang==SrcLangExt_Markdown) // assume doxygen symbol link { + if (lp==-1) // link to markdown page + { + out.addStr("@ref "); + } out.addStr(link); out.addStr(" \""); if (explicitTitle && !title.isEmpty()) |