On May 7, 2013, at 21:00:00, Allan Odgaard <lists+cocoa-...@simplit.com> wrote:
> TextMate’s implementation is here > https://github.com/textmate/textmate/blob/master/Frameworks/OakAppKit/src/NSMenuItem%20Additions.mm#L170-L189 > and sets the title as an attributed string using an NSTextTableBlock to have > the key equivalent string show as the second column. This is fairly > unobtrusive and the only (user visible) shortcoming I have found is that it > doesn’t left/right align the key/modifier glyphs and writes out F1-Fn instead > of using the special glyphs for these keys. Allan, I've tried using your approach, which works better than what we did before (setting the title to "Do Something numpad1", so it was never even close to being in the key equiv column). But what do you do about having the actual keyEquivalent set? If I leave that set at, for instance, command-1, it draws to the right of my attributed title. Do you clear the key equiv from menu items and use your own key equiv lookup elsewhere? -- Steve Mills office: 952-818-3871 home: 952-401-6255 cell: 612-803-6157 _______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com