10
votes

A Doxygen class reference page consists primarily of lists of class members, each followed by its brief description (if such exists). The member proper is a link to a details page for that member. Invariably the brief description is followed by a 'More...' link. The content of this link is identical to that of the member proper. This 'More...' link suggests - at least to me - that a more extended description is available at the other end of that link. This is misleading when the member has only a brief description. In that case the link points to a page which simply repeats that brief description and then states "Definition at line NN of file abcxyz.ext."

Is there anyway to get Doxygen to suppress these frustratingly vacuous 'More...' links?

3

3 Answers

2
votes

Experimental patch for doxygen 1.8.10, which allows you to remove the "More..." links by using "USE_MORE_LINK = NO" in Doxyfile.

<!-- language: diff -->
=== modified file 'src/classdef.cpp'
--- src/classdef.cpp    2015-07-06 11:29:12 +0000
+++ src/classdef.cpp    2015-07-06 11:37:57 +0000
@@ -1802,12 +1802,14 @@

   // HTML only
   ol.pushGeneratorState();
-  ol.disableAllBut(OutputGenerator::Html);
-  ol.docify(" ");
-  ol.startTextLink(getOutputFileBase(),
-      anchor.isEmpty() ? QCString("details") : anchor);
-  ol.parseText(theTranslator->trMore());
-  ol.endTextLink();
+  if (Config_getBool("USE_MORE_LINK")) {
+    ol.disableAllBut(OutputGenerator::Html);
+    ol.docify(" ");
+    ol.startTextLink(getOutputFileBase(),
+        anchor.isEmpty() ? QCString("details") : anchor);
+    ol.parseText(theTranslator->trMore());
+    ol.endTextLink();
+  }
   ol.popGeneratorState();

   if (!anchor.isEmpty())

=== modified file 'src/config.xml'
--- src/config.xml  2015-07-06 11:29:12 +0000
+++ src/config.xml  2015-07-06 11:57:09 +0000
@@ -366,6 +366,13 @@
 ]]>
       </docs>
     </option>
+    <option type='bool' id='USE_MORE_LINK' defval='1'>
+      <docs>
+<![CDATA[
+ Experimental parameter, which allows you to remove the "More..." links by using USE_MORE_LINK = NO.
+]]>
+      </docs>
+    </option>
     <option type='list' id='ABBREVIATE_BRIEF' format='string'>
       <docs>
 <![CDATA[

=== modified file 'src/filedef.cpp'
--- src/filedef.cpp 2015-07-06 11:29:12 +0000
+++ src/filedef.cpp 2015-07-06 11:31:41 +0000
@@ -373,8 +373,8 @@
       ol.writeString(" \n");
       ol.enable(OutputGenerator::RTF);

-      if (Config_getBool("REPEAT_BRIEF") ||
-          !documentation().isEmpty()
+      if ( (Config_getBool("REPEAT_BRIEF") || !documentation().isEmpty() ) &&
+          Config_getBool("USE_MORE_LINK")
          )
       {
         ol.disableAllBut(OutputGenerator::Html);

=== modified file 'src/memberdef.cpp'
--- src/memberdef.cpp   2015-07-06 11:29:12 +0000
+++ src/memberdef.cpp   2015-07-06 11:37:48 +0000
@@ -1805,22 +1805,24 @@
       {
         static bool separateMemberPages = Config_getBool("SEPARATE_MEMBER_PAGES");
         ol.pushGeneratorState();
-        ol.disableAllBut(OutputGenerator::Html);
-        //ol.endEmphasis();
-        ol.docify(" ");
-        if (separateMemberPages ||
-            (m_impl->group!=0 && gd==0) ||
-            (m_impl->nspace!=0 && nd==0)
-           ) // forward link to the page or group or namespace
-        {
-          ol.startTextLink(getOutputFileBase(),anchor());
-        }
-        else // local link
-        {
-          ol.startTextLink(0,anchor());
-        }
-        ol.parseText(theTranslator->trMore());
-        ol.endTextLink();
+        if (Config_getBool("USE_MORE_LINK")) {
+          ol.disableAllBut(OutputGenerator::Html);
+          //ol.endEmphasis();
+          ol.docify(" ");
+          if (separateMemberPages ||
+              (m_impl->group!=0 && gd==0) ||
+              (m_impl->nspace!=0 && nd==0)
+             ) // forward link to the page or group or namespace
+          {
+            ol.startTextLink(getOutputFileBase(),anchor());
+          }
+          else // local link
+          {
+            ol.startTextLink(0,anchor());
+          }
+          ol.parseText(theTranslator->trMore());
+          ol.endTextLink();
+        }
         //ol.startEmphasis();
         ol.popGeneratorState();
       }
2
votes

(Tentative answer as this particular case is not something I've ever needed to do.)

In the case that you want to remove all detailed descriptions (and thus, presumably, the links to it) you might be able to modify the 'layout' file to make that section invisible.

Reference: http://www.doxygen.nl/manual/customize.html#layout

Alternatively..

From your description it sounds like REPEAT_BRIEF is set on. If there really is no description beyond the first full stop then you may find that turning REPEAT_BRIEF off will remove the link, as the text there will truly be vacuous.

0
votes

It might be a bit late but I faced the same problem and solved it easily, with the following doxyfile configuration:

ALWAYS_DETAILED_SEC = NO
BRIEF_MEMBER_DESC = YES
REPEAT_BRIEF = NO
EXTRACT_ALL = NO
# Since EXTRACT_ALL is NO, configure the following as you wish. In my case
EXTRACT_PRIVATE = YES
EXTRACT_STATIC = YES
EXTRACT_LOCAL_CLASSES = YES
EXTRACT_LOCAL_METHODS = YES

I hope that helps.