From unknown Tue Jun 17 01:35:37 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#34001 <34001@debbugs.gnu.org> To: bug#34001 <34001@debbugs.gnu.org> Subject: Status: 26.1.90; :distant-foreground face property fails to work in most cases Reply-To: bug#34001 <34001@debbugs.gnu.org> Date: Tue, 17 Jun 2025 08:35:37 +0000 retitle 34001 26.1.90; :distant-foreground face property fails to work in m= ost cases reassign 34001 emacs submitter 34001 Tina Russell severity 34001 normal thanks From debbugs-submit-bounces@debbugs.gnu.org Sun Jan 06 17:55:33 2019 Received: (at submit) by debbugs.gnu.org; 6 Jan 2019 22:55:33 +0000 Received: from localhost ([127.0.0.1]:47424 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ggHKP-0002Jf-5a for submit@debbugs.gnu.org; Sun, 06 Jan 2019 17:55:33 -0500 Received: from eggs.gnu.org ([209.51.188.92]:39429) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ggGxp-0001mR-Gi for submit@debbugs.gnu.org; Sun, 06 Jan 2019 17:32:14 -0500 Received: from lists.gnu.org ([209.51.188.17]:53736) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1ggGxk-0000yW-AL for submit@debbugs.gnu.org; Sun, 06 Jan 2019 17:32:08 -0500 Received: from eggs.gnu.org ([209.51.188.92]:49631) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ggGxj-0000E5-3m for bug-gnu-emacs@gnu.org; Sun, 06 Jan 2019 17:32:08 -0500 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, HTML_MESSAGE autolearn=disabled version=3.3.2 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ggGxi-0000xV-0F for bug-gnu-emacs@gnu.org; Sun, 06 Jan 2019 17:32:07 -0500 Received: from mail-lf1-x133.google.com ([2a00:1450:4864:20::133]:35037) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1ggGxh-0000we-Ou for bug-gnu-emacs@gnu.org; Sun, 06 Jan 2019 17:32:05 -0500 Received: by mail-lf1-x133.google.com with SMTP id e26so28849006lfc.2 for ; Sun, 06 Jan 2019 14:32:05 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:from:date:message-id:subject:to; bh=5ujmUdK3IcGd+aRwv4WXluvL52SmRbhSGnJTEGij9Wo=; b=JnzMKrHnQrCmvWyaoiCnEQyOeN0AszPqXCjkaNZ7nqj90Xn1eBFKkN8pMqx/lyFW7Q bSobMII8MhCzPuX9s7gPbNyKvvKhhhKnv45ilO/o4mQm2xl1im+qqpn9gScSTW9tlVHR hV4EtnVjFP4RgK1orFQZb5ws+dkKIoZZTu6Z6yAZzzlToxglsLE7626lkBQQrZCqvUOn 0dt7da9MYV/Wp3eo3CFAE2JYywBc740rzZW3y14vwtOYviAiOTWkgvao6RipLDC2tIKq 1AINuLRTYZUuITIaaL7SZu6uEXUlzcVbVx6ybybuM6cCPiYmbzn1BcH0u5iaxA5NSCm6 qefg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=5ujmUdK3IcGd+aRwv4WXluvL52SmRbhSGnJTEGij9Wo=; b=cDOuSX7LfeRjBfZA749YcRYX/ficDWtIV7Wn/EzZ9ssq0DJf5ZUuzsDFFkK7ypr1jV /lpK0kqD9ajiWNkHMgwDfS13wxjAP57unMNEEM6dlEgs36aoNwjmiqs4UAibWayy2pZw 8GI38w47SWzeTO9wr7f++hCsynncUV0ZqTZTBiTNlGAC/jSfaXFuVyd/Ui9PMuocNcH5 zEZ0rVaLmpQ1qghoJ2EjShSzZ8IdDrut9b5vTiMSkoI0lzVhZT0sQB0Nd8EuIVE5qV8V Yzu2ZDOT5oqPF2afzvnNzyjpXzwMPYpKIvlFrFwst6ixliKb/9QVP94mA+/O7sSmiFct Sdbw== X-Gm-Message-State: AA+aEWaK2uxqjJCGFxYfF5QOkxQPz50JQbf0RtxxW+8VbH7UxQVgEQYB i9LslLeKlULiMNPH8xDoF0gqoRnRDYN81Qm6Ma3yR118 X-Google-Smtp-Source: AFSGD/WfBVmobXK1tgxLMDFT+Nd0bGWgwx1URznmiCNllKqhE1MzBqlvwP/J/I7Rf7kYnrZa2HYDkgg9DWje90Gu368= X-Received: by 2002:a19:41c4:: with SMTP id o187mr31037306lfa.32.1546813923139; Sun, 06 Jan 2019 14:32:03 -0800 (PST) MIME-Version: 1.0 From: Tina Russell Date: Sun, 6 Jan 2019 14:31:51 -0800 Message-ID: Subject: 26.1.90; :distant-foreground face property fails to work in most cases To: bug-gnu-emacs@gnu.org Content-Type: multipart/alternative; boundary="0000000000006c27dd057ed1ae37" X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4864:20::133 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Spam-Score: 1.0 (+) X-Debbugs-Envelope-To: submit X-Mailman-Approved-At: Sun, 06 Jan 2019 17:55:32 -0500 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.0 (/) --0000000000006c27dd057ed1ae37 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable :distant-foreground is a very useful concept for a face property: text will be rendered with the :foreground color, unless it=E2=80=99s too close = to the current background color, in which case :distant-foreground kicks in. Like, try this in Eshell or IELM: (propertize "Greetings, esteemed Emacs developers!" 'face '(:foreground "yellow" :background "yellow")) You=E2=80=99ll get a solid band of yellow, of course. But, with :distant-foreground=E2=80=A6 (propertize "Greetings, esteemed Emacs developers!" 'face '(:foreground "yellow" :background "yellow" :distant-foreground "black")) Now it is a friendly greeting. (Naturally, you wouldn=E2=80=99t normally se= t :background and :distant-foreground in the same face, this is just an example.) But, try this: (propertize "Greetings, esteemed Emacs developers!" 'face '(:foreground "yellow" :background "white" :distant-foreground "black")) :distant-foreground doesn=E2=80=99t kick in=E2=80=94and you=E2=80=99re left= with yellow-on-white text that=E2=80=99s impossible to read, the exact scenario that :distant-foreground was quite rightly designed to avoid. I=E2=80=99m not the only one who=E2=80=99s noticed this; there=E2=80=99s a = good StackExchange thread from 2015 here: https://emacs.stackexchange.com/questions/7982/ The author notes that there should be a user option to set the amount of =E2=80=9Cdistance=E2=80= =9D (between foreground and background colors) that is required for distant-foreground to kick in, and adds that a good way to measure color distance in real-world circumstances is described here: http://web.mst.edu/~rhall/web_design/color_readability.html A commenter suggested that he file a bug, but I can=E2=80=99t find an Emacs bug report related to this issue, so I=E2=80=99m filing this now. I really hope this gets addressed, because :distant-foreground is a really nice and clever feature. Thanks! In GNU Emacs 26.1.90 (build 2, x86_64-pc-linux-gnu, GTK+ Version 3.22.30) of 2019-01-02 built on pannychis Repository revision: 08840f2f7bfc6144bd163dd85efe87d28541e425 Windowing system distributor 'The X.Org Foundation', version 11.0.11906000 System Description: Ubuntu 18.04.1 LTS Configured using: 'configure --with-xaw3d --with-modules --with-xwidgets' --0000000000006c27dd057ed1ae37 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
:distant-foreground is a very useful concept for a face pr= operty: text
will be rendered with the :foreground color, unless it=E2= =80=99s too close to
the current background color, in which case :distan= t-foreground kicks
in. Like, try this in Eshell or IELM:

(propert= ize "Greetings, esteemed Emacs developers!" 'face '(:fore= ground
"yellow" :background "yellow"))

You=E2= =80=99ll get a solid band of yellow, of course. But, with
:distant-foreg= round=E2=80=A6

(propertize "Greetings, esteemed Emacs developer= s!" 'face '(:foreground
"yellow" :background &quo= t;yellow" :distant-foreground "black"))

Now it is a f= riendly greeting. (Naturally, you wouldn=E2=80=99t normally set
:backgro= und and :distant-foreground in the same face, this is just an
example.)<= br>
But, try this:

(propertize "Greetings, esteemed Emacs de= velopers!" 'face '(:foreground
"yellow" :backgrou= nd "white" :distant-foreground "black"))

:distan= t-foreground doesn=E2=80=99t kick in=E2=80=94and you=E2=80=99re left with y= ellow-on-white
text that=E2=80=99s impossible to read, the exact scenari= o that
:distant-foreground was quite rightly designed to avoid.

I= =E2=80=99m not the only one who=E2=80=99s noticed this; there=E2=80=99s a g= ood StackExchange
thread from 2015 here:
https://emacs.stackexchange.com/questions/7= 982/ The author notes that
there should be a user option to set the = amount of =E2=80=9Cdistance=E2=80=9D (between
foreground and background = colors) that is required for
distant-foreground to kick in, and adds tha= t a good way to measure
color distance in real-world circumstances is de= scribed here:
http://web.mst.edu/~rhall/web_design/color_readability.html A commenter
suggested that he file a bug, but I can=E2=80=99t find an= Emacs bug report
related to this issue, so I=E2=80=99m filing this now.=

I really hope this gets addressed, because :distant-foreground is a=
really nice and clever feature. Thanks!

In GNU Emacs 26.1.90 (bu= ild 2, x86_64-pc-linux-gnu, GTK+ Version 3.22.30)
=C2=A0of 2019-01-02 bu= ilt on pannychis
Repository revision: 08840f2f7bfc6144bd163dd85efe87d285= 41e425
Windowing system distributor 'The X.Org Foundation', vers= ion 11.0.11906000
System Description: Ubuntu 18.04.1 LTS

Configur= ed using:
=C2=A0'configure --with-xaw3d --with-modules --with-xwidge= ts'
--0000000000006c27dd057ed1ae37-- From debbugs-submit-bounces@debbugs.gnu.org Tue Jan 15 20:08:32 2019 Received: (at 34001) by debbugs.gnu.org; 16 Jan 2019 01:08:32 +0000 Received: from localhost ([127.0.0.1]:60474 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gjZgy-0002vI-Oc for submit@debbugs.gnu.org; Tue, 15 Jan 2019 20:08:32 -0500 Received: from mail-qt1-f180.google.com ([209.85.160.180]:41491) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gjZgv-0002v1-Vs for 34001@debbugs.gnu.org; Tue, 15 Jan 2019 20:08:26 -0500 Received: by mail-qt1-f180.google.com with SMTP id l12so5287642qtf.8 for <34001@debbugs.gnu.org>; Tue, 15 Jan 2019 17:08:26 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:subject:references:date:in-reply-to:message-id:user-agent :mime-version; bh=gIFZotwgzaPsQBnRvjEZinpRn+mDYsbOhwyATBfJbSE=; b=Dl+YZHnx/AS8WQ8e78k1Le3u4FWebFhJ3kVx5cQ+w5dpALFv/6z7Q4LiGgjqesoS9r cSMAk8K85xUgZybwy4YrVNtvUGIq7zo5EfC85X7lyhAsKqIt6seVD0qRmnWA5cvC2fP8 DKR/zBcTLL2AUnkaBYNXMRmCrebub0DsHdq8aQWprxw/NhbVFkLpAKlkFLyGaU1fAFkE QyFEFAZfF67bR2rn0K2iwexqBa4Ods+onbP2NBfvZHJzdYqhyof/VHkhQtKX0tO2JOon GkHqMD3QEaKOuk/sk5KPSrGsaM60Hskm7Het00Ht1XK86a/vMlFtGPiI9D5jHZzb3JKz WePw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=gIFZotwgzaPsQBnRvjEZinpRn+mDYsbOhwyATBfJbSE=; b=YIZWPfuW396/1QDuMFb+KuQcWNfifyeTP993QeoADoqwN3U0cAAzRxz+fR3tW2SPJU zRbG9IG6gJW14SEVZwiZ4NYkt2nBwm8s5mVsyTG97Z/4SrVGGb3N27qxmlXvT7m4m5VJ A1eUH6cmtPD9lA4vAgJF5OpnzhmHExf+DLSIKCoF3glNNCD3GrTqIu+D9+eWjqwGI3Pk GjyVnqf4SRmN6sZ6TsqFzFNLH6Y1tStXEqO+AxlgfcWX5ctpCeonslk9VM3CRkAqKHCX mY39hA8+NilZ8w+LkxCic6FpegmXjr3a0fEZFDGR8IhUEf/ufdy1yjtdCDSws6Pr9FIY sU9g== X-Gm-Message-State: AJcUukdn/YfkDkWP3AH3a/9uG5Lulf8zafpAFrM4PMpPhjmxzKxz0KW0 2DIAQSN60Zq13oxLNOiTHmFTOXsQ X-Google-Smtp-Source: ALg8bN6EX64aCFUPdWV8hWDdFnkp7eNbkhRYYpIqtCSjozC/qOFmnmzbO0s3kZ5sPgeY1sBRkDLCvQ== X-Received: by 2002:a0c:8322:: with SMTP id j31mr5155780qva.56.1547600899912; Tue, 15 Jan 2019 17:08:19 -0800 (PST) Received: from hideo ([186.139.31.173]) by smtp.gmail.com with ESMTPSA id t5sm24270467qkl.14.2019.01.15.17.08.17 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 15 Jan 2019 17:08:18 -0800 (PST) From: Federico Tedin To: Tina Russell , 34001@debbugs.gnu.org Subject: Re: bug#34001: 26.1.90; :distant-foreground face property fails to work in most cases References: Date: Tue, 15 Jan 2019 22:08:15 -0300 In-Reply-To: (Tina Russell's message of "Sun, 6 Jan 2019 14:31:51 -0800") Message-ID: <87a7k1l88w.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.1 (gnu/linux) MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 34001 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 (-) --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Tina Russell writes: > :distant-foreground is a very useful concept for a face property: text > will be rendered with the :foreground color, unless it=E2=80=99s too clos= e to > the current background color, in which case :distant-foreground kicks > in. Like, try this in Eshell or IELM: > > (propertize "Greetings, esteemed Emacs developers!" 'face '(:foreground > "yellow" :background "yellow")) > > You=E2=80=99ll get a solid band of yellow, of course. But, with > :distant-foreground=E2=80=A6 > > (propertize "Greetings, esteemed Emacs developers!" 'face '(:foreground > "yellow" :background "yellow" :distant-foreground "black")) > > Now it is a friendly greeting. (Naturally, you wouldn=E2=80=99t normally = set > :background and :distant-foreground in the same face, this is just an > example.) > > But, try this: > > (propertize "Greetings, esteemed Emacs developers!" 'face '(:foreground > "yellow" :background "white" :distant-foreground "black")) > > :distant-foreground doesn=E2=80=99t kick in=E2=80=94and you=E2=80=99re le= ft with yellow-on-white > text that=E2=80=99s impossible to read, the exact scenario that > :distant-foreground was quite rightly designed to avoid. > > I=E2=80=99m not the only one who=E2=80=99s noticed this; there=E2=80=99s = a good StackExchange > thread from 2015 here: > https://emacs.stackexchange.com/questions/7982/ The author notes that > there should be a user option to set the amount of =E2=80=9Cdistance=E2= =80=9D (between > foreground and background colors) that is required for > distant-foreground to kick in, and adds that a good way to measure > color distance in real-world circumstances is described here: > http://web.mst.edu/~rhall/web_design/color_readability.html A commenter > suggested that he file a bug, but I can=E2=80=99t find an Emacs bug report > related to this issue, so I=E2=80=99m filing this now. > > I really hope this gets addressed, because :distant-foreground is a > really nice and clever feature. Thanks! > > In GNU Emacs 26.1.90 (build 2, x86_64-pc-linux-gnu, GTK+ Version 3.22.30) > of 2019-01-02 built on pannychis > Repository revision: 08840f2f7bfc6144bd163dd85efe87d28541e425 > Windowing system distributor 'The X.Org Foundation', version 11.0.11906000 > System Description: Ubuntu 18.04.1 LTS > > Configured using: > 'configure --with-xaw3d --with-modules --with-xwidgets' I've created a patch that introduces a new variable `face-near-same-color-threshold', with a default value of 30000 (as was defined in NEAR_SAME_COLOR_THRESHOLD in xfaces.c). Changing this variable's value will make certain color combinations be considered as 'same', which will lead to :distant-foreground being used. For example: M-: (setq face-near-same-color-threshold 200000) M-: (clear-font-cache) Then, using your third example, the text will be displayed with a black foregound. Is this a reasonable fix, or should we consider implementing another way of measuring distance between colors like Tina mentioned? --=-=-= Content-Type: text/x-diff Content-Disposition: attachment; filename=foreground.patch Content-Description: patch diff --git a/src/xfaces.c b/src/xfaces.c index cffa89e1f3..eeea165187 100644 --- a/src/xfaces.c +++ b/src/xfaces.c @@ -1157,8 +1157,6 @@ load_color (struct frame *f, struct face *face, Lisp_Object name, #ifdef HAVE_WINDOW_SYSTEM -#define NEAR_SAME_COLOR_THRESHOLD 30000 - /* Load colors for face FACE which is used on frame F. Colors are specified by slots LFACE_BACKGROUND_INDEX and LFACE_FOREGROUND_INDEX of ATTRS. If the background color specified is not supported on F, @@ -1198,8 +1196,9 @@ load_face_colors (struct frame *f, struct face *face, face->foreground = load_color2 (f, face, fg, LFACE_FOREGROUND_INDEX, &xfg); dfg = attrs[LFACE_DISTANT_FOREGROUND_INDEX]; + int distance = color_distance (&xbg, &xfg); if (!NILP (dfg) && !UNSPECIFIEDP (dfg) - && color_distance (&xbg, &xfg) < NEAR_SAME_COLOR_THRESHOLD) + && distance < face_near_same_color_threshold) { if (EQ (attrs[LFACE_INVERSE_INDEX], Qt)) face->background = load_color (f, face, dfg, LFACE_BACKGROUND_INDEX); @@ -6768,6 +6767,12 @@ RESCALE-RATIO is a floating point number to specify how much larger a font of 10 point, we actually use a font of 10 * RESCALE-RATIO point. */); Vface_font_rescale_alist = Qnil; + DEFVAR_INT ("face-near-same-color-threshold", face_near_same_color_threshold, + doc: /* Number representing the minimum tolerated distance +between face background and foreground colors before distant-foreground is +used instead (when present). */); + face_near_same_color_threshold = 30000; + #ifdef HAVE_WINDOW_SYSTEM defsubr (&Sbitmap_spec_p); defsubr (&Sx_list_fonts); --=-=-=-- From debbugs-submit-bounces@debbugs.gnu.org Sat Jan 19 22:20:37 2019 Received: (at 34001) by debbugs.gnu.org; 20 Jan 2019 03:20:37 +0000 Received: from localhost ([127.0.0.1]:38217 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gl3f2-0004Rk-IP for submit@debbugs.gnu.org; Sat, 19 Jan 2019 22:20:36 -0500 Received: from mail-lj1-f175.google.com ([209.85.208.175]:42634) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gl3f0-0004RW-FS for 34001@debbugs.gnu.org; Sat, 19 Jan 2019 22:20:35 -0500 Received: by mail-lj1-f175.google.com with SMTP id l15-v6so14745677lja.9 for <34001@debbugs.gnu.org>; Sat, 19 Jan 2019 19:20:34 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc:content-transfer-encoding; bh=STqH1sLX25/kBb4idgxwJGFUKnAavj8s53wTHMxgJfU=; b=t/4ShXAAm6mUKp2B485xOfAzRklZgP6OOVBEhKyAvm6VDBrz4dO+XEyq7af64ZnsFR VnFyG7+Ya0VSaBYlNJcrl+yfQDsdTBjqxyW4dc1s875cohpHyxRnUX/092ZpX9tYivyX Qv50vKXQH5RRybDc6A4Nbnjyc0khfze8AbqkzMi8Q8bmNamz9WsjlxAHh6uJ1ffG8yLs r1uhsDyorDleHDxOMupRs8AiOhwOgwLPsyGYQIImavtuI8ya8gpr50hpBwhxj8e/YZFe 8DaE7gp8yE7IBhBRuEMm0n9E1u6CzQ2YrT2VqEFVTsu7VsxLqwzBcUU3i+x5JYFAE3l+ 74dg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc:content-transfer-encoding; bh=STqH1sLX25/kBb4idgxwJGFUKnAavj8s53wTHMxgJfU=; b=JjXdZxGlnx0MGtmW9mVSvmZvIS6xYWzBnuMv7zH+2vHN/vy3tQaNHc4dJnh+WWuhDT b740pZrwneXm/NtnwzuAgRLrbQppkrLilE+klzNctZCf1YyZQwopDaFVVL22PjTyv1Wl BIozIMx5EpF7NsofmlA8/QLtmQuxMSUfHndST4yysNcZFd2XZZmLuWVtuZEDEDQPHkMZ DvFNuEZ7G8YjCbVXjQz5THCcRQNO1jJ27K3uUeTdz0KG4OF3EiGyliDzt7G5UOVi2zG8 zuyMndrbQ5xJqBV2+ftymCtPFzVDCLsESuVYmchZ3HxQxR/hXXJPDWQxQ2UYVFWDFMau NjlA== X-Gm-Message-State: AJcUukca/58f3Pf8b8GjYk7jUb17Pr7UOf1Wx+5fu6RO+HlDGN3eUZwb xy1u1jadVNEraWFxi5Z0M7+XU/ySQFFBrAuhAB4= X-Google-Smtp-Source: ALg8bN6xuW9A9B1r5bfUAUIaHq6f7idF8vvgTI5w4Y9x89Vbr4t36GHccpFsEhlhqUN/IMlDATMy7ufmv9BTjjZxF70= X-Received: by 2002:a2e:5109:: with SMTP id f9-v6mr16163286ljb.52.1547954428316; Sat, 19 Jan 2019 19:20:28 -0800 (PST) MIME-Version: 1.0 References: <87a7k1l88w.fsf@gmail.com> In-Reply-To: <87a7k1l88w.fsf@gmail.com> From: Tina Russell Date: Sat, 19 Jan 2019 19:20:16 -0800 Message-ID: Subject: Re: bug#34001: 26.1.90; :distant-foreground face property fails to work in most cases To: Federico Tedin Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 34001 Cc: 34001@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 (-) Well, even if we change the backend for how color distance is measured, we=E2=80=99ll probably still need a user option for =E2=80=9Chow = much color distance is required for two colors to be considered appropriately distant,=E2=80=9D so it seems like a good place to start in any event. Thanks! On Tue, Jan 15, 2019 at 5:08 PM Federico Tedin wr= ote: > > Tina Russell writes: > > > :distant-foreground is a very useful concept for a face property: text > > will be rendered with the :foreground color, unless it=E2=80=99s too cl= ose to > > the current background color, in which case :distant-foreground kicks > > in. Like, try this in Eshell or IELM: > > > > (propertize "Greetings, esteemed Emacs developers!" 'face '(:foreground > > "yellow" :background "yellow")) > > > > You=E2=80=99ll get a solid band of yellow, of course. But, with > > :distant-foreground=E2=80=A6 > > > > (propertize "Greetings, esteemed Emacs developers!" 'face '(:foreground > > "yellow" :background "yellow" :distant-foreground "black")) > > > > Now it is a friendly greeting. (Naturally, you wouldn=E2=80=99t normall= y set > > :background and :distant-foreground in the same face, this is just an > > example.) > > > > But, try this: > > > > (propertize "Greetings, esteemed Emacs developers!" 'face '(:foreground > > "yellow" :background "white" :distant-foreground "black")) > > > > :distant-foreground doesn=E2=80=99t kick in=E2=80=94and you=E2=80=99re = left with yellow-on-white > > text that=E2=80=99s impossible to read, the exact scenario that > > :distant-foreground was quite rightly designed to avoid. > > > > I=E2=80=99m not the only one who=E2=80=99s noticed this; there=E2=80=99= s a good StackExchange > > thread from 2015 here: > > https://emacs.stackexchange.com/questions/7982/ The author notes that > > there should be a user option to set the amount of =E2=80=9Cdistance=E2= =80=9D (between > > foreground and background colors) that is required for > > distant-foreground to kick in, and adds that a good way to measure > > color distance in real-world circumstances is described here: > > http://web.mst.edu/~rhall/web_design/color_readability.html A commenter > > suggested that he file a bug, but I can=E2=80=99t find an Emacs bug rep= ort > > related to this issue, so I=E2=80=99m filing this now. > > > > I really hope this gets addressed, because :distant-foreground is a > > really nice and clever feature. Thanks! > > > > In GNU Emacs 26.1.90 (build 2, x86_64-pc-linux-gnu, GTK+ Version 3.22.3= 0) > > of 2019-01-02 built on pannychis > > Repository revision: 08840f2f7bfc6144bd163dd85efe87d28541e425 > > Windowing system distributor 'The X.Org Foundation', version 11.0.11906= 000 > > System Description: Ubuntu 18.04.1 LTS > > > > Configured using: > > 'configure --with-xaw3d --with-modules --with-xwidgets' > > I've created a patch that introduces a new variable > `face-near-same-color-threshold', with a default value of 30000 (as was > defined in NEAR_SAME_COLOR_THRESHOLD in xfaces.c). Changing this > variable's value will make certain color combinations be considered as > 'same', which will lead to :distant-foreground being used. For example: > > M-: (setq face-near-same-color-threshold 200000) > M-: (clear-font-cache) > > Then, using your third example, the text will be displayed with a black > foregound. > > Is this a reasonable fix, or should we consider implementing another way > of measuring distance between colors like Tina mentioned? > From debbugs-submit-bounces@debbugs.gnu.org Sun Jan 20 12:15:51 2019 Received: (at 34001) by debbugs.gnu.org; 20 Jan 2019 17:15:51 +0000 Received: from localhost ([127.0.0.1]:39133 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1glGhL-0007D3-3o for submit@debbugs.gnu.org; Sun, 20 Jan 2019 12:15:51 -0500 Received: from mail-qk1-f174.google.com ([209.85.222.174]:43276) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1glGhJ-0007Co-UM for 34001@debbugs.gnu.org; Sun, 20 Jan 2019 12:15:50 -0500 Received: by mail-qk1-f174.google.com with SMTP id z18so10846995qkj.10 for <34001@debbugs.gnu.org>; Sun, 20 Jan 2019 09:15:49 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version:content-transfer-encoding; bh=K8ywnO0mUIzyRulDZvoQU4detNcDd26tI9po4fqf4c0=; b=seDXDUd3r+eReaSk9DhHe4YOcVd38D2tVTX+O4BWbGVR93nEEuBdv+khuVzDRLXut6 uf2/Inp+RR+1iaLFWLQCAPtg6olhw0KCiHbM4nGkzwl80mRYqzJecnMNi6ythbliubZ3 6HmOkD0yXqK167HT6kg9cmbq7rZ47LduqcZAYV9QlJ/aZoxdkCP4IHDoWNLCpiX36vQQ hjXTDB1ewCd/k0d7ANOj7DzuZTqIvhsrlnjS1VkrR/i4E1UGdUxzHByM8rvrPZRaI1iT yKx+16mKITlUSQqva8nRi1uZPS6sbZ8Z8AHGVksvwCjURY37Ikhbh6zrIbBf7r6QYj62 mtlA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version:content-transfer-encoding; bh=K8ywnO0mUIzyRulDZvoQU4detNcDd26tI9po4fqf4c0=; b=q2RgZmq8ChV8Xb6paaXIDcBz88hJRKAeqqereshYPCgYB2GmOwGZQ8x+PWVazMCjdJ KZQs/gZlAWQ/aG3Nrf1s6xhIQzhV+zipCg7DBGr6oXvzg2bH4OoCf3F/R0oDQlO+EMdG 5ant/+vwrQx+SrLZbekfedmCEA0Dd1p7fVquuIX11DqyqSTj0m/8EqiMGyQkunbxLAos YKjJh8lmxHar4IlD+Tj1ZCpTtUa7H2Wvxexuj6i0XIae5YcqTwQUB/uFoMQwLjwPmYbL 1iXK5Meh8RX86UFIu9zDqmZKTvkSU/WPMRN6jdloniRsHGB1izHQCy1D5lrbupU25/Vf 1ycg== X-Gm-Message-State: AJcUukfftCyPkLW7VQ72U+7B2oo9HyOjMCgKbhJcG8BN5MJn1rgbtNMi fWMr2HruKzWwDWd3AbjB+VCA6/iBtA8= X-Google-Smtp-Source: ALg8bN4JHvw26b6nKjn542kGgAl9R6h6CkMlsvkH8pp6XTRFI76OSXeO3bTsaw6IAt+Nl81jQvYrow== X-Received: by 2002:a37:5647:: with SMTP id k68mr21559450qkb.250.1548004543912; Sun, 20 Jan 2019 09:15:43 -0800 (PST) Received: from lead ([186.139.31.173]) by smtp.gmail.com with ESMTPSA id e29sm39753046qtc.74.2019.01.20.09.15.41 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Sun, 20 Jan 2019 09:15:42 -0800 (PST) From: Federico Tedin To: Tina Russell Subject: Re: bug#34001: 26.1.90; :distant-foreground face property fails to work in most cases References: <87a7k1l88w.fsf@gmail.com> Date: Sun, 20 Jan 2019 14:15:39 -0300 In-Reply-To: (Tina Russell's message of "Sat, 19 Jan 2019 19:20:16 -0800") Message-ID: <87k1izgshw.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 34001 Cc: 34001@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 (-) > Well, even if we change the backend for how color distance is > measured, we=E2=80=99ll probably still need a user option for =E2=80=9Cho= w much color > distance is required for two colors to be considered appropriately > distant,=E2=80=9D so it seems like a good place to start in any event. I agree! Either option should be configurable. We should wait and see if a maintainer has any thoughts on this as well. From debbugs-submit-bounces@debbugs.gnu.org Mon Jan 21 17:58:17 2019 Received: (at 34001) by debbugs.gnu.org; 21 Jan 2019 22:58:17 +0000 Received: from localhost ([127.0.0.1]:40632 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gliWG-0004e7-O5 for submit@debbugs.gnu.org; Mon, 21 Jan 2019 17:58:17 -0500 Received: from mail-ed1-f44.google.com ([209.85.208.44]:36052) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gliWE-0004dt-3P for 34001@debbugs.gnu.org; Mon, 21 Jan 2019 17:58:14 -0500 Received: by mail-ed1-f44.google.com with SMTP id f23so17831366edb.3 for <34001@debbugs.gnu.org>; Mon, 21 Jan 2019 14:58:13 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=tcd-ie.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version:content-transfer-encoding; bh=TxB33x7eoEhjl1HHLtCD4fGeGe43CX9p6dRD4oeLQUI=; b=XomA2Nas+IMH5AK/hlL8F+pYvHkYfWwGGQ7eE3Ch3+QYuiXQI33pkb+5ZP9zQXRX5B 81nZKOwaKNx/A3p4NPCqeUMBmHFJxMuBlri/lBzvFZzevo48bJiWD+XjKQolsC2o831+ K0/kMv/Ym6Gei6uC6y/RERUM9FtjXIbjMkRevjj7pLZQ/fnu5kqmaxgWoFxJgEVG0+6a p9pphTkkQrLB+5eJ2PAyJLEzksBkeVCcSIbAErVJjnNc7lSol1YmlgArd90WeExzoy16 Ixw8kOVNNkkWXqc7Zgu3RXCkg34rnjNNQrNqnA4yciBWYZcNCJPNGKK/syPO0BQKuTZn vf4g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version:content-transfer-encoding; bh=TxB33x7eoEhjl1HHLtCD4fGeGe43CX9p6dRD4oeLQUI=; b=q7k4BPb/2LSOmgM0haSBr2FUZUGmvUQWPBE7P2rd0U5uLN5G2CcM6V9N45PKItWYUg CD0+fMTycgoIb8wzsTNMRLhLgagItBnk6D/yCnARwNQ1Sfxr02lfN6PTk8MdwZwuFayU IBPf2UCHjSYWXfMPBbM7IkrrlLUYuL+3JoWh5MamJhpyAeH1O0HMm6/1sX4rRk0Uye5G hwNhQsCBTjx9nCZmTDTMfY/1fzfGfHCijsU9D/opvtEpJjCh1vV859CM2bSr8sfzFr1T VZiRt7djIIW3NBjjNk4tYppDtS8p7mDHtuce+hCPS6xX9ilXqlc04NGqqh7HIk2LmfFr joUw== X-Gm-Message-State: AJcUukc4y0NdWZckhZujdUh6M4tGmnSDskP0eJX/J9wOeFAy1+lNCxzs oyHZKrHiZvxp4/QqVvKfIAZ9LA== X-Google-Smtp-Source: ALg8bN5zkMNUzZ+ukpAe7g25IEl1kT9pLJcPHbFPCwB6e8Rsjc4WGqjoszrXYKjg9r7Gp12obBXE0w== X-Received: by 2002:a05:6402:8d2:: with SMTP id d18mr29008541edz.119.1548111488244; Mon, 21 Jan 2019 14:58:08 -0800 (PST) Received: from localhost ([2a02:8084:20e2:c380:20c2:134e:4f3a:683a]) by smtp.gmail.com with ESMTPSA id j4sm9240928edh.69.2019.01.21.14.58.07 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Mon, 21 Jan 2019 14:58:07 -0800 (PST) From: "Basil L. Contovounesios" To: Tina Russell Subject: Re: bug#34001: 26.1.90; :distant-foreground face property fails to work in most cases References: Date: Mon, 21 Jan 2019 22:58:06 +0000 In-Reply-To: (Tina Russell's message of "Sun, 6 Jan 2019 14:31:51 -0800") Message-ID: <87muntwrcx.fsf@tcd.ie> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 34001 Cc: Julien Danjou , 34001@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 (-) Tina Russell writes: > I=E2=80=99m not the only one who=E2=80=99s noticed this; there=E2=80=99s = a good StackExchange > thread from 2015 here: > https://emacs.stackexchange.com/questions/7982/ The author notes that > there should be a user option to set the amount of =E2=80=9Cdistance=E2= =80=9D (between > foreground and background colors) that is required for > distant-foreground to kick in It would be nice if any work in this area took into consideration existing efforts by Julien Danjou (CCed) in lisp/net/shr-color.el (see e.g. user options shr-color-visible-luminance-min and shr-color-visible-distance-min and function shr-color-visible). For example, the library may end up either duplicating existing core logic, or prove sufficiently useful that it is moved to a less SHR-specific location (I'm just speculating). > , and adds that a good way to measure > color distance in real-world circumstances is described here: > http://web.mst.edu/~rhall/web_design/color_readability.html A commenter > suggested that he file a bug, but I can=E2=80=99t find an Emacs bug report > related to this issue, so I=E2=80=99m filing this now. FWIW, there has been some discussion of colour distances in bug#25525 and bug#30295: https://debbugs.gnu.org/25525 https://debbugs.gnu.org/30295 --=20 Basil From debbugs-submit-bounces@debbugs.gnu.org Mon Jan 21 18:09:55 2019 Received: (at 34001) by debbugs.gnu.org; 21 Jan 2019 23:09:55 +0000 Received: from localhost ([127.0.0.1]:40642 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1glihT-0004v8-Bf for submit@debbugs.gnu.org; Mon, 21 Jan 2019 18:09:55 -0500 Received: from dancol.org ([96.126.100.184]:37838) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1glihR-0004uz-7h for 34001@debbugs.gnu.org; Mon, 21 Jan 2019 18:09:50 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=dancol.org; s=x; h=Content-Transfer-Encoding:Content-Type:In-Reply-To:MIME-Version:Date:Message-ID:From:References:Cc:To:Subject; bh=GlwuhyM2TBPzSLT7PKswPasuIoloTSe2fo8OKRM77kA=; b=dUvZdNtUUum/JcCe6THrKPfZ6mG//0WwdH6i20ui40AB6qXG5EFEq0Q6yqyjI6NAxcdzMKGMFvKVOF9rxayOOpNav88HfWZZ8uGaTK0kkODrTVAJy71QV24ZlpPjkkcmBhDirEEmYERyJcSctp8ckybI10DEp/ZxlkvrX/fUx/lEDStz+83rOrr1X0L8eB5HGgY2ExOtd7Y5nGMs3Kpxtvw2ft5TBM0hkIYNH5FJvJC0pLsUmKRPPevuivBiTBmrWZWuiVrwFS35O2XSQEIL9JPVyVxnqTsciAempEe1JKhovwqydYu3o2ZiM8aAzcQm9b/yj/zh8jVgDS+0v7bxKA==; Received: from [2604:4080:1321:9a00:281a:fe2d:5d87:d563] by dancol.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.84_2) (envelope-from ) id 1glihP-00074h-1s; Mon, 21 Jan 2019 15:09:47 -0800 Subject: Re: bug#34001: 26.1.90; :distant-foreground face property fails to work in most cases To: "Basil L. Contovounesios" , Tina Russell References: <87muntwrcx.fsf@tcd.ie> From: Daniel Colascione Message-ID: <8fee11d3-aaad-2173-f05e-05c83a84dbb4@dancol.org> Date: Mon, 21 Jan 2019 18:09:39 -0500 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.2.1 MIME-Version: 1.0 In-Reply-To: <87muntwrcx.fsf@tcd.ie> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit X-Spam-Score: -0.0 (/) X-Debbugs-Envelope-To: 34001 Cc: Julien Danjou , 34001@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 1/21/19 5:58 PM, Basil L. Contovounesios wrote: > Tina Russell writes: > >> I’m not the only one who’s noticed this; there’s a good StackExchange >> thread from 2015 here: >> https://emacs.stackexchange.com/questions/7982/ The author notes that >> there should be a user option to set the amount of “distance” (between >> foreground and background colors) that is required for >> distant-foreground to kick in > > It would be nice if any work in this area took into consideration > existing efforts by Julien Danjou (CCed) in lisp/net/shr-color.el > (see e.g. user options shr-color-visible-luminance-min and > shr-color-visible-distance-min and function shr-color-visible). > > For example, the library may end up either duplicating existing core > logic, or prove sufficiently useful that it is moved to a less > SHR-specific location (I'm just speculating). > >> , and adds that a good way to measure >> color distance in real-world circumstances is described here: >> http://web.mst.edu/~rhall/web_design/color_readability.html A commenter >> suggested that he file a bug, but I can’t find an Emacs bug report >> related to this issue, so I’m filing this now. > > FWIW, there has been some discussion of colour distances in bug#25525 > and bug#30295: > > https://debbugs.gnu.org/25525 > https://debbugs.gnu.org/30295 > I think I had a proposal a long time ago to just call into lisp during redisplay in order to compute the color composition. From debbugs-submit-bounces@debbugs.gnu.org Fri Mar 01 03:40:32 2019 Received: (at 34001-done) by debbugs.gnu.org; 1 Mar 2019 08:40:32 +0000 Received: from localhost ([127.0.0.1]:55781 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gzdia-0002GH-2T for submit@debbugs.gnu.org; Fri, 01 Mar 2019 03:40:32 -0500 Received: from eggs.gnu.org ([209.51.188.92]:42069) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gzdiY-0002G4-K1 for 34001-done@debbugs.gnu.org; Fri, 01 Mar 2019 03:40:30 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]:59819) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gzdiT-0007sE-BC; Fri, 01 Mar 2019 03:40:25 -0500 Received: from [176.228.60.248] (port=3697 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1gzdiS-0007o4-VM; Fri, 01 Mar 2019 03:40:25 -0500 Date: Fri, 01 Mar 2019 10:40:10 +0200 Message-Id: <83o96vhtsl.fsf@gnu.org> From: Eli Zaretskii To: Federico Tedin In-reply-to: <87a7k1l88w.fsf@gmail.com> (message from Federico Tedin on Tue, 15 Jan 2019 22:08:15 -0300) Subject: Re: bug#34001: 26.1.90; :distant-foreground face property fails to work in most cases References: <87a7k1l88w.fsf@gmail.com> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Spam-Score: -0.0 (/) X-Debbugs-Envelope-To: 34001-done Cc: 34001-done@debbugs.gnu.org, tinakellyrussell@gmail.com 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 (-) > From: Federico Tedin > Date: Tue, 15 Jan 2019 22:08:15 -0300 > > I've created a patch that introduces a new variable > `face-near-same-color-threshold', with a default value of 30000 (as was > defined in NEAR_SAME_COLOR_THRESHOLD in xfaces.c). Changing this > variable's value will make certain color combinations be considered as > 'same', which will lead to :distant-foreground being used. For example: Sorry for the long delay, I've now pushed your change to the master branch. Please in the future provide a ChangeLog-style commit log message for your changes, and also accompany them with the pertinent updates for the documentation. I did that for this change. Thanks again for working on this. From debbugs-submit-bounces@debbugs.gnu.org Fri Mar 01 07:44:49 2019 Received: (at 34001-done) by debbugs.gnu.org; 1 Mar 2019 12:44:49 +0000 Received: from localhost ([127.0.0.1]:55882 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gzhWz-00028J-ED for submit@debbugs.gnu.org; Fri, 01 Mar 2019 07:44:49 -0500 Received: from mail-qk1-f172.google.com ([209.85.222.172]:40172) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gzhWx-000283-Ak for 34001-done@debbugs.gnu.org; Fri, 01 Mar 2019 07:44:47 -0500 Received: by mail-qk1-f172.google.com with SMTP id h28so14152824qkk.7 for <34001-done@debbugs.gnu.org>; Fri, 01 Mar 2019 04:44:47 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=o13bh/9zETm7hG9ifVkamlmSnBJWYLPAWiBbf/CVTn8=; b=uEpq0vIGzPvMsbSS8dhK5Q1AhujYxsu5vz4r1fxqevsBkcRIcD/nKAoeLE9fi0dE5d NsDjprGeu6hdAzj+vaU58JHq6YjSvqcqAL7L4OzgE7yR7UTgVipqDZjJzOcOOTGRPDBd cPgW/01jIr+yBdNjeTyeZ++9k0aUGLCw/M3Dw/DqGI8cGWOyDIL2NaJWL73OOoKbPioU OVY70NGaS7PCg7RoBwKuBdAHnZ8k1bcRhgvo8yNFXUhKWWfmFmACk0T09gjtPyW3MaPk itNbpf1zxgAVRsVId79UOtTlJh5oV5V2pBEpjMhNqA2IbOBR4PRWP0lpU0iNXtts8FbM k1pQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=o13bh/9zETm7hG9ifVkamlmSnBJWYLPAWiBbf/CVTn8=; b=nSBq9708OKzhwUfK74V92qZ3MhvjTKhHGCgBjfpcBL5oslPy8T8nkLAK+VzFZvc3q0 zrI/nBEHfVMpdqZxvxoWRXXFbtTUfedBUoV4IssNSlnfPhBqIdW9o4Vq9EuzzNwjjHT1 MV90VqVqqgDVSLIP8JkpngzNwzFUjbl6vnEIcyJT5u7NQ/jPXsJNJY+m5k6IXlsqCwDO 3LrT4V/F8rQq24POACbdtd9Ge7Lt6RSTWx/2vrf3wu8Z5LnwfLoIoOvnoPqPH5sz7x9C 5M9v2aYAGDmxc86PjUVMmC0kP62U8xGfdqLqZPngV5haR0G9b/cnA1ujxmE8j/Tsxz8O 7jiA== X-Gm-Message-State: APjAAAXm2OQKtURWqi3yuEkE/Rq88ejdxM7VkM7wKx22os+fnRa1ivZK d9nz30lnrD2UcnjCZSxznPqSVDk8dK5mUrzWLLE= X-Google-Smtp-Source: APXvYqyBSgXvO4IDQNIN6qd1Cd2ASOCANdopvRcreUQDrKoVa+DPfEfv9t/+0/29/2x9jZ/9by24WAZfXK/PJ+Ddllc= X-Received: by 2002:a37:f513:: with SMTP id l19mr3696449qkk.313.1551444281629; Fri, 01 Mar 2019 04:44:41 -0800 (PST) MIME-Version: 1.0 References: <87a7k1l88w.fsf@gmail.com> <83o96vhtsl.fsf@gnu.org> In-Reply-To: <83o96vhtsl.fsf@gnu.org> From: Federico Tedin Date: Fri, 1 Mar 2019 09:44:30 -0300 Message-ID: Subject: Re: bug#34001: 26.1.90; :distant-foreground face property fails to work in most cases To: Eli Zaretskii Content-Type: multipart/alternative; boundary="0000000000004ba246058307c532" X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 34001-done Cc: 34001-done@debbugs.gnu.org, tinakellyrussell@gmail.com 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 (-) --0000000000004ba246058307c532 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Thanks Eli! I have a question regarding commit messages and documentation: should I include them in the first iteration of the patch I created, or should I wait until there=E2=80=99s been some conversation first? Until now I=E2=80= =99ve chosen the first option since I=E2=80=99m not always sure the patch I created is correct/applicable/etc. On Fri, 1 Mar 2019 at 05:40 Eli Zaretskii wrote: > > From: Federico Tedin > > Date: Tue, 15 Jan 2019 22:08:15 -0300 > > > > I've created a patch that introduces a new variable > > `face-near-same-color-threshold', with a default value of 30000 (as was > > defined in NEAR_SAME_COLOR_THRESHOLD in xfaces.c). Changing this > > variable's value will make certain color combinations be considered as > > 'same', which will lead to :distant-foreground being used. For example: > > Sorry for the long delay, I've now pushed your change to the master > branch. > > Please in the future provide a ChangeLog-style commit log message for > your changes, and also accompany them with the pertinent updates for > the documentation. I did that for this change. > > Thanks again for working on this. > --0000000000004ba246058307c532 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Thanks Eli!

<= div dir=3D"auto">I have a question regarding commit messages and documentat= ion: should I include them in the first iteration of the patch I created, o= r should I wait until there=E2=80=99s been some conversation first?=C2=A0 U= ntil now I=E2=80=99ve chosen the first option since I=E2=80=99m not always = sure the patch I created is correct/applicable/etc.

> From: Federico Ted= in <federic= otedin@gmail.com>
> Date: Tue, 15 Jan 2019 22:08:15 -0300
>
> I've created a patch that introduces a new variable
> `face-near-same-color-threshold', with a default value of 30000 (a= s was
> defined in NEAR_SAME_COLOR_THRESHOLD in xfaces.c). Changing this
> variable's value will make certain color combinations be considere= d as
> 'same', which will lead to :distant-foreground being used. For= example:

Sorry for the long delay, I've now pushed your change to the master
branch.

Please in the future provide a ChangeLog-style commit log message for
your changes, and also accompany them with the pertinent updates for
the documentation.=C2=A0 I did that for this change.

Thanks again for working on this.
--0000000000004ba246058307c532-- From debbugs-submit-bounces@debbugs.gnu.org Fri Mar 01 08:49:26 2019 Received: (at 34001) by debbugs.gnu.org; 1 Mar 2019 13:49:26 +0000 Received: from localhost ([127.0.0.1]:55929 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gziXV-0003km-Qy for submit@debbugs.gnu.org; Fri, 01 Mar 2019 08:49:26 -0500 Received: from eggs.gnu.org ([209.51.188.92]:45778) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gziXU-0003kX-LG for 34001@debbugs.gnu.org; Fri, 01 Mar 2019 08:49:24 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]:48345) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gziXM-0003ry-Sl; Fri, 01 Mar 2019 08:49:18 -0500 Received: from [176.228.60.248] (port=2854 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1gziXL-00041n-5j; Fri, 01 Mar 2019 08:49:16 -0500 Date: Fri, 01 Mar 2019 15:48:49 +0200 Message-Id: <83a7ieiu2m.fsf@gnu.org> From: Eli Zaretskii To: Federico Tedin In-reply-to: (message from Federico Tedin on Fri, 1 Mar 2019 09:44:30 -0300) Subject: Re: bug#34001: 26.1.90; :distant-foreground face property fails to work in most cases References: <87a7k1l88w.fsf@gmail.com> <83o96vhtsl.fsf@gnu.org> MIME-version: 1.0 Content-type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 34001 Cc: 34001@debbugs.gnu.org, tinakellyrussell@gmail.com 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 (-) > From: Federico Tedin > Date: Fri, 1 Mar 2019 09:44:30 -0300 > Cc: 34001-done@debbugs.gnu.org, tinakellyrussell@gmail.com > > I have a question regarding commit messages and documentation: should I include them in the first iteration > of the patch I created, or should I wait until there’s been some conversation first? Until now I’ve chosen the > first option since I’m not always sure the patch I created is correct/applicable/etc. Please include them with all the iterations, so that whoever ends up pushing the changes will only need to look at a single email message. From unknown Tue Jun 17 01:35:37 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Sat, 30 Mar 2019 11:24:03 +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