How to pass keypresses through?

Apologies if this has been covered before.

I’d like to add some code to ZynZilla to allow it to pass keypresses through, so that every gui update doesn’t require a click on the waveform to hear the result. I imagine this is fairly simple to do, I just haven’t a clue how to do it.

Any coding wizards want to help? :mage:

It was fairly simple actually.

com.noisebeuter.ZynZilla.xrnx (11.5 KB)

thanks, but this file refuses to load for me for some reason.

What code did you add to it?

Rats of NIMH! Sorry about that. That’s most likely my fault.

In gui.lua I added a key_handler function and then passed it to show_custom_dialog:

  -- Key handler simply returns any key presses back to Renoise
  local function key_handler(dialog, key)
    return key
  end

  -- `key_handler` added to the tool's main dialog
  dialog = renoise.app():show_custom_dialog (
    "ZynZilla",
    dialog_content, 
    key_handler
  )

end
2 Likes

I don’t fully understand (not surprising)

Are both of these snippets of code inserted into the gui.lua file? Or is the key handler section added to main.lua?
If so, does it matter where? line numbers helpful/appreciated!

I’m also using the “fixed” version of zynzilla from this thread if that makes a difference: Could somebody please fix ZynZilla?

many thanks

Oh sorry about that. I figured since you asked for the code that was modified, that a snippet of what was done would be sufficient.

Anyway, I fixed the tool so it now installs. I’m still not super familiar with the creation process and I missed a step that messed everything up. Here it is again.

PS: I did base the change off of the “fixed” version.

com.noisebeuter.ZynZilla.xrnx (11.2 KB)

4 Likes

This is the best community ever.

3 Likes

Out of curiosity and being a newbie to the tools ecosystem, since this tool doesn’t seem to be officially maintained anymore, what would be the appropriate way for other devs to share ongoing development?

1 Like

Thank you very much!

1 Like
1 Like

Ah, this is fucking awesome. Thank you VERY much!

If you’re feeling ambitious and want to clean up a little bug - at least I think it’s a bug - when the user selects “wave” as the wave shape, zynzilla throws this error message:
Screen Shot 2023-01-04 at 6.28.30 PM

not a big deal, but it would be an improvement to have it cleaned up… IF you’re feeling ambitious.

Thanks again for the huge usability improvement here!!!

renoise community is the best

1 Like

I did notice that earlier…

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.