Can a .txt print file font be changed?

I would like to print to a .txt file with a different font (font and size) can this be done?


Firefox font settings


Went to your site, clicked on your "days-old" link, and the list of days appeared, numerals and all were perfectly OK. Then "copied page as" .txt file, and it reads perfectly in a text editor (EditPad Lite).

I think your problem may be in the Firefox Font settings. I am using "Firefox version 54.0.1 (32 bit)" even tho this is a 64bit Win 7 computer.

Anyway, try looking at the Firefox settings under

"Options" > Content > Fonts and colors > Advanced >

which should produce a dialog box something like:

--------------------- Fonts -----------------------
(these are the settings on mine)
Fonts for: [ Latin ] size [ 16 ]
Proportional: [ Serif ]
Serif: [ times new roman ]
Sans-serif: [ Arial ]
Monospace: [ Courier New ] size [ 13 ]
Minimum Font size: [ none ]

[checked] "Allow pages to choose their own fonts, instead of your selections above"

"Text Encoding for Legacy Content"
"This text encoding is used for legacy content that fails to declare its encoding."
"Fallback Text Encoding:" [ Default for Current Locale ]

[ OK ] [ Cancel ] [ Help ]

Maybe this will solve your problem. Your "days old" thing is interesting, but I got you by about 7700 days!!!

You're right, the TB forum does seem pretty much dead, but I check nearly every day anyway. It's sad, really.

Mike C.


Thanks for all your suggestions Mike, I forgot to mention that the Firefox I was using is mac version.
Neither that version or Firefox under parallels emulation has the TOOLS tab. The problem (missing nines's) doesnt appear on the emulated version so I'll just live with it.

Surprisingly this response (typed on mac) will not permit the keying of a nine just -------. Does this 9work ?

7700 days-- That makes you about --- 100 congrats.

I wrote the TrueBasic program for my brother who is like "rainman" and facinated with days old.

Another project here is a computer for my pool system ( see) which ran the pace and room lighting with a mac G3 computer circa 2000 and true basic . Trying to make a mac backup system appears impossible --- too much has changed-- even getting a correct OS is difficult ( there were MANY versions of the G3 with many different I/O configurations.

Good to meet you Mike-- What did you do during your career?


change font

Hello, jrobertson

Any .txt file can be printed with any choice of font and size, if the text file is opened in any regular text editor, but you probably know this.

Assuming that you meant: Can the "output of a TB program" be made to print out with a specified font and size, the answer is YES.

After the program runs and the output is on the screen, there is a drop-down menu at the top of the screen entitled "FILE"; which offers three options: "Print", "Copy", "Stop".

Clicking on "Print" will produce a standard "Print Setup Dialog Box"; and upon pressing "OK" your printer will proceed to print the contents of the TB output screen, using whatever font and size had been previously specified. There are several ways to specify the font and size (and style, as well).

1. There is a "Settings" menu in the TB editor with the option "Set Font For...", and under that, the options "This source window...", "Command window...", "Output window...".

Clicking the "Output window..." option will produce a Font Selection Dialog Box, by which the desired font, size, and style may be selected for the Output Window. When the program runs, the output on the screen will appear in the selected font. The default font is "courier", 10 point, "regular"

2. A second method of specifying a font is by using the line:

CALL TC_Win_SetFont(window, fontname$,fontsize,style$).

But the statement: LIBRARY "TRUECTRL.TRC" must precede the CALL to the above SUB. (Usually just put the LIBRARY statement up at the beginning of your program.)

As you can see, the "TC_Win_SetFont" CALL will supercede the font specified in the "settings" menu.

You can change the font any time/anywhere in your program with the "TC_Win_SetFont" CALL.

EXAMPLE Program:
option nolet
!(Edit the path to this file appropriate to your computer)

print, "Font in this line was set by the ""settings"" menu"

fontname$="times new roman"
style$="bold italic"

CALL TC_Win_SetFont(window, fontname$,12,style$)

print, "This font was set via the Win_SetFont statement..."

set color 12
CALL TC_Win_SetFont(window, "arial",10,"bold")

print, "...and so was this one. Press any key to QUIT..."

get key zz


Hope this helps
Regards, Mike C.

Thanks Re. .txt Font Changes

Thanks so much for your reply mcc. I certainly didn’t expect a prompt and good response on a Forum used so rarely.

I have no problem reading or altering .txt files locally on non Firefox browsers , word , text edit etc

Background—I am an amateur trying to help my disabled " Rainman like" brother who is infatuated with ages and birthdays.

See …family days old…john. This sequence downloads a .txt file which displays my days old correctly on most all browsers. However on Firefox it displays the nine digits as “ - “.

I had assumed that the .txt file I created was in a font that Firefox didn’t interpret correctly. Surprisingly in typing this reply on the true basic webpage reply box using Firefox , typing nines digits are also “-“ !!

So its probably just academic to see of I can change the font in the .txt files
I am producing. I’ll just not use Firefox!

I create the .txt files as follows

OPEN #3: NAME "A"& str$(P) & ".txt" , CREATE NEWOLD,ORG TEXT
. erase #3

Print #3: B$
close #3

Firefox appears to use a default font which some applications seem to say is “monaco” ---not an internet "standard"

If you can suggest how to change the font in the .txt file ---- Thanks but likely Ill just not use Firefox and move on.

Thanks again Cheers and 73