In case you have not heard, Ruby on Rails (RoR) <http:// rubyonrails.com/> is getting a lot of attention in Web Development circles. It is a neat environment, but basically the same kind of Models, Views, Controllers structure as Fusebox. Both require some (maybe a lot) and study to become useful.

One of the interesting statistics on RoR is that the the majority of the developers are using Mac OS X! When someone posted a question asking why this was the case - the majority of the responses were "TextMate..." <http://macromates.com/>. TextMate is a Mac only text editor that is still maturing, but....

As a long time user of BBEdit, I reluctantly took Doug Hall's advise and played around with TextMate this weekend. I've tried jedit and fortunately I don't need to do cross platform editing (and would retire before I would!). I'm sure jedit is a great development environment for Active4D, but I couldn't get past all the non-Mac- like stuff and new terminology.

After about 10 hours of playing with TextMate, trying to understand it's language formating, project views etc., I think I might be convinced to move from BBEdit.

Much like jedit, it has project view, language formating, macros and what they call snippets that will auto-complete a section of code based on a keyword and tab action. Works fine for ruby, html, javascript, php, etc. But what about Active4D? If I understood RegEx, I'm sure I could of done this a little faster, but I've created a rudimentary Active4D Bundle (where all the language stuff goes) for TextMate.

For instance I created a snippet "whilenot", that if you type "whilenot" followed by a tab would produce:

First Record([])
while (not(end selection([])))
        # code...

        next record([])
end while

and will position the cursor in between the table brackets on line 1. After putting in the table name and tabbing, it puts the table name in the other table name locations and then highlights the "# code" for further editing.

As I said, this is just a start and by no means complete - or probably correct! I did steal the Active4D keywords and commands from Aparajita's jedit xml file. I'm sure I'll update it, but if anyone is interested in this early version, it can be found at <http:// maxwellgaggle.com/salex/textmate.zip>. The zip file contains 1 theme and 2 bundles that go in ~/library/application support/TextMate. There is a demo of TextMate at the above site. Upon opening your first .a4d file, select HTML (A4D) as the file type/bundle.

Now, if someone can speak RegEx, they maybe able to make TextMate sing with Active4D - I just got it to carry a tune. By using regular expressions in the bundles editor, code highlighting, auto-indention, etc. can be much more thorough than with other editors I've seen.

Regards,

Steve Alex
AIDT

"There are no silver bullets." _______________________________________________
Active4D-dev mailing list
[email protected]
http://mailman.aparajitaworld.com/mailman/listinfo/active4d-dev
Archives: http://mailman.aparajitaworld.com/archive/active4d-dev/

Reply via email to