Set a another 8x8 font in real mode and in protected mode

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
sytze
Posts: 1
Joined: Tue Jan 03, 2023 3:29 am
Libera.chat IRC: sytze

Set a another 8x8 font in real mode and in protected mode

Post by sytze »

I would like to know how to set a different 8x8 vga text font via the bios. I also wonder if I can do this in protected mode as well
Octocontrabass
Member
Member
Posts: 5563
Joined: Mon Mar 25, 2013 7:01 pm

Re: Set a another 8x8 font in real mode and in protected mod

Post by Octocontrabass »

sytze wrote:I would like to know how to set a different 8x8 vga text font via the bios.
INT 0x10 AX=0x1100. On VGA, the font will actually be 9x8 by default. If you use INT 0x10 AH=0x12 BL=0x30 to reduce the vertical resolution, the character width will be reduced to 8 pixels too. As far as I know, there's no way to reduce the character size to 8x8 using the BIOS without also reducing the vertical resolution.
sytze wrote:I also wonder if I can do this in protected mode as well
You can directly manipulate the VGA registers to do anything the BIOS does. If you really want to, you can try using virtual 8086 mode to run the BIOS code, but this might not work very well on modern PCs.

Modern UEFI-only PCs don't have VGA compatibility; VGA requires a legacy BIOS (or UEFI CSM).
Post Reply