Page 1 of 1

Code Creator Button

Posted: Wed Nov 19, 2014 12:22 pm
by 16670455
My God... it is impressive how Teechart evolves every year ! Lots of new features and facilities(properties/methods) that it is easy to get confused sometimes.

Well, I use VB6 (ActiveX teechart) and I noticed that in Editor some properties does not follow the common name as in the code. An example is the axis tick lenght properties

While in Editor you set Axis - Tick - Outer - Lenght that in code it is Axis.Left.TickLength

the same applies for Axis - Tick - Inner - Lenght that in code it is Axis.Left.TickInnerLength

It would be more intuitive that in code the first example to be Axis.Left.Outer.Lenght and the second one to be Axis.Tick.Inner.Lenght or even .OuterLenght/.InnerLenght whatever.

I don´t know what is easy to implement but in case the syntax above is the hard one, maybe a create code button could help this. When we press this button inside the panel in Edit Window, teechart would create the code automatically, automatically at the bottom of the Edit chart window, for the focused property or the last one focused. If not the code, at least the syntax to change that property in the code.


Regards and congratulations for the excellent development tool you all Steema Staff has built.

Angelo

Re: Code Creator Button

Posted: Thu Nov 20, 2014 9:55 am
by yeray
Hi Angelo,
Angelo wrote:While in Editor you set Axis - Tick - Outer - Lenght that in code it is Axis.Left.TickLength

the same applies for Axis - Tick - Inner - Lenght that in code it is Axis.Left.TickInnerLength

It would be more intuitive that in code the first example to be Axis.Left.Outer.Lenght and the second one to be Axis.Tick.Inner.Lenght or even .OuterLenght/.InnerLenght whatever.
Changing the properties would break backwards compatibility and we pay special attention to this.
I agree it would be more elegant, but adding a property for elegance and keeping the old one for backwards compatibility would end in unnecessary complications.
Angelo wrote:I don´t know what is easy to implement but in case the syntax above is the hard one, maybe a create code button could help this. When we press this button inside the panel in Edit Window, teechart would create the code automatically, automatically at the bottom of the Edit chart window, for the focused property or the last one focused. If not the code, at least the syntax to change that property in the code.
An easy way to find how a change in the editor is interpreted in code, you can use the export feature. If you click move to the "Export/Native" tab, you select "Text" Format and you click the "View..." button, you'll see all the properties defining the Chart, Tools and Series related.