Roo/doc/Synopsis.js
[roojs1] / Roo / doc / Synopsis.js
1 /*
2  * - LGPL
3  *
4  */
5
6 /**
7  * @class Roo.doc.Synopsis
8  * @extends Roo.bootstrap.Component
9  * Synopsis Element class
10  * @cfg {String} returntype return value
11  * @cfg {String} name title really..
12  * @cfg {String} stype (function|constant)
13  * @cfg {String} memberof class name
14  * @cfg {bool} is_static is a static member
15  * 
16  * @constructor
17  * Create a new Synopsis
18  * @param {Object} config The config object
19  */
20
21 Roo.doc.Synopsis = function(config){
22     Roo.doc.Synopsis.superclass.constructor.call(this, config);
23 };
24
25 Roo.extend(Roo.doc.Synopsis, Roo.bootstrap.Component,  {
26     
27     
28     returntype : '',
29     name: '',
30     stype:   'function',
31      
32     getAutoCreate : function(){
33         
34         var cfg ={
35             tag: 'h5',
36             cls : 'refsynopsisdiv',
37             cn : [
38                 {
39                     cls: 'funcsynopsis',
40                     cn: [
41                         {
42                             tag: 'p',
43                             cn: {
44                                 tag:'code',
45                                 cls : 'funcprototype',
46                                 cn: [
47                                     this.returntype + ' ',
48                                     {
49                                         tag: 'strong',
50                                         cls : this.stype,
51                                         html : this.name
52                                     },
53                                     '(',
54                                     {
55                                         tag: 'span',
56                                         cls : 'roo-params'
57                                     },
58                                     ')'
59                                 ]
60                                 
61                             }
62                         }
63                     ]
64                 }
65                 
66             ]
67         };
68         
69         
70         
71         return cfg;
72     },
73     getChildContainer : function(build_call)
74     {
75          
76         
77         return this.el.select('.roo-params',true).first();
78     }
79     
80     
81     
82     
83    
84 });
85
86  
87
88