Closed djdv closed 3 years ago
it's possible that building gdlv with go build -tags=nucular_gio
will fix both problems, as quick a workaround.
It seems so. Using gio, the layout is preserved through minimize, and drawing seems to be instant while resizing.
Is your CPU made by AMD?
Currently using an Intel i7 8086K for the CPU, and an Nvidia GTX 970 for graphics.
Fixed the resize issue on the shiny backend and made the gio backend default on windows.
@aarzilli Thanks for that :^) However, I noticed a new issue. When using gio as the backend with gdlv, the default keybinds, F5, F10, etc. don't seem to work, as they did with the shiny backend. If you want, I can open a seperate issue for that.
Also a minor thing, the nucular README needs to be updated: https://github.com/aarzilli/nucular/commit/7376405f445445bfd5bb03901a544210d1f362f9#commitcomment-47463203
Try now.
Closer! The F keys are detected now but there seems to be an issue that requires them to be pressed twice. Random thoughts: I'm not sure if it's related to losing focus on one of the panes, or something to do with how the event queue is handled. If I hit an F key, then click the window, then hit an F key again, it, works every time. Otherwise I have to press the F key twice. Example: https://youtu.be/M8S-JeDIRd4
It seems that it's specifically F10, it's focusing the titlebar menu. If you press F10 followed by the down arrow you'll see it.
If you change vendor/gioui.org/app/internal/window/os_windows.go and add this
if msg == windows.WM_SYSKEYDOWN && wParam == windows.VK_F10 {
return 0
}
on line 250 (at the end of the case where windows.WM_SYSKEYDOWN is processed) it works.
Nice! With that change applied, F10 seems to no longer move the focus to the titlebar when using gio, and steps as expected. Thanks for helping me with this :^)
Is this something that should be changed upstream in Gio?
Without it, using Gio as the default backend for gdlv on Windows, combined with the default key bindings, seems a bit troublesome.
It seems like Gio would need to offer some means of providing a list of events to ignore/filter.
Abstractly something like gio.Ignore(windowsSystemBinding)
where the bindings are a list key-event message parameters that the GUI-program wants to use itself (like windows.VK_F10
).
Yes, however when I tried to apply the patch to the latest version of gio I've noticed that there are more problems with it (specifically with registering key presses) which I'll eventually have to investigate. Since there are other keybindings for step and step into I don't consider this a high priority.
Example: https://www.youtube.com/watch?v=vLXF9g-1O4k
I've been experiencing this for a while but wasn't sure what was causing it. Seems to be minimizing the window. If there's anything I can do to get more helpful information, let me know.
The environment is pretty standard, building 45df4efb18600788cffd3aa9ca3f57a0b4bbd2bf with Go 1.16 on Windows 10 (19042.804).