web: pass Ctrl-= through to browser for font size increase#1713
web: pass Ctrl-= through to browser for font size increase#1713
Conversation
Agent-Logs-Url: https://github.com/solvespace/solvespace/sessions/5adeab0f-ee43-4436-afa4-2f332ce0eb7d Co-authored-by: phkahler <[email protected]>
|
@copilot Why do you think CTRL - works but CRTL = need this change? |
The difference is in how each key is handled inside
} else if(event.chr == '=') {
// Treat = as +.
MenuView(Command::ZOOM_IN);
return true;
}This fires for both bare The fix in |
phkahler
left a comment
There was a problem hiding this comment.
This should work. Another option would be to add a condition to the code that converts "=" to a zoom in menu action (normally "+") to check that the CTRL key is not pressed. This would prevent consumption of the keypress event when CTRL is pressed and return false to the caller, letting the browser handle it.
|
Probably the other option would have been cleaner, but this is minimal and non-intrusive. |
|
Its been 3 hours since I pushed and this doesn't seem to do anything. ;-( |
|
@phkahler yes, it has not updated (the easiest way to check is I do not know why. Perhaps a rate limiting logic @jwesthues put in? The CI ran normally and the site responded "good" https://github.com/solvespace/solvespace/actions/runs/24147131706/job/70465587468#step:6:77 The time stamp is "Wed Apr 8 13:00:03 EDT 2026" The problem is I'm not on a PC and I do not know how to check exact commit time stamps on GitHub. |
|
Weird, and not any deliberate rate limiting and not the Cloudflare cache. The CI says it succeeded at 09:55 PDT = 12:55 EDT, /pull-webver.pl got hit at 12:55:41 EDT, and the download happened at 13:00:03 EDT per above; so those all seem correct. Is it possible that the download doesn't work immediately after the CI completes and I need to deliberately wait? I see some unofficial reports of delays in GitHub's CDN. I re-triggered the download and it worked this time. I've added more logging so that I can debug this better if/when it recurs, but haven't added the delay yet. |
Ctrl-=(the no-Shift convention for Ctrl-plus) was intercepted by SolveSpace's canvas zoom-in handler, blocking the browser from using it to increase font size.Ctrl-minusalready passed through unblocked because the ZOOM_OUT accelerator is bound to bare-(no Ctrl), so the match failed andEM_FALSEwas returned — butCtrl-=had a special-case handler inGraphicsWindow::KeyboardEventthat matched regardless of Ctrl state.Change
Added an early-exit in
KeyboardCallback(guihtml.cpp) before any event processing:=without Ctrl continues to trigger canvas zoom-in as before.