home *** CD-ROM | disk | FTP | other *** search
- SetFont 2.0
-
- by Dave Haynie (Hazy)
- CIS: 76703,2047
- Usenet: {allegra,caip,ihnp4}!cbmvax!daveh
- Drink: Guiness
-
-
- CHANGES FROM SetFont 1.0
-
- 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 thin 7 TITLES WINDOW (Sets font "thin 7" 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 that (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.
-
- BUSINESS (MUNDANE, BUT IMPORTANT):
-
- This program is written by me, Dave Haynie, as mentioned above.
- I have, however, placed it in the PUBLIC DOMAIN. That, of course, means
- that you can do (almost) absolutely anything with it. You may hack it
- to bits, include it with YOUR product, sell it, GIVE IT AWAY, or anything
- else you like. Of course, since anyone else can also give it away, it
- would be foolish to stick your name on it and try to sell it. I really
- would like everyone to give it away, nicely, without being mean about it.
- If you want to use it with your product, do that too, new products for
- the Amiga are generally a good thing for the entire Amiga community. You
- can take bit and pieces and use them in your own programs, or the whole
- thing for that matter. And if you really want to have fun, you can even
- IMPROVE this program, as its far from perfect, and give YOUR version
- away too, if you're so inclined. That's about it for the (mundane)
- business section, let's get on to the (interesting) notes section.
-