add CANVAS_STRING_VARIABLE, the first step in being able to avoid using GTK rc files...
authorPaul Davis <paul@linuxaudiosystems.com>
Fri, 13 Jun 2014 11:30:09 +0000 (07:30 -0400)
committerPaul Davis <paul@linuxaudiosystems.com>
Fri, 13 Jun 2014 11:30:27 +0000 (07:30 -0400)
Still needs a way to generate the font specs at build time to account for platform differences

gtk2_ardour/ui_config.h

index bfa8859afdc671994b52935dfaae33a06e604bf5..46dd8e9806522e34156e3ef2cecc106ada22c801 100644 (file)
@@ -101,11 +101,16 @@ class UIConfiguration : public PBD::Stateful
 #include "ui_config_vars.h"
 #undef  UI_CONFIG_VARIABLE
 #undef CANVAS_VARIABLE
+#undef CANVAS_STRING_VARIABLE
 #define CANVAS_VARIABLE(var,name) \
        uint32_t get_##var () const { return var.get(); } \
        bool set_##var (uint32_t val) { bool ret = var.set (val); if (ret) { ParameterChanged (name); } return ret;  }
+#define CANVAS_STRING_VARIABLE(var,name) \
+       std::string get_##var () const { return var.get(); }                    \
+       bool set_##var (const std::string& val) { bool ret = var.set (val); if (ret) { ParameterChanged (name); } return ret;  }
 #include "canvas_vars.h"
 #undef  CANVAS_VARIABLE
+#undef CANVAS_STRING_VARIABLE
 
   private:
 
@@ -118,8 +123,10 @@ class UIConfiguration : public PBD::Stateful
 
 #undef CANVAS_VARIABLE
 #define CANVAS_VARIABLE(var,name) UIConfigVariable<uint32_t> var;
+#define CANVAS_STRING_VARIABLE(var,name) UIConfigVariable<std::string> var;
 #include "canvas_vars.h"
 #undef  CANVAS_VARIABLE
+#undef CANVAS_STRING_VARIABLE
 
        XMLNode& state ();
        bool _dirty;