aboutsummaryrefslogtreecommitdiff
path: root/engines
diff options
context:
space:
mode:
authorNicola Mettifogo2008-01-09 21:54:58 +0000
committerNicola Mettifogo2008-01-09 21:54:58 +0000
commit605c9d0fd61a14a6f479c6e1177fa10844f6feff (patch)
treeda38a5d61ae4ba3cfe56627be3a1de746f486213 /engines
parentbdf440fdaebf74e07ff6889c15b11ab61a8c7e59 (diff)
downloadscummvm-rg350-605c9d0fd61a14a6f479c6e1177fa10844f6feff.tar.gz
scummvm-rg350-605c9d0fd61a14a6f479c6e1177fa10844f6feff.tar.bz2
scummvm-rg350-605c9d0fd61a14a6f479c6e1177fa10844f6feff.zip
Turned Gfx::setFont into a protected member, since now Gfx can automatically detect which font to use. Gfx still needs setFont internally to select fonts. The font shadowing introduced in revision 30221 has been removed as well, since the new approach handles it better.
svn-id: r30361
Diffstat (limited to 'engines')
-rw-r--r--engines/parallaction/dialogue.cpp2
-rw-r--r--engines/parallaction/graphics.cpp6
-rw-r--r--engines/parallaction/graphics.h5
-rw-r--r--engines/parallaction/gui_ns.cpp3
-rw-r--r--engines/parallaction/parser_ns.cpp1
5 files changed, 2 insertions, 15 deletions
diff --git a/engines/parallaction/dialogue.cpp b/engines/parallaction/dialogue.cpp
index 5fd0798b01..6d756f172f 100644
--- a/engines/parallaction/dialogue.cpp
+++ b/engines/parallaction/dialogue.cpp
@@ -297,8 +297,6 @@ int16 DialogueManager::selectAnswer() {
void Parallaction::runDialogue(SpeakData *data) {
debugC(1, kDebugExec, "runDialogue: starting dialogue '%s'", data->_name);
- _gfx->setFont(_dialogueFont);
-
DialogueManager man(this, data);
man.run();
diff --git a/engines/parallaction/graphics.cpp b/engines/parallaction/graphics.cpp
index 37e4f781ee..296218df15 100644
--- a/engines/parallaction/graphics.cpp
+++ b/engines/parallaction/graphics.cpp
@@ -849,11 +849,6 @@ void Gfx::getStringExtent(char *text, uint16 maxwidth, int16* width, int16* heig
void Gfx::setFont(Font *font) {
assert(font);
_font = font;
- setFontShadow(false);
-}
-
-void Gfx::setFontShadow(bool enable) {
- _fontShadow = enable && (_vm->getPlatform() == Common::kPlatformAmiga);
}
void Gfx::restoreBackground(const Common::Rect& r) {
@@ -962,7 +957,6 @@ Gfx::Gfx(Parallaction* vm) :
_hbCircleRadius = 0;
_font = NULL;
- _fontShadow = false;
return;
}
diff --git a/engines/parallaction/graphics.h b/engines/parallaction/graphics.h
index ac42e116e6..654b76fde9 100644
--- a/engines/parallaction/graphics.h
+++ b/engines/parallaction/graphics.h
@@ -316,8 +316,6 @@ public:
// misc
int16 queryMask(int16 v);
- void setFont(Font* font);
- void setFontShadow(bool enable);
void swapBuffers();
void updateScreen();
void setBackground(Graphics::Surface *surf);
@@ -344,7 +342,6 @@ protected:
Graphics::Surface *_buffers[NUM_BUFFERS];
MaskBuffer *_depthMask;
Font *_font;
- bool _fontShadow;
bool _halfbrite;
Common::Point _hbCirclePos;
@@ -399,6 +396,8 @@ protected:
bool drawWrappedText(Graphics::Surface* surf, char *text, byte color, int16 wrapwidth);
void blit(const Common::Rect& r, uint16 z, byte *data, Graphics::Surface *surf);
void flatBlit(const Common::Rect& r, byte *data, Graphics::Surface *surf, byte transparentColor);
+ void setFont(Font* font);
+
};
diff --git a/engines/parallaction/gui_ns.cpp b/engines/parallaction/gui_ns.cpp
index 8b9a9abbcf..8033378c08 100644
--- a/engines/parallaction/gui_ns.cpp
+++ b/engines/parallaction/gui_ns.cpp
@@ -388,9 +388,6 @@ int Parallaction_ns::guiSelectCharacter() {
setArrowCursor();
_soundMan->stopMusic();
- _gfx->setFont(_introFont);
- _gfx->setFontShadow(true);
-
_disk->selectArchive((getFeatures() & GF_LANG_MULT) ? "disk1" : "disk0");
showSlide("password"); // loads background into kBitBack buffer
diff --git a/engines/parallaction/parser_ns.cpp b/engines/parallaction/parser_ns.cpp
index fef9cf803c..b593cc23bf 100644
--- a/engines/parallaction/parser_ns.cpp
+++ b/engines/parallaction/parser_ns.cpp
@@ -973,7 +973,6 @@ void Parallaction_ns::parseLocation(const char *filename) {
// TODO: the following two lines are specific to Nippon Safes
// and should be moved into something like 'initializeParsing()'
- _gfx->setFont(_labelFont);
_hasLocationSound = false;
_locParseCtxt.end = false;