summaryrefslogtreecommitdiffstats
path: root/src/memberdef.cpp
diff options
context:
space:
mode:
authordimitri <dimitri@afe2bf4a-e733-0410-8a33-86f594647bc7>2005-08-06 11:48:27 (GMT)
committerdimitri <dimitri@afe2bf4a-e733-0410-8a33-86f594647bc7>2005-08-06 11:48:27 (GMT)
commit624a187c926b69bdfc11fca8e929b71938b28eff (patch)
tree340cca67808f566b0c458391835834e717e26a61 /src/memberdef.cpp
parente2bafacf8c0f6ef0dd7f9f4958a125761bda31ec (diff)
downloadDoxygen-624a187c926b69bdfc11fca8e929b71938b28eff.zip
Doxygen-624a187c926b69bdfc11fca8e929b71938b28eff.tar.gz
Doxygen-624a187c926b69bdfc11fca8e929b71938b28eff.tar.bz2
Release-1.4.4-20050806
Diffstat (limited to 'src/memberdef.cpp')
-rw-r--r--src/memberdef.cpp29
1 files changed, 28 insertions, 1 deletions
diff --git a/src/memberdef.cpp b/src/memberdef.cpp
index 3e9becf..3bfb93d 100644
--- a/src/memberdef.cpp
+++ b/src/memberdef.cpp
@@ -2006,9 +2006,36 @@ QCString MemberDef::getScopeString() const
return result;
}
+static QCString escapeAnchor(const QCString &anchor)
+{
+ QCString result;
+ int l = anchor.length(),i;
+ for (i=0;i<l;i++)
+ {
+ char c = anchor.at(i);
+ if ((c>='a' && c<='z') || (c>='A' && c<='Z'))
+ {
+ result+=c;
+ }
+ else
+ {
+ static char hexStr[]="0123456789ABCDEF";
+ char escChar[]={ '_', 0, 0, 0 };
+ escChar[1]=hexStr[c>>4];
+ escChar[2]=hexStr[c&0xf];
+ result+=escChar;
+ }
+ }
+ return result;
+}
+
void MemberDef::setAnchor(const char *a)
{
- anc=a;
+ //anc=a;
+ a=a;
+ QCString memAnchor = name();
+ if (!args.isEmpty()) memAnchor+=args;
+ anc = escapeAnchor(memAnchor);
}
void MemberDef::setGroupDef(GroupDef *gd,Grouping::GroupPri_t pri,