Re: How to set menu shortcuts, and fonts?



On Thu, 14 Feb 2008 16:45:06 -0800, Norman Diamond <ndiamond@xxxxxxxxxxxxxxxx> wrote:

OK, for comparison, here's a screenshot of a Microsoft application under
Windows XP. Notice that the shortcuts are in their normal position in
parentheses after each menu title name:
http://www.geocities.jp/hitotsubishi/xp_shortcuts.png

"Normal" for whom? It's normal for character-based languages, because the letters used for the shortcuts aren't part of the language. But it's not normal for the vast majority of the people reading your message.

The only way to do European-style shortcuts is to use names that contain
only Italian characters.

What's Italian got to do with it? Do you mean Roman letters, the un-accented characters used in a wide variety of Western languages?

While I haven't used Vista very much at all, I would be _extremely_ surprised if Microsoft changed the basic behavior of formatting a string with an underscore when a letter is preceded by the '&' in control names and menu items. It is such a basic part of the operating system behavior that to change it would be crazy.

Then be surprised.

Why? You've yet to demonstrate that using an '&' character in a string for menu and control text in Vista doesn't provide the usual underlining in appropriate situations.

All you've shown is that it's possible for the underlining to not be visible at all times. But XP can do this too, and it's a matter of user configuration, not of programming practice. So that doesn't prove anything.

Look at the screenshot that I posted yesterday. There are a ton of other surprises waiting for you too. Enough other people have already found enough surprises so that vendors persuaded Microsoft to let vendors continue offering XP to customers who can't stand Me2.

Ah. I see. It seems this is less about you wanting help with your program, and more about you wanting to rant about Vista.

There is no such operating system as "Windows Me2". You cannot expect to be taken seriously as someone who warrants attention and help if you insist on taking your rants so far that you can't be bothered to write the actual name of the operating system.

I can believe that the default user configuration is to not show the underscores unless the Alt key is pressed,

That is *not* the default.

Apparently, it is. If it weren't, wouldn't you be getting underlines for shortcut key letters?

Again look at the screenshot that I posted today.

The screenshot you posted today doesn't include any underlined characters. How does that dispute the suggestion that in Vista the default is to not show underlined characters?

Oh wait. In XP that isn't the default, but maybe this is one more thing that Microsoft screwed up in Me2. But I can't even find that option in Me2 in order to change it to match XP (besides which, I shouldn't even be looking for that option on customers' machines, only on mine).

I'm sorry you can't find the option in Vista. But that's not a programming issue. You need to talk to someone who can help you configure your Vista installation to work as you desire.

but this _should_ be configurable in the OS and is not a C# or .NET issue.

Fine, but I still want to make my application look right. My application does look right in XP.

Any given application can take on a wide variety of appearances depending on operating system configuration. This is especially true when using operating-system-provided user interface elements.

For some things, you can do things in code to help make things look right. But for other things, such as the formatting behavior for dealing with shortcut keys, this is under operating-system control, and you need to look into operating system configuration settings to deal with it.

[...]
Assuming you're using the Control-derived components in the Forms namespace, you should be able to just set the Control.Font property to control what font is used. In this way you can override the default behavior provided by .NET.

Fine, what should I set it to? In C++ I used to set the font to MS Shell Dlg but that doesn't seem to work in C#.

Meaning what? _How_ doesn't it work? Do you get an error? Does it just not show the font you expected? Does it show the font, but fail to do something else you expected?

The default is MS Gothic which, as discussed, works in XP but produces an ugly mixture in Vista.

Well, for the record, I don't have MS Gothic installed on my copy of XP. It sounds like a font that may be particular to whatever localized version you have, or maybe it came with some other Microsoft software or something.

As far as the "ugly mixture" goes, I had the impression from your previous post that the mixture is due to different fonts appearing in the same window. Are you saying that even applying MS Gothic to every user item element results in a mixture?

Do you think I should set it to Meiryo? Then maybe it should work in Vista but what would it do in XP?

If you don't deliver the font with your application, the OS will substitute one. Possibly one you don't like. So if you take that approach, one thing you may want to do is check the OS version and/or installed fonts and choose a font explicitly on the basis of that information.

And what would it do in foreign versions of XP?

Define "foreign". As near as I can tell, relative to my own installation of XP, the version you are using _is_ foreign.

It's funny...Americans are often accused (rightly so) of being culture-egocentric. But right now, you're the one who seems to be treating his own localized version as "the" locale.

Your questions would be a lot easier to understand if you would be clear about what localizations you're dealing with and why your system is configured the way it is. So far your posts have presented information referring to Italian and Japanese, both of which would be considered "foreign" in an English-language forum such as this one.

[...]
That said, this is the first I've heard of this font issue in Vista. You write "Microsoft closed this issue as a Won'tFix", which implies to me two things: Microsoft has acknowledged the issue as an actual problem, and that there's some bug report somewhere that describes the problem and their response.

I submitted it on the Connect site during Me2 SP1 beta testing.

As I wrote, you should include a link to that bug report if you want people to fully understand your question and Microsoft's response.

[...]
In the screenshot you're showing, there are a variety of character sets being displayed, which requires different fonts according to which ones support the characters used.

Wrong. MS Gothic contains all of those characters and it works correctly in XP.

Then use MS Gothic. I don't have it installed on my system so I can't confirm that it supports all of the different character sets. But if you're right that it does, just use that font.

[...]
My application has the same issue, i.e. one single font should suffice, but I don't know how to persuade Vista to use one single font.

Why not? What code have you tried and what doesn't work when you try it? This is a programming newsgroup. If you want help with your program, you really should post a concise-but-complete code sample that reliably demonstrates whatever problem it is you're having.

And if that problem is dependent on a specific configuration and/or localization, you need to be very specific about those prerequisites and how to achieve them, and of course hope that someone reading your message either is using that configuration and/or localization, or is willing to configure/install their version of Windows as such.

If so, then this isn't a Vista problem but rather just a basic issue of needing to display specific characters, and fonts not being able to support 100% of the Unicode code space.

Then you should have done some studying before even replying to this issue.

I hope for a reply from someone who really knows how to fix it. I wonder if I need to post a new thread now in hopes of getting snagged by Microsoft.

The only replies that will appear here from Microsoft are generally in response to messages posted by MSDN subscribers. If you are an MSDN subscriber then you should get a reply, whether or not you start a new thread.

If you're not, then it's extremely unlikely that anyone from Microsoft would reply and you're stuck with people who frankly have a lot lower tolerance for insolence and ranting than a paid professional from Microsoft would have. Use that information as you see fit.

Frankly, I hope for your sake that someone else fields your question and provides an answer. I don't see what's so wrong about trying to help even when one doesn't have exactly the answer you were hoping for, and I don't see why you expect perfection in a forum like this one. But your approach to the question and your attitude about Vista and my own reply aren't likely to encourage me or anyone else to really want to put a lot more effort into pursuing an answer.

Pete
.



Relevant Pages

  • Re: Dates and Column Widths in Excel 2007
    ... "If the default font is a non-proportional font, ... 8.43 characters of any type fit into a cell ... I don't think either I or Microsoft can can explain it any more clearly. ... Microsoft Excel 2000 Standard Edition ...
    (microsoft.public.excel.misc)
  • Re: How to set menu shortcuts, and fonts?
    ... So instead of appending a shortcut letter in parentheses I used ... In Vista this doesn't work. ... In Vista the title bar and menu bar are in Meiryo and are antialiased even at font size 9. ... (Somehow foreign versions of XP understand a default font of MS Gothic and they use a different font instead, which works if only Italian characters are used in the captions. ...
    (microsoft.public.dotnet.languages.csharp)
  • Re: Where is the word count tool?
    ... Note that the people answering questions here do not work for Microsoft. ... What font are you using and what view are you working in. ... Word then doesn't see 'words' just characters, ... live word count /should/ show the number of words in the selected portion ...
    (microsoft.public.word.docmanagement)
  • Re: fonts introduced by custom keyboard shortcuts
    ... I have three boxes running Vista 64 and one running ... I have no experience with Unicode support and multiple foreign languages. ... in Arial Unicode instead of in the font I'm actually using; ... because it has even more such characters than Times ...
    (microsoft.public.word.printingfonts)
  • Re: How to set menu shortcuts, and fonts?
    ... So instead of appending a shortcut letter in parentheses I used the European style of putting an & in front of a chosen letter in each actual menu title and menu entry. ... In both XP and Vista I have not changed the display options for shortcuts so they are still the defaults. ... File Dialog Box) and lots of Vista's own forms have visually disturbing font mixtures like this. ... Microsoft closed this issue as a Won'tFix. ...
    (microsoft.public.dotnet.languages.csharp)