summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMatthias Melcher <fltk@matthiasm.com>2010-11-15 13:10:14 +0000
committerMatthias Melcher <fltk@matthiasm.com>2010-11-15 13:10:14 +0000
commit0af4b7367f87f157a6368e8f1728cd7e25eff66b (patch)
tree836385da6f37e3bc5a2b4d56e76ee7845700d1ad /src
parent4cfee0c9c2ba2e977a8aea7ea035712ff8f84bde (diff)
Applied latest changes for STR 2215
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@7840 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'src')
-rw-r--r--src/fl_font_xft.cxx6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/fl_font_xft.cxx b/src/fl_font_xft.cxx
index e994dee84..01b5c2bc4 100644
--- a/src/fl_font_xft.cxx
+++ b/src/fl_font_xft.cxx
@@ -433,15 +433,14 @@ static XFontStruct* load_xfont_for_xft2(void) {
}
// first, we do a query with no prefered size, to see if the font exists at all
- snprintf(xlfd, 128, "-*-*%s*-%s-%c-*--*-*-*-*-*-*-*-*", name, weight, slant); // make up xlfd style name
+ snprintf(xlfd, 128, "-*-%s-%s-%c-*--*-*-*-*-*-*-*-*", name, weight, slant); // make up xlfd style name
xgl_font = XLoadQueryFont(fl_display, xlfd);
if(xgl_font) { // the face exists, but can we get it in a suitable size?
XFreeFont(fl_display, xgl_font); // release the non-sized version
- snprintf(xlfd, 128, "-*-*%s*-%s-%c-*--*-%d-*-*-*-*-*-*", name, weight, slant, (size*10));
+ snprintf(xlfd, 128, "-*-%s-%s-%c-*--*-%d-*-*-*-*-*-*", name, weight, slant, (size*10));
xgl_font = XLoadQueryFont(fl_display, xlfd); // attempt to load the font at the right size
}
//puts(xlfd);
- free(pc); // release our copy of the font name
// try alternative names
if (!xgl_font) {
@@ -459,6 +458,7 @@ static XFontStruct* load_xfont_for_xft2(void) {
snprintf(xlfd, 128, "-*-*%s*-%s-%c-*--*-%d-*-*-*-*-*-*", name, weight, slant, (size*10));
xgl_font = XLoadQueryFont(fl_display, xlfd);
}
+ free(pc); // release our copy of the font name
// if we have nothing loaded, try a generic proportional font
if(!xgl_font) {