K-Resource

Reviewed by Matthew Jones

 

Issue 24

Nov/Dec 86

Next Article >>

<< Prev Article

 

 

Kuma

If you have an ST, you will have noticed that many programs consist of two files, the APP (or .PRG) file and the .RSC file which contains encoded dialogs, icons, and other GEM objects. I have in past issues reviewed several compilers each able to create the APP application program file but, as I said in issue 21, this is only half the process of generating a GEM application.

A resource editing program is needed to generate the .RSC file. The trouble is that until now, the only resource editors have been the Digital Research (DRI) Resource Construction Set (RCS) which suffers from bugs and design problems often making it unusable, and the rather limited Megamax version. Both come with expensive (and perhaps unnecessary) C compilers. To solve the problem Kuma have released K-Resource, an advanced resource editor which is available on its own.

THE MANUAL

K-Resource is packed in an 8 inch square folder and comes with a 31 page manual. The manual is in three parts, an introduction, an example, and a (relatively) large reference section. Like many manuals, this one only sets out to tell you what K-Resource will do, and how to use it, it does not really aim to teach you all about resources, what they are, how they work, and how to program for them - if you want to know that sort of information, get a copy of the ANTIC professional GEM series (1 through 15). The example takes the user through a very simple resource creating session, with 12 accompanying screen dumps. It is a simple demo, and I thoroughly recommend that anyone new to resource editors should play with it for some time. The reference section is quite thorough and explains all of the programs operations.

THE EDITOR

K-Resource differs from the two aforementioned editors in its basic operation by not having a window with all of the objects on the desktop which you copy into the single resource window to use. The K-Resource desktop is used very much in the same way as the normal GEM desktop (you can copy and delete files, create and open folders), but has been enhanced so that you can copy a resource file icon from the window (the disk) onto the desktop (representing memory) by dragging. By dragging more than one, you can edit several resources at the same time (something unique to K-Resource). When editing a resource tree (tree is the term used to describe the whole of a GEM `part', tree types are: forms (dialogs); menus; free strings; alerts; and free images) you generate a new object by selecting a menu item which brings up a dialog with suitable possible parts. Click on one and you have it. This is easier than the drag from window used by the other editors and means you can use a 'fulled' window if convenient.

The increased usability does not stop at the new item selection. When you have an object you will want to customise it (to change the text in a string, make it coloured or give it a `macro' name for reference by the application) and a double click brings a large dialog with all the variables (other editors make you go to several places to make all the changes). Alternatively a single click produces a pop-up menu, just where the cursor is, with options available from: edit (like a double click); hide; unhide; flatten; snap; sort; and retype.

If you click on an icon or image, you can use a built in icon editor which is more convenient than having to use a separate one (though see later). The final option available is a test facility. Again unique to K-Resource, this allows you to do a simple test of your resource before you leave the editor. If you test a dialog, it will appear in the middle of the screen, fully animated, and allow you to click on buttons, edit strings, and use all the various parts to ensure correct operation. When you select an EXIT button an alert showing its number and name (if any) appears, and you can either continue or end the test. Similarly menus and alerts can be tested (anything unsuitable for testing, e.g. a tree with no exit button, is automatically untestable).

Error messages are provided in a very novel way. If you make a mistake, you do not usually get an alert, rather the erroneous item is surrounded by a thick, rounded rectangle linked to another box which explains the error. A very nice and useful touch, and one I hope others learn to emulate.

ADVANCED FACILITIES

K-Resource also makes some of the more advanced GEM resource facilities easily available. When DRI defined the resource structure they left a few spare flags around for programmers to use for special effects. These extra flags (obstate, obflags and obtype high byte) are included in the K-Resource flag setting dialog.

PROBLEMS!

Unfortunately K-Resource is not without its problems. The first I noticed was that you cannot load icons from other icon editors (indeed you cannot load icons at all, only edit them). If you have to make two versions of a resource for different resolutions, it is useful to be able to create a low resolution version from the high resolution file, by just loading in the correctly sized icons. This is partly solved by the fact that you can delete the old icon and then copy the new icon from another resource. This is risky though as it is critical that the order of the icons is the same in both resources if one application is to use both. Deleting and then copying is likely to alter the order.

The next problem I had was also with icons. I found it impossible to move a small image (an icon without a mask) just a fraction when it was at the bottom of a tree. This is because as soon as I started to drag it, an enormous `shadow' was generated which fell off the bottom of the tree and prevented me placing it back down again. Similarly, I found it impossible to shrink an image box size to reduce its inverse-select area.

It may be that I make exceptional demands upon a resource editor, but another of the facilities I occasionally require is the generation of the C source code from which a resource can be recreated on another machine (an IBM for instance). Of the three resource editors available, only the Digital Research version can produce the C source. I hope a future version of K-Resource will give this option too.

The above problems may seem trivial, especially as most users will not notice them, but there are other more serious errors. K-Resource occasionally just hangs, I'm not sure when, but it seems to be when you cancel an operation. Once hung, you have to reboot, and that means that you lose all your work. I also managed to bomb the system in the test mode by double clicking on a TOUCHEXIT button. The reason for this should be well known to the person who wrote K-Resource (in this situation the high bit is set in the returned 'hit-button' value, making it seem negative), and it worries me because it is a basic mistake and there may be more I haven't found. It is obviously necessary to save your resource often.

CONCLUSION

While there are a few problems they are relatively minor when weighed against the advantages that K-Resource gives you, and certainly less serious than those in the DRI editor. It really is much easier to use than the other resource editors, and is well worth adding to your set of utilities. Remember my reservation that you need other literature to tell you about resources and how to program for them though.

K-RESOURCE costs £39.95 and is published by Kuma Computers Ltd. 12 Horseshoe Park, Pangbourne, Berks RG8 7JW.

top