Upgrade to ExtJS 4.0.7 - Released 10/19/2011
[extjs.git] / docs / source / Abstract.html
1 <!DOCTYPE html>
2 <html>
3 <head>
4   <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
5   <title>The source code</title>
6   <link href="../resources/prettify/prettify.css" type="text/css" rel="stylesheet" />
7   <script type="text/javascript" src="../resources/prettify/prettify.js"></script>
8   <style type="text/css">
9     .highlight { display: block; background-color: #ddd; }
10   </style>
11   <script type="text/javascript">
12     function highlight() {
13       document.getElementById(location.hash.replace(/#/, "")).className = "highlight";
14     }
15   </script>
16 </head>
17 <body onload="prettyPrint(); highlight();">
18   <pre class="prettyprint lang-js"><span id='Ext-chart-axis-Abstract'>/**
19 </span> * @class Ext.chart.axis.Abstract
20  * Base class for all axis classes.
21  * @private
22  */
23 Ext.define('Ext.chart.axis.Abstract', {
24
25     /* Begin Definitions */
26
27     requires: ['Ext.chart.Chart'],
28
29     /* End Definitions */
30
31 <span id='Ext-chart-axis-Abstract-method-constructor'>    /**
32 </span>     * Creates new Axis.
33      * @param {Object} config (optional) Config options.
34      */
35     constructor: function(config) {
36         config = config || {};
37
38         var me = this,
39             pos = config.position || 'left';
40
41         pos = pos.charAt(0).toUpperCase() + pos.substring(1);
42         //axisLabel(Top|Bottom|Right|Left)Style
43         config.label = Ext.apply(config['axisLabel' + pos + 'Style'] || {}, config.label || {});
44         config.axisTitleStyle = Ext.apply(config['axisTitle' + pos + 'Style'] || {}, config.labelTitle || {});
45         Ext.apply(me, config);
46         me.fields = [].concat(me.fields);
47         this.callParent();
48         me.labels = [];
49         me.getId();
50         me.labelGroup = me.chart.surface.getGroup(me.axisId + &quot;-labels&quot;);
51     },
52
53     alignment: null,
54     grid: false,
55     steps: 10,
56     x: 0,
57     y: 0,
58     minValue: 0,
59     maxValue: 0,
60
61     getId: function() {
62         return this.axisId || (this.axisId = Ext.id(null, 'ext-axis-'));
63     },
64
65     /*
66       Called to process a view i.e to make aggregation and filtering over
67       a store creating a substore to be used to render the axis. Since many axes
68       may do different things on the data and we want the final result of all these
69       operations to be rendered we need to call processView on all axes before drawing
70       them.
71     */
72     processView: Ext.emptyFn,
73
74     drawAxis: Ext.emptyFn,
75     addDisplayAndLabels: Ext.emptyFn
76 });
77 </pre>
78 </body>
79 </html>