Unoffical empeg BBS

Quick Links: Empeg FAQ | RioCar.Org | Hijack | BigDisk Builder | jEmplode | emphatic
Repairs: Repairs

Topic Options
#371405 - 24/11/2018 07:36 Is this problem with Ctrl-V a Webkit bug, or a Mac OS X bug?
tfabris
carpal tunnel

Registered: 20/12/1999
Posts: 31597
Loc: Seattle, WA

I've been having this interesting problem on Mac OS X when using Chrome. At first I thought it was isolated to Chrome, but I just checked and it also happens in Safari. Do any Mac experts know where this problem lies? Is it in Webkit, or is it somewhere in the operating system?

Background: Because I switch back and forth between OSX and Windows every day, I have remapped some common keyboard shortcuts so that I can (mostly) use the same shortcuts on both operating systems. The most common is copy/paste, ctrl-C and ctrl-V. These remaps work in most applications, but ctrl-V has stopped functioning correctly in Chrome and Safari in recent months.

What I'd like to do is to have some Mac experts help me narrow down the source of the problem so that I can either find a work-around, or find the correct person to report the bug to, since this is a regression.

Anyone interested in poking at this with me?


Steps:

Starting on Mac OS X...

Open System Preferences of the Mac OS X operating system.

Select "Keyboard".

Select the tab "Shortcuts".

Select on the left column "App Shortcuts".

Select "All Applications".

Press the "+" button to add a custom keyboard shortcut for "All Applications", for the menu title of "Copy" and the keyboard shortcut of control-C (will appear as "^C" once you have pressed the key combo). Press "Add".

Press the "+" button to add a custom keyboard shortcut for "All Applications", for the menu title of "Paste" and the keyboard shortcut of control-V (will appear as "^V" once yuo have pressed the key combo). Press "Add".

Now you have remapped "Copy" and "Paste" on the Mac to Ctrl-C and Ctrl-V.

Now attempt to use these items in either the Chrome or the Safari web browser.

Attempt to paste text using Ctrl-V at the top of an existing multiline text field which already contains some text.

EXAMPLE: Editing an email in Gmail, type some text, copy it to the clipboard, then move your cursor to the top of the email and try to paste the text ABOVE existing text in the email editing field using Control-V.

Expected: Text should paste a the top of the field.

Actual: Cursor jumps to the bottom of the field without pasting. Only if the cursor is already at the end of the field does the paste work.



Notes:

This used to work fine before, this behavior is new in the last couple of months.

I am not certain if the behavior changed when there was a Chrome update or when there was an OS X update. Since I rarely used Safari, I don't know if there was a period where Chrome had the problem and Safari didn't, or vice-versa. I only know that I noticed the problem starting at some point in Chrome, and put up with it for a couple of months before checking to see if the problem also happened in Safari.

The behavior is fine in other apps. For example try it in Mac OS "Text Edit" program and see that it works fine as expected.

This seems to be limited to web browser apps such as Chrome and Safari, making me suspect it's something new in WebKit.

Please don't respond with "you shouldn't be remapping these keys in the first place" since this method worked fine until recently (and still works fine in other apps). I'm trying to locate the source of the regression, not change the way I use the computer.

Please don't respond with "you should use the Modifier Keys feature of OS X instead of the remap feature", because using the Modifier Keys feature was the first thing I tried, when I first got the mac, and it was not sufficient for my needs. It caused more problems than it solved. Again, I'm trying to find the source of the regression here.



Can anyone help me narrow down where/why this issue is occurring?

Thanks!
_________________________
Tony Fabris

Top
#371406 - 24/11/2018 07:41 Re: Is this problem with Ctrl-V a Webkit bug, or a Mac OS X bug? [Re: tfabris]
tfabris
carpal tunnel

Registered: 20/12/1999
Posts: 31597
Loc: Seattle, WA
Some other useful pieces of information:

This user is describing something similar but it's for a program that I don't use. My guess it that his program uses the same underlying engine and thus is subject to the same bug.
https://github.com/jupyter/notebook/issues/4138

This is not related to the new OSX Mojave upgrade. I have been having the problem for a couple of months, and I only upgraded to Mojave last night, and it didn't fix or change the problem.
_________________________
Tony Fabris

Top
#371407 - 24/11/2018 08:21 Re: Is this problem with Ctrl-V a Webkit bug, or a Mac OS X bug? [Re: tfabris]
andy
carpal tunnel

Registered: 10/06/1999
Posts: 5916
Loc: Wivenhoe, Essex, UK
Chrome forked away from WebKit some time ago, so it seems unlikely that changes in WebKit are to blame.
_________________________
Remind me to change my signature to something more interesting someday

Top
#371408 - 25/11/2018 05:05 Re: Is this problem with Ctrl-V a Webkit bug, or a Mac OS X bug? [Re: andy]
tfabris
carpal tunnel

Registered: 20/12/1999
Posts: 31597
Loc: Seattle, WA
Interesting, thanks, that's great information.

I wonder if there is anything shared between the Chrome and Safari code bases. I also wonder if there might be other apps on the Mac platform that I can find which would exhibit the same bug. I'll poke around.
_________________________
Tony Fabris

Top
#371409 - 25/11/2018 05:25 Re: Is this problem with Ctrl-V a Webkit bug, or a Mac OS X bug? [Re: tfabris]
tfabris
carpal tunnel

Registered: 20/12/1999
Posts: 31597
Loc: Seattle, WA
Okay, it's a collision with an existing assignment to Ctrl-V, somewhere that I can't find, and only in certain apps, depending on their built-in implementation of whatever they think Ctrl-V should be.

Example: Remapping "Copy" to Ctrl-C always worked. So I know Ctrl-C is safe. If I remap "Paste" to Ctrl-C, it works fine. Pasting with the remapped key combination of Ctrl-C works as expected.

So the problem isn't copying and pasting, it's the particular key combination. I need to figure out how to find out what the normal thing for "Ctrl-V" is in certain apps and kill it there, perhaps by finding it in the menus and remapping it for those apps.

If I turn off remapping of the Ctrl-V key combination, it seems like the page scrolls when I press it. But I can't find anything for Ctrl-V in the menus of these apps.

Still poking at it.
_________________________
Tony Fabris

Top
#371410 - 25/11/2018 05:32 Re: Is this problem with Ctrl-V a Webkit bug, or a Mac OS X bug? [Re: tfabris]
tfabris
carpal tunnel

Registered: 20/12/1999
Posts: 31597
Loc: Seattle, WA
I'm thinking that at some point, certain apps including Chrome added a built-in keystroke of "Ctrl-V" for something like "Vertical Scroll", but only recently. I can't find Ctrl-V in their menus. Ideally I would find that menu item and remap it to swizzlestick-V, but since it's not a menu item I can't find it or remap it.

I still only reproduce the problem on Chrome and Safari, I can't find other apps that do it yet. But I'll bet they exist.
_________________________
Tony Fabris

Top
#371411 - 25/11/2018 06:11 Re: Is this problem with Ctrl-V a Webkit bug, or a Mac OS X bug? [Re: tfabris]
tfabris
carpal tunnel

Registered: 20/12/1999
Posts: 31597
Loc: Seattle, WA
I tried adding the Shortkeys extension to Chrome and telling it that "Ctrl-V" was "Do Nothing" and it didn't fix the issue unfortunately.
_________________________
Tony Fabris

Top