Ok, as per my last entry, I’m gonna do some comparisons between Komodo 3.5 and Zend Studio 5.0. Both have recently been released, both are “heavy weight” IDE’s (Integrated Development Environments). Zend Studio deals particularly with PHP… that’s Zend’s bread and butter, so it makes sense. Komodo, on the other hand, is more of a programmer’s editor in that it does PHP, Python, Perl, Ruby, XSLT, and Tcl. Of course, you can use either as an editor for other languages, but most of the IDE features beyond syntax highlighting would be, obviously, unavailable. They both weigh in at about the same size, which is interesting… I actually thought that Zend would be bigger due to the inclusion of PHP, etc. but then again, Komodo does deal with a larger number of languages. The proof:

vdanen@odin:/Applications/Tools/ >% du -sh Zend\ Studio\ 5
82M     Zend Studio 5
vdanen@odin:/Applications/Tools/ >% du -sh Komodo.app     
93M     Komodo.app

Anyways, on with the comparison!

The first thing is how they open. Not a big deal, but Komodo has this neat “Start Page”. It shows you recently opened files and projects, links to help tutorials for the different languages it supports and demos. This is something I always liked about Komodo. Zend just opens up into a blank document.

Each has a multi-pane view; by default Komodo’s panels are off, but there are buttons to toggle them. With Komodo, on the left you get the file tree view split into two tabs: Projects and Code. Without a defined project, the Projects tab is empty. The Code browser shows you currently opened files. Clicking the triangle next to the file name will break down functions, variables, and whatnot. Double-click on any of these will take you to where they are defined in the code. There’s even a little box below the code browser that shows you function comments if you defined them in the code. There’s a search box to help you find what you’re looking for and the list is slimmed down as you type. Nice feature.

Zend, on the other hand, also uses the left panel to inspect files and projects. It’s inspector isn’t quite as nice… it shows functions and included files, like Komodo, but doesn’t show comments. Double-clicking will take you to where the function is defined in the code. Alas, unlike Komodo, it doesn’t show variables. One thing it does have that’s kind of neat is a “PHP Inspector” that will let you look at all the defined functions and constants that PHP uses. It’s kind of goofy tho.. it needs to open the documentation with a browser, but the shell script it uses doesn’t seem to work… when I pointed it to Safari directly (unfortunately, you can’t just point it an app, but have to dig deep into it… for instance, to use Safari as the browser I used “/Applications/Safari.app/Contents/MacOS/Safari”… not very nice) it opened a second instance of Safari and made Saft think it had crashed. Uh oh. Good thing nothing happened to the first Safari process or I’d be re-typing all of this.

It’s irritating that the ./runBrowser.sh definition that’s in there doesn’t work… from the commandline, it works fine. I’ll have to file a bug about this.

In Zend, the right pane is for debug output… this lets you see what your script is doing. The bottom pane is for debug messages and there’s also a debug window that will let you inspect variables, watches, stack, breakpoints, and the output buffer from the debug session. If you’re note debugging, a simple click on the window name will minimize them and allow you to see more of your code.

In Komodo, the bottom pane is for various informational views; breakpoints, command output, and “SCC Output” (or the output of source code control stuff… cvs, subversion, etc.). One neat thing with Komodo is the right pane… it’s the Toolbox browser. This was a new feature in Komodo 3, IIRC, and I never really got to play with it much although it seemed really cool. The Toolbox contains snippets of code; the samples show HTML snippets that when you double-click get added to the code. You can even configure URLs as snippets.. a quick way to get to some online documentation. Defining a toolbox entry is easy… create a new snippet, add the code you want it to insert, give it a name, and you can even bind it to a hotkey. This is actually an extremely slick feature… you can have it so that at the touch of a key (say ALT-CTRL-F) you could have it put in a function definition complete with a section for code comments, etc. Zend needs to get a feature like this (man, I had completely forgotten about this feature!)

Oh, wait! It does have a feature like this… just not as prominent. Nice thing to stumble across. Zend has a feature called Code Snippets and it can update the snippets from Zend’s website. Damn! I wish I had noticed this before. Zend! What’s wrong with you? Why not make this more obvious?!? Looks like the code snippets are user-contributed to boot, so you can keep getting new code snippets and they’re broken down into different categories. Wow. Now I’m impressed. Go to Edit->Show Snippets to check this out. I don’t like the fact that it floats in another window… I much prefer how Komodo has their Toolbox laid out, but I’ll take what I can get. This is something I’m going to be exploring a lot more of soon.

That’s pretty much it for the interface. The Komodo interface looks nicer, but it’s Mozilla-based rather than some java thing. Yes, that means that, like Zend, Komodo isn’t very “OS X-ish”, but it still looks clean. I find the layout looks better than Zend’s does. You can always tell a java app… they all look kinda… ugly. Komodo just looks like an app running under X11, which is ok with me.

Hmmm… looks like Zend’s Code Analyzer function has taken a step backwards with the final release, or they’re being more picky. BTW, the Code Analyzer is awesome… I find it extremely useful. Not as good as debugging or profiling, but works really handy for looking at code and offering suggestions for things or letting you know if a defined variable is never used, etc. Helps to make things more efficient and catches some stuff you might not otherwise notice. But it seems a little wonky now… for instance, it’s telling me that there is an “Unused function argument: $md5 (line 384) in the following piece of code:

function mkmd5($md5)
    global $debug, $distar;
    $marray = array();

    foreach($md5 as $name => $val)

Ummm… yeah… $md5 is being used… it’s right there in the foreach(). The RC didn’t pick that one up. Then it has the balls to tell me that the value of the variable was never used. Well, sure… it’s because it’s an array silly. That’s why we’re using a foreach. The value of $md5, all on it’s own, is “Array” and that wouldn’t be overly useful now would it?

Gripes aside, the code analyzer is extremely useful. I really like it. Komodo doesn’t have anything like this… all it has is the debugger (which is ok, but I’ve never actually gotten it to work nicely for me in the past).

Speaking of the debuggers… I can’t speak for either of them. I’ve tried to setup the Zend stuff in the past to make the debugger work but my firewalls keep getting in the way. Apparently there is a way to tunnel debugging messages through an open port to work with firewalls, but I couldn’t make that work either (although, in all fairness, I didn’t try overly hard). I do need to attempt to get that working, tho.

Oh! A new feature in Zend is code folding. This is cool, but something Komodo has had forever (so I was natually excited to see it appear in Zend). Now, when you edit a PHP file, there’s a little +/- box next to the start of a function, click on this and the function folds. Line number count stays accurate… ie. your function may start on line 302, fold it, and the next line below the folded function is 380, so line numbering is consistant. This is great… but… Komodo has had it for way longer, and much better to boot. You think “function folding” is cool? Komodo’s code folding smokes it. You can fold functions, if statements, foreach, for, while, and so on…. in fact, anything you use curly braces for, you can fold. I’m not sure why Zend didn’t carry it further… granted, folding functions and getting them out of the way is awesome, but being able to fold if statements and such as well is extremely useful.

One thing that Zend Studio has that I like is an SQL browser. This allows you to connect to an SQL server (be it MySQL, Oracle, PostgreSQL, or whatever) from within Zend itself. This is really useful when you’re working on a script with database connectivity. You can walk a tree view of the database server and look at different databases, tables, and so forth. Now, it’s just a browser mind you, not an editor, so it’s not a replacement for something like phpMyAdmin, but it works in a pinch. To me, this isn’t a be-all end-all feature, so it doesn’t disappoint that Komodo doesn’t have it.

One thing that Komodo has that Zend doesn’t (and this lends itself more to the fact that Komodo deals with perl and other languages) is the regular expression toolkit. This is really slick.. it helps you build regular expressions. For someone like me who pretty much sucks with regexps, this is handy.

In fact, Komodo has a lot of features that Zend doesn’t have, such as a GUI builder. You can use Komodo to build GUI applications, but only with Perl/Tk, Python/Tkinter, Ruby/Tk, and Tcl/Tk. It also gives Perl, Python, and Tcl programmers an interactive shell which lets you type code and watch it being stepped through as you go. Kinda neat, and I can see it being exceptionally useful for the perl/python types.

Both IDE’s can handle CVS and Subversion, which is great. I’ve recently switched over from CVS to Subversion, so having the capability to commit from within the IDE is nice. Zend’s svn support works quite well.. Komodo, I’m not so sure of. The only source control setting I seem to have with my script (which is in subversion and the working copy is in my local subversion copy) is to remove it. That doesn’t sound good at all. Can’t see anything I’d need to configure in the preferences tho.. bug maybe? Wierd. Using one of my old CVS files, the property inspector shows that it’s update to date at revision 1.1 but the only SCC control I have is to add it. That seems wrong too. Methinks Komodo has some issues with SCC as it seems neither subversion nor CVS is working properly.

I guess the bottom line, is they both have some quirks, they’re both good and capable IDEs, and they both serve different purposes. It’s a fact that Komodo’s main language support is perl and python; PHP is something that is supported, but it seems to lag a little behind the support for perl and python.. maybe lag isn’t the right word… PHP doesn’t have some of the more powerful features that perl and python support does; but that could also be due to the language itself and the interpretters. Suffice it to say, Komodo is meant as an all-around IDE, and it does very well at it. I’ve heard rave reviews from other beta testers who are more perl or python programmers. Me… not so much. I avoid perl if I can, and I’ve never tried python. I like PHP.

To that end, Zend seems to be a better fit for me. Sure, I like some of the features Komodo has better… I like the way it looks and feels better. But I think Zend has got a handle on what a PHP programmer wants, and Zend Studio delivers. If you do programming with more than just one language, and/or you do PHP programming but it’s not your main language you code in, Komodo is probably a better fit than Zend. If I did more perl programming (or, rather, if I liked perl more), I’d probably end up using Komodo more just because if I used it for perl, got familiar with it, built up my code toolbox, I’d be more apt to use the same IDE to work with PHP than switch back to Zend just for PHP work. Since almost all the coding I do is in PHP (and I can’t see that letting up since I just converted a fairly hefty perl script to PHP and the dang thing runs twice as fast), I’ll stick with Zend and it’s arguably better PHP support. Komodo, I’ll keep it around and installed and probably play with it some more. After all, it does syntax highlighting for almost every language out there (even my bash scripts).

Well, to wrap this up (yes, my druid… I know you want to slaughter some furbolgs!) I feel sorry for the poor fellow you decided it wasn’t worth his time to try out Zend because the installer failed so miserably (as he put it) and because it didn’t conform to a nice Mac package. His total loss (my entry earlier today noted that blog entry). If he doesn’t have time to install a new version of java to play with it, he probably wouldn’t have time to explore and goof off in the IDE either, and he’d be missing a whole bunch of cool features. He uses BBEdit, and granted, so do I, but rarely for PHP code (my wife does to edit some websites, but she’s not doing very much there). BBEdit’s PHP syntax highlighting is not nearly as nice as what Zend or Komodo offer, and it doesn’t have the great features that both IDE’s have, like debugging. Yup, it has subversion support (which is great), but BBEdit is just a glorified text editor. A great one, don’t get me wrong, but it’s not an IDE. If you type stuff wrong in BBEdit, it won’t tell you that you did… it’ll just let you do it. Komodo and Zend both give visual cues when they detect syntax errors… something that can save a lot of time.

Komodo vs. Zend… well, I’d have to say that if you’re just doing PHP… Zend is a clear winner. If you’re a jack-of-all-languages, you’ll probably be more interested in Komodo. If you’re a total geek (or loser, take your pick) like me, then you’ll want both just for kicks. =) Personally, I’ll stick with Zend. I keep watching what the Komodo folks are doing… it’s been a long time since I used Komodo for anything other than goofing off, but that’s because I changed my main platform and they didn’t follow. It only took me a little over a year of begging for an OS X version to get it, and that’s gotta count for something. My kudos to the Komodo development team. (I also like that Komodo is a Canadian product… too bad Vancouver’s gonna get all soggy for the next few months).

Oh, for what it’s worth, this “review” is based on the OS X versions of the programs. Both Zend Studio and Komdo are cross-platform, so if you work on OS X, Linux, Windows, Solaris, etc. you’ll be pleased to note that you can use either program on any platform now (and I believe one license covers all platforms as well, which is nice). For me, that’s a must… being able to use the same program on my desktop, powerbook, or my libretto is really important to me.

Share on: TwitterLinkedIn




Stay in touch