I recently taught a class at the MGFest in Washginton on animation with Actionscript. In doing so I had to find a good way to teach students using both windows and OSX how to program AS3 in an External Editor. For windows I was very comfortable showing FlashDevelop, a free open source editor, and personally my favorite to work with. Having started to work at home on OSX and having to teach this to other I decided to research a good editor.
The obvious leader is FDT from Powerflasher, who has an eclipse based solution that is well tied to the Flash IDE and the mxmlc compiler. Having used Flex builder for a while now I felt pretty comfy in this environment. the problem is I don’t like eclipse. the program itself is made to accomplish so much and I see this as its advantage and its downfall. it has always felt a bit bloated to me, and I have had slowdowns and simple problem with just color schemes I would like to use.
So with that I started to look at easier solutions. TextMate has always been a big favorite of mine for editing all sorts of documents. From PHP, HTML and CSS, and now to ActionScript I have found TextMate to be lightweight and simple, yet powerful. So I started a hunt for a bundle to help do As3 Development. that’s when I cam across a Blog post by Simon Gregory which included his Actionscript 3 and Flex Bundles which have since then been placed up on github.I ended up forking this project and started to work on some variations of my own. Nothing too amazing, just simple things I was use to in FlashDevelop, now I could accomplish in TextMate.
To make this easier I decided to do a Video Tutorial on getting everything setup. I apologize in advance as I have been sick and still decided to record this thing, so if there is some sneezing and stuffy nose madness, well I am sorry. Either way, the following is a link to the tutorial and all the assets I used. I really hope this is helpful for people getting started in Actionscript programming, and stay tuned for more on why I see Actionscript and Flash in general starting to push its way into Film, Motion Graphics and Television!.
Watch Tutorial : TextMate for Actionscript 3 Tutorial
Links
Tags: actionscript, textmate, tutorial






your bundle fork seems to be very interesting … i will test it ..
I have a question.
During my tests with textmate/as3 the most annoying thing for me was the lack of autocompletions for custom distant sources. I see in your tutorial that your monsterdebugger import autocompletion works nice.
Does the imported classes/packages have to be in the src folders or is there any alternatives ?
thanks ..
@david, custom code completion definitely works. Not sure what you mean by “distant sources”. There are a few places you can put code, if you are really interested check out line 40 of “ActionScript3.tmbundle/Preferences/Settings.tmPreferences” you will also notice it uses the TextMate variable TM_AS3_USUAL_SRC_DIRS which I would think you could control if you needed to. The templates I have provided only include code from the src, lib/bin, and lib/src folders, though you can add more in the config xml if needed.
Though personally I wouldn’t recommend this. I know there are a lot of people that like to have a central location on their drive for some code repos. I however am from the world of projects and for me a project should consist of all the code I need to compile and rework the project. So I still recommend putting your code into the libs/src, libs/bin, or the src folder. This covers all the bases as src is for your code, lib/bin for swc’s and lib/src for external source code. This makes things a lot easier in 2 years when you want to come back to a project but you have updated to paper vision version whatever and it doesn’t work with your project anymore… I mean its not very hard to keep your repos updated, then just export them out and copy over the ones in your project…
After a little research I have noticed that the compiler and code completion will follow symbolic links, but not textmate’s import completion, I will look into this a little maybe symlinks could be a solve for this?
Hope that makes sense :)
-ross
Thanks a lot for making this intro vid for switchers like me. I wish I saw it a week ago :)
A couple of things I miss from FD is the possibility to “jump to method definition”, getting the tool tips for methods from keyboard combo and for some reason I can’t get the method params predefined on constructors like new Bitmap(bitmapData:BitmapData) however works great on methods.
Cheers,
Ted
This video is great.
I had puzzled through setting up TextMate with the original AS3 bundle and Flex SDK a few months ago. I was working with the TextMate demo then. Recently I bought TextMate and am working with some elementary papervision stuff. I was interested to see if you would touch on external class paths in the vid. That was something I had to really hunt for in my initial setup. But your comment #2 @david made a good case for pulling those libraries all into the same folder structure. I’m trying to see if I can set up TM to allow both kinds of development.
I became interested in the idea of developing Flash apps for as cheap as possible earlier last year. I also couldn’t really get into Elcipse.
So, yeah, good job on the video and the bundle. I’ll be sure to link to this post if I use this setup for anything cool (or lame I guess too).
autocomplete work great! even with custom classes
I found one bug: when custom class returns sthng other than void, autocomplete doesnt work as it should.
one more thing that could be great is to color Custom classes.
any chance to make/fix this problems?
haha I use TextMate as well and is my favorite tool for programming.
thank you Ross, this helped a lot.
Hy.
First tanks for that amazing job!
Second, unfortunate I found a error in auto completion.
If I press control + i to auto complete a, for example, MovieClip var, I got the tip popup error: WARNING: completions incomplete. The class MovieClip was not found.
Can you help me?
Thanks for Brazil, and again, great job!
Hey mate, thanks for the tutorial. Just wondering, you were about to talk about how to add snippets but skipped that?
I wanted to add a snippet for addEventListener, any tips?
Cheers.
Great tutorial, in between the sniffles. I needed to set up my TextMate for AS3 development after installing a Flex trial so this video guide was perfect. I’m having a problem with embedding images though. The java just chugs along but nothing happens. I tried just embedding an image to use as a class and it never works. Any tips?
Thanks!
I realize this post isn’t too recent, but I am having the same problem as Gerry. Everything will compile and build fine until I try to embed any form of image. After that flex2.tools.Mxmlc will load and just hang there indefinitely. Does any one have any ideas why this might be happening or a direction to look in to solve this problem?
I will dig into it more, I can honestly say i didn’t do a lot of Flex Dev in textmate mainly pure AS stuff. I also will say I have jumped ship a bit have been working with IntelliJ for a while now, and cant really imagine going back. Regardless I will try to reproduce what your talking about see if i can offer any insight.