X-Git-Url: http://git.roojs.org/?a=blobdiff_plain;f=JSDOC%2FDocTag.js;h=ffa343b4d850972eeb6ea6ff1059ece473abed0e;hb=d9dd7890a864631c253aba4de205c60a7ef8e0bb;hp=692d1f4c860910fd1d2a76ea17bdc211401f4888;hpb=f09257f2222075d34e96d061cb24430de9973463;p=gnome.introspection-doc-generator diff --git a/JSDOC/DocTag.js b/JSDOC/DocTag.js index 692d1f4..ffa343b 100644 --- a/JSDOC/DocTag.js +++ b/JSDOC/DocTag.js @@ -26,6 +26,7 @@ DocTag = XObject.define( this.isOptional = false; this.defaultValue = ""; this.desc = ""; + this.optvalues = false; if (typeof src != "undefined") { this.parse(src); } @@ -90,6 +91,26 @@ DocTag = XObject.define( if (Options.LOG) Options.LOG.warn(e); else throw e; } + + // if type == @cfg, and matches (|....|...) + + src = src.trim(); + if (this.title == "cfg" && src.match(/^\([^)]+\)/)) { + var m = src.match(/^\(([^)]+)\)/); + print(m); + if (m[1].match(/\|/)) { + var opts = m[1].split(/\|/); + this.optvalues = opts; + src = src.substring(m[0].length).trim(); + print(src); + + + } + + + } + + this.desc = src; // whatever is left // example tags need to have whitespace preserved