delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2024/04/11/10:42:07

X-Recipient: archive-cygwin AT delorie DOT com
DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 1E8483858401
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cygwin.com;
s=default; t=1712846525;
bh=n1HJWep0rqiKOvvUeJuyURiHVj2i70eRnCfiWe3gv+8=;
h=Date:Subject:To:References:In-Reply-To:List-Id:List-Unsubscribe:
List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:Cc:
From;
b=ow/rj18HyifuKrs3flFFaU0ZU8OaT8Mx1LXm5HeuQdrAAqUsCVN1p6gutPy+afzHk
TXw9OozJfioZg0IJTnVVEJeHZScrzJvdeSFvhqSYki6CSdD3XpC7s5EXhBeXhQ+5tg
q/6yEyFt4jzoeVpM0/6UXPTRmMo576eBrTaU9Bqg=
X-Original-To: cygwin AT cygwin DOT com
Delivered-To: cygwin AT cygwin DOT com
DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 366EC384AB75
ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 366EC384AB75
ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1712846454; cv=none;
b=sXUxRFJHvw9rC3ayl08wAxckv1f+EfZp5fLO2KS5W70Swi4+eQS0gghvo+gcVBfiQYSvQIJGMP6HRluPyo3Gin9f/6EVssFj6qP26wp2w9+aXInxdOUinHcetx/fPmr/OFYcIR/aZUH8J5XgljcDhmANAEfgWmMK4rTxMlzTC6k=
ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key;
t=1712846454; c=relaxed/simple;
bh=ndKl8Ob0mRPEjg2AfZQHt9UkC6wphd9X3t7YzbE2IUw=;
h=Message-ID:Date:MIME-Version:Subject:To:From;
b=u4H4dJcFy2wHoFh7M09Y6JqkZZ3VlLMo9ocM2krec+Pu8E3tc3HeR8bTEtVziodWpf+RkHMTrFSAfPpn7ka9DultEL+ZiuOXS12utADJZDFNkXRRiNV8Avkv4HWPm/XGtHOeZeREVyCI2f14D4ZsV21JE9bd57uLOiKDfNjKipo=
ARC-Authentication-Results: i=1; server2.sourceware.org
Message-ID: <19349faa-703c-474a-bcd2-b1355d35e7bb@SystematicSW.ab.ca>
Date: Thu, 11 Apr 2024 08:40:48 -0600
MIME-Version: 1.0
User-Agent: Mozilla Thunderbird
Subject: Re: Use Microsoft YaHei UI as UI font for Chinese language
To: cygwin AT cygwin DOT com
References: <CY8PR10MB65629A75555083838A1CF46CA23D2 AT CY8PR10MB6562 DOT namprd10 DOT prod DOT outlook DOT com>
<a050c9e8-4158-49e1-9a46-c6785cd1b891 AT dronecode DOT org DOT uk>
Organization: Systematic Software
In-Reply-To: <a050c9e8-4158-49e1-9a46-c6785cd1b891@dronecode.org.uk>
X-Rspamd-Queue-Id: 12ECD22
X-Spam-Status: No, score=-6.6 required=5.0 tests=BAYES_00, BODY_8BITS,
GIT_PATCH_0, KAM_DMARC_STATUS, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H3,
RCVD_IN_MSPIKE_WL, SPF_HELO_PASS, SPF_PASS, TXREP,
UNPARSEABLE_RELAY autolearn=ham autolearn_force=no version=3.4.6
X-Stat-Signature: rudix466z3zr7p4q47gidgne4cxesuzx
X-Rspamd-Server: rspamout04
X-Session-Marker: 427269616E2E496E676C69734053797374656D6174696353572E61622E6361
X-Session-ID: U2FsdGVkX19Rap4X+cHcGos53v16BPrQYIxcsp2eq0E=
X-HE-Tag: 1712846448-805741
X-HE-Meta: U2FsdGVkX1/ZDuD3VkBJCRFbLIeHt84CTUigKKyME5Rg8XZwrmcijU7CfK5Txe3/M6IG9SdWlBHMnjEmx2Aw+nSFVxnGTVLtFu0V+2yvvj6OVprwoBeeMMcKLSunzLvK0TyTyNoJmN/P8YH92K0Y5CVLEcgmPHihZu/bGEGqs0kiuJf05miDBARx4hjAQqLt1/mXwHYqbHmIR8Hx1juNoaHfyoxrFm4evUen3UBA+tcxqWUyv0T5wikOe0MC737fh0hBLtBsiXETubJEB0BMCzu3kKOPh+nnMgVfrMAtpy2ObMeFUqT1dv8dnDYLf6VLHtDhmi0wD7yBsC9Xs5iAAUFvCmd/wD65YCv/vQV6w1F6xchMgSP0FhoyKUkIaRym7J+Y0zav6Lw=
X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on
server2.sourceware.org
X-BeenThere: cygwin AT cygwin DOT com
X-Mailman-Version: 2.1.30
List-Id: General Cygwin discussions and problem reports <cygwin.cygwin.com>
List-Unsubscribe: <https://cygwin.com/mailman/options/cygwin>,
<mailto:cygwin-request AT cygwin DOT com?subject=unsubscribe>
List-Archive: <https://cygwin.com/pipermail/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-request AT cygwin DOT com?subject=help>
List-Subscribe: <https://cygwin.com/mailman/listinfo/cygwin>,
<mailto:cygwin-request AT cygwin DOT com?subject=subscribe>
From: Brian Inglis via Cygwin <cygwin AT cygwin DOT com>
Reply-To: cygwin AT cygwin DOT com
Cc: Brian Inglis <Brian DOT Inglis AT SystematicSW DOT ab DOT ca>
Errors-To: cygwin-bounces+archive-cygwin=delorie DOT com AT cygwin DOT com
Sender: "Cygwin" <cygwin-bounces+archive-cygwin=delorie DOT com AT cygwin DOT com>
X-MIME-Autoconverted: from base64 to 8bit by delorie.com id 43BEg6ag1097352

On 2024-04-11 06:42, Jon Turney via Cygwin wrote:
> On 03/04/2024 14:19, Yang Yu Lin via Cygwin wrote:
>> For Chinese language, the app’s default UI font is Microsoft YaHei UI. Using 
>> MS Shell Dlg makes the UI become annoying.
>> Here are my changes:
>> diff --git a/res/zh_Hans/res.rc b/res/zh_Hans/res.rc
>> index 9f67a5a..da9d6e8 100644
>> --- a/res/zh_Hans/res.rc
>> +++ b/res/zh_Hans/res.rc
>> @@ -8,7 +8,7 @@ LANGUAGE LANG_CHINESE, SUBLANG_CHINESE_SIMPLIFIED
>>   IDD_SOURCE DIALOG 0, 0, SETUP_STANDARD_DIALOG_DIMS
>>   STYLE DS_MODALFRAME | DS_CENTER | WS_CHILD | WS_CAPTION | WS_SYSMENU
>>   CAPTION "Cygwin 安装程序 - 选择安装类型"
>> -FONT 8, "MS Shell Dlg"
>> +FONT 9, "Microsoft YaHei UI"

> Thanks very much for this patch!
> So, this isn't applicable as is, because the localized res.rc files are 
> generated from a template res.rc file and the language .po file (using po2rc 
> from Translate Toolkit [1][2]).  See section starting after "rules for 
> translation maintenance" in Makefile.am
> However, this seems like it would be straightforward to do via a post-processing 
> step there.
> I'll take your word over the aesthetics of the font choice, but I do have a 
> question about what versions of Windows we can assume that font is available on 
> (in theory at least, one might be using a current setup executable to install 
> Cygwin from the CTM on OSs back to Windows XP3)

MS Yahei UI appeared in Win8; Yahei Reg/Bold in Win7.

> I wonder if we ought to be using "MS Shell Dlg 2" and/or DS_SHELLFONT, but the 
> documentation about those is incomprehensible.

They appear to be intended to be "localizable" font names implemented using font 
substitution on each Windows language version to MS Sans Serif (MS UI Gothic if 
jp) and Tahoma (2 was for W2K):

https://learn.microsoft.com/en-us/windows/win32/intl/using-ms-shell-dlg-and-ms-shell-dlg-2
https://github.com/MicrosoftDocs/win32/blob/docs/desktop-src/Intl/using-ms-shell-dlg-and-ms-shell-dlg-2.md

> If you have any future patches to setup, please send them to the cygwin-apps 
> mailing list
> [1] https://github.com/translate/translate
> [2] (Although there may be some patches needed which have yet to make it 
> upstream, so this might not work for you, yet)

-- 
Take care. Thanks, Brian Inglis              Calgary, Alberta, Canada

La perfection est atteinte                   Perfection is achieved
non pas lorsqu'il n'y a plus rien à ajouter  not when there is no more to add
mais lorsqu'il n'y a plus rien à retirer     but when there is no more to cut
                                 -- Antoine de Saint-Exupéry

-- 
Problem reports:      https://cygwin.com/problems.html
FAQ:                  https://cygwin.com/faq/
Documentation:        https://cygwin.com/docs.html
Unsubscribe info:     https://cygwin.com/ml/#unsubscribe-simple

- Raw text -


  webmaster     delorie software   privacy  
  Copyright 2019   by DJ Delorie     Updated Jul 2019