
When using outtextxy() in graphic.h, I can only use limited number of font. How can I display the very basic font above? It is just the normal window console raster font.

When using outtextxy() in graphic.h, I can only use limited number of font. How can I display the very basic font above? It is just the normal window console raster font.
If Console Raster is not in the list enumerated below - you may want to use installuserfont and then use the installed font in settextstyle.
You have to make .CHR file that contains the console raster font -
enum font_names
{
DEFAULT_FONT,
TRIPLEX_FONT,
SMALL_FONT,
SANS_SERIF_FONT,
GOTHIC_FONT,
SCRIPT_FONT,
SIMPLEX_FONT,
TRIPLEX_SCR_FONT,
COMPLEX_FONT,
EUROPEAN_FONT,
BOLD_FONT
};
userfont = installuserfont("CONSOLE_RASTER.CHR"); /* install font file with console raster */
settextstyle(userfont, HORIZ_DIR, 4); /* select the user font */
outtextxy(x, y, "Hello World!"); /* output some text */
Those .CHR file store Stroked fonts - where each stem of the glyph is represented by one line down the center of the stem, and the line is later drawn with a certain width. You have to make available the console Raster in .CHR format.
BTW, it has been almost 20 years since I looked at these BGI functions!
Though I hope you have considered modern graphics libraries.