X-Git-Url: http://git.roojs.org/?p=roojs1;a=blobdiff_plain;f=roojs-doc-debug.js;h=d1a39ba30c427dcd2895b04c3de327de253c877b;hp=f923844f93ed9e719f6ea3cba7b9ea30a75d93bc;hb=a79418f2d639838995134f03eb135328a1039665;hpb=ff0988355df4fe44e68fa047750ea6e4555bc8e0 diff --git a/roojs-doc-debug.js b/roojs-doc-debug.js index f923844f93..d1a39ba30c 100644 --- a/roojs-doc-debug.js +++ b/roojs-doc-debug.js @@ -103,9 +103,10 @@ Roo.extend(Roo.doc.Entry, Roo.bootstrap.Component, { * @extends Roo.bootstrap.Component * Example Element class * @cfg {String} title short title describing example - * @cfg {String} lang (php|txt|sql) section type. + * @cfg {String} lang (php|txt|sql) code language. * @cfg {String} code example code * @cfg {String} output The expected output from the code + * @cfg {String} outputlang php|txt|sql) output language * * * @constructor @@ -215,7 +216,7 @@ Roo.extend(Roo.doc.Para, Roo.bootstrap.Component, { var cfg ={ tag: 'p', cls: 'para', - html : this.html + html : Roo.Markdown.toHtml(this.html) }; if (this.parent().is_list) { @@ -275,6 +276,7 @@ Roo.extend(Roo.doc.Param, Roo.bootstrap.Component, { //?? this is the synopsis type.... + var desc = Roo.Markdown.toHtml(this.desc); if (this.parent().stype == 'parameter') { @@ -289,7 +291,7 @@ Roo.extend(Roo.doc.Param, Roo.bootstrap.Component, { tag: 'code', html : this.type + ' ' + this.name }, - this.desc + desc ] } ] @@ -305,7 +307,7 @@ Roo.extend(Roo.doc.Param, Roo.bootstrap.Component, { tag: 'code', html : this.type }, - this.desc + desc ] }; @@ -339,6 +341,9 @@ Roo.extend(Roo.doc.Param, Roo.bootstrap.Component, { }, getAutoCreateParamSection : function() { + var desc = Roo.Markdown.toHtml(this.desc); + + return { tag : 'li', cn : [ @@ -350,7 +355,7 @@ Roo.extend(Roo.doc.Param, Roo.bootstrap.Component, { tag: 'code', html : this.type + ' ' + this.name }, - this.desc + desc ] } ] @@ -429,7 +434,7 @@ Roo.extend(Roo.doc.Section, Roo.bootstrap.Component, { cfg.cn.push(ul); } - if (this.stype == 'return' && syn.returndesc.length) { + if (this.stype == 'return' && (syn.returndesc.length || syn.returntype.length )) { cfg.cn.push({ tag: 'p', @@ -469,7 +474,8 @@ Roo.doc.Section.map = { 'parameter' : 'Parameters', 'return' : 'Return Value', 'note' : 'Notes', - 'example' : 'Examples' + 'example' : 'Examples', + 'throws' : 'Throws Exception' } /* * - LGPL @@ -486,6 +492,7 @@ Roo.doc.Section.map = { * @cfg {String} stype (function|constant) * @cfg {String} memberof class name * @cfg {bool} is_static is a static member + * @cfg {bool} is_constructor is a static member * * @constructor * Create a new Synopsis @@ -504,7 +511,8 @@ Roo.extend(Roo.doc.Synopsis, Roo.bootstrap.Component, { returndesc : '', name: '', stype: 'function', - + is_constructor : false, + getAutoCreate : function(){ var syn = this.items[0]; // hopefully... @@ -515,9 +523,15 @@ Roo.extend(Roo.doc.Synopsis, Roo.bootstrap.Component, { this.memberof + (this.is_static ? '::' : '->'); - + var nm = this.name; // this should probably do the params....?? then we need to disable the rendering.. + if (this.is_constructor) { + + nm = this.memberof; + nmp = 'new '; + } + var cfg ={ tag: 'h5', @@ -536,7 +550,7 @@ Roo.extend(Roo.doc.Synopsis, Roo.bootstrap.Component, { { tag: 'strong', cls : this.stype, - html : this.name + html : nm }, '(', {