5.4. Internationalisation

Desktop Hacker may be altered to work in another language. If more than one language is available, the language may be picked from the Choices window. Currently available languages are English (UK) and German (D). To make a new language, shift-double-click on !dHacker and copy the 'UK' directory with the name of the new language.

The language directory contains a Messages file and a Templates file. The Messages file is self-explanatory, but in the Templates file Desktop Hacker uses its own system of 3D borders, which you will not be able to see in a template editor. However, they have a similar numbering system to the WimpExt and Interface modules, so if you have an editor that supports either of these modules you'll be able to see them if you alter all 'bnumber' validation commands to 'wnumber' for WimpExt, or 'bnumber' for Interface.

The borders are not quite the same, especially as their look can be configured; 0-6 are the same as WimpExt (6 being a new-style group title), and 7 is a version of 0 that can also be slabbed in by pressing Menu (for menu arrows). Remember to change the valiation commands back to 'bnumber' once you have finished!

Desktop Hacker supports some other validation commands, again prefixed with ''. You shouldn't need to tamper with these when translating templates to other langusges, but for the record they are:

When Return is pressed with the caret in this icon, the icon offset away from the icon number is 'pressed'. The offset system is used rather than absolute icon number so that icon groups can easily be copied, moved, and renumbered.
Same as r, but for the Escape key, to allow persistant dialogue boxes to be closed by pressing Escape, as the Style Guide rightly says, but everyone ignores. Pressing Escape should 'click' the Cancel icon.
When the up-arrow key, or Shift-Tab is pressed with the caret in this icon, the caret moves to icon number current icon-offset. (Yes, it's -ve. So if you specify a -ve number, the real offset used will be +ve. This is done because normally pressing up arrow moves to lesser-numbered icons.)

When the down-arrow key, or Tab is pressed with the caret in this icon, the caret moves to icon number current icon+offset.

Note that r, e, u, and d do the same thing with icons affected: If they're writable, the caret will be moved to the icon, if they are option icons, they are selected (deselecting others in the ESG), and otherwise a Mouse_Click event is generated for the icon (possibly making it pop in too).

Note that the validations r, e, u and d may be used more than once in the same validation, as long as all except the last one select icons rather than position the caret or click icons. For example, the Compare window sets two options and then clicks Compare when Return is pressed in any of the bottom three fields.

When this button is clicked upon, it slabs by being selected. This is useful to give odd-shaped slabbing sprites, like up and down arrows.
When this button is clicked upon, the number in the icon after it is increased by one.
When this button is clicked upon, the number in the icon before it is decreased by one. (Excuse the perverse naming of these two validations!)

You must keep the red 'help' icons in the right place, but you will find that you have to move them around in order to get at the icons beneath them. The help_icon system works by checking each help icon and seeing whether the pointer lies under it. If it does, the icon's message (translated from the token in the red help_icon) is sent to !Help. This is not hierarchical - it is always the first match that is copied. So if icon areas overlap, it is the lowest numbered icon's message that is used.

The only window sizes that are fixed are:

Disser Must retain its current width
DisserLink Must retain its current size
ListLink Must retain its current size
XferSend Must retain its current height and icon vertical positions
Print Must retain its current height and icon vertical positions
ProgInfo Must retain its current width and icon horizontal positions

All other window dimensions and icon positionings may be altered, for example to accomodate any larger icons. If you do make any bits of window bigger, remember to move the help icons over them! Oh, and remember when you alter icons that the fonts may eventually be bigger than those you're using so leave lots of space in the icons.

If you drag Desktop Hacker's Sprites file to your template editor, you notice you can't actually see the icons. This is because Desktop Hacker processes the sprite names in the file to allow the icons to change on a mode change. To see the icons properly, make a copy of sprite file, and rename all sprites called '22_name' (for VGA-res) or '24_name' (for TV-res) to 'name>'. Then drag this new file into the template editor.

Leave all icons deselected. On startup, Desktop Hacker sets the default option and radio icons itself. Setting any others may mess it up. Also, leave all writable icons empty save for list selectors, the slowdown selector, and the print_copies selector, which should have the default (1) in them. All writable icons must be indirected.

--) /!\ History of Desktop Hacker
(-- /!\ Format of list files
/\ /!\ Technical stuff

23rd April 1998