]> Dogcows Code - chaz/openbox/blobdiff - src/i18n.cc
add option to the rc file to use/not use AA for Xft fonts
[chaz/openbox] / src / i18n.cc
index b8aa361a45f7eec351e905e28ea39dff7b1418b9..0eb0a9116f069bd2a13e325af74c9f6aebc51db4 100644 (file)
@@ -1,5 +1,5 @@
 // -*- mode: C++; indent-tabs-mode: nil; c-basic-offset: 2; -*-
-// i18n.cc for Openbox
+// i18n.cc for Blackbox - an X11 Window manager
 // Copyright (c) 2001 - 2002 Sean 'Shaleh' Perry <shaleh@debian.org>
 // Copyright (c) 1997 - 2000 Brad Hughes (bhughes@tcac.net)
 //
@@ -48,10 +48,15 @@ extern "C" {
 #include <string>
 using std::string;
 
-#include "i18n.h"
+#include "i18n.hh"
 
-I18n::I18n(const char *catalog) {
-  mb = false;
+
+// the rest of bb source uses True and False from X, so we continue that
+#define True true
+#define False false
+
+I18n::I18n(void) {
+  mb = False;
 #ifdef    HAVE_SETLOCALE
   locale = setlocale(LC_ALL, "");
   if (! locale) {
@@ -62,7 +67,7 @@ I18n::I18n(const char *catalog) {
   } else {
     // MB_CUR_MAX returns the size of a char in the current locale
     if (MB_CUR_MAX > 1)
-      mb = true;
+      mb = True;
     // truncate any encoding off the end of the locale
     char *l = strchr(locale, '@');
     if (l) *l = '\0';
@@ -74,12 +79,10 @@ I18n::I18n(const char *catalog) {
   catalog_fd = (nl_catd) -1;
 #endif
 #endif // HAVE_SETLOCALE
-  if (catalog)
-    openCatalog(catalog);
 }
 
 
-I18n::~I18n() {
+I18n::~I18n(void) {
 #if defined(NLS) && defined(HAVE_CATCLOSE)
   if (catalog_fd != (nl_catd) -1)
     catclose(catalog_fd);
This page took 0.022283 seconds and 4 git commands to generate.