From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: "Nicolas P. Rougier (inria)" Newsgroups: gmane.emacs.devel Subject: Re: Font weight selection problem Date: Tue, 23 Jan 2024 18:39:40 +0100 Message-ID: References: <86il3k558x.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="26556"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: mu4e 1.10.8; emacs 29.2 Cc: emacs-devel@gnu.org To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Tue Jan 23 19:08:42 2024 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1rSLCU-0006iB-12 for ged-emacs-devel@m.gmane-mx.org; Tue, 23 Jan 2024 19:08:42 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rSLBp-0002P1-6V; Tue, 23 Jan 2024 13:08:01 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rSLBm-0002Of-P4 for emacs-devel@gnu.org; Tue, 23 Jan 2024 13:07:58 -0500 Original-Received: from mail3-relais-sop.national.inria.fr ([192.134.164.104]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rSLBi-0003Y9-Jy; Tue, 23 Jan 2024 13:07:56 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=inria.fr; s=dc; h=references:from:to:cc:subject:date:in-reply-to: message-id:mime-version:content-transfer-encoding; bh=wHMoFIzCecykWS3RlLi/93IMfchRzu3/JTCXRB/kl8c=; b=dfg1APOypGes4NMYPOsRgRFREer+3qfPbFicZYt8JZ67aMhh/fdx9ype ZdReoy/v+XkgIrDk8r2Xf0+EO4sD7CcjBpijOMt9LHo9xaIscLIaxT7rj JJSdMztWzVTTbZU9HijZ7cuFKfFCmW7v79nnQRi3A1H4UPKmWrVS+aw0p s=; Authentication-Results: mail3-relais-sop.national.inria.fr; dkim=none (message not signed) header.i=none; spf=SoftFail smtp.mailfrom=nicolas.rougier@inria.fr; dmarc=fail (p=none dis=none) d=inria.fr X-IronPort-AV: E=Sophos;i="6.05,215,1701126000"; d="scan'208";a="77623782" Original-Received: from 91-160-114-139.subs.proxad.net (HELO M-E7-NPR.local) ([91.160.114.139]) by mail3-relais-sop.national.inria.fr with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 23 Jan 2024 19:07:27 +0100 In-reply-to: <86il3k558x.fsf@gnu.org> Received-SPF: pass client-ip=192.134.164.104; envelope-from=nicolas.rougier@inria.fr; helo=mail3-relais-sop.national.inria.fr X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:315265 Archived-At: On Tue 23 Jan 2024 at 19:28, Eli Zaretskii wrote: > Did you try to change the order between :family and :weight in=20 > your > 'propertize' call? No change. =20 > > I think the problem has been here since at least version 28.0 > I'm not sure it was ever supported. Can you make that do what=20 > you > expect in older versions of Emacs? With version 27.0 I was able to select the "Roboto Mono" light,=20 but version 28.0 did not work anymore for some reason. I solved=20 the issue by creating a font file with a unique weight (light)=20 (and named it differently). It looks as if Emacs is confused by=20 the "light" version inside the font but I don't know if the font=20 is malformed or if Emacs interprets "light" differently. I've=20 tried other fonts and the light face always ends up either thin or=20 regular, which makes me think that Emacs might be the cause. I've since found what seems to be a relevant (small) patch: https://github.com/yaglo/emacs-mac-patches/blob/main/fix_weights_and_widths= .diff but I did not tested it yet. The patch change values for weights=20 but I don't know what is the semantic of these values (and if it=20 is relevant here). Nicolas --=20 Nicolas P. Rougier =E2=80=94=E2=80=94 www.labri.fr/perso/nrougier Institute of Neurodegenerative Diseases, Bordeaux