[Scummvm-cvs-logs] SF.net SVN: scummvm: [30361] scummvm/trunk/engines/parallaction

peres001 at users.sourceforge.net peres001 at users.sourceforge.net
Wed Jan 9 22:54:59 CET 2008


Revision: 30361
          http://scummvm.svn.sourceforge.net/scummvm/?rev=30361&view=rev
Author:   peres001
Date:     2008-01-09 13:54:58 -0800 (Wed, 09 Jan 2008)

Log Message:
-----------
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.

Revision Links:
--------------
    http://scummvm.svn.sourceforge.net/scummvm/?rev=30221&view=rev

Modified Paths:
--------------
    scummvm/trunk/engines/parallaction/dialogue.cpp
    scummvm/trunk/engines/parallaction/graphics.cpp
    scummvm/trunk/engines/parallaction/graphics.h
    scummvm/trunk/engines/parallaction/gui_ns.cpp
    scummvm/trunk/engines/parallaction/parser_ns.cpp

Modified: scummvm/trunk/engines/parallaction/dialogue.cpp
===================================================================
--- scummvm/trunk/engines/parallaction/dialogue.cpp	2008-01-09 21:46:57 UTC (rev 30360)
+++ scummvm/trunk/engines/parallaction/dialogue.cpp	2008-01-09 21:54:58 UTC (rev 30361)
@@ -297,8 +297,6 @@
 void Parallaction::runDialogue(SpeakData *data) {
 	debugC(1, kDebugExec, "runDialogue: starting dialogue '%s'", data->_name);
 
-	_gfx->setFont(_dialogueFont);
-
 	DialogueManager man(this, data);
 	man.run();
 

Modified: scummvm/trunk/engines/parallaction/graphics.cpp
===================================================================
--- scummvm/trunk/engines/parallaction/graphics.cpp	2008-01-09 21:46:57 UTC (rev 30360)
+++ scummvm/trunk/engines/parallaction/graphics.cpp	2008-01-09 21:54:58 UTC (rev 30361)
@@ -849,13 +849,8 @@
 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) {
 
 	int16 left = r.left;
@@ -962,7 +957,6 @@
 	_hbCircleRadius = 0;
 
 	_font = NULL;
-	_fontShadow = false;
 
 	return;
 }

Modified: scummvm/trunk/engines/parallaction/graphics.h
===================================================================
--- scummvm/trunk/engines/parallaction/graphics.h	2008-01-09 21:46:57 UTC (rev 30360)
+++ scummvm/trunk/engines/parallaction/graphics.h	2008-01-09 21:54:58 UTC (rev 30361)
@@ -316,8 +316,6 @@
 
 	// 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 @@
 	Graphics::Surface	*_buffers[NUM_BUFFERS];
 	MaskBuffer			*_depthMask;
 	Font				*_font;
-	bool				_fontShadow;
 	bool				_halfbrite;
 
 	Common::Point		_hbCirclePos;
@@ -399,6 +396,8 @@
 	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);
+
 };
 
 

Modified: scummvm/trunk/engines/parallaction/gui_ns.cpp
===================================================================
--- scummvm/trunk/engines/parallaction/gui_ns.cpp	2008-01-09 21:46:57 UTC (rev 30360)
+++ scummvm/trunk/engines/parallaction/gui_ns.cpp	2008-01-09 21:54:58 UTC (rev 30361)
@@ -388,9 +388,6 @@
 	setArrowCursor();
 	_soundMan->stopMusic();
 
-	_gfx->setFont(_introFont);
-	_gfx->setFontShadow(true);
-
 	_disk->selectArchive((getFeatures() & GF_LANG_MULT) ? "disk1" : "disk0");
 
 	showSlide("password");	// loads background into kBitBack buffer

Modified: scummvm/trunk/engines/parallaction/parser_ns.cpp
===================================================================
--- scummvm/trunk/engines/parallaction/parser_ns.cpp	2008-01-09 21:46:57 UTC (rev 30360)
+++ scummvm/trunk/engines/parallaction/parser_ns.cpp	2008-01-09 21:54:58 UTC (rev 30361)
@@ -973,7 +973,6 @@
 
 	// 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;


This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.




More information about the Scummvm-git-logs mailing list