Open Kevinpgalligan opened 8 months ago
I would love to see this feature because Sketch is really annoying in my tiling window manager ... on every recompile the window is restarted and my window manager renders the window in a slightly different place (which is correct for my workflow).
Anyone know what it would take to implement this feature?
I've never been sure exactly how the window gets reinitialized. I imagine it's something to do with update-instance-for-redefined-class
- maybe sdl2kit provides an implementation of that method that recreates the window? I'll look into it when I get the chance.
I am learning Lisp and don't know enough to dig in to that level my self yet. I will try to help if I can.
Things to add:
:restart-on-redefinition nil
, so the window doesn't have to restart every time the defsketch is recompiled. If someone is just tweaking the drawing code, for example, or how the state gets updated (as opposed to adding new state), then they may not need to restart the window. Or even if they're adding new state, maybe they don't need to refresh (this might require ensuring that the newdraw
doesn't get called before any new slots are added).prepare
.close-on
) to manually trigger restarts.Together, these features would enable something closer to "true" interactive development.