robbielyman / seamstress

seamstress is an art engine
GNU General Public License v3.0
123 stars 12 forks source link

PSETs #51

Closed dndrks closed 1 year ago

dndrks commented 1 year ago

this PR includes a migration of the PSET file mechanisms from norns, with seamstress-specific UI + state management 😃 @ryleelyman , i think this is pretty feature-complete, but please please lmk if there's anything i've overlooked / anything you want to behave differently!! <33

navigation

toggle the PSET menu with SHIFT + P:

image

use the left and right arrow keys to switch between SAVE, LOAD, and DELETE. use the up and down arrow keys to navigate the PSET list -- hold ALT to jump by 8 slots.

save

when SAVE is highlighted, press ENTER on any PSET slot to open a text field for naming it:

image

scripting

you can use params:write(number, string) to commit a preset to slot number using string name.

you can also specify params.action_write(filename, name, number) as a callback to this action in your script's init()

load

when LOAD is highlighted, press ENTER on any PSET slot to load it:

image

on successful read, pset >> read: <path_to_file>.pset will print to the console

scripting

you can use:

you can also specify params.action_read(filename, name, number, silent) as a callback to this action in your script's init()

delete

when DELETE is highlighted, press ENTER on any PSET slot to queue it for deletion, which requires secondary confirmation:

image

scripting

you can use:

you can also specify params.action_delete(filename, name, number) as a callback to this action in your script's init()

data management

I've also added seamstress.state.data, which is an alias for path.seamstress .. "/data/" .. seamstress.state.name .."/").

further: