From 6fe73015cec996cb18a9d4cb1217025d7d4f514b Mon Sep 17 00:00:00 2001 From: onyx-and-iris <75868496+onyx-and-iris@users.noreply.github.com> Date: Sat, 14 May 2022 16:00:58 +0100 Subject: [PATCH] gain labels added to submix frame patch bump --- setup.py | 2 +- vmcompact/builders.py | 4 ++-- vmcompact/gainlayer.py | 10 ++++++---- 3 files changed, 9 insertions(+), 7 deletions(-) diff --git a/setup.py b/setup.py index c976144..3b00512 100644 --- a/setup.py +++ b/setup.py @@ -5,7 +5,7 @@ with open("README.md", "r", encoding="utf-8") as fh: setuptools.setup( name="vmcompact", - version="1.2.2", + version="1.2.3", author="Onyx and Iris", author_email="code@onyxandiris.online", description="Compact Tkinter Voicemeeter Remote App", diff --git a/vmcompact/builders.py b/vmcompact/builders.py index e1642b2..a82524d 100644 --- a/vmcompact/builders.py +++ b/vmcompact/builders.py @@ -182,7 +182,7 @@ class NavigationFrameBuilder(AbstractBuilder): if isinstance(child, ttk.Checkbutton) ] if _configuration.themes_enabled: - self.navframe.rowconfigure(1, minsize=_configuration.level_height - 16) + self.navframe.rowconfigure(1, minsize=_configuration.level_height) else: self.navframe.rowconfigure(1, minsize=_configuration.level_height - 5) @@ -276,7 +276,7 @@ class ChannelLabelFrameBuilder(AbstractBuilder): style=f"{'Toggle.TButton' if _configuration.themes_enabled else f'{self.identifier}On{self.index}.TButton'}", variable=self.labelframe.on, ) - self.button_on.grid(column=0, row=1, columnspan=2) + self.button_on.grid(column=0, row=2, columnspan=2) def teardown(self): self.labelframe.grid_remove() diff --git a/vmcompact/gainlayer.py b/vmcompact/gainlayer.py index 7127665..e76a338 100644 --- a/vmcompact/gainlayer.py +++ b/vmcompact/gainlayer.py @@ -24,6 +24,7 @@ class GainLayer(ttk.LabelFrame): self.builder.setup() self.builder.add_progressbar() self.builder.add_scale() + self.builder.add_gain_label() self.builder.add_on_button() self.sync() self.grid_configure() @@ -50,13 +51,13 @@ class GainLayer(ttk.LabelFrame): def reset_gain(self, *args): self.setter("gain", 0) self.gain.set(0) - self.parent.parent.nav_frame.info_text.set(0) + self.gainlabel.set(0) def scale_callback(self, *args): """callback function for scale widget""" self.setter("gain", self.gain.get()) - self.parent.parent.nav_frame.info_text.set(round(self.gain.get(), 1)) + self.gainlabel.set(round(self.gain.get(), 1)) def scale_press(self, *args): _base_values.in_scale_button_1 = True @@ -106,6 +107,7 @@ class GainLayer(ttk.LabelFrame): def sync_params(self): self.gain.set(self.getter("gain")) + self.gainlabel.set(round(self.gain.get(), 1)) self.on.set( getattr( self.parent.target.strip[self.index], @@ -184,9 +186,9 @@ class GainLayer(ttk.LabelFrame): self.columnconfigure(1, minsize=36) # on button if _configuration.themes_enabled: - self.rowconfigure(1, minsize=70) + self.rowconfigure(2, minsize=70) else: - self.rowconfigure(1, minsize=55) + self.rowconfigure(2, minsize=55) class SubMixFrame(ttk.Frame):