A Look At XULRunner And Songbird

About 2 weeks ago I found out about Songbird, a media-player that is suppose to be “the last media player ever” (I’m assuming that because it will be so good, we won’t need any other media player). Songbird is written in XUL which is a user interface markup language also used by Firefox and Thunderbird. The interesting thing about XUL is that it looks like HTML. So anyone who is familiar with HTML can look at the XUL tags and kinda know what to do.

Here are a couple of my assumptions about Songbird relating to XUL. I’m assuming that Songbird is going to be using XULRunner. XULRunner is great because you can run XUL applications without the need of Firefox or Thunderbird. The only problem I see with XULRunner is the fact that applications run through XULRunner, kind of like Java applications are run by the Java Virtual Machine. So you don’t see appname.exe in the table of processes, rather you see xulrunner.exe. If I had to write a XUL application this would bother me big time. I like seeing my apps name in the table of processes (Task Manager). I’m assuming that the developpers of Songbird will want that too which is why I’m guessing they’ll be compiling XULRunner themselves to fit with Songbird instead of using the available binaries. This has the added advantage that they can compile it to fit Songbird’s specific needs. Another advantage of XUL is that you can let someone who isn’t a programmer design the interface of the application without it actually working and without the need for compiling the app. Just run xulrunner application.ini at the command line and the application starts.

While XULRunner has many advantages, it has it’s weaknesses. One obvious weakness I’ve noticed is the application’s size at runtime. A basic XULRunner application takes at least 10 MB. It’s the XULRunner runtime environment that is taking all that space. A lot of people have been asking the Songbird developpers to make it leaner and faster than iTunes. I’m not sure how they will do that considering that Songbird seems to put together a lot of different open source project together (XULRunner, VLC, ml_ipod…). It would be great if in the near future, you can choose to disable certain XULRunner features in order to save memory.

I’m personally becoming very interested in XUL and XULRunner. I wrote a basic app tonight but if only I didn’t suck at JavaScript. I’ll be looking into XPCOM to see how I can have a program do something by using C++ instead of JavaScript.

Oh and another problem I have with XUL: the documentation sucks for beginners. I’ve been searching like crazy on how to create a basic application using XULRunner. Something that helped a lot was Darin Fisher’s MyBrowser sample XUL application. Nonetheless, I still have a lot of unanswered questions which are mostly related to the JavaScript.

Update: I’ve found a pretty simple way of deploying an application running XULRunner thanks to this tutorial. This still doesn’t solve the fact that your application will still be named xulrunner.exe in the table of processes. But a simple solution to this is to rename your copy of xulrunner.exe to whatever name you want (e.g. appname.exe). Then you can add a appname.bat file in the application folder with the following syntax: start xulrunner/appname.exe (appname.exe is whatever you renamed xulrunner.exe to). Alternatively, I’m sure you could compile a C++ program to do whatever the bat file does and somehow avoid that console window that shows up for a split second.
My solution doesn’t make for a professional application. This is why I think that you’d still have to compile your own copy of XULRunner for your specific application.

9 Responses to “A Look At XULRunner And Songbird”

  1. December 9th, 2005 | 1:58 am

    I’m interested to know why you think that a binary named “xulrunner.exe” is a big deal: end-users don’t look in the process table; and the stub binary that semi-advanced users might come across browsing your installation folder is called “yourapp.exe”.

    Recompiling XULRunner to remove extraneous features (to save download weight or runtime memory footprint) has significant disadvantages, which I’ve blogged about:

    http://benjamin.smedbergs.us/blog/2005-07-29/the-testing-matrix/

    Not only does compiling XULRunner yourself have significant opportunity cost for most developers, it also means that you can’t share single XULRunner install between multiple apps (you have to have a private XULRunner). This isn’t so much a problem in the developer previews, since we don’t have a documented and well-tested shared-install mechanism yet, but we will for the first production release.

    –BDS

  2. marv
    December 9th, 2005 | 11:45 am

    One of the reasons that come to mind (and this may not be an issue for the average user) is that if the XUL app freezes and the user wants to kill it, then they may have difficulty finding the process in Task Manager.

    I don’t know anything about the internals of XULRunner, but I’m wondering what happens if the system has one runtime environment for multiple XUL apps and that one of those XUL apps freezes? Does the entire XULRunner process stall because of that one app? if this is the case, then this is an obvious reason for having your own XULRunner copy for your application. Software developpers wouldn’t want there app to freeze just because the user was running a buggy XUL app written by a kid.

    I agree with your disadvantages about stripping XUL of certain features. I think the problem may lie in the fact that everyone seems to have a different idea as to how to use XULRunner. I mean if I’m doing an app and I don’t need 90% of the XULRunner features, then shouldn’t I be able to take ‘em out? I believe that people think of doing this because XULRunner seems to be small and manageable (compared to .NET and Java which I’m sure a lot of people compare it to) and because you can have 1 copy or multiple copies. You don’t have that option of having a unique copy of the runtime environment for your program when you use .NET or Java.

    Lately I’ve taken a lot of interest in XULRunner because it seems very promising (who doesn’t want to create a user interface by coding something similar to HTML ;)) Can anyone help with developping XULRunner? I’m just a college student though.

  3. December 10th, 2005 | 5:24 pm

    Each XULRunner app runs in its own process, so a single app hanging will not affect other apps at all.

    And yes, anyone can help with XULRunner, it’s an open-source project and I’m happy to get you started (or just look in http://bugzilla.mozilla.org/ for XULRunner bugs).

  4. February 8th, 2006 | 8:32 pm

    I was wondering what that process was…I just downloaded Songbird, and did a Google search on that process. Your page was the 2nd result :) Thanks for explaining!

  5. Herndon
    May 9th, 2007 | 1:48 pm

    I can tell you that it does matter to end users, even those that aren’t that tech savvy. I don’t know what I’ve downloaded that incorporates it but something running xulrunner.exe has been clogging up my memory/CPU usage (on further review it’s the newest Google Adwords editor tool) and I came across this page in a search to find out if it was some kind of spyware. And I know I’m not the only one who has had the same concerns.

  6. August 6th, 2007 | 7:38 am

    life’s basically been My boring lately. ,

  7. August 30th, 2009 | 6:36 pm

    Great blog you got here…keep up the good work.

  8. Rakesh
    October 15th, 2009 | 3:18 am

    Good work….
    I have one query… Can we create multiple processes of xulrunner?
    I am trying to use crowbar and want to create separate process for each xulrunner instance.
    Regards…

  9. July 12th, 2012 | 4:05 am

    Viagra Launch Date Buy arctica Cheap Medical Buy Soma Cialis No Prescription Counter melanie raspberry Is Impotence Permanent Blood Pressure Medications Motilium Tablets 5 Mg Prolonged Use Of Viagra Erection Percentage Dht Propecia Methotrexate Vaccines Prescription Sample Amoxicillin Tramadol Mexico Injection Prescription Soma Picture How Long Can Xanax Be Detected In Urine Xenical Usa Propecia Xanax Know No Prescription Rheumatrex Online Prednisone Vs Amoxicillin Xanax For Public Speaking Alcohol Methotrexate Endocrine Methotrexate Monitoring Laws Xanax Xr 30 Mg Tramadol For Dogs And Body Buy Levitra Part D Online Bupropion And Ritalin Deep Sleep Klonopin Vs Xanax bandidos Percocet Legal In Mexico Xanax

Leave a reply