diff options
-rw-r--r-- | src/index.cpp | 7 | ||||
-rw-r--r-- | src/pagedef.cpp | 14 | ||||
-rw-r--r-- | src/pagedef.h | 2 |
3 files changed, 20 insertions, 3 deletions
diff --git a/src/index.cpp b/src/index.cpp index 944d5db..5970a43 100644 --- a/src/index.cpp +++ b/src/index.cpp @@ -4129,16 +4129,19 @@ static void writeIndex(OutputList &ol) } QCString title = pd->title(); if (title.isEmpty()) title=pd->name(); + ol.startIndexSection(isPageDocumentation); ol.parseText(title); ol.endIndexSection(isPageDocumentation); + ol.pushGeneratorState(); // write TOC title (RTF only) ol.disableAllBut(OutputGenerator::RTF); ol.startIndexSection(isPageDocumentation2); ol.parseText(title); ol.endIndexSection(isPageDocumentation2); - ol.popGeneratorState(); - ol.writeAnchor(0,pd->name()); + ol.popGeneratorState(); + + ol.writeAnchor(0,pd->getOutputFileBase()); ol.writePageLink(pd->getOutputFileBase(),first); first=FALSE; diff --git a/src/pagedef.cpp b/src/pagedef.cpp index e93b3fd..0133be1 100644 --- a/src/pagedef.cpp +++ b/src/pagedef.cpp @@ -61,6 +61,20 @@ QCString PageDef::getOutputFileBase() const return m_fileName; } +void PageDef::setFileName(const char *name) +{ + static bool shortNames = Config_getBool("SHORT_NAMES"); + if (shortNames) + { + m_fileName = convertNameToFile(name); + } + else + { + m_fileName = name; + } +} + + void PageDef::addInnerCompound(Definition *def) { if (def->definitionType()==Definition::TypePage) diff --git a/src/pagedef.h b/src/pagedef.h index 4670ecd..f0e96c2 100644 --- a/src/pagedef.h +++ b/src/pagedef.h @@ -32,7 +32,7 @@ class PageDef : public Definition ~PageDef(); // setters - void setFileName(const char *name) { m_fileName = name; } + void setFileName(const char *name); void setShowToc(bool b); // getters |