From debbugs-submit-bounces@debbugs.gnu.org Tue Jun 18 21:44:38 2019 Received: (at submit) by debbugs.gnu.org; 19 Jun 2019 01:44:38 +0000 Received: from localhost ([127.0.0.1]:45800 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hdPeP-0007pc-Rv for submit@debbugs.gnu.org; Tue, 18 Jun 2019 21:44:38 -0400 Received: from lists.gnu.org ([209.51.188.17]:49286) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hdPeO-0007pT-Cj for submit@debbugs.gnu.org; Tue, 18 Jun 2019 21:44:36 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:56829) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hdPeN-0007Fm-Ct for bug-gnu-emacs@gnu.org; Tue, 18 Jun 2019 21:44:36 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50,FREEMAIL_FROM, URIBL_BLOCKED autolearn=disabled version=3.3.2 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hdPSe-0006ek-JC for bug-gnu-emacs@gnu.org; Tue, 18 Jun 2019 21:32:29 -0400 Received: from mail-wr1-x434.google.com ([2a00:1450:4864:20::434]:33231) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hdPSe-0006e9-8C for bug-gnu-emacs@gnu.org; Tue, 18 Jun 2019 21:32:28 -0400 Received: by mail-wr1-x434.google.com with SMTP id n9so1519714wru.0 for ; Tue, 18 Jun 2019 18:32:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:to:from:subject:message-id:date:user-agent:mime-version :content-language:content-transfer-encoding; bh=flyBjIqy+Vuia/UxztmGfrK2vORnWKUBphD99vN2m0c=; b=mZNy7HvyzdNhoZG58kRaN8KYsL1/t+iR96kqqBrvssqfDi62tYN5GztfrGiTH9V6ZW 0eKwmkxwhmwqr8qWVLRUJgObwKzlVI1aqliZWBTwi5Z77hweZ6jBFnGQiU1dc85KEnwU FGajbe/gDAYdYnzlZzcaRXFBpKCXJS0j0Ko2DJb3vOtszt4DilIAdEJEkwVQVVDdHqjW VLD0pDUSfS/UL913O0UffxsW/ymQuMw2oOSwoCU05VnAw32UNp/xtEsUwCD+Zz/FIyVW fe8FY2HQ012a81jr88dZ9N033+9iMqtKOy25FW4TbS42M4+3ykaH/IIu4yZwKoLYej/F JpDg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:to:from:subject:message-id:date :user-agent:mime-version:content-language:content-transfer-encoding; bh=flyBjIqy+Vuia/UxztmGfrK2vORnWKUBphD99vN2m0c=; b=IBxtW67jmeu/Cgz96Z1ESmnshMiTH2VlXYngo6zp3ce05T1Ur/e7aBhQjdszmK0rBw nnKKNxzSrAtOahfjL0kyclRv14qhHmPd5k1KlheVvlSMM37YbX4OdbTbI/npLshYvEzy Sgp+EUksiVja9xwsBvHsC4PqEHjlnbzdwCQf6sgCuL04KY2PJAmsbf0HAXYBwS2BPW4w 67SpVvHxhUK2LlESTAxn0obDRFu/+EPv2cytUG30BMJCGgTAxeNWyyX+7sifLcyVq6+j 1QOOEC/LThGU27JuxdijPS3vRk0jL8kzCRXlh3g2C0eHMAoumyKmEPXZXZQ7UvIs50NP jsYA== X-Gm-Message-State: APjAAAVfwZTjQFWg4jG0d0bTDjJ+06rRvGI83kaOsn8pw8wn0uK4BPpg 5Z0sKTrBbxxaY5bW7mWmv/+IFtcaDqc= X-Google-Smtp-Source: APXvYqzzAJ2X8nZ9TX/2/wqpaEUj42OO1D6m7cZaFfVIiSuai+8NNltb0u9bmg5GODiFKBKcPURxGw== X-Received: by 2002:a5d:43c9:: with SMTP id v9mr82424801wrr.70.1560907946781; Tue, 18 Jun 2019 18:32:26 -0700 (PDT) Received: from [192.168.1.3] ([185.105.174.23]) by smtp.googlemail.com with ESMTPSA id v18sm10758557wrs.80.2019.06.18.18.32.25 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 18 Jun 2019 18:32:26 -0700 (PDT) To: bug-gnu-emacs@gnu.org From: Dmitry Gutov Subject: 27.0.50; [Cairo] Setting default face :family attribute in the init script is broken Message-ID: Date: Wed, 19 Jun 2019 04:32:24 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.7.0 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4864:20::434 X-Spam-Score: -0.8 (/) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.8 (-) When using a build with Cairo, putting (set-face-attribute 'default nil :height 113 :family "Inconsolata LGC") into the init script doesn't have any effect. Evaluating (face-attribute 'default :family) in the new session after that still returns "Ubuntu Mono". However, if I evaluate the set-face-attribute call form later in the new frame, the font changes successfully. In GNU Emacs 27.0.50 (build 68, x86_64-pc-linux-gnu, GTK+ Version 3.22.30, cairo version 1.15.10) of 2019-06-19 built on zappa Repository revision: 922121e7ddbc107da14ea9c1280d15c828e85063 Repository branch: master Windowing system distributor 'The X.Org Foundation', version 11.0.12001000 System Description: Ubuntu 18.04.2 LTS From debbugs-submit-bounces@debbugs.gnu.org Tue Jun 18 23:37:08 2019 Received: (at 36284) by debbugs.gnu.org; 19 Jun 2019 03:37:08 +0000 Received: from localhost ([127.0.0.1]:45846 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hdRPH-0002Ny-R1 for submit@debbugs.gnu.org; Tue, 18 Jun 2019 23:37:08 -0400 Received: from mathmail.math.s.chiba-u.ac.jp ([133.82.132.2]:57839) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hdRPF-0002No-Ma for 36284@debbugs.gnu.org; Tue, 18 Jun 2019 23:37:06 -0400 Received: from mathent.math.s.chiba-u.ac.jp (mathent [192.168.32.5]) by mathmail.math.s.chiba-u.ac.jp (Postfix) with ESMTP id 3DFADF08DA; Wed, 19 Jun 2019 12:37:05 +0900 (JST) (envelope-from mituharu@math.s.chiba-u.ac.jp) Date: Wed, 19 Jun 2019 12:37:05 +0900 Message-ID: From: YAMAMOTO Mitsuharu To: Dmitry Gutov Subject: Re: bug#36284: 27.0.50; [Cairo] Setting default face :family attribute in the init script is broken In-Reply-To: References: User-Agent: Wanderlust/2.15.9 (Almost Unreal) SEMI-EPG/1.14.7 (Harue) FLIM/1.14.9 (=?ISO-8859-4?Q?Goj=F2?=) APEL/10.8 EasyPG/1.0.0 Emacs/25.3 (x86_64-pc-linux-gnu) MULE/6.0 (HANACHIRUSATO) Organization: Faculty of Science, Chiba University MIME-Version: 1.0 (generated by SEMI-EPG 1.14.7 - "Harue") Content-Type: text/plain; charset=US-ASCII X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 36284 Cc: 36284@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) On Wed, 19 Jun 2019 10:32:24 +0900, Dmitry Gutov wrote: > > When using a build with Cairo, putting > > (set-face-attribute 'default nil :height 113 :family "Inconsolata LGC") > > into the init script doesn't have any effect. > > Evaluating (face-attribute 'default :family) in the new session after > that still returns "Ubuntu Mono". > > However, if I evaluate the set-face-attribute call form later in the new > frame, the font changes successfully. It seems that some changes I made to xsetting.c in order to remove dependency on libXft was too naive. For this particular problem, the patch below would work. For stricter consistency with the behavior of the Xft version, one would need to implement replacements for XftDefaultSubstitute and XftDefaultSet. YAMAMOTO Mitsuharu mituharu@math.s.chiba-u.ac.jp diff --git a/src/xsettings.c b/src/xsettings.c index 3e9012e3ab1..06c47c6c6ce 100644 --- a/src/xsettings.c +++ b/src/xsettings.c @@ -608,18 +608,16 @@ static void apply_xft_settings (struct x_display_info *dpyinfo, struct xsettings *settings) { -#if defined USE_CAIRO || defined HAVE_XFT +#ifdef HAVE_XFT FcPattern *pat; struct xsettings oldsettings; bool changed = false; memset (&oldsettings, 0, sizeof (oldsettings)); pat = FcPatternCreate (); -#ifdef HAVE_XFT XftDefaultSubstitute (dpyinfo->display, XScreenNumberOfScreen (dpyinfo->screen), pat); -#endif FcPatternGetBool (pat, FC_ANTIALIAS, 0, &oldsettings.aa); FcPatternGetBool (pat, FC_HINTING, 0, &oldsettings.hinting); #ifdef FC_HINT_STYLE @@ -719,9 +717,7 @@ apply_xft_settings (struct x_display_info *dpyinfo, }; char buf[sizeof format + d_formats * d_growth + lf_formats * lf_growth]; -#ifdef HAVE_XFT XftDefaultSet (dpyinfo->display, pat); -#endif store_config_changed_event (Qfont_render, XCAR (dpyinfo->name_list_element)); Vxft_settings @@ -733,7 +729,7 @@ apply_xft_settings (struct x_display_info *dpyinfo, } else FcPatternDestroy (pat); -#endif /* USE_CAIRO || HAVE_XFT */ +#endif /* HAVE_XFT */ } /* Read XSettings from the display for DPYINFO. From debbugs-submit-bounces@debbugs.gnu.org Wed Jun 19 06:47:28 2019 Received: (at 36284) by debbugs.gnu.org; 19 Jun 2019 10:47:28 +0000 Received: from localhost ([127.0.0.1]:46079 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hdY7i-0005YK-4G for submit@debbugs.gnu.org; Wed, 19 Jun 2019 06:47:26 -0400 Received: from mail-wm1-f49.google.com ([209.85.128.49]:55650) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hdY7g-0005Y8-1E for 36284@debbugs.gnu.org; Wed, 19 Jun 2019 06:47:24 -0400 Received: by mail-wm1-f49.google.com with SMTP id a15so1204781wmj.5 for <36284@debbugs.gnu.org>; Wed, 19 Jun 2019 03:47:23 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=9pg/0HOtX0/BlV9Xpp6XOfJ6EVpS1pbLT0cV0jNcw3o=; b=CMysHapxB6hWbYjEIiJWG10wfs4V+Wegax3QbIg9njKqA3En82IjbcwnpeoElrLndJ aSLBKf6i07VD7h8xX05ydvd5rTuWDOf/p9xs0YcZ2bzuqNtM0/uCoPGUduUWb+XkoZTX tgwR2xK9a/y0ON1qLKLgBBdmN+0V928BXnPp5d7zFMY1QArvB3q/VvLsPA5TdqDhG/MX EKzApq+wm4eyF41YA88LJ8oJ8cKhX1VbLFGIPhhCb76l4yq9Vxxx0TxfhBKQpoqpMcyO 4LohqBUFrtxAOdCiVE55bh+vaEPlulfZOlbJWK95ve6fU/iqWzdYh6OGHXE9kF3YfRzL +e+w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:subject:to:cc:references:from:message-id :date:user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=9pg/0HOtX0/BlV9Xpp6XOfJ6EVpS1pbLT0cV0jNcw3o=; b=KWMwi+fv18HAAbIBW/wDmOa6QTIWNMQ7QGXfdbJim5duPIOItP7sXlyxfgC+IJwAcs E4G7VuQtcEtF+iLP06JxEII1Hj9qoy0Jd2lH7r4yETz4q91+1YUQ3H8zhzSDfwmj/hxJ 83eJXb7ZXCef6rIhvLzcg+mraQgy1TnHGHz54p7s8nBu0KvnB1nCVSERTMfi7hbJEf0x hGmWCoHFirQsZr3W4/TLvLwh5FuSHMuKu9WXOVNtUfLZPLMCI17HrRRXMQ3HSFtq2nPU pYwCLDKc1HWkjonIv7pp1PnJd3MkKn4vQXn9tR2FiHEDVCJm4ilCuj11MUaYgLGdKdIj zMFw== X-Gm-Message-State: APjAAAVpijPlWo/xozxDQm4Dlr7YtbdVQM0gKZeknA++GGjRJlMxVMIT 01pESQUoXWN/KkpA0s4CnFCkRHDIGUA= X-Google-Smtp-Source: APXvYqwVUJtLKlVPfOCaoGLnJEr3ZHVPpNgPdMPR5AkCtIDc5U0hEqmEbIrITjHsyfoNzVjm+sLeiw== X-Received: by 2002:a7b:c3d5:: with SMTP id t21mr5995128wmj.87.1560941237656; Wed, 19 Jun 2019 03:47:17 -0700 (PDT) Received: from [192.168.1.3] ([185.105.174.23]) by smtp.googlemail.com with ESMTPSA id w2sm16838782wrr.31.2019.06.19.03.47.15 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 19 Jun 2019 03:47:16 -0700 (PDT) Subject: Re: bug#36284: 27.0.50; [Cairo] Setting default face :family attribute in the init script is broken To: YAMAMOTO Mitsuharu References: From: Dmitry Gutov Message-ID: Date: Wed, 19 Jun 2019 13:47:14 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.7.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-Spam-Score: 0.5 (/) X-Debbugs-Envelope-To: 36284 Cc: 36284@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.5 (/) On 19.06.2019 6:37, YAMAMOTO Mitsuharu wrote: > It seems that some changes I made to xsetting.c in order to remove > dependency on libXft was too naive. For this particular problem, the > patch below would work. For stricter consistency with the behavior of > the Xft version, one would need to implement replacements for > XftDefaultSubstitute and XftDefaultSet. This patch works, thank you. Please install whichever version seems most appropriate to you. From debbugs-submit-bounces@debbugs.gnu.org Wed Jun 19 23:02:48 2019 Received: (at 36284-done) by debbugs.gnu.org; 20 Jun 2019 03:02:48 +0000 Received: from localhost ([127.0.0.1]:47694 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hdnLc-0001AN-Fz for submit@debbugs.gnu.org; Wed, 19 Jun 2019 23:02:48 -0400 Received: from mathmail.math.s.chiba-u.ac.jp ([133.82.132.2]:57028) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hdnLa-0001A8-RS for 36284-done@debbugs.gnu.org; Wed, 19 Jun 2019 23:02:47 -0400 Received: from mathent.math.s.chiba-u.ac.jp (mathent [192.168.32.5]) by mathmail.math.s.chiba-u.ac.jp (Postfix) with ESMTP id 9F347F08C6; Thu, 20 Jun 2019 12:02:47 +0900 (JST) (envelope-from mituharu@math.s.chiba-u.ac.jp) Date: Thu, 20 Jun 2019 12:02:47 +0900 Message-ID: From: YAMAMOTO Mitsuharu To: Dmitry Gutov Subject: Re: bug#36284: 27.0.50; [Cairo] Setting default face :family attribute in the init script is broken In-Reply-To: References: User-Agent: Wanderlust/2.15.9 (Almost Unreal) SEMI-EPG/1.14.7 (Harue) FLIM/1.14.9 (=?ISO-8859-4?Q?Goj=F2?=) APEL/10.8 EasyPG/1.0.0 Emacs/25.3 (x86_64-pc-linux-gnu) MULE/6.0 (HANACHIRUSATO) Organization: Faculty of Science, Chiba University MIME-Version: 1.0 (generated by SEMI-EPG 1.14.7 - "Harue") Content-Type: text/plain; charset=US-ASCII X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 36284-done Cc: 36284-done@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) On Wed, 19 Jun 2019 19:47:14 +0900, Dmitry Gutov wrote: > > On 19.06.2019 6:37, YAMAMOTO Mitsuharu wrote: > > It seems that some changes I made to xsetting.c in order to remove > > dependency on libXft was too naive. For this particular problem, the > > patch below would work. For stricter consistency with the behavior of > > the Xft version, one would need to implement replacements for > > XftDefaultSubstitute and XftDefaultSet. > > This patch works, thank you. > > Please install whichever version seems most appropriate to you. Thanks for testing. The previous patch is applied to master as 0701634aa78. Closing the bug. YAMAMOTO Mitsuharu mituharu@math.s.chiba-u.ac.jp From unknown Mon Jun 23 13:13:19 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Thu, 18 Jul 2019 11:24:05 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator