changeset 32707:697fd62b65f9

Allow double quote to be defined in the font description file: """ = x, y, width, height
author ib
date Tue, 18 Jan 2011 10:57:52 +0000
parents 7a79424a81ac
children 29b63f338a9b
files gui/skin/font.c
diffstat 1 files changed, 2 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/gui/skin/font.c	Mon Jan 17 19:45:40 2011 +0000
+++ b/gui/skin/font.c	Tue Jan 18 10:57:52 2011 +0000
@@ -101,7 +101,8 @@
     {
      int i;
      cutItem( command,command,'"',1 );
-     i=(int)command[0];
+     if ( !command[0] ) i=(int)'"';
+     else i=(int)command[0];
      cutItem( param,tmp,',',0 ); Fonts[id]->Fnt[i].x=atoi( tmp );
      cutItem( param,tmp,',',1 ); Fonts[id]->Fnt[i].y=atoi( tmp );
      cutItem( param,tmp,',',2 ); Fonts[id]->Fnt[i].sx=atoi( tmp );