Homebrew Printing colored text

  • Thread starter Deleted User
  • Start date
  • Views 1,040
  • Replies 4
D

Deleted User

Guest
OP
Lorem Ipsum is slechts een proeftekst uit het drukkerij- en zetterijwezen. Lorem Ipsum is de standaard proeftekst in deze bedrijfstak sinds de 16e eeuw, toen een onbekende drukker een zethaak met letters nam en ze door elkaar husselde om een font-catalogus te maken.
 
Last edited by ,

Det1re

det1re.de
Member
Joined
Oct 28, 2008
Messages
1,272
Trophies
0
Age
34
Location
Germany
Website
det1re.de
XP
264
Country
Gambia, The
Code:
// implementation by WiiPower
printf("\x1b[%u;%um", 47, false);
printf("\x1b[%u;%um", 30, false);

Where the numbers represent the colors.
Those beginning with 4 are for the background, those with 3 are text/foreground.

So in this example we would have a white background with black text. For other colors see ANSI escape codes @ wikipedia.
 

pembo

Well-Known Member
Member
Joined
Jun 1, 2009
Messages
105
Trophies
0
XP
121
Country
I put a sample project together with generated documentation from the bootmii configuration editor source code to do these sorts of things
Download

it's a little more complex as this example demonstrates the use of the console skins that I used in BCE. You should download and take a look at the code.

You'll be most interested in the console class.
 
D

Deleted User

Guest
OP
Lorem Ipsum is slechts een proeftekst uit het drukkerij- en zetterijwezen. Lorem Ipsum is de standaard proeftekst in deze bedrijfstak sinds de 16e eeuw, toen een onbekende drukker een zethaak met letters nam en ze door elkaar husselde om een font-catalogus te maken.
 
Last edited by ,

pembo

Well-Known Member
Member
Joined
Jun 1, 2009
Messages
105
Trophies
0
XP
121
Country
diego_pmc said:
Thank you! There are some other things in your code that might be useful for me. BTW, pembo, how do you produce those documentation pages?

your welcome - that's why I put this stuff together in the first place after going through the pains building the bootmii config editor
smile.gif


The documentation is generated by a program called doxygen. http://www.doxygen.org/
 

Similar threads

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
    K3Nv2 @ K3Nv2: https://youtu.be/wUvTbatPieQ?si=tt-FGz51yUMg8L_q