![]() |
||
| Home | SwiftForth Archive | SwiftX Archive | |

My printer font problem/solution was as follows. Considering the teaching
files FONTTOOLS.F, FORMATTEXT.F, and PRINTEXAMPLE.F, compiled in order, I
called up my own font by copying Mike's GET-....-FONT
FONTTOOLS.F: : GET-TIMES-FONT ...
S" Times Roman" FONT ... ;
I called my own sizes with entering number(s) into the appropriate spots.
FORMATTEXT.F : CREATE-FONTS ... GET-TIMES-FONT ... ;
I executed the program
PRINTEXAMPLE.F : PRINT-TEST ... ;
and it worked.
My original failure, due to haste, lay with thinking the -TEST of PRINT-TEST
was the TEST of FORMATTEXT.F. Instead, PRINT-TEST is independent of TEST,
so the changes I made on TEST were not received into the printer. Oh well.
I changed TEST with larger fonts and more characters on the 'preamble' words
but couldn't get the main text to move over to accomodate changed spacing.
By the way, I programmed in PRINT-TEST to block out the text string output
word YADA and replace it with TEST of the previous file, and execution gave
me an error "Error ending printed page".
My windows knowledge is pretty meager, so could you expand on SetBkMode in
Windows API? Does it also contain itallics and bold?
Many thanks for these programming examples. This is very helpful. Best
wishes --- Allen
http://www.logix-controls.com/SwiftForth/FontTools.htm
http://www.logix-controls.com/SwiftForth/FormatText.htm
http://www.logix-controls.com/SwiftForth/PrintExample.htm
----- Original Message -----
From: "Mike Ghan" <mikeghan_at_logix-controls.com>
To: <sftalk_at_forth.com>
Sent: Tuesday, June 03, 2003 10:29 PM
Subject: [sftalk] Re: changing fonts and sizes II
> Allen,
>
> See SetBkMode in the Windows API. What was your printer font
problem/solution?
>
> Mike
>
> -----Original Message-----
> From: sftalk-bounce_at_forth.com [mailto:sftalk-bounce_at_forth.com]On
> Behalf
> Of Allen Anway
> Sent: Tuesday, June 03, 2003 6:26 PM
> To: sftalk_at_forth.com
> Subject: [sftalk] Re: changing fonts and sizes II
>
>
Thanks to Mike Ghan's help and help from others, I'm starting to make
progress on this all-fonts all-sizes all-places program. I finally got my
printer to respond to changing fonts. Can one OR the text output upon the
screen so that new type will not erase the previous type?
Best wishes --- Allen Anway
> ----- Original Message -----
> From: "Mike Ghan" <mikeghan_at_logix-controls.com>
> To: <sftalk_at_forth.com>
> Sent: Tuesday, June 03, 2003 10:27 AM
> Subject: [sftalk] Re: changing fonts and sizes II
>
>
SHOW-FILE requires a complete filename with extension. Try
S" yourfile.ext" SHOW-FILE
To print, the trick is to set the user variable CURRENT-DC with the
printer's Device Context (DC). This directs all output to the printer.
I added PrintExample.F to our site at
http://www.logix-controls.com/SwiftForth/PrintExample.htm
Also, FormatText.F has a some minor changes.
Mike
----------------------------------------------------------------------
sftalk_at_forth.com The SwiftForth programming discussion email list
To unsubscribe, send subject "unsubscribe" to sftalk-request_at_forth.com
For list command help, send subject "help" to sftalk-request_at_forth.com
Message archives are located at http://www.forth.com/archive/sftalk
----------------------------------------------------------------------
This list is a forum for SwiftForth users. For product support and bug
reports, please send email to support_at_forth.com
----------------------------------------------------------------------
Received on Wed Jun 04 2003 - 11:16:27 PDT
This archive was generated by hypermail 2.2.0 : Tue Dec 02 2008 - 03:04:32 PST