Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

@ref commands with CREATE_SUBDIRS might not work properly with Latex output (Origin: bugzilla #338205) #2114

Closed
doxygen opened this Issue Jul 1, 2018 · 0 comments

Comments

Projects
None yet
1 participant
@doxygen
Copy link
Owner

doxygen commented Jul 1, 2018

status RESOLVED severity major in component general for ---
Reported in version 1.4.x on platform Other
Assigned to: Dimitri van Heesch

Original attachment names and IDs:

On 2006-04-12 11:32:24 +0000, Mario Sopena Novales wrote:

Please describe the problem:
If the CREATE_SUBDIRS is activated and some @ref commands are pointing to some
@anchor, the PDF output doesnn't generate the properly path to the file where
the @anchor is.

Steps to reproduce:
Activate the CREATE_SUBDIRS and PDF_HYPERLINKS.

use two files:

  • autoconf.dox
    /**
  • @defgroup autoconf Autoconfiguration
  • All of the set callback functions must follow the format below:
  • @anchor setcallback
  • @include setcallback.c
  • All of the get callback functions must follow the format below:
  • @anchor getcallback
  • @include getcallback.c
    **/
  • examples.dox
    /**
  • @page examples_autoconf Autoconfiguration examples
  • @ref setcallback "Set callback example"
  • @ref getcallback "Get callback example"

**/

Then generate the PDF. The page that contains the @ref has some hyperlinks which
should point to the autoconf module but they don't (the links are just broken)

Actual results:
The links are broken

Expected results:

Does this happen every time?
yes

Other information:
The problem seems to be in the LatexDocVisitor::startLink function of the
latexdocvisitor.cpp file. The call to "stripPath(file)" when constructing the
link leaves only the .tex filename but not the path to the file and therefore,
the link is broken. I've took out the stripPath function and left only the file
string. Now, everything seems to work but I'm not really sure if I broke something.

On 2010-02-10 11:00:39 +0000, eva.hovelsrod@gmail.com wrote:

Created attachment 153404
Minimal doxygen setup which demonstrates error.

On 2010-02-10 11:03:31 +0000, eva.hovelsrod@gmail.com wrote:

Comment on attachment 153404
Minimal doxygen setup which demonstrates error.

I have a very similar problem with HTML output. Use the attached The zip file contains doxygen config and one source file. Run doxygen. Click the "dummy" link on the main page - the link doesn't work.

On 2010-02-20 20:35:31 +0000, Dimitri van Heesch wrote:

(In reply to comment # 2)

(From update of attachment 153404 [details])
I have a very similar problem with HTML output. Use the attached The zip file
contains doxygen config and one source file. Run doxygen. Click the "dummy"
link on the main page - the link doesn't work.

This is more related to bugs # 607432 and # 608002 which should already be fixed in the latest subversion update.

On 2013-05-06 18:27:15 +0000, albert wrote:

Did some test and the problem of Eva looks like to be solved.

The original problem of Mario is in version 1.8.3.1 still present. Some digging led to the conclusion that with the \hypertarget / \label the reference was given including the directory names and with the \hyperlinks the reference was given without the directory names:

  • d8/d10/group__autoconf.tex
    \section{Autoconfiguration}
    \label{d8/d10/group__autoconf}\index{Autoconfiguration@{Autoconfiguration}}
    All of the set callback functions must follow the format below-: \label{d8/d10/group__autoconf_setcallback}%
    \hypertarget{d8/d10/group__autoconf_setcallback}{}%
    include setcallback.-c

All of the get callback functions must follow the format below-:

\label{d8/d10/group__autoconf_getcallback}%
\hypertarget{d8/d10/group__autoconf_getcallback}{}%
include getcallback.-c

  • dd/d49/examples_autoconf.tex
    \hyperlink{group__autoconf_setcallback}{Set callback example}

\hyperlink{group__autoconf_getcallback}{Get callback example}

Both files are correctly loaded by means of the \input in the refman.tex
I think that that either the directory names have to be added or removed everywhere (as long as the names are unique). Looking in latexgen.cpp and latexdocvisitor.cpp at some places the path is tripped and on other places it is not, hard to tell for me where the path has to be stripped and where not.

On 2013-05-10 14:20:37 +0000, Dimitri van Heesch wrote:

Confirmed. Should be fixed in the next subversion update.

On 2013-05-19 12:35:56 +0000, Dimitri van Heesch wrote:

This bug was previously marked ASSIGNED, which means it should be fixed in
doxygen version 1.8.4. Please verify if this is indeed the case. Reopen the
bug if you think it is not fixed and please include any additional information
that you think can be relevant.

@doxygen doxygen closed this Jul 1, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.