APL Character Set and Browsers
GIF Images

Contents | Previous | Next


Use a set of GIF's (a GIF is a file in Graphic Interchange Format, which is essentially a picture) to represent the APL character set, and insert each APL character into the text using the IMG tag.

Details

This method is "universal", that is, it allows all browsers (i.e. browsers following HTML standards on Windows, Macintosh, Sun, Unix/Linux, etc.) to display the APL characters in "default" mode.

Given a set of GIF files, each one representing one APL character with a size of, for example, 15 by 15 pixels, we can represent a statement that includes APL characters simply by using several image tags <img src="filename">. For example, to represent the statement (which I have written first using words) ...

a is x times y

... the following line of HTML text is sufficient ...

a <img src="assign.gif"> z <img src="times.gif"> y

which, when inserted into the HTML text and supplied with a source of images, will display in any standard browser with the APL characters displaying correctly, as follows ...

a x y

If desired one could add size and "alternative message" information to the HTML text. If the GIF's are sized as desired, size information is optional.

a <img src="assign.gif" width="15" height="15" alt="is-assigned"> z <img src="times.gif" width="13" height="15" alt="times"> y

It is not necessary to "manually" code the above HTML text (that is, via the keyboard). For any significant amount, one could translate the APL expressions to the fully marked up text (HTML form) using a program (which is easy to write in APL!).

Browser performance is said to be quite good as the image files are small and they are accessible in the browser cache when displaying large amounts of text. This method is completely independent of fonts, and allows everyone to see the unique characters of any APL interpreter without any "extra" effort. However, the technique does not allow "cut and paste" into another window, in particular, the window of an APL interpreter.

Mayer Goldberg's site contains a complete set of GIF's for the APL character set, as well as comprehensive explanations. It also describes a technique involving Javascript functions intended to simplify entering statements or nicely-formatted functions into the HTML text via the keyboard, but this is not essential to the method.

More Examples

a is 10 power a

a 10 a

a is 2 3 reshape index-generator 6

a 2 3 6

References

http://www.cs.bgu.ac.il/~gmayer/interests-programming-languages/apl/apl-in-html.html

Mayer Goldberg's site contains a complete set of GIF's and comprehensive explanations.