]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
let's use a free font for now, even though it doesn't look totally good
authorRudolf Polzer <divverent@alientrap.org>
Wed, 23 Jun 2010 10:57:35 +0000 (12:57 +0200)
committerRudolf Polzer <divverent@alientrap.org>
Wed, 23 Jun 2010 10:57:35 +0000 (12:57 +0200)
defaultXonotic.cfg
loadfonts.cfg [deleted file]
qcsrc/client/miscfunctions.qc
qcsrc/menu/draw.qc
quake.rc

index 909dfd6d47deaf18f25507c69e99c04629e84c1b..5e26dca4689c99c842427e481482c7c87ad7a0c1 100644 (file)
@@ -1787,9 +1787,6 @@ collision_endposnudge 1
 set cl_lerpanim_maxdelta_framegroups 0.05 // must be faster than fastest weapon refire
 set cl_lerpanim_maxdelta_server 0.1 // must be slower than slowest server controlled anim (e.g. animinfo stuff)
 
 set cl_lerpanim_maxdelta_framegroups 0.05 // must be faster than fastest weapon refire
 set cl_lerpanim_maxdelta_server 0.1 // must be slower than slowest server controlled anim (e.g. animinfo stuff)
 
-// FIXME temporary
-set menu_font_size_snapping_fix 1
-
 // player ID
 seta _cl_userid "" "player ID (e.g. for tournaments)"
 
 // player ID
 seta _cl_userid "" "player ID (e.g. for tournaments)"
 
diff --git a/loadfonts.cfg b/loadfonts.cfg
deleted file mode 100644 (file)
index dd3b637..0000000
+++ /dev/null
@@ -1,21 +0,0 @@
-// When freetype support is in SVN, remove the space between vera-sans and the comma :)
-// like: loadfont user0 gfx/vera-sans,gfx/fallback 8 12 16 24 32
-// loadfont console     gfx/vera-mono,gfx/fallback $con_textsize 9 10 11
-// loadfont sbar        gfx/vera-mono
-loadfont notify      gfx/vera-sans,gfx/fallback 8 12 16 24 32
-loadfont chat        gfx/vera-sans,gfx/fallback 8 13 16 24 32
-// loadfont centerprint gfx/vera-mono
-// loadfont infobar     gfx/vera-mono
-loadfont user0       gfx/vera-sans,gfx/fallback 8 12 16 24 32
-
-// now create the real sbar_font alias
-alias sbar_font "loadfont user1 ${1},gfx/fallback ${2-}; loadfont user2 ${1}-big,gfx/fallback ${2-}; sbar_columns_set"
-// if _requested_sbar_font is empty, the string becaomse "nonempty: "
-// for the case "nonempty: " a default value is used
-// in any other case, the _requested_sbar_font is sued
-set _used_sbar_font "nonempty: $_requested_sbar_font"
-toggle _used_sbar_font "$_requested_sbar_font" "nonempty: " "gfx/vera-sans 8 12 16 24 32"
-toggle _requested_sbar_font "" "gfx/vera-sans 8 12 16 24 32" "gfx/vera-sans 8 12 16 24 32" "$_requested_sbar_font"
-sbar_font ${_requested_sbar_font asis}
-
-set menu_font_size_snapping_fix 1
index 0e3e58f49607542917a34d1ebfa154cd20962e22..74830223d9306f31cead7823a6f3ff590b593e7f 100644 (file)
@@ -510,18 +510,13 @@ void drawstring_expanding(vector position, string text, vector scale, vector rgb
        float sz;
        sz = expandingbox_sizefactor_from_fadelerp(fadelerp);
 
        float sz;
        sz = expandingbox_sizefactor_from_fadelerp(fadelerp);
 
-       if(cvar("menu_font_size_snapping_fix"))
-               drawfontscale = sz * '1 1 0';
-       else
-               drawfontscale = '1 1 0';
+       drawfontscale = sz * '1 1 0';
        dummyfunction(0, 0, 0, 0, 0, 0, 0, 0);
         drawstring(position + expandingbox_resize_centered_box_offset(sz, scale, stringwidth(text, FALSE, scale * (sz / drawfontscale_x)) / (scale_x * sz)), text, scale * (sz / drawfontscale_x), rgb, alpha * (1 - fadelerp), flag);
        // width parameter:
        //    (scale_x * sz / drawfontscale_x) * drawfontscale_x * SIZE1 / (scale_x * sz)
        //    SIZE1
        dummyfunction(0, 0, 0, 0, 0, 0, 0, 0);
         drawstring(position + expandingbox_resize_centered_box_offset(sz, scale, stringwidth(text, FALSE, scale * (sz / drawfontscale_x)) / (scale_x * sz)), text, scale * (sz / drawfontscale_x), rgb, alpha * (1 - fadelerp), flag);
        // width parameter:
        //    (scale_x * sz / drawfontscale_x) * drawfontscale_x * SIZE1 / (scale_x * sz)
        //    SIZE1
-
-       if(cvar("menu_font_size_snapping_fix"))
-               drawfontscale = '1 1 0';
+       drawfontscale = '1 1 0';
 }
 
 void drawcolorcodedstring_expanding(vector position, string text, vector scale, float alpha, float flag, float fadelerp)
 }
 
 void drawcolorcodedstring_expanding(vector position, string text, vector scale, float alpha, float flag, float fadelerp)
@@ -529,15 +524,10 @@ void drawcolorcodedstring_expanding(vector position, string text, vector scale,
        float sz;
        sz = expandingbox_sizefactor_from_fadelerp(fadelerp);
 
        float sz;
        sz = expandingbox_sizefactor_from_fadelerp(fadelerp);
 
-       if(cvar("menu_font_size_snapping_fix"))
-               drawfontscale = sz * '1 1 0';
-       else
-               drawfontscale = '1 1 0';
+       drawfontscale = sz * '1 1 0';
        dummyfunction(0, 0, 0, 0, 0, 0, 0, 0);
        drawcolorcodedstring(position + expandingbox_resize_centered_box_offset(sz, scale, stringwidth(text, TRUE, scale * (sz / drawfontscale_x)) / (scale_x * sz)), text, scale * (sz / drawfontscale_x), alpha * (1 - fadelerp), flag);
        dummyfunction(0, 0, 0, 0, 0, 0, 0, 0);
        drawcolorcodedstring(position + expandingbox_resize_centered_box_offset(sz, scale, stringwidth(text, TRUE, scale * (sz / drawfontscale_x)) / (scale_x * sz)), text, scale * (sz / drawfontscale_x), alpha * (1 - fadelerp), flag);
-
-       if(cvar("menu_font_size_snapping_fix"))
-               drawfontscale = '1 1 0';
+       drawfontscale = '1 1 0';
 }
 
 // this draws the triangles of a model DIRECTLY. Don't expect high performance, really...
 }
 
 // this draws the triangles of a model DIRECTLY. Don't expect high performance, really...
index b504022a5174603e6fa0feb0b30c31f8ffce2ada..2cbf3694d6ae842dc96acce63b24221d6d8d1a6c 100644 (file)
@@ -233,19 +233,10 @@ void draw_Text(vector theOrigin, string theText, vector theSize, vector theColor
        vector fs;
        if(theSize_x <= 0 || theSize_y <= 0)
                error("Drawing zero size text?\n");
        vector fs;
        if(theSize_x <= 0 || theSize_y <= 0)
                error("Drawing zero size text?\n");
-       if not(cvar("menu_font_size_snapping_fix")) // FIXME remove this, this is to detect old engines
-       {
-               fs = draw_fontscale;
-               draw_fontscale = '1 1 0';
-       }
        if(ICanHasKallerz)
                drawcolorcodedstring(boxToGlobal(theOrigin, draw_shift, draw_scale), theText, globalToBoxSize(boxToGlobalSize(theSize, draw_scale), draw_fontscale), theAlpha * draw_alpha, 0);
        else
                drawstring(boxToGlobal(theOrigin, draw_shift, draw_scale), theText, globalToBoxSize(boxToGlobalSize(theSize, draw_scale), draw_fontscale), theColor, theAlpha * draw_alpha, 0);
        if(ICanHasKallerz)
                drawcolorcodedstring(boxToGlobal(theOrigin, draw_shift, draw_scale), theText, globalToBoxSize(boxToGlobalSize(theSize, draw_scale), draw_fontscale), theAlpha * draw_alpha, 0);
        else
                drawstring(boxToGlobal(theOrigin, draw_shift, draw_scale), theText, globalToBoxSize(boxToGlobalSize(theSize, draw_scale), draw_fontscale), theColor, theAlpha * draw_alpha, 0);
-       if not(cvar("menu_font_size_snapping_fix")) // FIXME remove this, this is to detect old engines
-       {
-               draw_fontscale = fs;
-       }
 }
 void draw_CenterText(vector theOrigin, string theText, vector theSize, vector theColor, float theAlpha, float ICanHasKallerz)
 {
 }
 void draw_CenterText(vector theOrigin, string theText, vector theSize, vector theColor, float theAlpha, float ICanHasKallerz)
 {
@@ -261,16 +252,7 @@ float draw_TextWidth(string theText, float ICanHasKallerz, vector SizeThxBye)
        vector v;
        v = '0 0 0';
        //float r;
        vector v;
        v = '0 0 0';
        //float r;
-       if not(cvar("menu_font_size_snapping_fix")) // FIXME remove this, this is to detect old engines
-       {
-               fs = draw_fontscale;
-               draw_fontscale = '1 1 0';
-       }
        v_x = stringwidth(theText, ICanHasKallerz, boxToGlobalSize(SizeThxBye, draw_scale)) / draw_fontscale_x;
        v_x = stringwidth(theText, ICanHasKallerz, boxToGlobalSize(SizeThxBye, draw_scale)) / draw_fontscale_x;
-       if not(cvar("menu_font_size_snapping_fix")) // FIXME remove this, this is to detect old engines
-       {
-               draw_fontscale = fs;
-       }
        v = globalToBoxSize(v, draw_scale);
        return v_x;
 }
        v = globalToBoxSize(v, draw_scale);
        return v_x;
 }
index 2dec76c772bcf12ee1e6e6d2fcbb03bb9f7bae6c..f24b01548edb1ba456d99059d82fb32c05bb0b88 100644 (file)
--- a/quake.rc
+++ b/quake.rc
@@ -9,4 +9,4 @@ exec loadfonts.cfg
 //startdemos
 //play announcer/male/welcome.ogg
 
 //startdemos
 //play announcer/male/welcome.ogg
 
-//exec font-dejavu.cfg
+exec font-nimbussansl.cfg