emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: PGTK-related misconceptions


From: Po Lu
Subject: Re: PGTK-related misconceptions
Date: Wed, 20 Apr 2022 12:05:05 +0800
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.91 (gnu/linux)

Trey Peacock <gpg@treypeacock.com> writes:

>> See https://docs.gtk.org/gdk3/flags.ModifierType.html, which says:
>>
>>   Since 2.10, GDK recognizes which of the Meta, Super or Hyper keys are
>>   mapped to Mod2 - Mod5, and indicates this by setting GDK_SUPER_MASK,
>>   GDK_HYPER_MASK or GDK_META_MASK in the state field of key events.
>
> The capability to do something is not the same as a requirement.

It's the documented behavior of GDK, and Emacs holds GDK to its
documentation.  Nowhere does the documentation say this is a
"capability", "recognizes" is in the third-person present tense, which
makes it a requirement.

> I would be happy to help. Granted, this is only my second interaction on
> the mailing list, but I do want to contribute how I can.

Great, one step forward would be to bring up the issue with either the
GTK or Wayland compositor developers.  Since you've already talked with
the latter, and they say it's not their problem, please contact the
former.

> It is not GDK that is responsible for this. Further, since this is not
> required, I don't think its proper to deem it a bug.

It is, as specified in its documentation.

> Your change seems to have removed a fallback in case there were no
> virtual modifiers and reverses the previous logic:

As you can see by the name of the function, it was directly ported over
from X (the current version is in xterm.c), and is yet another example
of the PGTK port translating X Windows code to GDK verbatim, duplicating
what GDK is supposed to do itself.

I will not change Emacs because the GTK developers, yet again, forgot to
follow their own documentation when implementing some feature.  It just
makes Emacs code bloated, hard-to-follow and liable to break at the
slightest whim of the GTK developers, who then respond that we're not
using GTK "properly", because we try to work around their problems.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]