home *** CD-ROM | disk | FTP | other *** search
- January, 1987 AMIGAZINE!
-
-
- SetFont 2.0
-
- by Dave Haynie
- (Released into Public Domain)
-
-
- A BRIEF OVERVIEW
-
- SetFont 2.0's main improvement is that it allows the individual
- font of a CLI window to be changed without changing the font of the entire
- WorkBench Screen. The old SetFont would change the default font descriptor
- of the WorkBench screen, which is where most new programs get their fonts.
- This was useful in that a font so set would be inhereted by new WorkBench
- applications, like new CLIs, Word Processors, Terminal Programs, and just
- about anything run on the WorkBench Screen (as opposed to a custom screen).
- What the old version doesn't do is change JUST the font of the current CLI.
- The new version does this. I've thrown in the capability to also change
- the default title font of the screen (based on the screen's RastPort);
- this isn't incredibly useful, but it was very little extra code in addition
- to the two more useful functions.
-
- WHAT IT DOES
-
- This function changes the default fonts of the Amiga's WorkBench
- screen or an Amiga CLI window. This allows programs like CLI, etc. to use a
- font other than one specified by Preferences. This change isn't perfect, but
- it is useful. The program is used as:
-
- SetFont [fontname [points [place]]
-
- Where the "fontname" is a normal Amiga font, "points" is the font's point
- size, and place is currently one of:
-
- SCREEN The WorkBench Screen, ala SetFont 1.0
-
- TITLES The WorkBench Screen's Titles
-
- WINDOW The current CLI window
-
- Setting the screen will essentially set the default font for newly created
- windows. Setting the title font will set the text displayed for window
- titles and things like that. This will look really ugly and generally not
- work very well if it is set to a font taller than the current screen font.
- Finally, setting the WINDOW font will set only the font of the calling CLI
- window. This will also clear the screen, which is required to fully set
- the font on an open console window. If no place is supplied, all three
- fonts are set. Examples are:
-
- SetFont (Displays current screen font)
- SetFont ? (Displays help text)
- SetFont topaz (Sets font "topaz 8" everywhere)
- SetFont ruby 12 (Sets font "ruby 12" everywhere)
- SetFont topaz 11 SCREEN (Sets font "topaz 11" on screen)
- SetFont clean 8 TITLES WINDOW (Sets font "clean 8" on CLI and titles)
-
- This program has a few limitations. First of all, some programs
- don't support fonts other than the 80 column, 8x8 cell "topaz 8" font,
- which is a default ROM font. If you're a 60 column user, you've probably
- experienced this before. Its not a problem with the Amiga as a whole, since
- most of the system will adjust itself. But it may be a problem with programs
- that have a fixed idea of what a font should look like. Most 80 column fonts
- work with most applications, and an 80 column 8x8 font will work just about
- everywhere. Some programs, like CLI for instance, have trouble with
- proportionally-spaced fonts. This is a "bug" or "feature" of the Amiga
- text display software, which is doing large amounts of spacing when only
- one character in a proportional font is displayed at a time. The best thing
- to do is try out the font you like.
-
- To use SetFont as a means of changing most of the default fonts
- during a session, insert it in your "s:Startup-Sequence" file, as:
-
- SetFont topaz 11
- LoadWB
- EndCLI >nil:
-
- or something like (SetFont topaz 11 SCREEN TITLES would work just as well).
-
- One final problem is that some applications ask the WorkBench screen
- to close when they start up. It'll close if there's nothing else open on it,
- but when it re-opens, it'll restart with the Preferences-selected font, not
- the SetFont selected font. Of course, Preferences't support arbitrary fonts
- (which is why this program is even necessary). Oh well, maybe in 1.3? The
- simplest way to prevent this is to leave some kind of window open, which will
- prevent any other application from closing the WorkBench screen. Of course,
- if you need the memory that closing the WorkBench screen gives you, this
- would not be a good thing to do.
-
- Double-click the GoToCLI icon to enter CLI and view all of the files in the
- OnlyCLI directory, including SetFont which only works under CLI.
-
-
-
-
-