On Thu, Aug 27, 2009 at 17:24, Adrian Buehlmann<adr...@cadifra.com> wrote:
> I think this patch should be pushed now, so the work done
> doesn't get lost.
>
> Yuki's problem report with the exotic application "X-Finder" (wanting
> ANSI help texts and getting only empty ones with this patch) is a
> marginal one.
>
> If he (or whoever) comes up with a patch fixing "X-Finder" later,
> it can be pushed in addition later.
>
> As Yuki noted, the help texts are fine in explorer with this
> patch.

Yes, I think so. The issue is happened in only rare cases.
And mostly won't notice if omitted help texts :)

BTW, I'm still trying to make a patch for this. To return ANSI help texts,
I must convert help texts from WIDE to ANSI by Adrian's changes.
So now I suppose to use "wcstombs_s" function for convertion,
but it need to call "setlocale" function before calling "wcstombs_s" function.
"setlocale" function takes a category and a language code (with
country code optionally).
The problem is that language code is NOT 2 letters (+2 letters)
format, such as "en_US", "ja".

Language strings: http://msdn.microsoft.com/en-us/library/39cwe7zf(VS.71).aspx
Country/Region strings:
http://msdn.microsoft.com/en-us/library/cdax410z(VS.71).aspx

Finally, to support ANSI help text, we have to introduce a new registry entry
"CMenuLangStr" to store language string for "setlocale" function calling
since we can't use existing "CMenuLang" entry.

I attached small patch for fixing my problem.
The patch is just for showing how I fix, so the language string were
hard coded as "japanese". Please correct language code to yours before running.

FYI: I know "_getmbcp" function but it's Windows specific extension.

-- 
Yuki KODAMA

Attachment: ansifix.patch
Description: Binary data

------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with 
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
Tortoisehg-develop mailing list
Tortoisehg-develop@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/tortoisehg-develop

Reply via email to