[Scummvm-cvs-logs] SF.net SVN: scummvm: [28278] scummvm/trunk/engines/drascula/drascula.cpp

aquadran at users.sourceforge.net aquadran at users.sourceforge.net
Sun Jul 29 00:00:21 CEST 2007


Revision: 28278
          http://scummvm.svn.sourceforge.net/scummvm/?rev=28278&view=rev
Author:   aquadran
Date:     2007-07-28 15:00:21 -0700 (Sat, 28 Jul 2007)

Log Message:
-----------
fix display fonts

Modified Paths:
--------------
    scummvm/trunk/engines/drascula/drascula.cpp

Modified: scummvm/trunk/engines/drascula/drascula.cpp
===================================================================
--- scummvm/trunk/engines/drascula/drascula.cpp	2007-07-28 21:36:46 UTC (rev 28277)
+++ scummvm/trunk/engines/drascula/drascula.cpp	2007-07-28 22:00:21 UTC (rev 28278)
@@ -1791,206 +1791,200 @@
 	int i = 0, y_de_letra = 0, x_de_letra = 0, h, longitud;
 	longitud = strlen(dicho);
 
-	// FIXME: We can't do this on read-only strings!
-#if 0
-	for (i = 0; dicho[i]; i++)
-		dicho[i] = toupper(dicho[i]);
-#endif
-
 	for (h = 0; h < longitud; h++) {
 		y_de_letra = Y_ABC;
-/*
-		if (dicho[h] == 'A')
+		char c = toupper(dicho[h]);
+		if (c == 'A')
 			x_de_letra = X_A;
-		else if (dicho[h] == 'B')
+		else if (c == 'B')
 			x_de_letra = X_B;
-		else if (dicho[h] == 'C')
+		else if (c == 'C')
 			x_de_letra = X_C;
-		else if (dicho[h] == 'D')
+		else if (c == 'D')
 			x_de_letra = X_D;
-		else if (dicho[h] == 'E')
+		else if (c == 'E')
 			x_de_letra = X_E;
-		else if (dicho[h] == 'F')
+		else if (c == 'F')
 			x_de_letra = X_F;
-		else if (dicho[h] == 'G')
+		else if (c == 'G')
 			x_de_letra = X_G;
-		else if (dicho[h] == 'H')
+		else if (c == 'H')
 			x_de_letra = X_H;
-		else if (dicho[h] == 'I')
+		else if (c == 'I')
 			x_de_letra = X_I;
-		else if (dicho[h] == 'J')
+		else if (c == 'J')
 			x_de_letra = X_J;
-		else if (dicho[h] == 'K')
+		else if (c == 'K')
 			x_de_letra = X_K;
-		else if (dicho[h] == 'L')
+		else if (c == 'L')
 			x_de_letra = X_L;
-		else if (dicho[h] == 'M')
+		else if (c == 'M')
 			x_de_letra = X_M;
-		else if (dicho[h] == 'N')
+		else if (c == 'N')
 			x_de_letra = X_N;
-		else if (dicho[h] == '\xA5')
-			x_de_letra = X_GN;
-		else if (dicho[h] == '\xA4')
-			x_de_letra = X_GN;
-		else if (dicho[h] == 'O')
+//TODO	else if (c == '\xA5')
+//			x_de_letra = X_GN;
+//		else if (c == '\xA4')
+//			x_de_letra = X_GN;
+		else if (c == 'O')
 			x_de_letra = X_O;
-		else if (dicho[h] == 'P')
+		else if (c == 'P')
 			x_de_letra = X_P;
-		else if (dicho[h] == 'Q')
+		else if (c == 'Q')
 			x_de_letra = X_Q;
-		else if (dicho[h] == 'R')
+		else if (c == 'R')
 			x_de_letra = X_R;
-		else if (dicho[h] == 'S')
+		else if (c == 'S')
 			x_de_letra = X_S;
-		else if (dicho[h] == 'T')
+		else if (c == 'T')
 			x_de_letra = X_T;
-		else if (dicho[h] == 'U')
+		else if (c == 'U')
 			x_de_letra = X_U;
-		else if (dicho[h] == 'V')
+		else if (c == 'V')
 			x_de_letra = X_V;
-		else if (dicho[h] == 'W')
+		else if (c == 'W')
 			x_de_letra = X_W;
-		else if (dicho[h] == 'X')
+		else if (c == 'X')
 			x_de_letra = X_X;
-		else if (dicho[h] == 'Y')
+		else if (c == 'Y')
 			x_de_letra = X_Y;
-		else if (dicho[h] == 'Z')
+		else if (c == 'Z')
 			x_de_letra = X_Z;
-		else if (dicho[h] == '\xA7' || dicho[h] == ' ')
+		else if (/*c == 0xa7 ||*/ c == ' ')
 			x_de_letra = ESPACIO;
 		else {
 			y_de_letra = Y_SIGNOS;
-			if (dicho[h] == '.')
+			if (c == '.')
 				x_de_letra = X_PUNTO;
-			else if (dicho[h] == ',')
+			else if (c == ',')
 				x_de_letra = X_COMA;
-			else if (dicho[h] == '-')
+			else if (c == '-')
 				x_de_letra = X_GUION;
-			else if (dicho[h] == '?')
+			else if (c == '?')
 				x_de_letra = X_CIERRA_INTERROGACION;
-			else if (dicho[h] == '\xA8')
-				x_de_letra = X_ABRE_INTERROGACION;
-			else if (dicho[h] == '"')
+//TODO			else if (c == '\xA8')
+//				x_de_letra = X_ABRE_INTERROGACION;
+			else if (c == '"')
 				x_de_letra = X_COMILLAS;
-			else if (dicho[h] == '!')
+			else if (c == '!')
 				x_de_letra = X_CIERRA_EXCLAMACION;
-			else if (dicho[h] == '\xAD')
-				x_de_letra = X_ABRE_EXCLAMACION;
-			else if (dicho[h] == ';')
+//TODO			else if (c == '\xAD')
+//				x_de_letra = X_ABRE_EXCLAMACION;
+			else if (c == ';')
 				x_de_letra = X_PUNTO_Y_COMA;
-			else if (dicho[h] == '>')
+			else if (c == '>')
 				x_de_letra = X_MAYOR_QUE;
-			else if (dicho[h] == '<')
+			else if (c == '<')
 				x_de_letra = X_MENOR_QUE;
-			else if (dicho[h] == '$')
+			else if (c == '$')
 				x_de_letra = X_DOLAR;
-			else if (dicho[h] == '%')
+			else if (c == '%')
 				x_de_letra = X_POR_CIENTO;
-			else if (dicho[h] == ':')
+			else if (c == ':')
 				x_de_letra = X_DOS_PUNTOS;
-			else if (dicho[h] == '&')
+			else if (c == '&')
 				x_de_letra = X_AND;
-			else if (dicho[h] == '/')
+			else if (c == '/')
 				x_de_letra = X_BARRA;
-			else if (dicho[h] == '(')
+			else if (c == '(')
 				x_de_letra = X_ABRE_PARENTESIS;
-			else if (dicho[h] == ')')
+			else if (c == ')')
 				x_de_letra = X_CIERRA_PARENTESIS;
-			else if (dicho[h] == '*')
+			else if (c == '*')
 				x_de_letra = X_ASTERISCO;
-			else if (dicho[h] == '+')
+			else if (c == '+')
 				x_de_letra = X_MAS;
-			else if (dicho[h] == '1')
+			else if (c == '1')
 				x_de_letra = X_N1;
-			else if (dicho[h] == '2')
+			else if (c == '2')
 				x_de_letra = X_N2;
-			else if (dicho[h] == '3')
+			else if (c == '3')
 				x_de_letra = X_N3;
-			else if (dicho[h] == '4')
+			else if (c == '4')
 				x_de_letra = X_N4;
-			else if (dicho[h] == '5')
+			else if (c == '5')
 				x_de_letra = X_N5;
-			else if (dicho[h] == '6')
+			else if (c == '6')
 				x_de_letra = X_N6;
-			else if (dicho[h] == '7')
+			else if (c == '7')
 				x_de_letra = X_N7;
-			else if (dicho[h] == '8')
+			else if (c == '8')
 				x_de_letra = X_N8;
-			else if (dicho[h] == '9')
+			else if (c == '9')
 				x_de_letra = X_N9;
-			else if (dicho[h] == '0')
+			else if (c == '0')
 				x_de_letra = X_N0;
 			else
 				y_de_letra = Y_ACENTOS;
-
-			if (dicho[h] == '\xA0')
+/*
+			if (c == '\xA0')
 				x_de_letra = X_A;
-			else if (dicho[h] == '\x82')
+			else if (c == '\x82')
 				x_de_letra = X_B;
-			else if (dicho[h] == '\xA1')
+			else if (c == '\xA1')
 				x_de_letra = X_C;
-			else if (dicho[h] == '\xA2')
+			else if (c == '\xA2')
 				x_de_letra = X_D;
-			else if (dicho[h] == '\xA3')
+			else if (c == '\xA3')
 				x_de_letra = X_E;
-			else if (dicho[h] == '\x85')
+			else if (c == '\x85')
 				x_de_letra = X_F;
-			else if (dicho[h] == '\x8A')
+			else if (c == '\x8A')
 				x_de_letra = X_G;
-			else if (dicho[h] == '\x8D')
+			else if (c == '\x8D')
 				x_de_letra = X_H;
-			else if (dicho[h] == '\x95')
+			else if (c == '\x95')
 				x_de_letra = X_I;
-			else if (dicho[h] == '\x97')
+			else if (c == '\x97')
 				x_de_letra = X_J;
-			else if (dicho[h] == '\x83')
+			else if (c == '\x83')
 				x_de_letra = X_K;
-			else if (dicho[h] == '\x88')
+			else if (c == '\x88')
 				x_de_letra = X_L;
-			else if (dicho[h] == '\x8C')
+			else if (c == '\x8C')
 				x_de_letra = X_M;
-			else if (dicho[h] == '\x93')
+			else if (c == '\x93')
 				x_de_letra = X_N;
-			else if (dicho[h] == '\x96')
+			else if (c == '\x96')
 				x_de_letra = X_GN;
-			else if (dicho[h] == '\'')
+			else if (c == '\'')
 				x_de_letra = X_O;
-			else if (dicho[h] == '\x80')
+			else if (c == '\x80')
 				x_de_letra = X_P;
-			else if (dicho[h] == '\x87')
+			else if (c == '\x87')
 				x_de_letra = X_P;
-			else if (dicho[h] == '\xB5')
+			else if (c == '\xB5')
 				x_de_letra = X_A;
-			else if (dicho[h] == '\x90')
+			else if (c == '\x90')
 				x_de_letra = X_B;
-			else if (dicho[h] == '\xD6')
+			else if (c == '\xD6')
 				x_de_letra = X_C;
-			else if (dicho[h] == '\xE0')
+			else if (c == '\xE0')
 				x_de_letra = X_D;
-			else if (dicho[h] == '\xE9')
+			else if (c == '\xE9')
 				x_de_letra = X_E;
-			else if (dicho[h] == '\xB7')
+			else if (c == '\xB7')
 				x_de_letra = X_F;
-			else if (dicho[h] == '\xD4')
+			else if (c == '\xD4')
 				x_de_letra = X_G;
-			else if (dicho[h] == '\xDE')
+			else if (c == '\xDE')
 				x_de_letra = X_H;
-			else if (dicho[h] == '\xE3')
+			else if (c == '\xE3')
 				x_de_letra = X_I;
-			else if (dicho[h] == '\xEB')
+			else if (c == '\xEB')
 				x_de_letra = X_J;
-			else if (dicho[h] == '\xB6')
+			else if (c == '\xB6')
 				x_de_letra = X_K;
-			else if (dicho[h] == '\xD2')
+			else if (c == '\xD2')
 				x_de_letra = X_L;
-			else if (dicho[h] == '\xD7')
+			else if (c == '\xD7')
 				x_de_letra = X_M;
-			else if (dicho[h] == '\xE2')
+			else if (c == '\xE2')
 				x_de_letra = X_N;
-			else if (dicho[h] == '\xEA')
+			else if (c == '\xEA')
 				x_de_letra = X_GN;
-		}
-*/
+*/		}
+
 		pos_texto[0] = x_de_letra;
 		pos_texto[1] = y_de_letra;
 		pos_texto[2] = x_pantalla;


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