Running i3, keystrokes only go to one of two Pale Moon windows

Support and discussions for the x86/x64 Linux version of Pale Moon and specific Linux distribution questions related to the browser.

Moderator: trava90

Forum rules
If your question is about general use of the browser and not specific to Linux, then please use the General Support board.
Post Reply
eater
Hobby Astronomer
Hobby Astronomer
Posts: 25
Joined: 2017-05-13, 21:31

Running i3, keystrokes only go to one of two Pale Moon windows

Post by eater » 2020-09-01, 16:20

I posted about this last year but it's happening more often and it's driving me crazy! I'd love to find some kind of fix.

I'm running the i3 window manager. Often, when I open a second Pale Moon window, for instance the Amazon customer support chat window, I get this weird glitch. While the chat window is open, if I focus my original Pale Moon window and start typing, everything I type into goes to the chat window instead of the one that's focused. Even if the two windows are on different workspaces.

It's extremely annoying and it doesn't happen with any other application, only Pale Moon.

User avatar
Moonchild
Pale Moon guru
Pale Moon guru
Posts: 27896
Joined: 2011-08-28, 17:27
Location: Tranås, SE
Contact:

Re: Running i3, keystrokes only go to one of two Pale Moon windows

Post by Moonchild » 2020-09-01, 16:26

So what makes you think this is a problem in the browser and not in the window manager? (perhaps the window manager has special treatment for "known" browsers?)
"There will be times when the position you advocate, no matter how well framed and supported, will not be accepted by the public simply because you are who you are." -- Merrill Rose
Image

eater
Hobby Astronomer
Hobby Astronomer
Posts: 25
Joined: 2017-05-13, 21:31

Re: Running i3, keystrokes only go to one of two Pale Moon windows

Post by eater » 2020-09-01, 16:35

Moonchild wrote:
2020-09-01, 16:26
So what makes you think this is a problem in the browser and not in the window manager? (perhaps the window manager has special treatment for "known" browsers?)
I checked first with the maintainers of the window manager. It doesn't have anything like that.

vannilla
Board Warrior
Board Warrior
Posts: 1140
Joined: 2018-05-05, 13:29

Re: Running i3, keystrokes only go to one of two Pale Moon windows

Post by vannilla » 2020-09-01, 17:13

Another possibility is that GTK for some reason is not handling the event sent by the window manager properly; or the opposite, i.e. the window manager sends junk events instead of what used to be sent while GTK 2 was still being maintained.

User avatar
Moonchild
Pale Moon guru
Pale Moon guru
Posts: 27896
Joined: 2011-08-28, 17:27
Location: Tranås, SE
Contact:

Re: Running i3, keystrokes only go to one of two Pale Moon windows

Post by Moonchild » 2020-09-01, 17:34

I'm open to the possibility that it might be something on the browser side... somehow, but it's extremely unlikely. The browser side simply responds to whatever events are sent to whatever window it is being told by the OS the events are for; I don't think there is any decision logic in that respect on our end.
"There will be times when the position you advocate, no matter how well framed and supported, will not be accepted by the public simply because you are who you are." -- Merrill Rose
Image

eater
Hobby Astronomer
Hobby Astronomer
Posts: 25
Joined: 2017-05-13, 21:31

Re: Running i3, keystrokes only go to one of two Pale Moon windows

Post by eater » 2020-09-01, 18:41

Could it be a combination, something about how PM identifies its windows to the WM? I don't know.

Any tips for trying to figure it out? Thanks!

vannilla
Board Warrior
Board Warrior
Posts: 1140
Joined: 2018-05-05, 13:29

Re: Running i3, keystrokes only go to one of two Pale Moon windows

Post by vannilla » 2020-09-01, 19:04

How do you move focus between windows?

eater
Hobby Astronomer
Hobby Astronomer
Posts: 25
Joined: 2017-05-13, 21:31

Re: Running i3, keystrokes only go to one of two Pale Moon windows

Post by eater » 2020-09-01, 19:14

vannilla wrote:
2020-09-01, 19:04
How do you move focus between windows?
Usually with the mouse, in "focus follows mouse" mode. Even when the correct Pale Moon window has focus, the keystrokes go to the unfocused window.

vannilla
Board Warrior
Board Warrior
Posts: 1140
Joined: 2018-05-05, 13:29

Re: Running i3, keystrokes only go to one of two Pale Moon windows

Post by vannilla » 2020-09-01, 19:51

Can you try disabling it and move focus in other ways, e.g. by clicking on the window?
I don't know how many other methods to move focus are available in i3 as I don't use it, but you should try every possible method and see if it works.

User avatar
Moonchild
Pale Moon guru
Pale Moon guru
Posts: 27896
Joined: 2011-08-28, 17:27
Location: Tranås, SE
Contact:

Re: Running i3, keystrokes only go to one of two Pale Moon windows

Post by Moonchild » 2020-09-01, 20:19

eater wrote:
2020-09-01, 19:14
Usually with the mouse, in "focus follows mouse" mode.
Aha, that's most likely why this happens, then. Unless the WM actually sends a signal to the individual window that focus is changing (as opposed to just raising the window internally for display, and limiting these signals to just different applications), Pale Moon won't see the focus change and will think the focus is still on the first-hovered-over window when application focus changed. That would actually be a bug in the WM in that particular mode, if so. Perhaps the devs of the WM never considered multi-window applications (that are still a single process)?
"There will be times when the position you advocate, no matter how well framed and supported, will not be accepted by the public simply because you are who you are." -- Merrill Rose
Image

eater
Hobby Astronomer
Hobby Astronomer
Posts: 25
Joined: 2017-05-13, 21:31

Re: Running i3, keystrokes only go to one of two Pale Moon windows

Post by eater » 2020-09-01, 20:28

Interesting. And clicking the window also wouldn't reset its focus properly? Is there a way I can check which of its windows Pale Moon thinks is focused?

vannilla
Board Warrior
Board Warrior
Posts: 1140
Joined: 2018-05-05, 13:29

Re: Running i3, keystrokes only go to one of two Pale Moon windows

Post by vannilla » 2020-09-01, 20:36

eater wrote:
2020-09-01, 20:28
And clicking the window also wouldn't reset its focus properly?
They are two different things.
Well, visually they look the same, but internally they are considered different and that's why this bug happens.
You should contact the i3 developers and reference Moonchild's post.
About checking which window has focus, by design the focused window is the one that receives keyboard events ("design" being the fact that the keyboard is one and can send key presses only to one window at a time.)
Just to clarify, I'm talking about generic graphical applications using the X protocol here, not about Pale Moon in particular.

eater
Hobby Astronomer
Hobby Astronomer
Posts: 25
Joined: 2017-05-13, 21:31

Re: Running i3, keystrokes only go to one of two Pale Moon windows

Post by eater » 2020-09-01, 20:53

To be clear, if I focus the window with the mouse, by clicking it, or by selecting it with the keyboard, the issue is the same.

When I click a button or link in the second Pale Moon window, it responds to the click normally, but if I start typing, the words I type show up in the first Pale Moon window.

User avatar
Moonchild
Pale Moon guru
Pale Moon guru
Posts: 27896
Joined: 2011-08-28, 17:27
Location: Tranås, SE
Contact:

Re: Running i3, keystrokes only go to one of two Pale Moon windows

Post by Moonchild » 2020-09-01, 21:04

That wouldn't be so strange, because you can send clicks to a window that doesn't have focus. It's not like all other windows become non-responsive if they are on screen but not the focused one.
"There will be times when the position you advocate, no matter how well framed and supported, will not be accepted by the public simply because you are who you are." -- Merrill Rose
Image

eater
Hobby Astronomer
Hobby Astronomer
Posts: 25
Joined: 2017-05-13, 21:31

Re: Running i3, keystrokes only go to one of two Pale Moon windows

Post by eater » 2020-09-01, 21:14

vannilla wrote:
2020-09-01, 20:36
eater wrote:
2020-09-01, 20:28
And clicking the window also wouldn't reset its focus properly?
They are two different things.
Well, visually they look the same, but internally they are considered different and that's why this bug happens.
Sorry, what are two different things? Mousing over and clicking? They have the same effect in terms of this issue as far as I can tell.

Post Reply