Futurescale, Inc. PureMVC Home

The PureMVC Framework Code at the Speed of Thought


Over 10 years of community discussion and knowledge are maintained here as a read-only archive.

New discussions should be taken up in issues on the appropriate projects at https://github.com/PureMVC

Pages: [1]
Print
Author Topic: Flex Code Formatter  (Read 10696 times)
Jason MacDonald
Sr. Member
****
Posts: 243


View Profile Email
« on: June 05, 2009, 08:52:37 »

It always drove me nuts that I couldn't control the default way Flex formats it's code. I've always coded by putting bracers on the same line as the method, class etc. I decided to do some searching and found this[1] eclipse plugin. I don't know how I survived before without it! It works perfectly and is highly configurable. Just thought I'd make a mention of it incase others have the same problem as I did.

[1] http://sourceforge.net/project/platformdownload.php?group_id=248408
Logged
Ondina
Sr. Member
****
Posts: 86


View Profile Email
« Reply #1 on: June 07, 2009, 02:40:08 »

Hey Jason,
Thanks for   the  tip.
I’ve just installed the Flex Formatter.  Very cool features!  Especially  the mxml options .
The  formatting of actionscript code works fine inside of  actionscript files and classes, but I can’t make it work inside of a Script tag.
Ondina
EDIT:I’ve tried Flex Formatter with Adobe Flash Builder 4. In FlexBuilder 3 it works fine inside of a <mx:Script></mx:Script>  tag.
The problem seems to be  the new  fx prefix. Obviously  Flex Formatter  doesn’t recognize  the <fx:Script> . Actually something to be reported on their forum, if I wasn’t so lazy.
Anyway I’m wondering how the Fx-prefix and the new namespaces will affect the porting of my apps from Flex3 to Flex4  FlashBuilder4…

« Last Edit: June 07, 2009, 03:48:57 by Ondina » Logged

~ Ondina ~
mldj
Newbie
*
Posts: 1


View Profile Email
« Reply #2 on: June 27, 2009, 11:10:05 »

I still don't have any idea about the backwards compatibility with Flex 3, after the new controls will be much more layout-customizable. One thing seems sure - porting apps to the Flash Builder will be more of a pain in the neck than porting Flex 2.0.1 to Flex 3. Thank god I'll be doing the Objective-C port ;)

As for the code beautifier, after I've coded for only two years according to that convention, I got used to it and now it's much more difficult for me to read through code with C++ styling: opening brace at the same line, etc.

Cheers
Logged
Pages: [1]
Print