aboutsummaryrefslogtreecommitdiff
path: root/src/FbTk/XmbFontImp.cc
diff options
context:
space:
mode:
authorfluxgen <fluxgen>2004-02-10 19:03:42 (GMT)
committerfluxgen <fluxgen>2004-02-10 19:03:42 (GMT)
commit6d1ed67e54edb37b65a78fcb0471f9286e39322e (patch)
tree50409f7fd57bbfba180265eebba08bdcc2c18f5c /src/FbTk/XmbFontImp.cc
parenta560e67df5b1f5a87e4301949f5cf6db9d3223af (diff)
downloadfluxbox-6d1ed67e54edb37b65a78fcb0471f9286e39322e.zip
fluxbox-6d1ed67e54edb37b65a78fcb0471f9286e39322e.tar.bz2
minor fix
Diffstat (limited to 'src/FbTk/XmbFontImp.cc')
-rw-r--r--src/FbTk/XmbFontImp.cc10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/FbTk/XmbFontImp.cc b/src/FbTk/XmbFontImp.cc
index 6a3ffed..9f47d6e 100644
--- a/src/FbTk/XmbFontImp.cc
+++ b/src/FbTk/XmbFontImp.cc
@@ -19,7 +19,7 @@
19// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER 19// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
20// DEALINGS IN THE SOFTWARE. 20// DEALINGS IN THE SOFTWARE.
21 21
22// $Id: XmbFontImp.cc,v 1.6 2003/04/26 18:57:51 fluxgen Exp $ 22// $Id: XmbFontImp.cc,v 1.7 2004/02/10 19:03:42 fluxgen Exp $
23 23
24#include "XmbFontImp.hh" 24#include "XmbFontImp.hh"
25 25
@@ -104,7 +104,7 @@ const char *getFontElement(const char *pattern, char *buf, int bufsiz, ...) {
104 while((v = va_arg(va, char *)) != 0) { 104 while((v = va_arg(va, char *)) != 0) {
105 p = FbTk::StringUtil::strcasestr(pattern, v); 105 p = FbTk::StringUtil::strcasestr(pattern, v);
106 if (p) { 106 if (p) {
107 std::strncpy(buf, p+1, bufsiz-2); 107 strncpy(buf, p+1, bufsiz-2);
108 p2 = strchr(buf, '-'); 108 p2 = strchr(buf, '-');
109 if (p2) *p2=0; 109 if (p2) *p2=0;
110 va_end(va); 110 va_end(va);
@@ -112,7 +112,7 @@ const char *getFontElement(const char *pattern, char *buf, int bufsiz, ...) {
112 } 112 }
113 } 113 }
114 va_end(va); 114 va_end(va);
115 std::strncpy(buf, "*", bufsiz); 115 strncpy(buf, "*", bufsiz);
116 return 0; 116 return 0;
117} 117}
118 118
@@ -153,9 +153,9 @@ XFontSet createFontSet(const char *fontname) {
153 getFontSize(fontname, &pixel_size); 153 getFontSize(fontname, &pixel_size);
154 154
155 if (! strcmp(weight, "*")) 155 if (! strcmp(weight, "*"))
156 std::strncpy(weight, "medium", FONT_ELEMENT_SIZE); 156 strncpy(weight, "medium", FONT_ELEMENT_SIZE);
157 if (! strcmp(slant, "*")) 157 if (! strcmp(slant, "*"))
158 std::strncpy(slant, "r", FONT_ELEMENT_SIZE); 158 strncpy(slant, "r", FONT_ELEMENT_SIZE);
159 if (pixel_size < 3) 159 if (pixel_size < 3)
160 pixel_size = 3; 160 pixel_size = 3;
161 else if (pixel_size > 97) 161 else if (pixel_size > 97)