mirror of
https://github.com/onyx-and-iris/nvda-voicemeeter.git
synced 2026-04-19 07:43:30 +00:00
Compare commits
9 Commits
09f052b4a3
...
v.0.3.1
| Author | SHA1 | Date | |
|---|---|---|---|
| 3ca9e14e96 | |||
| 4ca64f94bc | |||
| 22bf109499 | |||
| a19aab3936 | |||
| 7134b6d209 | |||
| 1525710d31 | |||
| 2745e2c41a | |||
| 8716149eda | |||
| dde940938f |
45
README.md
45
README.md
@@ -8,7 +8,7 @@ A remote control app for [Voicemeeter][voicemeeter], designed to be used with th
|
||||
|
||||
For an outline of this projects goals see the [SPECIFICATION][spec].
|
||||
|
||||
<img src="./img/settings.png" width=350 alt="Image of Voicemeeter NVDA app settings tab">
|
||||
<img src="./img/nvda-voicemeeter.png" width=960 alt="Image of Voicemeeter NVDA app settings tab">
|
||||
|
||||
## Requirements
|
||||
|
||||
@@ -57,7 +57,7 @@ import nvda_voicemeeter
|
||||
|
||||
KIND_ID = "potato"
|
||||
|
||||
with voicemeeterlib.api(KIND_ID, sync=True) as vm:
|
||||
with voicemeeterlib.api(KIND_ID) as vm:
|
||||
with nvda_voicemeeter.draw(KIND_ID, vm) as window:
|
||||
window.run()
|
||||
```
|
||||
@@ -94,9 +94,19 @@ To adjust Patch Asio Inputs to Strips and Patch Insert values use `UP` and `DOWN
|
||||
|
||||
To access Advanced Settings you may press the Advanced Settings button or use `Control + A` when in the `Settings` tab.
|
||||
|
||||
#### `Strip/Bus`
|
||||
#### `Physical Strip|Virtual Strip|Buses`
|
||||
|
||||
To rename a strip/bus channel navigate to the relevant tab, then press `F2`. This will open a popup window where you can set the channel index (with a spinbox) and set the new label using a text input box.
|
||||
You will find in each of these tabs two nested tabs,`Buttons` and `Sliders`. For each nested tab you will find the controls appropriate for the Voicemeeter kind and channel type.
|
||||
|
||||
All buttons may be triggered by pressing `SPACE` or `ENTER`.
|
||||
|
||||
All sliders may be controlled in three different ways:
|
||||
|
||||
- `Left|Right arrow` to move a slider by 1 step.
|
||||
- `Shift + Left|Right arrow` to move a slider by 0.1 steps.
|
||||
- `Control + Left|Right arrow` to move a slider by 3 steps.
|
||||
|
||||
To rename a strip/bus channel focus on the channel in question and press `F2`. Then enter the new channel name into the text input widget and press the `Ok` button.
|
||||
|
||||
Pressing the `OK` button with an empty text input will clear the label. In this case the label will be read as a default value for that channel. For example, if the leftmost Strip label were cleared, the screen reader will now read `Hardware Input 1`.
|
||||
|
||||
@@ -114,6 +124,33 @@ The `Save Settings` option opens a popup window with two buttons, `Browse` and `
|
||||
|
||||
`Load Settings` and `Load on Startup` both open an Open dialog box immediately.
|
||||
|
||||
### `Quick access binds`
|
||||
|
||||
There are a number of quick binds available to assist with faster navigation and general use.
|
||||
|
||||
When focused on any one of "Physical Strip", "Virtual Strip" or "Buses" you may use `Control + Number` to skip to the corresponding channel.
|
||||
|
||||
When focused on any single channel (Strip or Bus), the following binds exist:
|
||||
|
||||
- `Alt + Number` will trigger the Bus output button corresponding to the number. For example `Alt + 3` will trigger the `A3` button
|
||||
- `Control + O` will trigger the Mono button
|
||||
- `Control + S` will trigger the Solo button
|
||||
- `Control + M` will trigger the Mute button
|
||||
|
||||
You may also enter slider modes which allow for control of the channels sliders until the slider mode is exited. You may access the slider modes with the following binds:
|
||||
|
||||
- `Control + U` will enter Audibility mode
|
||||
- `Control + G` will enter Gain mode
|
||||
- `Control + T` will enter Gate mode
|
||||
- `Control + L` will enter Limit mode
|
||||
- `Control + B` will enter Bass mode
|
||||
- `Control + I` will enter Mid mode
|
||||
- `Control + R` will enter Treble mode
|
||||
|
||||
To exit any of the slider modes press `Escape`.
|
||||
|
||||
Once you are in a slider mode you may now control the slider that matches the slider mode. Slider mode binds are the same as the normal slider binds with the addition of the Alt keypress. For example, where you would normally use `Right Arrow` to shift a slider rightwards by 1 step, in slider mode you would now use `Alt + Right Arrow`.
|
||||
|
||||
### Issues
|
||||
|
||||
If you have any questions/suggestions feel free to raise an issue or open a new discussion.
|
||||
|
||||
@@ -4,6 +4,6 @@ import nvda_voicemeeter
|
||||
|
||||
KIND_ID = "potato"
|
||||
|
||||
with voicemeeterlib.api(KIND_ID, sync=True) as vm:
|
||||
with voicemeeterlib.api(KIND_ID) as vm:
|
||||
with nvda_voicemeeter.draw(KIND_ID, vm) as window:
|
||||
window.run()
|
||||
|
||||
BIN
img/nvda-voicemeeter.png
Normal file
BIN
img/nvda-voicemeeter.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 777 KiB |
@@ -1,6 +1,6 @@
|
||||
[project]
|
||||
name = "nvda_voicemeeter"
|
||||
version = "0.2.2a1"
|
||||
version = "0.3.1"
|
||||
description = "A Voicemeeter app compatible with NVDA"
|
||||
authors = [
|
||||
{ name = "onyx-and-iris", email = "code@onyxandiris.online" },
|
||||
|
||||
@@ -323,7 +323,7 @@ class Builder:
|
||||
)
|
||||
|
||||
def add_param_sliders(layout):
|
||||
layout.append([LabelSlider(self.window, i, param) for param in util.get_slider_params(i, self.vm)])
|
||||
layout.append([LabelSlider(self.window, i, param) for param in util.get_slider_params(i, self.kind)])
|
||||
|
||||
def add_limit_slider(layout):
|
||||
layout.append(
|
||||
@@ -416,13 +416,13 @@ class Builder:
|
||||
|
||||
def add_param_sliders(layout):
|
||||
if self.kind.name in ("basic", "banana"):
|
||||
for param in util.get_slider_params(i, self.vm):
|
||||
for param in util.get_slider_params(i, self.kind):
|
||||
layout.append([LabelSlider(self.window, i, param, range_=(-12, 12))])
|
||||
else:
|
||||
layout.append(
|
||||
[
|
||||
LabelSlider(self.window, i, param, range_=(-12, 12))
|
||||
for param in util.get_slider_params(i, self.vm)
|
||||
for param in util.get_slider_params(i, self.kind)
|
||||
]
|
||||
)
|
||||
|
||||
|
||||
@@ -11,6 +11,7 @@ logger = logging.getLogger(__name__)
|
||||
class Popup:
|
||||
def __init__(self, window):
|
||||
self.window = window
|
||||
self.kind = self.window.kind
|
||||
self.logger = logger.getChild(type(self).__name__)
|
||||
|
||||
def save_as(self, message, title=None, initial_folder=None):
|
||||
@@ -46,28 +47,27 @@ class Popup:
|
||||
if filepath:
|
||||
return Path(filepath)
|
||||
|
||||
def rename(self, message, title=None, tab=None):
|
||||
if tab == "Physical Strip":
|
||||
upper = self.window.kind.phys_in + 1
|
||||
elif tab == "Virtual Strip":
|
||||
upper = self.window.kind.virt_in + 1
|
||||
elif tab == "Buses":
|
||||
upper = self.window.kind.num_bus + 1
|
||||
|
||||
def rename(self, message, index, title=None, tab=None):
|
||||
if "Strip" in tab:
|
||||
if index < self.kind.phys_in:
|
||||
title += f" Physical Strip {index + 1}"
|
||||
else:
|
||||
title += f" Virtual Strip {index - self.kind.phys_in + 1}"
|
||||
else:
|
||||
if index < self.kind.phys_out:
|
||||
title += f" Physical Bus {index + 1}"
|
||||
else:
|
||||
title += f" Virtual Bus {index - self.kind.phys_out + 1}"
|
||||
layout = [
|
||||
[psg.Text(message)],
|
||||
[
|
||||
[
|
||||
psg.Spin(
|
||||
list(range(1, upper)), initial_value=1, size=2, enable_events=True, key=f"Index", readonly=True
|
||||
),
|
||||
psg.Input(key="Edit"),
|
||||
],
|
||||
[psg.Button("Ok"), psg.Button("Cancel")],
|
||||
],
|
||||
]
|
||||
popup = psg.Window(title, layout, finalize=True)
|
||||
popup["Index"].bind("<FocusIn>", "||FOCUS IN")
|
||||
popup["Edit"].bind("<FocusIn>", "||FOCUS IN")
|
||||
popup["Ok"].bind("<FocusIn>", "||FOCUS IN")
|
||||
popup["Ok"].bind("<Return>", "||KEY ENTER")
|
||||
@@ -81,15 +81,8 @@ class Popup:
|
||||
if event in (psg.WIN_CLOSED, "Cancel"):
|
||||
break
|
||||
match parsed_cmd := self.window.parser.match.parseString(event):
|
||||
case ["Index"]:
|
||||
val = values["Index"]
|
||||
self.window.nvda.speak(f"Index {val}")
|
||||
case [[button], ["FOCUS", "IN"]]:
|
||||
if button == "Index":
|
||||
val = values["Index"]
|
||||
self.window.nvda.speak(f"Index {val}")
|
||||
else:
|
||||
self.window.nvda.speak(button)
|
||||
self.window.nvda.speak(button)
|
||||
case [[button], ["KEY", "ENTER"]]:
|
||||
popup.find_element_with_focus().click()
|
||||
case ["Ok"]:
|
||||
@@ -135,7 +128,7 @@ class Popup:
|
||||
self.logger.debug(f"values::{values}")
|
||||
if event in (psg.WIN_CLOSED, "Exit"):
|
||||
break
|
||||
match parsed_cmd := self.parser.match.parseString(event):
|
||||
match parsed_cmd := self.window.parser.match.parseString(event):
|
||||
case ["BUFFER MME" | "BUFFER WDM" | "BUFFER KS" | "BUFFER ASIO"]:
|
||||
if values[event] == "Default":
|
||||
if "MME" in event:
|
||||
@@ -147,10 +140,12 @@ class Popup:
|
||||
else:
|
||||
val = int(values[event])
|
||||
driver = event.split()[1]
|
||||
self.vm.set(f"option.buffer.{driver.lower()}", val)
|
||||
self.TKroot.after(200, self.window.nvda.speak, f"{driver} BUFFER {val if val else 'default'}")
|
||||
self.window.vm.set(f"option.buffer.{driver.lower()}", val)
|
||||
self.window.TKroot.after(
|
||||
200, self.window.nvda.speak, f"{driver} BUFFER {val if val else 'default'}"
|
||||
)
|
||||
case [["BUFFER", driver], ["FOCUS", "IN"]]:
|
||||
val = int(self.vm.get(f"option.buffer.{driver.lower()}"))
|
||||
val = int(self.window.vm.get(f"option.buffer.{driver.lower()}"))
|
||||
self.window.nvda.speak(f"{driver} BUFFER {val if val else 'default'}")
|
||||
case [["BUFFER", driver], ["KEY", "SPACE" | "ENTER"]]:
|
||||
util.open_context_menu_for_buttonmenu(popup, f"BUFFER {driver}")
|
||||
|
||||
@@ -141,12 +141,19 @@ def check_bounds(val, bounds: tuple) -> int | float:
|
||||
return val
|
||||
|
||||
|
||||
def get_slider_params(i, vm) -> Iterable:
|
||||
if i < vm.kind.phys_in:
|
||||
if vm.kind.name == "basic":
|
||||
def get_slider_params(i, kind) -> Iterable:
|
||||
if i < kind.phys_in:
|
||||
if kind.name == "basic":
|
||||
return ("AUDIBILITY",)
|
||||
if vm.kind.name == "banana":
|
||||
if kind.name == "banana":
|
||||
return ("COMP", "GATE")
|
||||
if vm.kind.name == "potato":
|
||||
if kind.name == "potato":
|
||||
return ("COMP", "GATE", "DENOISER")
|
||||
return ("BASS", "MID", "TREBLE")
|
||||
|
||||
|
||||
def get_full_slider_params(i, kind) -> Iterable:
|
||||
params = list(get_slider_params(i, kind) + ("GAIN", "LIMIT"))
|
||||
if kind.name == "basic":
|
||||
params.remove("LIMIT")
|
||||
return params
|
||||
|
||||
@@ -50,7 +50,7 @@ class NVDAVMWindow(psg.Window):
|
||||
[self[f"PATCH COMPOSITE||PC{i + 1}"].Widget.config(**buttonmenu_opts) for i in range(self.kind.phys_out)]
|
||||
slider_opts = {"takefocus": 1, "highlightthickness": 1}
|
||||
for i in range(self.kind.num_strip):
|
||||
for param in util.get_slider_params(i, self.vm):
|
||||
for param in util.get_slider_params(i, self.kind):
|
||||
self[f"STRIP {i}||SLIDER {param}"].Widget.config(**slider_opts)
|
||||
self[f"STRIP {i}||SLIDER GAIN"].Widget.config(**slider_opts)
|
||||
if self.kind.name != "basic":
|
||||
@@ -109,7 +109,7 @@ class NVDAVMWindow(psg.Window):
|
||||
self[f"STRIP {i}||SLIDER GAIN"].update(value=self.vm.strip[i].gain)
|
||||
if self.kind.name != "basic":
|
||||
self[f"STRIP {i}||SLIDER LIMIT"].update(value=self.vm.strip[i].limit)
|
||||
for param in util.get_slider_params(i, self.vm):
|
||||
for param in util.get_slider_params(i, self.kind):
|
||||
if param in ("AUDIBILITY", "BASS", "MID", "TREBLE"):
|
||||
val = getattr(self.vm.strip[i], param.lower())
|
||||
else:
|
||||
@@ -148,16 +148,18 @@ class NVDAVMWindow(psg.Window):
|
||||
self.bind("<Control-o>", "CTRL-O")
|
||||
self.bind("<Control-s>", "CTRL-S")
|
||||
self.bind("<Control-m>", "CTRL-M")
|
||||
|
||||
self.bind("<Control-g>", "GAIN MODE")
|
||||
self.bind("<Control-b>", "BASS MODE")
|
||||
self.bind("<Control-i>", "MID MODE")
|
||||
self.bind("<Control-r>", "TREBLE MODE")
|
||||
if self.kind.name == "basic":
|
||||
self.bind("<Control-u>", "AUDIBILITY MODE")
|
||||
self.bind("<Control-g>", "GAIN MODE")
|
||||
elif self.kind.name == "banana":
|
||||
self.bind("<Control-g>", "GAIN MODE")
|
||||
self.bind("<Control-c>", "COMP MODE")
|
||||
self.bind("<Control-t>", "GATE MODE")
|
||||
self.bind("<Control-l>", "LIMIT MODE")
|
||||
else:
|
||||
self.bind("<Control-g>", "GAIN MODE")
|
||||
self.bind("<Control-c>", "COMP MODE")
|
||||
self.bind("<Control-t>", "GATE MODE")
|
||||
self.bind("<Control-d>", "DENOISER MODE")
|
||||
@@ -231,9 +233,7 @@ class NVDAVMWindow(psg.Window):
|
||||
|
||||
# Strip Sliders
|
||||
for i in range(self.kind.num_strip):
|
||||
for param in util.get_slider_params(i, self.vm) + ("GAIN", "LIMIT"):
|
||||
if self.kind.name == "basic" and param == "LIMIT":
|
||||
continue
|
||||
for param in util.get_full_slider_params(i, self.kind):
|
||||
self[f"STRIP {i}||SLIDER {param}"].bind("<FocusIn>", "||FOCUS IN")
|
||||
self[f"STRIP {i}||SLIDER {param}"].bind("<FocusOut>", "||FOCUS OUT")
|
||||
self[f"STRIP {i}||SLIDER {param}"].bind("<Left>", "||KEY LEFT")
|
||||
@@ -291,12 +291,12 @@ class NVDAVMWindow(psg.Window):
|
||||
self.logger.debug(f"values::{values}")
|
||||
if event in (psg.WIN_CLOSED, "Exit"):
|
||||
break
|
||||
elif event in ("GAIN MODE", "COMP MODE", "GATE MODE", "DENOISER MODE", "LIMIT MODE"):
|
||||
elif event.endswith("MODE"):
|
||||
mode = event
|
||||
self.nvda.speak(f"{mode} enabled")
|
||||
elif event == "Escape:27":
|
||||
if mode:
|
||||
self.nvda.speak(f"{mode.split()[0]} mode disabled")
|
||||
self.nvda.speak(f"{mode} disabled")
|
||||
mode = None
|
||||
|
||||
if mode:
|
||||
@@ -372,83 +372,55 @@ class NVDAVMWindow(psg.Window):
|
||||
if focus := self.find_element_with_focus():
|
||||
identifier, param = focus.Key.split("||")
|
||||
self.write_event_value(f"{identifier}||MUTE", None)
|
||||
case ["SLIDER-MODE-LEFT"]:
|
||||
case [
|
||||
"SLIDER-MODE-LEFT"
|
||||
| "SLIDER-MODE-RIGHT"
|
||||
| "SLIDER-MODE-SHIFT-LEFT"
|
||||
| "SLIDER-MODE-SHIFT-RIGHT"
|
||||
| "SLIDER-MODE-CTRL-LEFT"
|
||||
| "SLIDER-MODE-CTRL-RIGHT" as op
|
||||
]:
|
||||
if values["tabgroup"] not in ("tab||Physical Strip", "tab||Virtual Strip", "tab||Buses"):
|
||||
continue
|
||||
param = values[event]
|
||||
if focus := self.find_element_with_focus():
|
||||
identifier, partial = focus.Key.split("||")
|
||||
if "SLIDER" not in partial:
|
||||
self.write_event_value(f"{identifier}||SLIDER {param}||KEY LEFT", None)
|
||||
case ["SLIDER-MODE-RIGHT"]:
|
||||
if values["tabgroup"] not in ("tab||Physical Strip", "tab||Virtual Strip", "tab||Buses"):
|
||||
continue
|
||||
param = values[event]
|
||||
if focus := self.find_element_with_focus():
|
||||
identifier, partial = focus.Key.split("||")
|
||||
if "SLIDER" not in partial:
|
||||
self.write_event_value(f"{identifier}||SLIDER {param}||KEY RIGHT", None)
|
||||
case ["SLIDER-MODE-SHIFT-LEFT"]:
|
||||
if values["tabgroup"] not in ("tab||Physical Strip", "tab||Virtual Strip", "tab||Buses"):
|
||||
continue
|
||||
param = values[event]
|
||||
if focus := self.find_element_with_focus():
|
||||
identifier, partial = focus.Key.split("||")
|
||||
if "SLIDER" not in partial:
|
||||
self.write_event_value(f"{identifier}||SLIDER {param}||KEY SHIFT LEFT", None)
|
||||
case ["SLIDER-MODE-SHIFT-RIGHT"]:
|
||||
if values["tabgroup"] not in ("tab||Physical Strip", "tab||Virtual Strip", "tab||Buses"):
|
||||
continue
|
||||
param = values[event]
|
||||
if focus := self.find_element_with_focus():
|
||||
identifier, partial = focus.Key.split("||")
|
||||
if "SLIDER" not in partial:
|
||||
self.write_event_value(f"{identifier}||SLIDER {param}||KEY SHIFT RIGHT", None)
|
||||
case ["SLIDER-MODE-CTRL-LEFT"]:
|
||||
if values["tabgroup"] not in ("tab||Physical Strip", "tab||Virtual Strip", "tab||Buses"):
|
||||
continue
|
||||
param = values[event]
|
||||
if focus := self.find_element_with_focus():
|
||||
identifier, partial = focus.Key.split("||")
|
||||
if "SLIDER" not in partial:
|
||||
self.write_event_value(f"{identifier}||SLIDER {param}||KEY CTRL LEFT", None)
|
||||
case ["SLIDER-MODE-CTRL-RIGHT"]:
|
||||
if values["tabgroup"] not in ("tab||Physical Strip", "tab||Virtual Strip", "tab||Buses"):
|
||||
continue
|
||||
param = values[event]
|
||||
if focus := self.find_element_with_focus():
|
||||
identifier, partial = focus.Key.split("||")
|
||||
if "SLIDER" not in partial:
|
||||
self.write_event_value(f"{identifier}||SLIDER {param}||KEY CTRL RIGHT", None)
|
||||
_, index = identifier.split()
|
||||
if param in util.get_full_slider_params(int(index), self.kind):
|
||||
if "SLIDER" not in partial:
|
||||
op = op.removeprefix("SLIDER-MODE-").split("-")
|
||||
self.write_event_value(f"{identifier}||SLIDER {param}||KEY {' '.join(op)}", None)
|
||||
|
||||
# Rename popups
|
||||
case ["F2:113"]:
|
||||
tab = values["tabgroup"].split("||")[1]
|
||||
if tab in ("Physical Strip", "Virtual Strip", "Buses"):
|
||||
data = self.popup.rename("Label", title=f"Rename {tab}", tab=tab)
|
||||
if not data: # cancel was pressed
|
||||
continue
|
||||
index = int(data["Index"]) - 1
|
||||
match tab:
|
||||
case "Physical Strip":
|
||||
label = data.get("Edit", f"Hardware Input {index + 1}")
|
||||
self.vm.strip[index].label = label
|
||||
self[f"STRIP {index}||LABEL"].update(value=label)
|
||||
self.cache["labels"][f"STRIP {index}||LABEL"] = label
|
||||
case "Virtual Strip":
|
||||
index += self.kind.phys_in
|
||||
label = data.get("Edit", f"Virtual Input {index - self.kind.phys_in + 1}")
|
||||
self.vm.strip[index].label = label
|
||||
self[f"STRIP {index}||LABEL"].update(value=label)
|
||||
self.cache["labels"][f"STRIP {index}||LABEL"] = label
|
||||
case "Buses":
|
||||
if index < self.kind.phys_out:
|
||||
label = data.get("Edit", f"Physical Bus {index + 1}")
|
||||
else:
|
||||
label = data.get("Edit", f"Virtual Bus {index - self.kind.phys_out + 1}")
|
||||
self.vm.bus[index].label = label
|
||||
self[f"BUS {index}||LABEL"].update(value=label)
|
||||
self.cache["labels"][f"BUS {index}||LABEL"] = label
|
||||
if focus := self.find_element_with_focus():
|
||||
identifier, partial = focus.Key.split("||")
|
||||
_, index = identifier.split()
|
||||
index = int(index)
|
||||
data = self.popup.rename("Label", index, title=f"Rename", tab=tab)
|
||||
if not data: # cancel was pressed
|
||||
continue
|
||||
match tab:
|
||||
case "Physical Strip":
|
||||
label = data.get("Edit", f"Hardware Input {int(index) + 1}")
|
||||
self.vm.strip[int(index)].label = label
|
||||
self[f"STRIP {index}||LABEL"].update(value=label)
|
||||
self.cache["labels"][f"STRIP {index}||LABEL"] = label
|
||||
case "Virtual Strip":
|
||||
label = data.get("Edit", f"Virtual Input {int(index) + 1}")
|
||||
self.vm.strip[int(index)].label = label
|
||||
self[f"STRIP {index}||LABEL"].update(value=label)
|
||||
self.cache["labels"][f"STRIP {index}||LABEL"] = label
|
||||
case "Buses":
|
||||
if index < self.kind.phys_out:
|
||||
label = data.get("Edit", f"Physical Bus {int(index) + 1}")
|
||||
else:
|
||||
label = data.get("Edit", f"Virtual Bus {int(index) - self.kind.phys_out + 1}")
|
||||
self.vm.bus[int(index)].label = label
|
||||
self[f"BUS {index}||LABEL"].update(value=label)
|
||||
self.cache["labels"][f"BUS {index}||LABEL"] = label
|
||||
|
||||
# Menus
|
||||
case [["Restart", "Audio", "Engine"], ["MENU"]]:
|
||||
@@ -1023,8 +995,10 @@ class NVDAVMWindow(psg.Window):
|
||||
val += 1
|
||||
case "LEFT" | "DOWN":
|
||||
val -= 1
|
||||
self.vm.bus[int(index)].gain = util.check_bounds(val, (-60, 12))
|
||||
val = util.check_bounds(val, (-60, 12))
|
||||
self.vm.bus[int(index)].gain = val
|
||||
self[f"BUS {index}||SLIDER GAIN"].update(value=val)
|
||||
self.nvda.speak(str(val))
|
||||
case [
|
||||
["BUS", index],
|
||||
["SLIDER", "GAIN"],
|
||||
@@ -1051,7 +1025,8 @@ class NVDAVMWindow(psg.Window):
|
||||
val += 0.1
|
||||
case "LEFT" | "DOWN":
|
||||
val -= 0.1
|
||||
self.vm.bus[int(index)].gain = util.check_bounds(val, (-60, 12))
|
||||
val = util.check_bounds(val, (-60, 12))
|
||||
self.vm.bus[int(index)].gain = val
|
||||
self[f"BUS {index}||SLIDER GAIN"].update(value=val)
|
||||
self.nvda.speak(str(val))
|
||||
case [["BUS", index], ["SLIDER", "GAIN"], ["KEY", "CTRL", "SHIFT", "R"]]:
|
||||
|
||||
Reference in New Issue
Block a user