Komodo 5 beta 1

Posted by toddw on 2008-10-15 11:58
Forums: Komodo Beta | OS: All / Any

Komodo 5.0.0b1

Komodo 5.0.0 beta 1 has just been released and it's now available for download:
http://downloads.activestate.com/Komodo/releases/5.0.0b1/

New Features in Komodo Beta 1

  • Code Formatting (IDE only)
    You can setup and use external code formatters directly within Komodo, using the "Code->Format Using->" menu command. This will format with your current code selection or the entire editor contents.
  • Tab Stops
    Tabstops in Komodo have been enhanced. They will now be visually highlighted in the Komodo editor. You can create a linked tabstop, which will automatically become updated as you type in the primary tabstop contents. You can even nest them, tabstops within tabstops.
  • Python 3
    We've started initial support for Python 3, Komodo now includes syntax checking capabilities for the Python3 interpreter.
  • Mac OS X PowerPC
    There are now powerpc builds of Komodo 5 available.

Komodo Extensions

A lot of the Komodo community extensions now support Komodo 5.0. You can
use the add-ons dialog within Komodo ("Tools->Add-ons" menu) to search
and install extensions, or download them directly from the community site:
http://community.activestate.com/addons

Additional Documentation

For full set of release notes and Komodo 5 documentation, see the online pages:
http://docs.activestate.com/komodo/5.0/

Cheers,
Todd

stan | Fri, 2008-10-17 03:00

Hi Todd,

Congrats on the new version. Beta 2 (build 2323) is amazing. I have been installing nightlies for quite some time now and things are only getting better and better.

I was surprised to see the tabstop system updated, very nice work indeed. I was wondering whether it would be possible to do the following:
<[[%tabstop2:h1 id="[[%tabstop1]]"]]>[[%tabstop1]]</[[%tabstop2]]>

And to take things a bit further:
<[[%tabstop2:h1 id="[[%tabstop1%macroNameInToolbox]]"]]>[[%tabstop1]]</[[%tabstop2]]>
where macroNameInToolbox is a macro with one JavaScript function taking one argument? This would allow us to do things such as auto-updating an element ID based on content (i.e. "Hello World" becomes ID "hello-world").

Thanks,
Stan

ericp
ActiveState Staff
Mon, 2008-10-20 13:52

The above snippet won't work. Let's take a step back, pull the bandanna off the crystal ball, and guess what's you're trying to do.

Clearly, you want to set up open and close tags for an element, that by
default is "h1". What you've got works fine:

<[[%tabstop2:h1>

I should mention that the only tabstop number that affects ordering is
tabstop 0, which is done last. Other tabstops are processed in the
order they're hit, although respecting order isn't impossible.

Putting a tabstop for the text is easy as well:

<[[%tabstop2:h1]]>[[%tabstop]]

The ":" for a standalone tabstop is optional when there's no
default text.

Now if you want to make an id attribute optional, you need
two more tabstops:

<[[%tabstop2:h1]][[%tabstop: id="[[%tabstop:ID]]]]>...

As for the macro/function hook, we've discussed it, but it's
off the radar right now, for reasons discussed in bug
http://bugs.activestate.com/show_bug.cgi?id=80514

- Eric

stan | Mon, 2008-10-20 14:01

Hi Eric,

Thanks for the update on both queries. I have tried the snippet below and it works like a charm:
&lt;[[%tabstop1:h1]][[%tabstop: id="[[%tabstop2:ID]]"]]&gt;[[%tabstop2]]&lt;/[[%tabstop1]]&gt;
On a side note, I can't get "Maintain selected text or cursor position after insertion" to work on build 2377, is this being replaced with tabstops as well?

Cheers,
Stan

ericp
ActiveState Staff
Mon, 2008-10-20 14:19

If you have tabstops in a snippet, Komodo ignores the "Maintain selected text or cursor position after insertion" option. You can put a '[[%tabstop0:]]' at the point where you want the cursor to be once there are no more tabstops to handle.

I suppose I could use the cursor position to stand in for '[[%tabstop0:]]',
if it isn't given. Mind adding a new bug?

- Eric

stan | Mon, 2008-10-20 14:34

Logged here: http://bugs.activestate.com/show_bug.cgi?id=80518
I sure am not the most popular guy among developers this week (rofl)

Thanks for the workaround Eric.