unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: "Mattias Engdegård" <mattiase@acm.org>
To: Alan Third <alan@idiocy.org>
Cc: 45502@debbugs.gnu.org, "Daniel Martín" <mardani29@yahoo.es>
Subject: bug#45502: [PATCH] Prettier key bindings in NS menu entries
Date: Tue, 29 Dec 2020 23:53:59 +0100	[thread overview]
Message-ID: <99CD03DA-DF1F-4C2C-A2FA-DFD7DF3B2750@acm.org> (raw)
In-Reply-To: <X+uelWP4QKMTPnC/@breton.holly.idiocy.org>

29 dec. 2020 kl. 22.24 skrev Alan Third <alan@idiocy.org>:

> I've pushed a small change. I also set the alloc'd objects to
> autorelease. We need to do that because when they're assigned to the
> NSMenuItem it will retain them, and because we alloc'd them we already
> have them retained once.
> 
> At least I hope that's right. For some reason I've found the
> retain/release cycle really hard to understand, but I think I'm
> getting there now.

Thanks! Is this the standard way of doing it? The objects that you marked autorelease (tab and pstyle) are only used for the extent of that method; I take it you prefer autorelease to sending them 'release' at the end of the method?

Presumably 'atitle' should be sent autorelease (or release) as well?

> I have no opinion on this, really. Although that is some ugly code! ;)

Oh yes, it should at least be table-driven in some way. 

> I think that might be confusing. It doesn't matter with most macOS
> apps because they don't differentiate between shortcuts with upper and
> lower case characters, but we do, and I feel as a seasoned Emacs user
> I'd see C-A and think that was actually C-S-a when it might be C-a.

Agreed. If we were to follow the macOS conventions fully then it would make sense to use ⌘K for M-k (if Command is Meta), but otherwise it's more likely to be confusing.






  reply	other threads:[~2020-12-29 22:53 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-12-28 14:23 bug#45502: [PATCH] Prettier key bindings in NS menu entries Mattias Engdegård
2020-12-28 18:36 ` Alan Third
2020-12-29 12:02   ` Mattias Engdegård
2020-12-29 13:53     ` Alan Third
2020-12-29 14:41       ` Mattias Engdegård
2020-12-29 15:50         ` Alan Third
2020-12-29 17:34           ` Mattias Engdegård
2020-12-29 21:24             ` Alan Third
2020-12-29 22:53               ` Mattias Engdegård [this message]
2020-12-29 23:49                 ` Alan Third
2020-12-30 12:19                   ` Mattias Engdegård
2020-12-30 12:46                     ` Alan Third
2020-12-30 13:09                       ` Alan Third
2020-12-30 15:53                         ` Mattias Engdegård
2020-12-30 13:12                       ` Mattias Engdegård
2020-12-28 22:46 ` Unknown

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=99CD03DA-DF1F-4C2C-A2FA-DFD7DF3B2750@acm.org \
    --to=mattiase@acm.org \
    --cc=45502@debbugs.gnu.org \
    --cc=alan@idiocy.org \
    --cc=mardani29@yahoo.es \
    /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.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

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).