Stupid question about text printing

Question about which tools to use, bugs, the best way to implement a function, etc should go here. Don't forget to see if your question is answered in the wiki first! When in doubt post here.
Post Reply
mastermesh

Stupid question about text printing

Post by mastermesh »

OK, i've figured out how to write text using function 0Eh of interrupt 10h. But how do i write coloured text? I know there's something like an attribute byte, but how do I set it?
User avatar
Pype.Clicker
Member
Member
Posts: 5964
Joined: Wed Oct 18, 2006 2:31 am
Location: In a galaxy, far, far away
Contact:

Re:Stupid question about text printing

Post by Pype.Clicker »

i guess you should use int 10h, function 09h instead... it has the opportunity of selecting the attribute byte (foreground_color+backgroundcolor*16, on most VGA text modes).

However, if you plan to use this to display text strings, you'll not have a fast output *at all*. Consider using int 10h, function 13h instead.
User avatar
Solar
Member
Member
Posts: 7615
Joined: Thu Nov 16, 2006 12:01 pm
Location: Germany
Contact:

Re:Stupid question about text printing

Post by Solar »

Thread "Quick Links", Posting #3 "BIOS and POST variables list", Interrupts, Int 10h, Int 10h 0eh leads you to http://www.clipx.net/ng/bios/ng10576.php.
Every good solution is obvious once you've found it.
mastermesh

Re:Stupid question about text printing

Post by mastermesh »

Thanks :D
one

Re:Stupid question about text printing

Post by one »

I think you have to set the BH register with the color attribute.
Post Reply