right aligned shortcut key in menu item

Started by czerny, August 18, 2014, 12:55:47 PM

Previous topic - Next topic

JohnF

That is exactly what that app does.

Note the "&Copy\tC"


AppendMenu(hSubMenu, MF_STRING, MENU_EDIT_CUT, TEXT("Cu&t\tCtrl+X"));
AppendMenu(hSubMenu, MF_STRING, MENU_EDIT_COPY, TEXT("&Copy\tC"));


John

czerny

Quote from: JohnF on August 19, 2014, 12:20:33 PM
That is exactly what that app does.

I have not compiled your SmallEd2 example and we have different looks. Doesn't that mean that it is OS dependent?

I am working here with XP SP3.

JohnF

Quote from: czerny on August 19, 2014, 12:41:32 PM
Quote from: JohnF on August 19, 2014, 12:20:33 PM
That is exactly what that app does.

I have not compiled your SmallEd2 example and we have different looks. Doesn't that mean that it is OS dependent?

I am working here with XP SP3.

Yes, I just tried it on an old XP - it is not working the same. Don't know what to suggest.

John

czerny

So the question arises: How can you left-align your shurtcuts?

Here (XP SP3) Pelles C ide shurtcuts are right-aligned and per example notepad is left-aligned. So there should be a difference. Do you have any differences?

Could anybody else try the SmallEd2 example and look at the edit menu?

czerny

#20
sprintf(MenuItem, "%s%cCtrl-X", "Example", 8); // works!
Though '\a' == 7 a value of 8 is working.
'\b' is working too!

jj2007

Ascii 7 doesn't work on XP SP3 (inserts a black dot),
8 means right-aligned,
9 means left-aligned.

Now the question is how it works on Win 7 + 8...

JohnF

On Win7 \t and \b work the same, right aligned.

John