aboutsummaryrefslogtreecommitdiff
path: root/engines/agi/graphics.cpp
diff options
context:
space:
mode:
authorMartin Kiewitz2015-05-19 12:39:39 +0200
committerMartin Kiewitz2015-05-19 12:39:39 +0200
commita709596b48b93e46b36f2142f6d781a5198fe8a2 (patch)
tree1774842709e6300a1dfb5297ff10f9725291a190 /engines/agi/graphics.cpp
parentaba98e910c9acea7063e1d21072c9943b5f26f8c (diff)
downloadscummvm-rg350-a709596b48b93e46b36f2142f6d781a5198fe8a2.tar.gz
scummvm-rg350-a709596b48b93e46b36f2142f6d781a5198fe8a2.tar.bz2
scummvm-rg350-a709596b48b93e46b36f2142f6d781a5198fe8a2.zip
AGI: implement original sierra font, fix bug #6405
custom font is still used for fanmade games i cannot test preAGI games, because I don't own those.
Diffstat (limited to 'engines/agi/graphics.cpp')
-rw-r--r--engines/agi/graphics.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/engines/agi/graphics.cpp b/engines/agi/graphics.cpp
index 2b1bd8c829..32d0fdc06a 100644
--- a/engines/agi/graphics.cpp
+++ b/engines/agi/graphics.cpp
@@ -616,6 +616,8 @@ void GfxMgr::putTextCharacter(int l, int x, int y, unsigned char c, int fg, int
int x1, y1, xx, yy, cc;
const uint8 *p;
+ assert(font);
+
p = font + ((unsigned int)c * CHAR_LINES);
for (y1 = 0; y1 < CHAR_LINES; y1++) {
for (x1 = 0; x1 < CHAR_COLS; x1++) {
@@ -699,7 +701,7 @@ void GfxMgr::printCharacter(int x, int y, char c, int fg, int bg) {
x *= CHAR_COLS;
y *= CHAR_LINES;
- putTextCharacter(0, x, y, c, fg, bg);
+ putTextCharacter(0, x, y, c, fg, bg, false, _vm->getFontData());
// redundant! already inside put_text_character!
// flush_block (x, y, x + CHAR_COLS - 1, y + CHAR_LINES - 1);
}
@@ -754,7 +756,7 @@ void GfxMgr::rawDrawButton(int x, int y, const char *s, int fgcolor, int bgcolor
drawRectangle(x1, y1, x2, y2, border ? BUTTON_BORDER : MSG_BOX_COLOR);
while (*s) {
- putTextCharacter(0, x + textOffset, y + textOffset, *s++, fgcolor, bgcolor);
+ putTextCharacter(0, x + textOffset, y + textOffset, *s++, fgcolor, bgcolor, false, _vm->getFontData());
x += CHAR_COLS;
}