While a lot of Java development has been happening in the last few months, Java's learning curve has still put many a company's project on hold while developers learn to master the language. By the time the developers have caught up, new techniques and products come along. Now, we have a product that is supposed to eliminate the learning curve, and enables the developer to start producing useful applets (using drag and drop components with "actions") that can be used as is or improved on with code that you integrate into the applet. Penumbra Software's Mojo includes built-in components for drawing, rich-text editing, email, buttons and panels, calendar, clock, and animation. In this issue, the Java Developer's Journal takes a look at Mojo and lets you know if it's just the tool to put some magic on your site.
I tested the Mojo on a 686 150 Mz machine with 16 MB of RAM, running Microsoft Windows 95.
In the last month, a few visual Integrated Development Environments (IDEs) have appeared, such as Microsoft's Visual J++, Symantec's Visual Cafe, Aimtech's Jamba, and now Penumbra's Mojo. In today's market, the code that these GUIs produce needs to be flexible and adaptable. Mojo enables programmers to enhance the code depending on their knowledge of Java programming. A lot of what Mojo does is hidden, which eliminates the need to deal with Java aspects such as threads and the AWT. Mojo's integrated Class and Method Browser lets you view actions and components, enabling the programmers to learn as they develop. Although it is possible to create and use an applet without typing a single line of code, Mojo encourages the programmers to integrate their own code, enabling a greater flexibility in the final applet or application.
Mojo installed from a single CD-ROM, taking about 13 MB of space on my hard drive. It comes with the complete JDK from Sun, although you can use whatever version you have installed on your system. Documentation includes a 55-page User's Guide that takes the user through the use of the toolbar and basic IDE functions, as well as an extensive online help system. The online help includes information on applets, compiling, components, declarations, functions, and general information such as Importing a Package, Mojo Directory and Package Structure, and Dual Hierarchies.
Mojo actually consists of two parts: the Coder (Figure 1) and the Designer. The Coder is a Smalltalk-like browser with an integrated editor; the Designer is the drag-and drop GUI builder.
The Coder makes Mojo truly robust by ensuring that programmers are not limited by their environment. Adding a Component is accomplished by dragging-and-dropping the Component from within the Class hierarchy into the Project. A dialog box will pop up, asking for the new instance name. After clicking OK, the new instance is added to the project. Existing code is edited by clicking on it in the Coder window under Current Project, and clicking on the Events tab under Available Options. By clicking on the right mouse button, you can add functions, remove functions, and override functions. The code is never actually added until you manually update it by pressing <ctrl>-U in the Code editor. You are able to revert back to the original code by pressing <ctrl>-R.
An applet can be created by starting Mojo, which opens a new Drawing area in the Designer (Figure 2). By clicking on a component in the Component Palette, and then clicking in the Drawing area, the designer is able to use Actions to incorporate functionality without touching a single line of code. Actions are dragged and dropped into a Component's Action List to create a particular response in reaction to an Event. Events happen to components; for example, a user clicks on a button, or drags and releases the mouse button.
Mojo features a list of Available Actions to choose from, including:
- Play Sound
- GoTo Screen
- GoTo URL
- Initiate FTP
- Initiate Email
Previewing an applet that you are creating is a matter of invoking the Coder window, which is invoked by clicking on the Switch to Coder button on the toolbar.
The Mojo development environment grows the more you use it. Mojo is component-based, and using it extends your library of components. Each component that you have created can be dragged and dropped into other applications you create later. All the methods you write for programming calls can become potential actions, and the code will always be there in the future. The programmers can make the components and actions they create accessible to others in the development team, and they in turn can make their code accessible to the original programmer. The idea is that Mojo is designed to facilitate open programming...which will make Java a much more production-programming language.
Mojo comes with several third-party components that you can add to your applets, or use on their own. They include:
Mojo can give the up-and-coming programmer a head start in today's fast moving market. The Java language isn't the hardest language in the world to learn, but it's not a two-day lesson, either. Mojo enables the skilled developer to prototype their applet, add their own code, test, and finally use the final product on their Web site. Using Mojo, the beginning Java developer is quickly on their way, creating, testing, and using an applet without actually having to write one line of code. If Java is to survive and dominate as the programming language of choice, it has to be accessible and usable by both beginners and masters. Mojo is one tool that makes it possible.
- Marquee Lights - TheMarqueeLights component puts a user-defined .gif file inside a moving marquee of lights.
- Ticker Tape - The TickerTape component allows the developer to place scrolling text in arbitrary places within the applet or application.
- Blink - The Blink component allows the developer to place blinking text in arbritrary places within the applet or application (as if we need something ELSE to do that).
- Guage- The Gauge component is a configurable, speedometer-like, progress meter.
- Calendar - The Calendar component provides a calendar framework to work with.
- Clock - The Clock component lets you put an analog clock into an applet or application.
- LEDClock - The LEDClock component lets the developer put a digital LED clock into an applet or application.
- Microline Tabs - The Microline Tabs component lets the developer add a grid to an applet or application.
- Microline Grid - The Microline Grid lets the developer add a grid to an applet or application.
- Microline Progress Bar - The Microline Progress Bar lets the developer add a progress/status bar to an applet or application.
- Microline Tree - The Microline Tree lets the developer use a visual tree structure in an applet or application.