Welcome, Guest. Please login or register.

Author Topic: Define font and background colour in CLI console?  (Read 968 times)

Description:

0 Members and 1 Guest are viewing this topic.

Offline Gerbinist

Re: Define font and background colour in CLI console?
« on: April 26, 2020, 04:08:22 PM »
On your sytem drive, you will find a file called S:Shell-Startup. One of the entries is:

Code: [Select]
Prompt "%N.%S> "
For a black shell, you could change this to:

Code: [Select]
Prompt "*e[>1m*e[33;41m%N.*e[30m%S>*e[32;41m "
Now save this change to S:Shell-Startup.Black or any other name you might fancy. Your Shell icon in SYS:System has a tooltype called FROM. Default this is:

Code: [Select]
FROM=S:Shell-Startup
If you want to always use a black shell, change this to:

Code: [Select]
FROM=S:Shell-Startup.Black
(or clone the current icon and thus create one that mentions Black Shell or whatever)


See below for a bit more information about all the codes that are being used in above example:

Code: [Select]
Esc[0m = Resets graphics modes to defaults
Esc[1m = Use Bold

Esc[30m = Use Text color0 = Grey
Esc[31m = Use Text color1 = Black
Esc[32m = Use Text color2 = White
Esc[33m = Use Text color3 = Blue

Esc[40m = Use Text Background color0 = Grey
Esc[41m = Use Text Background color1 = Black
Esc[42m = Use Text Background color2 = White
Esc[43m = Use Text Background color3 = Blue

Esc[>1m = Use Console Background color1 = Black

*e     = Esc

Prompt "*e[>1m*e[33;41m%N.*e[30m%S>*e[32m "
        ======
        Sets the console background colour to Black

Prompt "*e[>1m*e[33;41m%N.*e[30m%S>*e[32m "
              ============
              Sets text colour to Blue, text background to Black and displays shell number (%N)

Prompt "*e[>1m*e[33;41m%N.*e[30m%S>*e[32m "
                          =========
                          Sets text colour to Grey and displays Source (%S)

Prompt "*e[>1m*e[33;41m%N.*e[30m%S>*e[32m "
                                   =======
                                   Sets text colour to White and adds a space
Current: OS 3.1.4, Blizzard 1260/50, 64 MB, AGA, CF, Ryś MKII, PCMCIA/CNET
Storage: Elbox E/BOX 1200, SCSI Kit IV, Mediator SX, Voodoo3/4/5, RTL8139 Ethernet, Spider USB 2.0, PixelView PlayTV MPEG2, Terratec 512i, MAS MP3 Player