[vim/vim] w32: Don't treat Ctrl+Alt as AltGr (PR #10308)

88 views
Skip to first unread message

LemonBoy

unread,
Apr 28, 2022, 3:36:11 AM4/28/22
to vim/vim, Subscribed

Users expect the two keys not to be combined into AltGr despite every
other Windows application doing so.

Reported by Axel Bender on vim_dev:
https://groups.google.com/g/vim_dev/c/4AMbHGkWWGU


You can view, comment on, or merge this pull request online at:

  https://github.com/vim/vim/pull/10308

Commit Summary

  • eb1c8a8 w32: Don't treat Ctrl+Alt as AltGr

File Changes

(1 file)

Patch Links:


Reply to this email directly, view it on GitHub.
You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/10308@github.com>

codecov[bot]

unread,
Apr 28, 2022, 3:48:20 AM4/28/22
to vim/vim, Subscribed

Codecov Report

Merging #10308 (eb1c8a8) into master (95e4dd8) will increase coverage by 1.46%.
The diff coverage is n/a.

@@            Coverage Diff             @@

##           master   #10308      +/-   ##

==========================================

+ Coverage   81.00%   82.46%   +1.46%     

==========================================

  Files         161      148      -13     

  Lines      185621   171691   -13930     

  Branches    41969    38825    -3144     

==========================================

- Hits       150362   141587    -8775     

+ Misses      22737    17495    -5242     

- Partials    12522    12609      +87     
Flag Coverage Δ
huge-clang-none 82.46% <ø> (-0.01%) ⬇️
linux 82.46% <ø> (-0.01%) ⬇️
mingw-x64-HUGE ?
mingw-x64-HUGE-gui ?
windows ?

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
src/highlight.c 78.57% <0.00%> (-2.67%) ⬇️
src/time.c 86.93% <0.00%> (-2.38%) ⬇️
src/buffer.c 84.08% <0.00%> (-2.36%) ⬇️
src/misc2.c 86.55% <0.00%> (-2.34%) ⬇️
src/help.c 79.89% <0.00%> (-2.20%) ⬇️
src/libvterm/src/screen.c 51.96% <0.00%> (-2.04%) ⬇️
src/session.c 62.83% <0.00%> (-2.01%) ⬇️
src/menu.c 81.02% <0.00%> (-1.87%) ⬇️
src/gui.c 71.18% <0.00%> (-1.84%) ⬇️
src/if_py_both.h 75.18% <0.00%> (-1.76%) ⬇️
... and 132 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 95e4dd8...eb1c8a8. Read the comment docs.


Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/10308/c1111860182@github.com>

Bram Moolenaar

unread,
Apr 28, 2022, 11:56:25 AM4/28/22
to vim/vim, Subscribed

Does the behavior perhaps depend on the type of keyboard? Or keyboard setting?


Reply to this email directly, view it on GitHub.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/10308/c1112378380@github.com>

LemonBoy

unread,
Apr 28, 2022, 1:38:50 PM4/28/22
to vim/vim, Subscribed

Does the behavior perhaps depend on the type of keyboard? Or keyboard setting?

Yes, this article briefly explains the current state of the affairs. In a previous PR I've made Ctrl+Alt behave as AltGr, streamlining gVim behaviour with Windows, assuming that no one would use this kind of mappings. But alas, I was wrong, and this PR reverts to the old behaviour.


Reply to this email directly, view it on GitHub.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/10308/c1112487082@github.com>

Bram Moolenaar

unread,
Apr 28, 2022, 2:51:40 PM4/28/22
to vim/vim, Subscribed

Closed #10308 via 202b4bd.


Reply to this email directly, view it on GitHub.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/10308/issue_event/6517529298@github.com>

Staffan Thomén

unread,
Jul 9, 2022, 9:33:51 AM7/9/22
to vim/vim, Subscribed

Well, this completely screwed me over. Can users perhaps also expect Ctrl+Alt to work as every other windows application?


Reply to this email directly, view it on GitHub.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/10308/c1179546197@github.com>

Bram Moolenaar

unread,
Jul 9, 2022, 4:26:16 PM7/9/22
to vim/vim, Subscribed

Read back: It was attempted to make CTRL-Alt work like AltGr, but it caused too many problems.

I don't know why you would need to use for CTRL-Alt, missing the AltGr key? Then isn't the rest of the effect missing on the keyboard as well? Perhaps users are just typing blindly.


Reply to this email directly, view it on GitHub.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/10308/c1179601775@github.com>

Staffan Thomén

unread,
Jul 10, 2022, 4:26:26 AM7/10/22
to vim/vim, Subscribed

I see. Can I enquire to what problems were caused by this? Binding Ctrl+Alt+something is obviously a problem, but what else?

My need for Ctrl+Alt acting as AltGr is that in my setup I can't use the AltGr key. I have two computers on my desktop with one keyboard and mouse. The keyboard is connected to my SGI Octane, and then I use an old version of Synergy (pretty much the last one before they closed sourced it) to connect the Octane to a regular windows PC enabling me to just slide the mouse cursor across to the other screen to send input to that system. Synergy doesn't send the right keycode for AltGr so that key is unusable but it wasn't a problem since Ctrl+Alt did the same thing.

I could possibly patch Synergy or put the octane on a shelf, but having vim act like every other windows program didn't seem too outlandish to me.


Reply to this email directly, view it on GitHub.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/10308/c1179682121@github.com>

Reply all
Reply to author
Forward
0 new messages