Wednesday, October 3, 2007

XPCharting For AS2

Hot news!!
We have just released XPCharting For AS2.

This is a port of our recently released FLEXPCharting which was for Flex2.

XPCharting For AS2 uses the exact same API as the Flex version and has the same features set as well. That includes over 30 different chart types, chart effects, color palettes, graphical borders etc.

This version is framework independent, it does not use nor interfere in any way with the FMX2004 framework, it is as happy being used in a class based application as a movieclip based one.

It is very flexible and lighweight with the footprint being around 60k for a chart including effects and borders.

If you need a poweful charting package for your AS2 applications today then this is for you, and if you decide to upgrade your application to Flex at some point in the future your code will be ready to run with FLEXPCharting.

For more info on XPCharting for AS2
http://www.xpcomponents.com/xpcharting.shtml


For more info on XPCharting for Flex
http://www.xpcomponents.com/charting.shtml


Tuesday, September 18, 2007

Using FlashDemoBuilder to create a tutorial for XPCharting

I have been looking at a few demo building tools recently and decided to give FlashDemoBuilder a go.

You can see the result here MY FirstChart.

Overall the experience was good, easy to install, easy to use and the end result is not to bad even if not perfect. There were a few glitches, it sometimes picks up the mouse or key click late so for example the menu has closed before the screen says "click here" same for some dialogs boxes. It also consumes a lot of disk space whilst recording the demo I built used over 1GB during building. Occasionaly it was also reluctant to stop recording.

Having said that it did exactly what it was supposed to and editing the timeline and adding in new objects was really simple.

I plan on trying a couple more demo building applications in the next few days to get a comparison. I will try to blog about them all.

I would be interested in hearing what you use.

Monday, September 17, 2007

Free Eclipse Plugin for FlexBuilder

Recently I have been doing a lot with the RegEx classes in AS3 and I got frustrated with creating projects to test out various RegEx expressions so I thought it would be really useful to have a small RegEx testing panel in Eclipse.

Initially I looked around to see if there was any existing RegEx plugin for Eclipse but none of those I found did what I wanted, namely to test parse expressions and replace experessions. So as a result we now have created our own plugin.

You can download it for free from here http://www.xpcomponents.com/regexbuilder_1.0.zip

The plugin is designed to let you test out all Regular Expression but particularly parse and replace experessions.


Unzip the contents into your plugin folder and start FlexBuilderwith the clean option.

You might need to click on the menu Window/OtherViews to show the plugin.




Charting Tools Demo for Flex

TrendLineTool
I have just updated the Charting Tools Demo for Flex2.

Tools Demo

XPCharting provides a simple API for adding interactive chart tools into a chart at run time. Interactive tools are designed to let end users manipulate charts at run time, probably one of the most common usages, and the one we have implemented ourselves, is allowing users to draw trend lines over a stock chart.

The demo highlights the use of our TrendLineTool on an AxisChart which plots the DJIA for the last year.

The user can draw trend lines on the chart at run time using the mouse.

First press the mouse button down and then start to drag, a trend line is anchored where you clicked and then drawn to the current mouse location. The line is highlighted red whilst it is being sized but reverts to black once the mouse button is released.

But what if a user wants to change the trend line after it is drawn?

If you mouse over the middle of the line segment it turns blue indicating it can be moved, click down and then you can move the line to a new location. Note the line retains its current angle whilst being dragged.

But what if you want to resize or change the location of the end points?

If you mouse over the two end points of the line then line turns red indicating it can be resized and the end points moved by clicking down on the line whilst it is highlighted

Additional features included deleting lines by holding the shift key down when clicking on the line or duplicating a line by holding the control key down when clicking a line.

If you have any ideas for other tools drop us a line you never know we might just implement it.

Upcoming Features
XPCharting is continuously being updated, we are currently working on rotated text for the chart legend just what you need when you are short of space, look out for that very shortly.....

If you have any suggestion for a new feature or new chart types let me know....




Wednesday, September 12, 2007

XPCharting for Flex released

We have just released FLEXPCharting 1.0 the Flex2 version of our XPCharting package.

FLEXPCharting is built on the Adobe Flex2 Framework and is 100% compatible with your Flex applications.

It is more than just a straight port of the AS2 version, it marks a major revision with many new and enhanced features. We have focused on providing more power to the developer and providing the tools that make it easy to create sophisticated charts. New chart types provide the developer with the power to create sophisticated chart analyses quickly. SubCharts enable you to add series to a child chart rather than being overlaid on the main chart, this is a commonly seen feature of stock charts where sub charts display additional information like volume or RSI that isn't appropriate to be overlaid. 3D look, graphical borders, DataEffects all empower the developer to create stunning visuals with little effort.

New series types
Lots of new series types like Stochastic, RSI, On Balance Volume, EMA and SMA.

SubCharts
SubCharts are a powerful new feature of FLEXPCharting. A sub chart is added below the main chart and shares a common horizontal axis with the main chart. This is useful where the series cant be overlaid, for example an RSI study tends to get lost if overlaid on a stock index chart but when appended underneath it easily conveys valuable information. The sub chart does not display a horizontal axis but shares the main chart horizontal axis.

Flexible Date Handling
Often charts needed to display date as a discontinuous range rather than a strict linear progression, For instance financial charts usually only have data for mon-fri rather than a full week. XPCharting default DateTime axis is a hyrbid value/category type allowing dates to be discontinuous but at the same time the are treated as Date objects that can be grouped as well as formatted. For example even with a discontinuous range of a years data it can still determine the periodicity and the appropriate labelling for the axis, displaying months with tick marks on the first data point of the new month whatever day it happens to be. We also provide a date/time as values axis so you get the best of both worlds. Date/Number formatting and parsing is handled by our own fully internationalized library which can format and parse any given pattern for any locale.

Multiple Axes
Multiple axes are supported. The SeriesSet object makes it easy to use a pair of indices with an array of Series whilst at the same time with each chart supporting multiple SeriesSets you can have any number of axes.

Drop Support
We have added in simple drop support so that users can now drag rows of data from a List or DataGrid control and drop it on to a chart and the chart will render it.

3D
3D versions of Pie and Doughnuts are included with work underway for more 3D types. We have provided both a full wire framed 3D model and also a shaded 3D model. The 3D charts can all be rotated in 3 dimensions.

DataEffects
We have added a whole slew of DataEffects like Fade, Slide, Zoom, Wipe etc. The effects are applied to a series when data changes. Many are built in allowing you to use them simply by setting a string property rather than needing to create them.

Palette
The Palette is a powerful new feature we have added to simplify the management of colors in a chart. The Palette not only manages all the strokes and fills in a chart but also can build them starting from a simple array of colors. It can create gradients both linear and radial and it will also generate additional complementary colors if it runs through the initial array rather than recycling which is important for per item fills. We have provided 15 built in palette each one with a range of complementary colors, these include the Halo palette, as well as others like BLAF or Excel. You can also easily create your own palette by specifying an array of colors or modify an existing palette. The palette makes it trivial to quickly change stroke width or alpha or use gradients without needing code just setting a few properties on the chart.

Background/Borders
We have provided 20 odd graphical border skins that allow you to quickly create attractive, distinctive charts.


Note: Although it is built on the existing Flex framework it doesn't not require the Adobe Flex Charts library.
For more info see http://xpcomponents.com/charting.shtml

Friday, September 2, 2005

Eclipse, ASDT, FDT and Zorn

Well I said I would talk about our experiences with Eclipse

We started using Eclipse a couple of weeks back as we have begun testing out Flux our flash xml ui product as it is targeted at non-IDE users.

We haven't used Eclipse before as all our previous Java coding has been done in JCreator which is a super fast C++ editor for Java, it is fully featured, with code folding and code completion and yet when it loads it takes only 18Mb of ram and rarely does it get much more than that, compared to Eclipse which being Java is a memory hog, a few days back I got up to 300MB in Eclipse and that was with every window closed!

Anyway Iam getting off the point, after installing Eclipse and getting it integrated with VSS for version control it was time to start editing some ActionScript.

First off we tried ASDT with Eclipse, ASDT is open source and free.
The initial experience was unfortunately bad. Like everyone when you start of in a new environment you tend to play around, so I created a project that would cover our source code that was in the Configuration/Classes folder. This was quite a trivial thing to do, unfortunately ASDT wasn’t happy about creating this project so it gave out an error message and proceeded to rollback. Unfortunately for me there is a known bug in the ASDT rollback code and thank you very much, ASDT deleted every single file under Configuration/Classes, going on for a 1000 classes! I must admit I was warned that ASDT has a tendency to delete files but, you know, I was smarter than that wasn't I! Lucky for me we have VSS so it was easy to replace the code.

After that I was put off for a few days but came back to it and with some help from a friend got ASDT and flashout working together relatively easily.

To be honest I found ASDT rather clunky, for its syntax checking it relies upon MTASC, there is nothing wrong with MTASC but MTASC is a compiler not an editor syntax checker. So here I am working on a class and ASDT says that there is an error in another class that is being referenced, I open that class fix the error jump back to my original class and lo and behold no errors! Unfortunately it’s not true, just that one error has been fixed, I need to get the syntax checker to kick in again to see if there are any more errors, so I have to "touch" the file, just type a space or something, then it will tell me the next error, and we begin the cycle again ..... That to me is a pain, and it was slow, even in the Flash IDE I can click the syntax checker and I get all the current errors displayed. Actually I found I was more productive using the Flash IDE editor and then just tab out to a command prompt to run MTASC than working with ASDT but thats a personal preference.

The issue as I see it with ASDT is that the pace of its development is just way to slow for it to keep up with the requirement needed for professional development, it not a criticism of the developers they have done a good job with the time they have, its just recognizing the fact they are doing it in their spare time and then don’t have enough time to dedicate to the project. It is the downside of open source development unfortunately. Really though there is an awful lot that needs doing and daresay it really needs re-writing from the ground up if it is to become viable long term.

But then in the last week along came FDT. FDT is a commercial equivalent of ASDT produce by PowerFlasher, it is also not exactly cheap! You can get it on a 20 day trial so we downloaded it and gave it a run.
Straight of it felt so much different from ASDT, you felt this was a product that was much more advanced, much more sophisticated. They have implemented there own syntax checking rather than relying on MTASC and this is just a huge plus. Not only do all your errors get labeled in one go but they actually put markers in the margin of your class file to easily see where the errors are and a little tooltip displays the error string. Now here is something which for the first time I would say was a productivity plus over the Flash IDE. FDT also picks up as an error where you havent put a ";" at the end of the line which is nice.

Not everything is perfect, this after all 1.0, we did have problem with classes reporting false errors due to an issue with not being able to resolve the super class. After struggling to sort this out for few days I contacted FDT directly and they were great and resolved the issue very quickly, it turned out to be a path issue which we could alter in the eclipse configuration.
Once that was fixed we were off and away, and I am happy to now report the XPComponent framework is fully compatible with FDT, no errors, no warnings (and also the same with MTASC).

I did mention to Nico at PowerFlasher that one thing that I missed from the Flash IDE was help panel integration. We have the whole XPComponent API in flash help panel format so you can have both code completion and easily get at the same sort of API help that MM provide for there own components when working in the Flsah IDE.
Well, they pointed that in FDT you can convert the Flash help so we ran that and in a couple of minutes we had our help file available in Eclipse. Unfortunately at the moment there is a small issue with the help as currently when it tries to jump to help for say the Button class it doesn’t have the right information to find the specific help file so you get a small list to choose form of all the help files for classes with Button in their name, like Button, ButtonList, RadioButton etc. but to give them there due the guys at FDT are working with us to find a solution to this problem so hopefully soon you will jump right to the help class and method you wanted without needing to pick anything from a list.

Overall when you compare ASDT and FDT the choice is clear, even though FDT is not cheap it is clearly so much better, so much more sophisticated and clearly a product with a devlopement team that are working round the clock to improve it further that’s it is well worth the price.

The only alternative on the horizon is Macromedia's Zorn, but at the moment Zorn is more questions than answers, what is it, when will it be available, how will it be packaged, what will it encompass and to be honest it is unlikley however it is packaged to be cheaper than FDT. So if your currently working in Eclipse I would say you really need to get FDT.

Thursday, September 1, 2005

Studio 8 Launch Event

I went to our local Studio 8 launch today.

There was some really cool stuff to see.

I am quite excited about the bitmap caching, this will have a major performance gain for us in the more complex controls and in scrolling content like grids I imagine and particularly for our Charting components it will really enable us to expand on their current capabilities significantly.

Back in January we added user interactive tools to our XPCharting components for drawing trends lines and doing real time chart analysis but to be honest once you started adding more than a few trend lines on the screen the performance quickly dropped off.

It was cool and to a degree useful but it was really ahead of the players capabilities so we put further development of the more sophisticated features on hold awaiting the arrival of Flash8. In one demo which Mike ran, the Flash logo was built from bouncing blocks that were drawn on screen row by row. In Flash 7 it ground to a halt quickly, in Flash 8 it ran fast and never slowed at all, all the way through to the last line. As I watched I could just imagine our charts drawing series after series without any drop off in performance, I guess for that feature alone Flash 8 is worth it for us.

Some of the other graphics capabilities will be very useful as well, with things like bevels and drop shadows now being built-in this will enable us to replace the equivalent functionality we currently have in our components that is provided by AS2 code, this should provide further performance gains and hopefully enable us to reduce the footprint.

Video is not currently a significant factor for us and neither is mobile development because of the lack of support for AS2, so those features whilst really cool don’t do a lot for us.

As a flash component developer though the most significant thing to me was that in an hour long presentation from Mike Downey the word "component" never got mentioned, ok I correct myself it got mentioned once in respect of the video playback control which was called a "component". Also the MXDJournal special on Studio8 that was being given away at the event also never mentions components. How things change in only a couple of years!

If you take this in conjunction with what has been said about Zorn recently it is clear that the writing is on the wall for the Flash IDE as an application development eniviroment, like it or not the future is Eclipse (well at least for another couple of years before MM move on to the next "next big thing" LOL). I am going to do an article for the blog shortly on our experience with Eclipse, ASDT and FDT so I will go into more detail on this later.

After hearing how, after years of refusing to listen to designers about gif/png support on the grounds that it was too heavy too include, they found it could be added in only a few kbytes I was dissapointed that we didn’t also see RegEx added for us application programmers, its hard these days to name another significant programming language that doesn’t have RegEx built-in even ActionScript's cousins JScript and JavaScript have long had this capability, oh well maybe F9 then....

Overall the new player enhancements are great and without a doubt were needed, but from a developers perspective I find it hard to call it the biggest ever release but none the less I guess the improvements are welcomed.

Rob