| 1 | /* |
| 2 | * Descent 3 |
| 3 | * Copyright (C) 2024 Parallax Software |
| 4 | * |
| 5 | * This program is free software: you can redistribute it and/or modify |
| 6 | * it under the terms of the GNU General Public License as published by |
| 7 | * the Free Software Foundation, either version 3 of the License, or |
| 8 | * (at your option) any later version. |
| 9 | * |
| 10 | * This program is distributed in the hope that it will be useful, |
| 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 13 | * GNU General Public License for more details. |
| 14 | * |
| 15 | * You should have received a copy of the GNU General Public License |
| 16 | * along with this program. If not, see <http://www.gnu.org/licenses/>. |
| 17 | |
| 18 | --- HISTORICAL COMMENTS FOLLOW --- |
| 19 | |
| 20 | * $Logfile: /DescentIII/Main/gamefont.h $ |
| 21 | * $Revision: 17 $ |
| 22 | * $Date: 5/02/99 11:04p $ |
| 23 | * $Author: Matt $ |
| 24 | * |
| 25 | * Game fonts |
| 26 | * |
| 27 | * $Log: /DescentIII/Main/gamefont.h $ |
| 28 | * |
| 29 | * 17 5/02/99 11:04p Matt |
| 30 | * Cleaned up HUD font code, now that we have only two sizes of HUD fonts. |
| 31 | * |
| 32 | * 16 4/27/99 2:13p Matt |
| 33 | * Replaced the two (new) new UI fonts with one new font from Doug. |
| 34 | * |
| 35 | * 15 4/26/99 10:34p Matt |
| 36 | * Deleted now-unused UI font. |
| 37 | * |
| 38 | * 14 4/25/99 5:19p Matt |
| 39 | * Revised font definition & loading |
| 40 | * |
| 41 | * 13 4/23/99 9:25p Matt |
| 42 | * Killed 'SMALL_FONT', since it was never being used. |
| 43 | * |
| 44 | * 12 4/16/99 5:06p Matt |
| 45 | * Deleted big UI font, which was unused. |
| 46 | * |
| 47 | * 11 3/02/99 6:26p Samir |
| 48 | * hires font madness. |
| 49 | * |
| 50 | * 10 2/28/99 3:23a Samir |
| 51 | * added superhires fonts. |
| 52 | * |
| 53 | * 9 2/16/99 12:08p Samir |
| 54 | * added new fonts. |
| 55 | * |
| 56 | * 8 10/20/98 3:20p Samir |
| 57 | * added big ui font. |
| 58 | * |
| 59 | * 7 5/15/98 5:35p Samir |
| 60 | * allow usage of hires and lores fonts. |
| 61 | * |
| 62 | * 6 4/16/98 6:51a Samir |
| 63 | * added big briefing font. |
| 64 | * |
| 65 | * 5 3/05/98 6:40p Samir |
| 66 | * New UI Font. |
| 67 | * |
| 68 | * 4 1/12/98 5:23p Samir |
| 69 | * New fonts. |
| 70 | * |
| 71 | * 3 12/29/97 5:46p Samir |
| 72 | * Modified gamefont system. |
| 73 | * |
| 74 | * 2 11/10/97 12:56p Samir |
| 75 | * Macros for font rendering using the renderer. |
| 76 | * |
| 77 | * 1 11/04/97 2:03p Samir |
| 78 | * Game font manager. |
| 79 | * |
| 80 | * $NoKeywords: $ |
| 81 | */ |
| 82 | |
| 83 | #ifndef GAMEFONT_H |
| 84 | #define GAMEFONT_H |
| 85 | |
| 86 | #include "grtext.h" |
| 87 | |
| 88 | extern int Game_fonts[]; // D3 font handles |
| 89 | |
| 90 | // Font defines |
| 91 | |
| 92 | #define NUM_FONTS 6 // How many fonts we have |
| 93 | |
| 94 | // Indices for the font handles |
| 95 | #define SMALL_FONT_INDEX 0 // Basic small font, used everywhere. Originally designed for briefing |
| 96 | #define BIG_FONT_INDEX 1 // Basic big Font, used for titles. |
| 97 | #define HUD_FONT_INDEX 2 // Dropshadowed font so can be seen over variable background |
| 98 | #define MENU_FONT_INDEX 3 // Main menu font, also used for some multiplayer messages |
| 99 | #define SMALL_UI_FONT_INDEX 4 // For the new UI |
| 100 | #define BIG_UI_FONT_INDEX 5 // For the new UI |
| 101 | |
| 102 | // Handles to the fonts |
| 103 | #define SMALL_FONT Game_fonts[SMALL_FONT_INDEX] |
| 104 | #define BIG_FONT Game_fonts[BIG_FONT_INDEX] |
| 105 | #define HUD_FONT Game_fonts[HUD_FONT_INDEX] |
| 106 | #define MENU_FONT Game_fonts[MENU_FONT_INDEX] |
| 107 | #define SMALL_UI_FONT Game_fonts[SMALL_UI_FONT_INDEX] |
| 108 | #define BIG_UI_FONT Game_fonts[BIG_UI_FONT_INDEX] |
| 109 | |
| 110 | // These are equivalencies for the base fonts |
| 111 | #define BRIEFING_FONT SMALL_FONT |
| 112 | #define BIG_BRIEFING_FONT BIG_FONT |
| 113 | #define BRIEF_FONT_INDEX SMALL_FONT_INDEX |
| 114 | #define BBRIEF_FONT_INDEX BIG_FONT_INDEX |
| 115 | #define MONITOR9_NEWUI_FONT SMALL_UI_FONT |
| 116 | #define MONITOR15_NEWUI_FONT BIG_UI_FONT |
| 117 | #define GADGET9_NEWUI_FONT SMALL_UI_FONT |
| 118 | #define GADGET15_NEWUI_FONT BIG_UI_FONT |
| 119 | |
| 120 | // loads all game fonts. |
| 121 | void LoadAllFonts(); |
| 122 | |
| 123 | // Set the HUD font resolution based on the render width |
| 124 | void SelectHUDFont(int rend_with); |
| 125 | |
| 126 | #endif |