From: Po Lu <luangruo@yahoo.com>
To: Arthur Miller <arthur.miller@live.com>
Cc: Eli Zaretskii <eliz@gnu.org>, help-gnu-emacs@gnu.org
Subject: Re: Would there be a drawback of using the same graphical toolkit on every platform?
Date: Mon, 21 Feb 2022 09:10:29 +0800 [thread overview]
Message-ID: <87r17xhvne.fsf@yahoo.com> (raw)
In-Reply-To: <AM9PR09MB4977B3A648FDF69B0FE3DD4D96399@AM9PR09MB4977.eurprd09.prod.outlook.com> (Arthur Miller's message of "Sun, 20 Feb 2022 20:34:01 +0100")
Arthur Miller <arthur.miller@live.com> writes:
>> You can of course build dynamic menus out of the GMenu and
>> GMenuModel API. The things become slightly more complex if you have
>> extension points, like plugins, that add and remove menus and menu
>> items depending on whether they have been enabled or disabled at run
>> time. We lack a decent API for that.
That isn't an option. You cannot attach arbitrary data to such menus,
only a GVariant that can be serialized to disk (or stored in HTML).
The programmatic GMenu and GMenuModel API also leaves much else to be
desired. It is slow, involves recreating the menu bar widget every time
something changes, and makes it impossible to create menu elements such
as checkboxes which are possible in the XML-based API.
`hidden-when' isn't an option, since there is no way to record all the
information required for Emacs's very deeply nested menus.
After struggling with both interfaces in my GTK 4 port, I decided to
create two separate widgets, LwPopupMenu and LwMenuBar, which build
their menu contents dynamically based on the contents of a
`widget_value'. It cannot look and behave exactly like the native GTK 4
menus, is a lot of code to maintain (and it was already broken once by
the changes to layout processing in GTK 4.4), but it's the best that can
be done in GTK 4.
Meanwhile, the GtkMenu interface that we have used all the way back to
GTK+ 2.x works fine, but was deleted by the GTK developers for GTK 4.
>> AFAIR, @hergertme had some wrapper API for GNOME Builder; I think we
>> could expand the API in GIO to have a better story for extensible
>> menus.
I won't be convinced until I see such an expansion.
next prev parent reply other threads:[~2022-02-21 1:10 UTC|newest]
Thread overview: 128+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-02-18 20:59 Would there be a drawback of using the same graphical toolkit on every platform? emacsq via Users list for the GNU Emacs text editor
2022-02-18 22:23 ` Emanuel Berg via Users list for the GNU Emacs text editor
2022-02-19 3:21 ` emacsq via Users list for the GNU Emacs text editor
2022-02-19 3:38 ` Po Lu
2022-02-19 3:44 ` Po Lu
2022-02-19 4:10 ` emacsq
2022-02-19 4:52 ` Po Lu
2022-02-19 6:24 ` emacsq
2022-02-19 6:37 ` Po Lu
2022-02-19 14:57 ` Arthur Miller
2022-02-19 19:20 ` emacsq
2022-02-19 19:37 ` Eli Zaretskii
2022-02-20 1:10 ` Po Lu
2022-02-20 13:46 ` Arthur Miller
2022-02-20 14:00 ` Eli Zaretskii
2022-02-20 17:53 ` Arthur Miller
2022-02-20 18:08 ` Eli Zaretskii
2022-02-20 19:34 ` Arthur Miller
2022-02-21 1:10 ` Po Lu [this message]
2022-02-21 7:01 ` Po Lu
2022-02-21 16:50 ` Arthur Miller
2022-02-22 0:50 ` Po Lu
2022-02-23 11:53 ` Arthur Miller
2022-02-23 12:03 ` Po Lu
2022-02-23 18:34 ` Arthur Miller
2022-02-20 18:32 ` tomas
2022-02-20 18:57 ` Arthur Miller
2022-02-20 19:47 ` tomas
2022-02-21 1:18 ` Po Lu
2022-02-21 5:58 ` tomas
2022-02-21 1:13 ` Po Lu
2022-02-20 14:05 ` Po Lu
2022-02-20 18:40 ` Arthur Miller
2022-02-21 1:02 ` Po Lu
2022-02-21 19:34 ` Arthur Miller
2022-02-22 0:55 ` Po Lu
2022-02-21 13:53 ` Max Brieiev
2022-02-22 0:56 ` Po Lu
2022-02-22 12:00 ` Byung-Hee HWANG
2022-02-22 12:02 ` Po Lu
2022-02-22 12:33 ` Byung-Hee HWANG
2022-02-22 14:09 ` Jean Louis
2022-02-22 14:39 ` Byung-Hee HWANG
2022-02-22 14:05 ` Jean Louis
2022-02-20 14:12 ` Jean Louis
2022-02-20 16:46 ` Samuel Banya
2022-02-20 13:41 ` Sergey Organov
2022-02-20 13:54 ` Po Lu
2022-02-20 20:11 ` Byung-Hee HWANG
2022-02-19 7:29 ` Eli Zaretskii
2022-02-19 7:38 ` Emanuel Berg via Users list for the GNU Emacs text editor
2022-02-19 8:53 ` Eli Zaretskii
2022-02-19 9:09 ` Emanuel Berg via Users list for the GNU Emacs text editor
2022-02-19 9:26 ` Eli Zaretskii
2022-02-19 12:04 ` Emanuel Berg via Users list for the GNU Emacs text editor
2022-02-19 10:01 ` Pankaj Jangid
2022-02-19 13:59 ` Emanuel Berg via Users list for the GNU Emacs text editor
2022-02-19 17:54 ` Jean Louis
2022-02-19 22:42 ` Emanuel Berg via Users list for the GNU Emacs text editor
2022-02-20 12:39 ` Jean Louis
2022-02-27 1:20 ` Emanuel Berg via Users list for the GNU Emacs text editor
2022-02-19 17:51 ` Jean Louis
2022-02-19 17:56 ` Samuel Banya
2022-02-19 18:06 ` DragonFlyBSD Jean Louis
2022-02-19 22:48 ` DragonFlyBSD Emanuel Berg via Users list for the GNU Emacs text editor
2022-02-20 12:17 ` DragonFlyBSD Jean Louis
2022-02-21 5:51 ` DragonFlyBSD Emanuel Berg via Users list for the GNU Emacs text editor
2022-02-21 14:03 ` DragonFlyBSD Jean Louis
2022-02-21 15:22 ` DragonFlyBSD Samuel Banya
2022-02-21 18:18 ` DragonFlyBSD Jean Louis
2022-02-26 16:54 ` DragonFlyBSD Emanuel Berg via Users list for the GNU Emacs text editor
2022-02-26 16:49 ` DragonFlyBSD Emanuel Berg via Users list for the GNU Emacs text editor
2022-02-26 16:45 ` DragonFlyBSD Emanuel Berg via Users list for the GNU Emacs text editor
2022-02-27 2:53 ` DragonFlyBSD Samuel Banya
2022-02-27 2:59 ` DragonFlyBSD Emanuel Berg via Users list for the GNU Emacs text editor
2022-02-21 19:49 ` DragonFlyBSD Lele Gaifax
2022-02-26 16:55 ` DragonFlyBSD Emanuel Berg via Users list for the GNU Emacs text editor
2022-03-01 20:33 ` DragonFlyBSD Lele Gaifax
2022-03-01 22:08 ` DragonFlyBSD Emanuel Berg via Users list for the GNU Emacs text editor
2022-03-02 7:19 ` DragonFlyBSD Lele Gaifax
2022-03-02 19:44 ` DEOL: Declarative Emacs On-Line (was: Re: DragonFlyBSD) Emanuel Berg via Users list for the GNU Emacs text editor
2022-03-03 7:14 ` DEOL: Declarative Emacs On-Line Lele Gaifax
2022-03-04 2:28 ` Emanuel Berg via Users list for the GNU Emacs text editor
2022-02-19 22:44 ` Would there be a drawback of using the same graphical toolkit on every platform? Emanuel Berg via Users list for the GNU Emacs text editor
2022-02-20 12:42 ` Purposes of BSD-like systems Jean Louis
2022-02-20 12:56 ` Po Lu
2022-02-21 4:41 ` Emanuel Berg via Users list for the GNU Emacs text editor
2022-02-21 9:50 ` andrew
2022-02-26 16:41 ` Emanuel Berg via Users list for the GNU Emacs text editor
2022-02-21 14:04 ` Jean Louis
2022-02-26 16:39 ` Emanuel Berg via Users list for the GNU Emacs text editor
2022-02-19 18:08 ` Would there be a drawback of using the same graphical toolkit on every platform? Eli Zaretskii
2022-02-19 19:30 ` Jean Louis
2022-02-19 19:38 ` Eli Zaretskii
2022-02-19 22:55 ` Emanuel Berg via Users list for the GNU Emacs text editor
2022-02-20 0:40 ` Emanuel Berg via Users list for the GNU Emacs text editor
2022-02-20 12:21 ` Why is GNU not Unix-like system? Jean Louis
2022-02-20 13:00 ` Eli Zaretskii
2022-02-19 19:35 ` Would there be a drawback of using the same graphical toolkit on every platform? Jean Louis
2022-02-19 23:02 ` Emanuel Berg via Users list for the GNU Emacs text editor
2022-02-19 22:52 ` Emanuel Berg via Users list for the GNU Emacs text editor
2022-02-19 22:29 ` Emanuel Berg via Users list for the GNU Emacs text editor
2022-02-19 23:50 ` [External] : " Drew Adams
2022-02-20 0:21 ` Emanuel Berg via Users list for the GNU Emacs text editor
2022-02-20 0:31 ` Drew Adams
2022-02-20 6:49 ` Yuri Khan
2022-02-20 11:16 ` Jean Louis
2022-02-21 6:31 ` Emanuel Berg via Users list for the GNU Emacs text editor
2022-02-22 14:11 ` Lumpers & Splitter Jean Louis
2022-02-27 1:01 ` Emanuel Berg via Users list for the GNU Emacs text editor
2022-02-20 23:12 ` [External] : Re: Would there be a drawback of using the same graphical toolkit on every platform? Drew Adams
2022-02-21 6:32 ` Emanuel Berg via Users list for the GNU Emacs text editor
2022-02-21 16:10 ` Drew Adams
2022-02-27 1:15 ` Emanuel Berg via Users list for the GNU Emacs text editor
2022-02-22 14:12 ` Lumpers & Splitter Jean Louis
2022-02-27 0:55 ` Emanuel Berg via Users list for the GNU Emacs text editor
2022-02-20 11:09 ` [External] : Re: Would there be a drawback of using the same graphical toolkit on every platform? Jean Louis
2022-02-21 6:28 ` Emanuel Berg via Users list for the GNU Emacs text editor
2022-02-21 6:50 ` Emanuel Berg via Users list for the GNU Emacs text editor
2022-02-22 14:24 ` Jean Louis
2022-02-27 1:02 ` Emanuel Berg via Users list for the GNU Emacs text editor
2022-02-22 14:22 ` Jean Louis
2022-02-27 1:09 ` Emanuel Berg via Users list for the GNU Emacs text editor
2022-02-27 1:10 ` Emanuel Berg via Users list for the GNU Emacs text editor
2022-02-27 1:12 ` Emanuel Berg via Users list for the GNU Emacs text editor
2022-02-20 10:59 ` Jean Louis
2022-02-20 10:55 ` Jean Louis
2022-02-27 1:22 ` Emanuel Berg via Users list for the GNU Emacs text editor
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87r17xhvne.fsf@yahoo.com \
--to=luangruo@yahoo.com \
--cc=arthur.miller@live.com \
--cc=eliz@gnu.org \
--cc=help-gnu-emacs@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).