summaryrefslogtreecommitdiff
path: root/gtk2_ardour/wscript
diff options
context:
space:
mode:
authorPaul Davis <paul@linuxaudiosystems.com>2011-01-27 18:46:47 +0000
committerPaul Davis <paul@linuxaudiosystems.com>2011-01-27 18:46:47 +0000
commit2f360574c3ccafaf2b950e32f7e93753a6bfe230 (patch)
treecfc756916ae5a299764dabfb5b732d0df3e14891 /gtk2_ardour/wscript
parentd2289f6d144e1211573fd6fdf55809d6ab16071a (diff)
new meta dark RC file (no light for now), along with tools to convert from .in into the real thing built into wscript - THIS WILL MESS UP COLORS AND SOME FONTS
git-svn-id: svn://localhost/ardour2/branches/3.0@8588 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'gtk2_ardour/wscript')
-rw-r--r--gtk2_ardour/wscript40
1 files changed, 21 insertions, 19 deletions
diff --git a/gtk2_ardour/wscript b/gtk2_ardour/wscript
index 38700fcbc3..0466f811c1 100644
--- a/gtk2_ardour/wscript
+++ b/gtk2_ardour/wscript
@@ -264,6 +264,23 @@ def set_winegcc(self):
self.env.LINK_CXX = self.env.LINK_CC = 'wineg++'
self.env.CC = 'winegcc'
+def build_color_scheme(path):
+ f = open (path, 'r')
+ color_scheme = ''
+ for line in f:
+ if re.search ('^#@color', line):
+ line.strip() # remove newline
+ words = line.split()
+ if len(color_scheme):
+ color_scheme += ';'
+ color_scheme += 'A_' # prefix for color name
+ color_scheme += words[1]
+ color_scheme += ':'
+ color_scheme += words[2]
+ f.close()
+ return color_scheme
+
+
def build(bld):
# GTK front-end; if we're using VST we build this as a shared library, otherwise
# it's a normal executabale
@@ -412,29 +429,14 @@ def build(bld):
# add normal monospace to font dict
font_subst_dict['FONT_MONOSPACE_NORMAL'] = 'monospace 10'
+ dark_rc_subst_dict = font_subst_dict
+ dark_rc_subst_dict['COLOR_SCHEME'] = build_color_scheme ('gtk2_ardour/ardour3_ui_dark.rc.in')
+
# RC files
obj = bld.new_task_gen('subst')
obj.source = 'ardour3_ui_dark.rc.in'
obj.target = 'ardour3_ui_dark.rc'
- obj.dict = font_subst_dict
- obj.install_path = os.path.join(bld.env['CONFIGDIR'], 'ardour3')
-
- obj = bld.new_task_gen('subst')
- obj.source = 'ardour3_ui_light.rc.in'
- obj.target = 'ardour3_ui_light.rc'
- obj.dict = font_subst_dict
- obj.install_path = os.path.join(bld.env['CONFIGDIR'], 'ardour3')
-
- obj = bld.new_task_gen('subst')
- obj.source = 'ardour3_ui_dark_sae.rc.in'
- obj.target = 'ardour3_ui_dark_sae.rc'
- obj.dict = font_subst_dict
- obj.install_path = os.path.join(bld.env['CONFIGDIR'], 'ardour3')
-
- obj = bld.new_task_gen('subst')
- obj.source = 'ardour3_ui_light_sae.rc.in'
- obj.target = 'ardour3_ui_light_sae.rc'
- obj.dict = font_subst_dict
+ obj.dict = dark_rc_subst_dict
obj.install_path = os.path.join(bld.env['CONFIGDIR'], 'ardour3')
# Menus