GNOME Bugzilla – Bug 703213
Can't use @ref instead of \ref with msc
Last modified: 2013-08-23 15:04:36 UTC
I'm documenting Python code, so I'm using @ notation instead of \. However @ref in an msc definition doesn't work. The doc snippet: # @msc # U [label=User], M [label=Metaserver], H [label="Hostserver 1"], # a [label="Node 1a"]; # U->M [label="connectRq()", URL="@ref rpcDox.Metaserver.connectRq()"]; # U<-M [label="connectRs()", URL="@ref rpcDox.User.connectRs()"]; # U->M [label="loginRq()", URL="@ref rpcDox.Metaserver.loginRq()"]; ... Generates HTML: <img src="msc_inline_mscgraph_1.png" alt="msc_inline_mscgraph_1" border="0" usemap="#msc_inline_mscgraph_1.map"/> <map name="msc_inline_mscgraph_1.map" id="msc_inline_mscgraph_1.map"> <area href="@ref" shape="rect" coords="0,2396656,0,3801144" alt=""/> <area href="@ref" shape="rect" coords="0,2396656,0,3801144" alt=""/> <area href="@ref" shape="rect" coords="0,2396656,0,3801144" alt=""/> ... Note the @ref as the URL and the crazy coordinate in the <area> tags. But changing @ref to \ref: # @msc # U [label=User], M [label=Metaserver], H [label="Hostserver 1"], # a [label="Node 1a"]; # U->M [label="connectRq()", URL="\ref rpcDox.Metaserver.connectRq()"]; # U<-M [label="connectRs()", URL="\ref rpcDox.User.connectRs()"]; # U->M [label="loginRq()", URL="\ref rpcDox.Metaserver.loginRq()"]; ... Produces sane output: <img src="msc_inline_mscgraph_1.png" alt="msc_inline_mscgraph_1" border="0" usemap="#msc_inline_mscgraph_1.map"/> <map name="msc_inline_mscgraph_1.map" id="msc_inline_mscgraph_1.map"> <area href="namespacerpc_dox_1_1_metaserver.html#a5c252ea20f6aaccc6d294dfb0dfd2e6f" shape="rect" coords="118,26,183,39" alt=""/> <area href="namespacerpc_dox_1_1_user.html#af757dffea7ab4edd855d1ed14ebbf2fc" shape="rect" coords="118,58,183,71" alt=""/> <area href="namespacerpc_dox_1_1_metaserver.html#ae323e84a7d042d3b0263801dafd70924" shape="rect" coords="124,90,177,103" alt=""/> ... Note how the URLs are valid and the coordinates are reasonable.
This is an issue in mscgen really. It supports \ref but not @ref. You may want to request the author of mscgen to add this.
I disagree. I don't believe it's an mscgen issue. I made two versions of an input file; one that starts with: msc { U [label=User], M [label=Metaserver], H [label="Hostserver 1"], a [label="Node 1a"]; U->M [label="connectRq()", URL="@ref rpcDox.Metaserver.connectRq()"]; U<-M [label="connectRs()", URL="@ref rpcDox.User.connectRs()"]; U->M [label="loginRq()", URL="@ref rpcDox.Metaserver.loginRq()"]; ... and one that starts with: msc { U [label=User], M [label=Metaserver], H [label="Hostserver 1"], a [label="Node 1a"]; U->M [label="connectRq()", URL="\ref rpcDox.Metaserver.connectRq()"]; U<-M [label="connectRs()", URL="\ref rpcDox.User.connectRs()"]; U->M [label="loginRq()", URL="\ref rpcDox.Metaserver.loginRq()"]; ... When I ran them through mscgen, I get output that starts with: rect @ref rpcDox.Metaserver.connectRq() 111,26 190,39 rect @ref rpcDox.User.connectRs() 111,58 189,71 rect @ref rpcDox.Metaserver.loginRq() 121,90 180,103 ... and: rect \ref rpcDox.Metaserver.connectRq() 111,26 190,39 rect \ref rpcDox.User.connectRs() 111,58 189,71 rect \ref rpcDox.Metaserver.loginRq() 121,90 180,103 ... respectively. In other words, mscgen's behavior is consistent, but doxygen's treatment of this output is not.
Confirmed. I overlooked one place where \ref is indeed hardcoded. Should be fixed in the next GIT update.
This bug was previously marked ASSIGNED, which means it should be fixed in doxygen version 1.8.5. 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.