change ordering of options for multichannel import
[ardour.git] / gtk2_ardour / ui_config.cc
index c6e538bb1b68c0fe37270663c1b3aa7f70d8dc70..024357b2667de250fc93361de7338ca3c99a6281 100644 (file)
@@ -158,18 +158,6 @@ UIConfiguration::reset_gtk_theme ()
 
 void
 UIConfiguration::reset_dpi ()
-{
-       long val = get_font_scale();
-       set_pango_fontsize ();
-       /* Xft rendering */
-
-       gtk_settings_set_long_property (gtk_settings_get_default(),
-                                       "gtk-xft-dpi", val, "ardour");
-       DPIReset(); //Emit Signal
-}
-
-void
-UIConfiguration::set_pango_fontsize ()
 {
        long val = get_font_scale();
 
@@ -182,6 +170,12 @@ UIConfiguration::set_pango_fontsize ()
        /* Cairo rendering, in case there is any */
 
        pango_cairo_font_map_set_resolution ((PangoCairoFontMap*) pango_cairo_font_map_get_default(), val/1024);
+
+       /* Xft rendering */
+
+       gtk_settings_set_long_property (gtk_settings_get_default(),
+                                       "gtk-xft-dpi", val, "ardour");
+       DPIReset(); //Emit Signal
 }
 
 float
@@ -266,8 +260,15 @@ UIConfiguration::color_file_name (bool use_my, bool with_version) const
                basename += "my-";
        }
 
-       //this is the overall theme file, e.g. "dark" plus "-downcase(PROGRAM_NAME)"
-       basename += color_file.get();  
+       std::string color_name = color_file.get();
+       size_t sep = color_name.find_first_of("-");
+       if (sep != string::npos) {
+               color_name = color_name.substr (0, sep);
+       }
+
+       basename += color_name;
+       basename += "-";
+       basename += downcase(PROGRAM_NAME);
 
        std::string rev (revision);
        std::size_t pos = rev.find_first_of("-");