The Bluefish HTML editor and integrated IDE

Tool In the Tank

By Andreas Grytz

The Bluefish HTML editor is useful for large-scale Web projects and also smaller programming projects. Syntax highlighting and code blocks help developers build projects efficiently.

Building complex Web projects with CGI support can quickly become confusing. An HTML editor such as Bluefish [1], with support for project management and the more popular scripting languages, helps you keep track. The current version 1.01 gives users a number of interesting new features.

The program is not officially part of the Gnome project, but it is often used in Gnome environments. Bluefish is based on the GTK toolkit and requires GTK version 2.0 or newer. libpcre version 3.0 or later provides useful syntax highlighting, however, the spellchecker, which is based on Aspell, is optional.

Users can also access online resources, such as FTP servers or WebDAV directoriess, transparently via Gnome VFS, a file system abstraction layer. Bluefish accesses the resources as if they were local directories.

Interface Design

The Bluefish interface has three panels: a menu bar with standard functions at the top of the window, a main panel, and a side bar below it. The main panel is where users edit files.

The Bluefish window uses tabs to allow users to quickly switch between various documents. According to the developers, the program can handle up to 3500 open documents, although this is hardly likely to happen under normal production conditions.

The sidebar fulfills three tasks: first, it has a small file browser, which gives users easy access to their files. Second, the developers have added documentation for some of the script and Web languages the program supports, and users can display the documentation in the sidebar if needed. Third, users can add bookmarks for directories they need to access regularly to the sidebar.

At the top of the editor window is a multi-tab menu that gives users quick access to HTML building blocks. The tabs are organized by function, allowing users to add tables, forms, or CSS elements with a minimum of effort. In the case of more complex constructs such as forms, the program prompts the user to specify the parameters required to display the element correctly.

Below the tabs, the software has some additional script editing tools. Depending on the language, the menu offers common building blocks for loops, includes, or SQL statements. This gives users the ability to put together smaller projects by pointing, clicking, and filling out dialogs.

The editor also facilitates Web page localization. Users can right click on the editor window to toggle through a number of input encoding variants. The program uses Unicode by default when saving files.

Developer Environment Light

The developers do not view their project as an HTML only editor. The fact that Bluefish supports script languages and traditional programming languages such as C means that Bluefish is more like a manageable integrated developer environment. This is useful whenever a full-fledged IDE might be too much trouble - such as for smaller projects - as an IDE often gives programmers unwanted features than are more likely to confuse than to help.

The fact that users can search the integrated Python and PHP documentation in the sidebar is another useful feature. This is the place to go for short descriptions of the standard functions and their return values. Automatic indenting, line numbers, and sophisticated syntax highlighting facilitate working with source code.

Bluefish gives users the ability to evaluate makefiles and to display the calls in a separate window. It uses the same approach for calls to external programs such as Tidy, an HTML syntax checker [2].

Some external programs are preconfigured by the standard Bluefish installation, however, the installation routine does not check if the programs really are installed and in the specified paths. This can cause confusion, as the software can give you menu items for non-existent programs if you don't watch out.

Nevertheless, integrating external programs does make the software extensible. For example, users could harness this ability to add their favorite developer tools.

Figure 1: Bluefish gives you a three panel interface you can configure to suit your needs.

Figure 4: Creating a Bluefish project.

Project Management

Bluefish really shines when you need to manage multiple files from a large-scale project. The program has a dialog for this purpose. Users can specify a target directory for the project and assign an internal Bluefish name; right clicking will allow you to add folders and files to the sidebar.

The project dialog also allows users to define a Remote Directory for the local project.

Figure 2: Warnings and error messages appear in the Output box, which is located below the main panel.

Impressions

Although the developers claim that the current version 1.0 is stable, the software still has one or two idiosyncrasies. For example, the program crashed repeatedly while creating a project when we attempted to select a template for the project. Make sure you have a safe copy before you start working on production data.

According to the Bluefish website, the developers are working on incorporating the Gnome Project Human Interface Guidelines wherever possible. Despite this commitment to interface improvements, the program interface is cluttered in places, and some dialogs, such as the sidebar settings dialog, take some getting used to.

When all is said and done, Bluefish is a robust editor that can give you a helping hand with your Web and programming work, once you get to know the ropes. The code blocks remove the need for repetitive typing and thus prevent human error.

Besides the dependencies we already mentioned, all of which will typically be fulfilled by default on a Gnome system, the software needs a few Gnome libraries. Again, most modern distributions should have these libraries. The program does not need much disk space and makes good use of memory resources, and that makes it useful for programmers working on older hardware.

Figure 3: Bluefish lets you add external tools.

INFO

[1] Bluefish homepage: http://bluefish.openoffice.nl

[2] HTML Tidy: http://tidy.sourceforge.net