Upgrade to ExtJS 3.0.0 - Released 07/06/2009
[extjs.git] / docs / source / spinner.html
1 <html>\r
2 <head>\r
3   <title>The source code</title>\r
4     <link href="../resources/prettify/prettify.css" type="text/css" rel="stylesheet" />\r
5     <script type="text/javascript" src="../resources/prettify/prettify.js"></script>\r
6 </head>\r
7 <body  onload="prettyPrint();">\r
8     <pre class="prettyprint lang-js">Ext.onReady(function(){\r
9     var simple = new Ext.FormPanel({\r
10         labelWidth: 40, // label settings here cascade unless overridden\r
11         frame: true,\r
12         title: 'Simple Form',\r
13         bodyStyle: 'padding:5px 5px 0',\r
14         width: 210,\r
15         defaults: {width: 135},\r
16         defaultType: 'textfield',\r
17 \r
18         items: [\r
19             new Ext.ux.form.SpinnerField({\r
20                 fieldLabel: 'Age',\r
21                 name: 'age'\r
22             }),\r
23             {\r
24                 xtype: 'spinnerfield',\r
25                 fieldLabel: 'Test',\r
26                 name: 'test',\r
27                 minValue: 0,\r
28                 maxValue: 100,\r
29                 allowDecimals: true,\r
30                 decimalPrecision: 1,\r
31                 incrementValue: 0.4,\r
32                 alternateIncrementValue: 2.1,\r
33                 accelerate: true\r
34             }\r
35         ]\r
36     });\r
37 \r
38     simple.render('form-ct');\r
39 });\r
40 </pre>    \r
41 </body>\r
42 </html>