GNU bug report logs - #32921
emacsclient obeys Xresources even when launched with -nw

Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.

Package: emacs; Reported by: Dimitrios Apostolou <jimis@HIDDEN>; Keywords: moreinfo; Done: Lars Ingebrigtsen <larsi@HIDDEN>; Maintainer for emacs is bug-gnu-emacs@HIDDEN.
bug marked as fixed in version 29.1, send any further explanations to 32921 <at> debbugs.gnu.org and Dimitrios Apostolou <jimis@HIDDEN> Request was from Lars Ingebrigtsen <larsi@HIDDEN> to control <at> debbugs.gnu.org. Full text available.

Message received at 32921 <at> debbugs.gnu.org:


Received: (at 32921) by debbugs.gnu.org; 19 Jun 2022 13:29:03 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sun Jun 19 09:29:03 2022
Received: from localhost ([127.0.0.1]:50887 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1o2uz9-0005e1-6r
	for submit <at> debbugs.gnu.org; Sun, 19 Jun 2022 09:29:03 -0400
Received: from quimby.gnus.org ([95.216.78.240]:50758)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <larsi@HIDDEN>) id 1o2uz6-0005db-Ic
 for 32921 <at> debbugs.gnu.org; Sun, 19 Jun 2022 09:29:01 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org;
 s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date:
 References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding:
 Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender:
 Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:
 List-Subscribe:List-Post:List-Owner:List-Archive;
 bh=XWEI1+NF0O3TlBOhdIdJwDnbiQrOd3/MuepwxtiTEJI=; b=AdJdNT3qO8bHiU/oOD2wEzSu1c
 Wx3wBsAi6JjXPnTZmb5bgC16Ecvro5t5KpnQGtAh/2Iu2Za3ylAlj0uB379EH01J5nWoX0XVYH3qU
 oFlNJkLdj7P8WW0zWcuyOoriSzDrfitlz7oDTxnudZUjEy/WRqwoDwBl/H2ZYDp0pvFM=;
Received: from [84.212.220.105] (helo=xo)
 by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.92) (envelope-from <larsi@HIDDEN>)
 id 1o2uyx-0006FS-5z; Sun, 19 Jun 2022 15:28:54 +0200
From: Lars Ingebrigtsen <larsi@HIDDEN>
To: Dimitrios Apostolou <jimis@HIDDEN>
Subject: Re: bug#32921: emacsclient obeys Xresources even when launched with
 -nw
References: <alpine.LFD.2.21.1810031946120.6536@jimisX1>
 <87o7zvc8xi.fsf@HIDDEN>
Date: Sun, 19 Jun 2022 15:28:49 +0200
In-Reply-To: <87o7zvc8xi.fsf@HIDDEN> (Lars Ingebrigtsen's message of "Wed,
 18 May 2022 14:38:33 +0200")
Message-ID: <87czf4wzn2.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org",
 has NOT identified this incoming email as spam.  The original
 message has been attached to this so you can view it or label
 similar future email.  If you have any questions, see
 @@CONTACT_ADDRESS@@ for details.
 Content preview: Lars Ingebrigtsen <larsi@HIDDEN> writes: > in term/x-win.el
 -- it sets reverse for all new frames, so when the -nw > frame appears, it
 also gets reverted (which isn't what we want, I > think). > > If I just remove
 this, then everything still [...] 
 Content analysis details:   (-2.9 points, 5.0 required)
 pts rule name              description
 ---- ---------------------- --------------------------------------------------
 -1.0 ALL_TRUSTED            Passed through trusted hosts only via SMTP
 -1.9 BAYES_00               BODY: Bayes spam probability is 0 to 1%
 [score: 0.0000]
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 32921
Cc: 32921 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

Lars Ingebrigtsen <larsi@HIDDEN> writes:

> in term/x-win.el -- it sets reverse for all new frames, so when the -nw
> frame appears, it also gets reverted (which isn't what we want, I
> think).
>
> If I just remove this, then everything still works fine (and the -nw
> client problem disappears), because:

[...]

> So it's always handled anyway, and the default-frame-alist setting is
> just counter-productive, I think?
>
> Does anybody see any possible negative consequences of just removing
> that code from x-win.el?

Much discussion ensued after this, and there's good arguments on both
sides.  I.e., this is long standing (if odd behaviour), so it might
annoy people to change this.  However, it is a real bug -- i.e., we
handle the reverseVideo X resource in a really abnormal way, like we
handle no other X resources, so I think we should fix it anyway.

So I've now done that in Emacs 29, and added a NEWS entry saying that
this is backwards incompatible.  We'll see whether anybody complaints.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#32921; Package emacs. Full text available.

Message received at 32921 <at> debbugs.gnu.org:


Received: (at 32921) by debbugs.gnu.org; 20 May 2022 11:30:28 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Fri May 20 07:30:28 2022
Received: from localhost ([127.0.0.1]:37801 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1ns0pw-0001m3-6u
	for submit <at> debbugs.gnu.org; Fri, 20 May 2022 07:30:28 -0400
Received: from quimby.gnus.org ([95.216.78.240]:33948)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <larsi@HIDDEN>) id 1ns0pu-0001fX-Qt
 for 32921 <at> debbugs.gnu.org; Fri, 20 May 2022 07:30:27 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org;
 s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date:
 References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding:
 Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender:
 Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:
 List-Subscribe:List-Post:List-Owner:List-Archive;
 bh=HiVsMAZaDRZAY5OWZp4hzEQ/yud4+TDJKs+3UhgJZD8=; b=eOsJoKUfgQpf7gADEkH9C/Tv/R
 4o/Fuqgr1oXe38e5si5dOElnkFrWQaNDQAl4Lgw7hBTzeG4zNR44sjnDoca/nH6DeTF5vzzSlODea
 gSiyEmTv0N8cTN6P8o25kgLZrj+qLKPtpePlqTrqh9ys2AMtQTWlYQRqWVwaeYpZPJzw=;
Received: from [84.212.220.105] (helo=xo)
 by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.92) (envelope-from <larsi@HIDDEN>)
 id 1ns0pm-00076U-41; Fri, 20 May 2022 13:30:20 +0200
From: Lars Ingebrigtsen <larsi@HIDDEN>
To: Eli Zaretskii <eliz@HIDDEN>
Subject: Re: bug#32921: emacsclient obeys Xresources even when launched with
 -nw
References: <alpine.LFD.2.21.1810031946120.6536@jimisX1>
 <87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yOTo0MyswMDowMJk4DJAAAAAldEVYdGRhdGU6bW9kaWZ5ADIwMjItMDUtMjBU
 MTE6Mjk6NDMrMDA6MDDoZbQsAAAAAElFTkSuQmCC
X-Now-Playing: Sonoko's _La Debutante_: "Romeo Sama"
Date: Fri, 20 May 2022 13:30:16 +0200
In-Reply-To: <83ilq0bh94.fsf@HIDDEN> (Eli Zaretskii's message of "Fri, 20 May
 2022 14:00:55 +0300")
Message-ID: <87r14o30hj.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org",
 has NOT identified this incoming email as spam.  The original
 message has been attached to this so you can view it or label
 similar future email.  If you have any questions, see
 @@CONTACT_ADDRESS@@ for details.
 Content preview:  Eli Zaretskii <eliz@HIDDEN> writes: > Moreover,
 I don't really
 see the rationale for such a change? Why > consider the X resources applicable
 to the initial frame, but not to > the consequent ones? I just thought of
 that a place to stash the darn thing, if we wanted to make it possible for
 users to retrieve it. 
 Content analysis details:   (-2.9 points, 5.0 required)
 pts rule name              description
 ---- ---------------------- --------------------------------------------------
 -1.0 ALL_TRUSTED            Passed through trusted hosts only via SMTP
 -1.9 BAYES_00               BODY: Bayes spam probability is 0 to 1%
 [score: 0.0000]
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 32921
Cc: luangruo@HIDDEN, 32921 <at> debbugs.gnu.org, jimis@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

Eli Zaretskii <eliz@HIDDEN> writes:

> Moreover, I don't really see the rationale for such a change?  Why
> consider the X resources applicable to the initial frame, but not to
> the consequent ones?

I just thought of that a place to stash the darn thing, if we wanted to
make it possible for users to retrieve it.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#32921; Package emacs. Full text available.

Message received at 32921 <at> debbugs.gnu.org:


Received: (at 32921) by debbugs.gnu.org; 20 May 2022 11:01:04 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Fri May 20 07:01:04 2022
Received: from localhost ([127.0.0.1]:37729 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1ns0NT-0005cx-TY
	for submit <at> debbugs.gnu.org; Fri, 20 May 2022 07:01:04 -0400
Received: from eggs.gnu.org ([209.51.188.92]:50538)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <eliz@HIDDEN>) id 1ns0NS-0005Wf-Rn
 for 32921 <at> debbugs.gnu.org; Fri, 20 May 2022 07:01:03 -0400
Received: from fencepost.gnu.org ([2001:470:142:3::e]:37598)
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1ns0NN-00040U-GW; Fri, 20 May 2022 07:00:57 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org;
 s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date:
 mime-version; bh=MfZMCD1TULviJtbtmYNh0N+xxTYFleIUo/LTq3xun5k=; b=SUztYT/Yg0uQ
 tw8NU5/65sqBSlSe7Nm6LlZkh8IvawFakY0CKRcGdPTxeTra5SnehWL7wZ4EnOsS6pYcEScFToAHg
 cFYdHQTJFOS7H7L3wEMw5hh7Zh6aDkglzXMAYXKqcHreYAeXMQNsowBUq9FvsrPGJqvxLo6VRgdfJ
 AnHV3s5SXsw0DL20hraxVqNtfDY3PO7qKTYdnmG2lAXtvFCJf44Jeoe2MqRYPGc5v8gv1ovM/Lh6H
 hUzC1RrLp/h8tVxe0QVIltJMwvuDUw5rqQYndxM9ngJaTV7ltvPa0IxNpCyzC0D4uHOgJ2Nlj7lyT
 msP7mWW/0Rafey+qh4v6dQ==;
Received: from [87.69.77.57] (port=3087 helo=home-c4e4a596f7)
 by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1ns0NM-0007tO-VQ; Fri, 20 May 2022 07:00:57 -0400
Date: Fri, 20 May 2022 14:00:55 +0300
Message-Id: <83ilq0bh94.fsf@HIDDEN>
From: Eli Zaretskii <eliz@HIDDEN>
To: Lars Ingebrigtsen <larsi@HIDDEN>
In-Reply-To: <87pmk8621s.fsf@HIDDEN> (message from Lars Ingebrigtsen on Fri, 
 20 May 2022 10:28:15 +0200)
Subject: Re: bug#32921: emacsclient obeys Xresources even when launched with
 -nw
References: <alpine.LFD.2.21.1810031946120.6536@jimisX1>
 <87o7zvc8xi.fsf@HIDDEN> <835ym3f0xt.fsf@HIDDEN>
 <875ym3c7bj.fsf@HIDDEN> <834k1nezs3.fsf@HIDDEN>
 <87ee0raqy2.fsf@HIDDEN> <87czgal2tt.fsf@HIDDEN>
 <838rqydmy8.fsf@HIDDEN> <878rqyklqj.fsf@HIDDEN>
 <831qwqdj2w.fsf@HIDDEN> <875ym19lat.fsf@HIDDEN>
 <831qwod78l.fsf@HIDDEN> <87pmk8621s.fsf@HIDDEN>
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 32921
Cc: luangruo@HIDDEN, 32921 <at> debbugs.gnu.org, jimis@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

> From: Lars Ingebrigtsen <larsi@HIDDEN>
> Cc: luangruo@HIDDEN,  32921 <at> debbugs.gnu.org,  jimis@HIDDEN
> Date: Fri, 20 May 2022 10:28:15 +0200
> 
> I wondered whether it might make sense to have the x-win.el code snippet
> stash the reverseVideo data in `initial-frame-alist', but I didn't
> investigate what effect that would have (if any)...

initial-frame-alist is only for the initial frame shown by Emacs.  So
making that change is also a significant change in behavior.

Moreover, I don't really see the rationale for such a change?  Why
consider the X resources applicable to the initial frame, but not to
the consequent ones?




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#32921; Package emacs. Full text available.

Message received at 32921 <at> debbugs.gnu.org:


Received: (at 32921) by debbugs.gnu.org; 20 May 2022 10:50:49 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Fri May 20 06:50:49 2022
Received: from localhost ([127.0.0.1]:37683 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1ns0DZ-0004Go-2d
	for submit <at> debbugs.gnu.org; Fri, 20 May 2022 06:50:49 -0400
Received: from eggs.gnu.org ([209.51.188.92]:49116)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <eliz@HIDDEN>) id 1ns0DX-0004Gb-Cl
 for 32921 <at> debbugs.gnu.org; Fri, 20 May 2022 06:50:48 -0400
Received: from fencepost.gnu.org ([2001:470:142:3::e]:36332)
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1ns0DS-0002ZX-1e; Fri, 20 May 2022 06:50:42 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org;
 s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date:
 mime-version; bh=vtU8IVVDyZomFE02E1gzPTk2nC0HUryLyazf4vnU224=; b=rti+5QBDzzaO
 4iSfdVuvEspKWtdAf5d7BpfWhRcN0i/evLAz6w3wLO1+MzES4kNajhcc9qjpDqWmfDJRKvcesXHRn
 jmpemGzRyULNkILGSLKxsa0POE7N1KFfFbqsxdm17is36HCz0OkcHIPh9pX6qh8Yf9OJCRXHZIYFM
 dYTlZiDxH2fTxAlZH4K4JaX707rKSsc+RL6LIB+yh/ZPAEXojmPl2h6W9Mm5R82fZPLzjXFmAQH59
 HtFzOnYZhkPvGmmpCq7NMpwi9TAQMaoPYIHN8x/VRVOmGl7hU3O8nIEC7AfRAGG0F/cQAFMkmXmXu
 1ft/zgssfZHfTsP0frfflA==;
Received: from [87.69.77.57] (port=2434 helo=home-c4e4a596f7)
 by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1ns0DQ-0006hE-PL; Fri, 20 May 2022 06:50:41 -0400
Date: Fri, 20 May 2022 13:50:40 +0300
Message-Id: <83leuwbhq7.fsf@HIDDEN>
From: Eli Zaretskii <eliz@HIDDEN>
To: Po Lu <luangruo@HIDDEN>
In-Reply-To: <87a6bczkd5.fsf@HIDDEN> (message from Po Lu on Fri, 20 May
 2022 16:19:50 +0800)
Subject: Re: bug#32921: emacsclient obeys Xresources even when launched with
 -nw
References: <alpine.LFD.2.21.1810031946120.6536@jimisX1>
 <87o7zvc8xi.fsf@HIDDEN> <835ym3f0xt.fsf@HIDDEN>
 <875ym3c7bj.fsf@HIDDEN> <834k1nezs3.fsf@HIDDEN>
 <87ee0raqy2.fsf@HIDDEN> <87czgal2tt.fsf@HIDDEN>
 <838rqydmy8.fsf@HIDDEN> <878rqyklqj.fsf@HIDDEN>
 <831qwqdj2w.fsf@HIDDEN> <875ym19lat.fsf@HIDDEN>
 <831qwod78l.fsf@HIDDEN> <87a6bczkd5.fsf@HIDDEN>
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 32921
Cc: 32921 <at> debbugs.gnu.org, larsi@HIDDEN, jimis@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

> From: Po Lu <luangruo@HIDDEN>
> Cc: Lars Ingebrigtsen <larsi@HIDDEN>,  32921 <at> debbugs.gnu.org,  jimis@HIDDEN
> Date: Fri, 20 May 2022 16:19:50 +0800
> 
> Eli Zaretskii <eliz@HIDDEN> writes:
> 
> > I object to removing that code without any trace.  We should resolve
> > the bug by adding the X resource derived reverseVideo argument to
> > window-system-default-frame-alist instead of default-frame-alist.
> 
> That would still change relatively old behavior from the days of Emacs
> 23, where the parameter in question began to apply to TTY frames as
> well.

Yes.  But ignoring X resources in TTY frames is much more defendable
change than ignoring them on all frames.

> But the "age-old behavior" is IMHO wrong enough that it's more
> likely to be a bug from 19.29 (when support for multiple X displays was
> introduced), as opposed to a feature.

What you consider a bug is nowadays a de-facto "feature", given how
much time Emacs behaved like that.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#32921; Package emacs. Full text available.

Message received at 32921 <at> debbugs.gnu.org:


Received: (at 32921) by debbugs.gnu.org; 20 May 2022 08:28:39 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Fri May 20 04:28:39 2022
Received: from localhost ([127.0.0.1]:37504 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nrxzw-00046T-65
	for submit <at> debbugs.gnu.org; Fri, 20 May 2022 04:28:39 -0400
Received: from quimby.gnus.org ([95.216.78.240]:60250)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <larsi@HIDDEN>) id 1nrxzo-00045l-Hq
 for 32921 <at> debbugs.gnu.org; Fri, 20 May 2022 04:28:34 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org;
 s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date:
 References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding:
 Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender:
 Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:
 List-Subscribe:List-Post:List-Owner:List-Archive;
 bh=7VUfzn9zAbz8F7kJZ+nwwEklu/SpOxUUVJ706e3yFis=; b=CpivOywfypzRDWyfo2aghPetSf
 CzIzLpxFhASk9nhT8dKwy7oE/pPgSKWHw8KTnVvgW0yh990JQsJwJJuJz2xZJAqTzYpZ2cDSKb4H+
 5frlDfRpCVc9VN7XYB0YGavIUKKM6Crq0P2zT788RFEoj0bAZSSdntIcBS0VG1gD3UN4=;
Received: from [84.212.220.105] (helo=xo)
 by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.92) (envelope-from <larsi@HIDDEN>)
 id 1nrxzf-0005Nn-1X; Fri, 20 May 2022 10:28:21 +0200
From: Lars Ingebrigtsen <larsi@HIDDEN>
To: Eli Zaretskii <eliz@HIDDEN>
Subject: Re: bug#32921: emacsclient obeys Xresources even when launched with
 -nw
References: <alpine.LFD.2.21.1810031946120.6536@jimisX1>
 <87o7zvc8xi.fsf@HIDDEN> <835ym3f0xt.fsf@HIDDEN>
 <875ym3c7bj.fsf@HIDDEN> <834k1nezs3.fsf@HIDDEN>
 <87ee0raqy2.fsf@HIDDEN> <87czgal2tt.fsf@HIDDEN>
 <838rqydmy8.fsf@HIDDEN> <878rqyklqj.fsf@HIDDEN>
 <831qwqdj2w.fsf@HIDDEN> <875ym19lat.fsf@HIDDEN>
 <831qwod78l.fsf@HIDDEN>
Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwAgMAAAAqbBEUAAAABGdBTUEAALGPC/xhBQAAACBj
 SFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAACVBMVEViUE6NeXD///+N
 ib42AAAAAWJLR0QCZgt8ZAAAAAd0SU1FB+YFFAgYIKw09K4AAAEpSURBVCjPRVJRjgUhCINE/p1E
 74PJm39M5P5X2Rbf7prJxNpSEBSxI3/L8mRYE1FpAFgTp6qvuMj20mjyP4P/DkYg5XET3di3QuYK
 tWlTUoxRrgsQ40uCWwJb4QPaz1WeoMOhm+7o5XaTFkGLl+neomQe5tdbm72wkPNfKG5xZbrobj1u
 dXWErF+mA1gxKocALi7TZZTYIQBQVgLQvgYWvETolSVETy6EgUpk/eTeDBMzbzlzMSzm6m2+iTq2
 jObe5tkAw83E+0QILtDROWkj5gOmN6a2weTIDWcdyp54rwtmlXVaqAmcNTgF1Kp7FeAAHbn3Beyt
 +fwFs2mB26bH9iJjNVXbqTjHg2DnPSVqGLVGGdzR4x1wPuM2slcHOj+8rbULaPhM9OIHGBsthXAq
 V+gAAAAldEVYdGRhdGU6Y3JlYXRlADIwMjItMDUtMjBUMDg6MjQ6MzIrMDA6MDDa7m4TAAAAJXRF
 WHRkYXRlOm1vZGlmeQAyMDIyLTA1LTIwVDA4OjI0OjMxKzAwOjAwmlvMMgAAAABJRU5ErkJggg==
X-Now-Playing: Sussan Deyhim & Richard Horowitz's _Desert Equations: Azax
 Attra_: "Tear"
Date: Fri, 20 May 2022 10:28:15 +0200
In-Reply-To: <831qwod78l.fsf@HIDDEN> (Eli Zaretskii's message of "Fri, 20 May
 2022 09:54:18 +0300")
Message-ID: <87pmk8621s.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org",
 has NOT identified this incoming email as spam.  The original
 message has been attached to this so you can view it or label
 similar future email.  If you have any questions, see
 @@CONTACT_ADDRESS@@ for details.
 Content preview:  Eli Zaretskii <eliz@HIDDEN> writes: > If you still insist
 on changing the age-old behavior, then at least > provide a way for users
 who want that to have that behavior back > (which might not be easy, since
 we are talking about somethin [...] 
 Content analysis details:   (-2.9 points, 5.0 required)
 pts rule name              description
 ---- ---------------------- --------------------------------------------------
 -1.0 ALL_TRUSTED            Passed through trusted hosts only via SMTP
 -1.9 BAYES_00               BODY: Bayes spam probability is 0 to 1%
 [score: 0.0000]
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 32921
Cc: luangruo@HIDDEN, 32921 <at> debbugs.gnu.org, jimis@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

Eli Zaretskii <eliz@HIDDEN> writes:

> If you still insist on changing the age-old behavior, then at least
> provide a way for users who want that to have that behavior back
> (which might not be easy, since we are talking about something that
> happens at startup, but I think we load the user init file before
> calling the window-system initialization?).

I wondered whether it might make sense to have the x-win.el code snippet
stash the reverseVideo data in `initial-frame-alist', but I didn't
investigate what effect that would have (if any)...

But if we did that, then

  (push (assq 'reverse initial-frame-alist) default-frame-alist)

would be a way to get the current behaviour back, if somebody wanted it.
(But I haven't actually tested this.)

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#32921; Package emacs. Full text available.

Message received at 32921 <at> debbugs.gnu.org:


Received: (at 32921) by debbugs.gnu.org; 20 May 2022 08:20:07 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Fri May 20 04:20:07 2022
Received: from localhost ([127.0.0.1]:37489 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nrxrj-0003Xg-Fw
	for submit <at> debbugs.gnu.org; Fri, 20 May 2022 04:20:07 -0400
Received: from sonic308-56.consmr.mail.ne1.yahoo.com ([66.163.187.31]:42339)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <luangruo@HIDDEN>) id 1nrxrg-0003Wk-SN
 for 32921 <at> debbugs.gnu.org; Fri, 20 May 2022 04:20:06 -0400
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048;
 t=1653034799; bh=gaV1IBGT7b0f1Oz2du9zfnL4WHheRintgSg++QHgUf4=;
 h=From:To:Cc:Subject:References:Date:In-Reply-To:From:Subject:Reply-To;
 b=khdijWJVmDbX9geint7aVOnP2RIDvqgrmzMdDr9gGJbdfDv8UT4EqdzNbABfpHOgAuRRmhe5Va0X/t1p5T0v7VHc2sOQruua1Sz30cWpjF/Vfw3gnQneiBpOxXeNzf1MDh22fNroLFs3ucfji/nU+xTIO5zGg3IWTzm3unoczY4AtX9htLFi6/+JCYvxaUDOPlNUx/z2hUJzof/lLeZR8V7eC4nRHYPIKooeRpstzgHf/aljuaQcdP6CmxjvTtWekb7vJczbE0N+xm7o40+rw2s5Er+XM2n6+vGISdTp/OCMaMSZYyYuLH4jMcemGvX+xljBwXxfGQuMF8b2gRKdog==
X-SONIC-DKIM-SIGN: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048;
 t=1653034799; bh=g8zuIgkw1rL7+VIzl5NJG0h6y+Lju6+/l5p/XTbyLJA=;
 h=X-Sonic-MF:From:To:Subject:Date:From:Subject;
 b=rIAdT5+9H0huO+5SG/gtxUE010qfJoPM/tneV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HIG4Vml2N0GjspnCLCXcqv4eJZIMzxiKt1d1JyjqAAS_8V
 jNuKMhJ308n9bbTXjGF_FhAWWdyIw2pop90Yj41iZPCgYsynRjKPcK9ZBvDrXtLApoN_uEDQ2NIl
 FlvzAYvArIXIAgTbNq8iLLXyZoQo62CE9gcqVNAJI8D4wG0QgRzX_BnS6o9S0KuPTBdqsKPhKz7w
 AYuqMZJs0I5_eQx3dTaQsUK3EqReDTpKeQbezRU8ytAZjJjFNorUVgbOBpexMk9dCNRz5DFngUXk
 EpJyaXprv9WhVF5UI1vS.WLnoCoDMgC2PJGQnRH.IHlcWVpOGMbMZBk1K1v5CW6TDXYzRDv_PUhD
 QRi6E.3mdXtDBx2ajTx60ts55HNQCPu11Fb5kWxEqVLZxDu.DSN_efX30uhChXPE0o3MNiK76DVV
 7kIZiIQsbEpZ6h8KE3d7c_RBrNpYCChVa9gnuijDEMHvZdsjDp_h_0NC7j4cTeE2JugxIGBEnfS1
 10KnKJU_vR6ET8XzlS2FGvckG7YqVayH63T4xye4ACKrkcNyoWDd2eIp4T4st
X-Sonic-MF: <luangruo@HIDDEN>
Received: from sonic.gate.mail.ne1.yahoo.com by
 sonic308.consmr.mail.ne1.yahoo.com with HTTP; Fri, 20 May 2022 08:19:59 +0000
Received: by hermes--canary-production-sg3-7959d4d9bd-56w7m (Yahoo Inc. Hermes
 SMTP Server) with ESMTPA ID 3a130c4c777d8b1222a7f1eb9a168a69; 
 Fri, 20 May 2022 08:19:56 +0000 (UTC)
From: Po Lu <luangruo@HIDDEN>
To: Eli Zaretskii <eliz@HIDDEN>
Subject: Re: bug#32921: emacsclient obeys Xresources even when launched with
 -nw
References: <alpine.LFD.2.21.1810031946120.6536@jimisX1>
 <87o7zvc8xi.fsf@HIDDEN> <835ym3f0xt.fsf@HIDDEN>
 <875ym3c7bj.fsf@HIDDEN> <834k1nezs3.fsf@HIDDEN>
 <87ee0raqy2.fsf@HIDDEN> <87czgal2tt.fsf@HIDDEN>
 <838rqydmy8.fsf@HIDDEN> <878rqyklqj.fsf@HIDDEN>
 <831qwqdj2w.fsf@HIDDEN> <875ym19lat.fsf@HIDDEN>
 <831qwod78l.fsf@HIDDEN>
Date: Fri, 20 May 2022 16:19:50 +0800
In-Reply-To: <831qwod78l.fsf@HIDDEN> (Eli Zaretskii's message of "Fri, 20 May
 2022 09:54:18 +0300")
Message-ID: <87a6bczkd5.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.91 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Mailer: WebService/1.1.20225
 mail.backend.jedi.jws.acl:role.jedi.acl.token.atz.jws.hermes.yahoo
Content-Length: 1022
X-Spam-Score: -0.0 (/)
X-Debbugs-Envelope-To: 32921
Cc: 32921 <at> debbugs.gnu.org, Lars Ingebrigtsen <larsi@HIDDEN>, jimis@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.0 (-)

Eli Zaretskii <eliz@HIDDEN> writes:

> I object to removing that code without any trace.  We should resolve
> the bug by adding the X resource derived reverseVideo argument to
> window-system-default-frame-alist instead of default-frame-alist.

That would still change relatively old behavior from the days of Emacs
23, where the parameter in question began to apply to TTY frames as
well.  But the "age-old behavior" is IMHO wrong enough that it's more
likely to be a bug from 19.29 (when support for multiple X displays was
introduced), as opposed to a feature.

> If you still insist on changing the age-old behavior, then at least
> provide a way for users who want that to have that behavior back
> (which might not be easy, since we are talking about something that
> happens at startup, but I think we load the user init file before
> calling the window-system initialization?).

window-system initialization is called before the user init file is
loaded, but the early-init file gets called before that, I think.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#32921; Package emacs. Full text available.

Message received at 32921 <at> debbugs.gnu.org:


Received: (at 32921) by debbugs.gnu.org; 20 May 2022 08:15:34 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Fri May 20 04:15:34 2022
Received: from localhost ([127.0.0.1]:37476 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nrxnK-0003Ez-Ba
	for submit <at> debbugs.gnu.org; Fri, 20 May 2022 04:15:34 -0400
Received: from sonic303-20.consmr.mail.ne1.yahoo.com ([66.163.188.146]:44113)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <luangruo@HIDDEN>) id 1nrxnI-0003EN-9m
 for 32921 <at> debbugs.gnu.org; Fri, 20 May 2022 04:15:32 -0400
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048;
 t=1653034526; bh=cDxPjlT+8NNEqTF9ipx9rBngrtZhfSWFyQEplXDrqYg=;
 h=From:To:Cc:Subject:References:Date:In-Reply-To:From:Subject:Reply-To;
 b=Me3Hu54h5qe6kmH3B2HwyrcGL7a5LAU/BEuY5+jLcX3jslGDHvAbzXFgLpi9nA4ZLoClGVDLSzzuP0GW3oucmwWZ/8mnDafrWRUwA7FvvtPq2iY1zMWVw+s4FSQo1Qz/lpOLmuRqbMnNV0vzAO1T9N1x9k4pSasIrnoWX2+xMRLoqSYYGF0a3MdVm/Uwdh1dxLMgmAaLm1doGfto/ELgeF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RCwFFw7.Rg3pG7MhsD7KJlHPRGxK0p9sCUzZm5NWi
 3Vbgf43AJd4etygKE7nKzw6Vc0QmOcklkmHjMupOTs7k5SqLErhimji3SBD0xfINNqQCAl.bwdFn
 OsfWxhvhF.aoAC.0ybjjtjOo0ZYBxAzlVDEaccWeaASwonkqpwW5gmbRevc.ERjYPnMwU0nYDiBW
 zXeLRB2VC7JYGj2UDFan1gjzdZQRw6a..SmgZbHaHzxzulfLKKRkDgS9Q9cQGguwBuEjWgsZXti9
 I9URPiBSN51N7VVf9engpdb0S1Nmr29TK5.TMnDS0foiiF8O2WCVO4MGauhHfARZLL1JGPbSwt5Y
 3u60Ml5C_EkI8QEycsOmHTZEZRIooC6PVi6mPYtTOtIDad11xzlJ_yk2v2c8UKHKwetUjhCqdOew
 pFZhvgG_RzFCJkwcWFdQy7a4XGNOeQxEUSUwMVCSiIvbfBhvchRE0zhEQd0.53gyX3OSyQb_Zc3w
 6uSTsnzWtg9JhBoGOEB5VJq7nS4sFRqFQ7ZUDgyOWFQQtsROZsv06nYbD2_iHvfU59ivA2fNSLHg
 qVRZm7EU8tIYSZ31bJ8g7A2n1Wi9Aj2pId.MKWf4qhcXxQAiN8_Je_gbfVjfR3T3JynYgZuq6re9
 jhLjJwqxhHXg.y1B6ZgTGethPjhMD3eyW43XUcARupqGRLZkl.WxlAo7M4QXKsDrmrjvDrzfG2Fx
 MxZdhXGuWBc3e2rOyUHQAjbjYDLNIEbhtagpBqQ8b0IKRVwIny4EzueVhncgzj8tjNMlXE23iQJM
 7ZR9l34gU..YTLcZAXSRgTX58wzcJD9Ea60uk_VlwLrhP0dTqJ_2eyujQf_OQ23c-
X-Sonic-MF: <luangruo@HIDDEN>
Received: from sonic.gate.mail.ne1.yahoo.com by
 sonic303.consmr.mail.ne1.yahoo.com with HTTP; Fri, 20 May 2022 08:15:26 +0000
Received: by hermes--canary-production-sg3-7959d4d9bd-v94mk (Yahoo Inc. Hermes
 SMTP Server) with ESMTPA ID 753d3d0205596c4e464fdca55cfb1bc1; 
 Fri, 20 May 2022 08:15:21 +0000 (UTC)
From: Po Lu <luangruo@HIDDEN>
To: Eli Zaretskii <eliz@HIDDEN>
Subject: Re: bug#32921: emacsclient obeys Xresources even when launched with
 -nw
References: <alpine.LFD.2.21.1810031946120.6536@jimisX1>
 <87o7zvc8xi.fsf@HIDDEN> <835ym3f0xt.fsf@HIDDEN>
 <875ym3c7bj.fsf@HIDDEN> <834k1nezs3.fsf@HIDDEN>
 <87ee0raqy2.fsf@HIDDEN> <87czgal2tt.fsf@HIDDEN>
 <838rqydmy8.fsf@HIDDEN> <878rqyklqj.fsf@HIDDEN>
 <831qwqdj2w.fsf@HIDDEN> <87fsl5sxse.fsf@HIDDEN>
 <83y1yxdffv.fsf@HIDDEN> <87czg93juo.fsf@HIDDEN>
 <83sfp5d7ad.fsf@HIDDEN> <87h75l1xeo.fsf@HIDDEN>
 <83r14pd5b6.fsf@HIDDEN> <877d6h1w01.fsf@HIDDEN>
 <83pmk9d3th.fsf@HIDDEN> <87wnehypz3.fsf@HIDDEN>
 <83tu9kbs85.fsf@HIDDEN>
Date: Fri, 20 May 2022 16:15:11 +0800
In-Reply-To: <83tu9kbs85.fsf@HIDDEN> (Eli Zaretskii's message of "Fri, 20 May
 2022 10:03:54 +0300")
Message-ID: <87ilq0zkkw.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.91 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Mailer: WebService/1.1.20225
 mail.backend.jedi.jws.acl:role.jedi.acl.token.atz.jws.hermes.yahoo
Content-Length: 628
X-Spam-Score: -0.0 (/)
X-Debbugs-Envelope-To: 32921
Cc: 32921 <at> debbugs.gnu.org, larsi@HIDDEN, jimis@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.0 (-)

Eli Zaretskii <eliz@HIDDEN> writes:

> Isn't that true for every parameter in default-frame-alist?

Sorry, I didn't make myself very clear.  But I also misunderstood how
make-frame worked.  I meant to say x-handle-reverse-video always
overrides what we put in default-frame-alist anyway, or so I thought,
until a little digging revealed that make-frame would actually pass the
contents of default-frame-alist to the frame-creation-function.

In that case, why does gui_display_get_arg still have to search inside
Vdefault_frame_alist, since that information should already be inside
the ALIST argument, provided by make-frame?




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#32921; Package emacs. Full text available.

Message received at 32921 <at> debbugs.gnu.org:


Received: (at 32921) by debbugs.gnu.org; 20 May 2022 07:04:03 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Fri May 20 03:04:03 2022
Received: from localhost ([127.0.0.1]:37384 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nrwg7-0007eU-9K
	for submit <at> debbugs.gnu.org; Fri, 20 May 2022 03:04:03 -0400
Received: from eggs.gnu.org ([209.51.188.92]:34610)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <eliz@HIDDEN>) id 1nrwg5-0007df-HG
 for 32921 <at> debbugs.gnu.org; Fri, 20 May 2022 03:04:01 -0400
Received: from fencepost.gnu.org ([2001:470:142:3::e]:49622)
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1nrwg0-0001WC-79; Fri, 20 May 2022 03:03:56 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org;
 s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date:
 mime-version; bh=lR8mix3etMZK+f7H0Ewz3hwEgblWtz938gkGEAnD+7Y=; b=bO/AzhkFBB8D
 CNmGXhY8sOzlBL4lWWAY/FbV4bg2B553jNE7nL7zjg3LkdnqMTjF6khdi/6PCgJGX6P4KC6f6S6IH
 HT8UzOc22sbnd8YNgrbvLhKPLk6RAsxvPB/WnTlyPCAiXEMhSiPo4RQh+Gb3qP+X1V6JgW7hCVzhL
 5WXqZxzLodvTEts3u44SjdZgQ496sWzxgrMCFgLcTLy23scomJsu3j3GX/1LKQvfcLX6DRdCSN6g5
 +sC9kBSUMuauJDSO19X+aQ24l5hoyL2fMGm8PYOShxTxlvwoH26RqB1iOfN7gcXm4A4erN5mw0H2m
 XD1bcFE0TgZexyWEoPHPSg==;
Received: from [87.69.77.57] (port=4523 helo=home-c4e4a596f7)
 by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1nrwfz-0006Qe-Ne; Fri, 20 May 2022 03:03:56 -0400
Date: Fri, 20 May 2022 10:03:54 +0300
Message-Id: <83tu9kbs85.fsf@HIDDEN>
From: Eli Zaretskii <eliz@HIDDEN>
To: Po Lu <luangruo@HIDDEN>
In-Reply-To: <87wnehypz3.fsf@HIDDEN> (message from Po Lu on Fri, 20 May
 2022 09:04:00 +0800)
Subject: Re: bug#32921: emacsclient obeys Xresources even when launched with
 -nw
References: <alpine.LFD.2.21.1810031946120.6536@jimisX1>
 <87o7zvc8xi.fsf@HIDDEN> <835ym3f0xt.fsf@HIDDEN>
 <875ym3c7bj.fsf@HIDDEN> <834k1nezs3.fsf@HIDDEN>
 <87ee0raqy2.fsf@HIDDEN> <87czgal2tt.fsf@HIDDEN>
 <838rqydmy8.fsf@HIDDEN> <878rqyklqj.fsf@HIDDEN>
 <831qwqdj2w.fsf@HIDDEN> <87fsl5sxse.fsf@HIDDEN>
 <83y1yxdffv.fsf@HIDDEN> <87czg93juo.fsf@HIDDEN>
 <83sfp5d7ad.fsf@HIDDEN> <87h75l1xeo.fsf@HIDDEN>
 <83r14pd5b6.fsf@HIDDEN> <877d6h1w01.fsf@HIDDEN>
 <83pmk9d3th.fsf@HIDDEN> <87wnehypz3.fsf@HIDDEN>
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 32921
Cc: 32921 <at> debbugs.gnu.org, larsi@HIDDEN, jimis@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

> From: Po Lu <luangruo@HIDDEN>
> Cc: larsi@HIDDEN,  32921 <at> debbugs.gnu.org,  jimis@HIDDEN
> Date: Fri, 20 May 2022 09:04:00 +0800
> 
> Eli Zaretskii <eliz@HIDDEN> writes:
> 
> > No, there is a difference: when we change default-frame-alist at
> > startup time, that change is thereafter propagated to all future
> > frames, independently of what frame-creation-function will do when
> > each new frame is created.
> 
> But it seems that the `reverse' frame parameter is also only handled
> inside `x-handle-reverse-video', so it only takes effect if the
> frame-creation-function is eventually called:

Isn't that true for every parameter in default-frame-alist?




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#32921; Package emacs. Full text available.

Message received at 32921 <at> debbugs.gnu.org:


Received: (at 32921) by debbugs.gnu.org; 20 May 2022 06:54:29 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Fri May 20 02:54:29 2022
Received: from localhost ([127.0.0.1]:37353 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nrwWq-00072A-MS
	for submit <at> debbugs.gnu.org; Fri, 20 May 2022 02:54:28 -0400
Received: from eggs.gnu.org ([209.51.188.92]:32850)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <eliz@HIDDEN>) id 1nrwWo-00071l-5Z
 for 32921 <at> debbugs.gnu.org; Fri, 20 May 2022 02:54:27 -0400
Received: from fencepost.gnu.org ([2001:470:142:3::e]:49470)
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1nrwWi-00006s-Fg; Fri, 20 May 2022 02:54:20 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org;
 s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date:
 mime-version; bh=vQ24fM7EENhCGqmtYwBxbYe26j1KIhwpSlpHJW0+kLw=; b=ZdjRYH9Mnwcr
 E11DGcCSV8kVpcf8y9u65wXCQSr5x0PpVWymWPbx3mxkQRvf8eHJsjDnqvNVkhWCT+A4tXr+Mm9zO
 hGrnGc4gPCX3u8e5Pv2S02kY5MYwCQpY1UA83WkpBk1Pe5dfhtlUjajiNpYaIqSz/2GGnwjp0SdR7
 ritMn7pxMQjfezRo/QOLvwwVE4ZFs6vpCyjbM4d5m6fQP9u9xxKaP7SVnLWgl4NtqJWvN9ghomDEx
 arkCQRyPxwhRiua71eawQ0XYmZU6wetZrGJiNJ6K6DFVTPz3tCbJfz/HEHpnLaDWRZz7beJ/if0pn
 srly10owOOTV5sryWzZp/g==;
Received: from [87.69.77.57] (port=3933 helo=home-c4e4a596f7)
 by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1nrwWh-0004a2-Vi; Fri, 20 May 2022 02:54:20 -0400
Date: Fri, 20 May 2022 09:54:18 +0300
Message-Id: <831qwod78l.fsf@HIDDEN>
From: Eli Zaretskii <eliz@HIDDEN>
To: Lars Ingebrigtsen <larsi@HIDDEN>
In-Reply-To: <875ym19lat.fsf@HIDDEN> (message from Lars Ingebrigtsen on Fri, 
 20 May 2022 01:04:10 +0200)
Subject: Re: bug#32921: emacsclient obeys Xresources even when launched with
 -nw
References: <alpine.LFD.2.21.1810031946120.6536@jimisX1>
 <87o7zvc8xi.fsf@HIDDEN> <835ym3f0xt.fsf@HIDDEN>
 <875ym3c7bj.fsf@HIDDEN> <834k1nezs3.fsf@HIDDEN>
 <87ee0raqy2.fsf@HIDDEN> <87czgal2tt.fsf@HIDDEN>
 <838rqydmy8.fsf@HIDDEN> <878rqyklqj.fsf@HIDDEN>
 <831qwqdj2w.fsf@HIDDEN> <875ym19lat.fsf@HIDDEN>
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 32921
Cc: luangruo@HIDDEN, 32921 <at> debbugs.gnu.org, jimis@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

> From: Lars Ingebrigtsen <larsi@HIDDEN>
> Cc: Po Lu <luangruo@HIDDEN>,  32921 <at> debbugs.gnu.org,  jimis@HIDDEN
> Date: Fri, 20 May 2022 01:04:10 +0200
> 
> Eli Zaretskii <eliz@HIDDEN> writes:
> 
> > And if you are saying that the code in x-win.el should only affect the
> > display on which Emacs was started, then that would be an even more
> > seriously breaking change.  Why should we assume that the user
> > intended his/her X resources to be only honored on the (random)
> > display where Emacs shows its first frame?  The files ~/.Xresources
> > and ~/.Xdefaults are not specific to any display, AFAIU, they are
> > global for the user.  Right?
> 
> As Po says, X resources are a per-display thing -- the user may have
> wildly differing X resources on different displays, and the intention of
> X is that programs should query the X resource database whenever a new
> window (i.e., frame) is opened.
> 
> Which removing that code from x-win.el would do.
> 
> I think Po is right here -- that code snippet in x-win.el just looks
> like a misunderstanding.  (We handle all other X resources correctly, it
> just this one that we handle in this wrong manner.)

I object to removing that code without any trace.  We should resolve
the bug by adding the X resource derived reverseVideo argument to
window-system-default-frame-alist instead of default-frame-alist.  If
you still insist on changing the age-old behavior, then at least
provide a way for users who want that to have that behavior back
(which might not be easy, since we are talking about something that
happens at startup, but I think we load the user init file before
calling the window-system initialization?).




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#32921; Package emacs. Full text available.

Message received at 32921 <at> debbugs.gnu.org:


Received: (at 32921) by debbugs.gnu.org; 20 May 2022 01:04:23 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Thu May 19 21:04:22 2022
Received: from localhost ([127.0.0.1]:36957 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nrr42-0005CP-MD
	for submit <at> debbugs.gnu.org; Thu, 19 May 2022 21:04:22 -0400
Received: from sonic311-25.consmr.mail.ne1.yahoo.com ([66.163.188.206]:43809)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <luangruo@HIDDEN>) id 1nrr3y-0005CA-Ky
 for 32921 <at> debbugs.gnu.org; Thu, 19 May 2022 21:04:21 -0400
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048;
 t=1653008653; bh=n5WFrwpe4u0xrxgzq56U3cye3QWM8tjzhSlOtqG8ACY=;
 h=From:To:Cc:Subject:References:Date:In-Reply-To:From:Subject:Reply-To;
 b=BgAnOBaE1BE2RqRXWpUjUP0btrvVvBGLtn/zYDg/k9uUnyyX0pHRBQUvttjJjKZF4Vo5dU1TowXeIqFtEmEGJHpUXfg5VMFy7e7ke3MhEKtegNdN0C4ONc8CiU0l/ny9/B5UQKin4J7JQT2RmURDQ3bPtA3aykdTcqK385bun0ZN7MSh3eCTa3lRpthx7YfMJ9e4cRHz8pBXE/afKcADq0Lt8OeAIHmuzuqUgQuLm72LXdLqEd7cM9o2aJxeWL041dgZ8nb/wEfGSZ1rboLxIQItXOCmZo6B//A0nIlmz3NpOxMy05GqE8+T/ggbEdsUqWAzHCAtWxCz1qwNy+LJPQ==
X-SONIC-DKIM-SIGN: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048;
 t=1653008653; bh=UwtFaRIXS17PgVOrH9ZZOiCTWiHvv/Q9/zYH6uCc+ua=;
 h=X-Sonic-MF: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PT
 Z9ZJNzw5JjTXvVdGcLj7jtlqgPRQ2ClcQNkmpJ53OFsjtporIHdAh23XTB8IX5ATMWwP_DfVoSsl
 dxzWLFn2RcB62V18VTrKnDcMGJF_eopX6YIm4k8qkBXEtE9_2Tot5MRMlm3IJeZd10aVsl0i4LQr
 cJLsFajSSN2Qxl2FcT2CW6pWTKX47JVp9ONFSKnanbPWyUsWW6g5JdFbLwF2USfoTtzuOxYnZ8vU
 VYEZkJPNNm8.35pwyVTHArIw4Px0mjFzAev3xcJVLqCyZywJRJn87zJTNKiPF20TgEILvhPw8ZJ5
 L0mF4q9nXUO6IRTYj4sCtLuBub_pbYGyY_PBZCmJDZ0gBvbK7QzUzEC0b5hUDIscJlXxebMdrb.I
 nxQknuPa6USJc8ndmE.ixSwSaCU7VceHTA.c0tXZOEyKoU72p_0fFQKqbFR82A3nTWE4zr90QpAg
 9UDotxQTgMlhoNChduX.5uDLKBntFA0iZo2JaiLupo.6wKdgy.NYhmWwn7w95dw7FYn8GZkLFPvk
 m.kpSuTZImHSz_wRbSY8TT38LdMXCza5xxY8nVVxsDn8BMcpXnHuF8ik-
X-Sonic-MF: <luangruo@HIDDEN>
Received: from sonic.gate.mail.ne1.yahoo.com by
 sonic311.consmr.mail.ne1.yahoo.com with HTTP; Fri, 20 May 2022 01:04:13 +0000
Received: by hermes--canary-production-sg3-7959d4d9bd-9z8f2 (Yahoo Inc. Hermes
 SMTP Server) with ESMTPA ID 8efee7dc73c0b2eb9378379505e304de; 
 Fri, 20 May 2022 01:04:08 +0000 (UTC)
From: Po Lu <luangruo@HIDDEN>
To: Eli Zaretskii <eliz@HIDDEN>
Subject: Re: bug#32921: emacsclient obeys Xresources even when launched with
 -nw
References: <alpine.LFD.2.21.1810031946120.6536@jimisX1>
 <87o7zvc8xi.fsf@HIDDEN> <835ym3f0xt.fsf@HIDDEN>
 <875ym3c7bj.fsf@HIDDEN> <834k1nezs3.fsf@HIDDEN>
 <87ee0raqy2.fsf@HIDDEN> <87czgal2tt.fsf@HIDDEN>
 <838rqydmy8.fsf@HIDDEN> <878rqyklqj.fsf@HIDDEN>
 <831qwqdj2w.fsf@HIDDEN> <87fsl5sxse.fsf@HIDDEN>
 <83y1yxdffv.fsf@HIDDEN> <87czg93juo.fsf@HIDDEN>
 <83sfp5d7ad.fsf@HIDDEN> <87h75l1xeo.fsf@HIDDEN>
 <83r14pd5b6.fsf@HIDDEN> <877d6h1w01.fsf@HIDDEN>
 <83pmk9d3th.fsf@HIDDEN>
Date: Fri, 20 May 2022 09:04:00 +0800
In-Reply-To: <83pmk9d3th.fsf@HIDDEN> (Eli Zaretskii's message of "Thu, 19 May
 2022 16:55:54 +0300")
Message-ID: <87wnehypz3.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.91 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Mailer: WebService/1.1.20225
 mail.backend.jedi.jws.acl:role.jedi.acl.token.atz.jws.hermes.yahoo
Content-Length: 2066
X-Spam-Score: -0.0 (/)
X-Debbugs-Envelope-To: 32921
Cc: 32921 <at> debbugs.gnu.org, larsi@HIDDEN, jimis@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.0 (-)

Eli Zaretskii <eliz@HIDDEN> writes:

> No, there is a difference: when we change default-frame-alist at
> startup time, that change is thereafter propagated to all future
> frames, independently of what frame-creation-function will do when
> each new frame is created.

But it seems that the `reverse' frame parameter is also only handled
inside `x-handle-reverse-video', so it only takes effect if the
frame-creation-function is eventually called:

    (defun x-handle-reverse-video (frame parameters)
      "Handle the reverse-video frame parameter and X resource.
    `x-create-frame' does not handle this one."
      (when (cdr (or (assq 'reverse parameters)
                     (let ((resource (x-get-resource "reverseVideo"
                                                     "ReverseVideo")))
                       (if resource
                           (cons nil (member (downcase resource)
                                             '("on" "true")))))))
          (let* ((params (frame-parameters frame))
                 (bg (cdr (assq 'foreground-color params)))
                 (fg (cdr (assq 'background-color params))))
            (modify-frame-parameters frame
                                     (list (cons 'foreground-color fg)
                                           (cons 'background-color bg)))
            (if (equal bg (cdr (assq 'border-color params)))
                (modify-frame-parameters frame
                                         (list (cons 'border-color fg))))
            (if (equal bg (cdr (assq 'mouse-color params)))
                (modify-frame-parameters frame
                                         (list (cons 'mouse-color fg))))
            (if (equal bg (cdr (assq 'cursor-color params)))
                (modify-frame-parameters frame
                                         (list (cons 'cursor-color fg)))))))

> The reverseVideo resource, like the -rv command-line argument, is
> supposed to invert the colors that the user's customizations set.
> Maybe this is why it is handled specially.

Hmm...




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#32921; Package emacs. Full text available.

Message received at 32921 <at> debbugs.gnu.org:


Received: (at 32921) by debbugs.gnu.org; 19 May 2022 23:04:22 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Thu May 19 19:04:22 2022
Received: from localhost ([127.0.0.1]:36820 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nrpBu-00043c-4S
	for submit <at> debbugs.gnu.org; Thu, 19 May 2022 19:04:22 -0400
Received: from quimby.gnus.org ([95.216.78.240]:55876)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <larsi@HIDDEN>) id 1nrpBs-00043P-IC
 for 32921 <at> debbugs.gnu.org; Thu, 19 May 2022 19:04:20 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org;
 s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date:
 References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding:
 Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender:
 Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:
 List-Subscribe:List-Post:List-Owner:List-Archive;
 bh=L5Ma+112cNzGzx9NjvmMj+0onuSYWxHl5UXKLkO3N4o=; b=XmZap0WFNr0ZmSKqtfDhQcoijs
 MEaKf5mo6WfiVmIV0EBI5dBNjAsJKroV5EMdr46N2NCQGV9N/GZtTwG184JU8W/iasVWOgs9Ughxo
 cLpC8TbGEV5pXbTwoUI17efr0y3b4ON1GkErgfXgFqHXfiC3Lq733R+9crbAaqQUPXaY=;
Received: from [84.212.220.105] (helo=xo)
 by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.92) (envelope-from <larsi@HIDDEN>)
 id 1nrpBj-0007qO-7d; Fri, 20 May 2022 01:04:13 +0200
From: Lars Ingebrigtsen <larsi@HIDDEN>
To: Eli Zaretskii <eliz@HIDDEN>
Subject: Re: bug#32921: emacsclient obeys Xresources even when launched with
 -nw
References: <alpine.LFD.2.21.1810031946120.6536@jimisX1>
 <87o7zvc8xi.fsf@HIDDEN> <835ym3f0xt.fsf@HIDDEN>
 <875ym3c7bj.fsf@HIDDEN> <834k1nezs3.fsf@HIDDEN>
 <87ee0raqy2.fsf@HIDDEN> <87czgal2tt.fsf@HIDDEN>
 <838rqydmy8.fsf@HIDDEN> <878rqyklqj.fsf@HIDDEN>
 <831qwqdj2w.fsf@HIDDEN>
Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwBAMAAAClLOS0AAAABGdBTUEAALGPC/xhBQAAACBj
 SFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAAGFBMVEXq39KMg4SlrcOg
 bFZbSD12lMMiGRb///85usWDAAAAAWJLR0QHFmGI6wAAAAd0SU1FB+YFExcAKzNQaYsAAAGkSURB
 VDjLdZLNcqwgEIV7TM1+EL1rIDNZx8HKWm+QdUiFfRYU7/8I6QYxaE2OVQrn49DyA4C6QNZJwE6n
 VuVGu/fVgK9GCJBQJxrJWjZ3s/zPZskYdkhKwNl/+cX1rves97733eIWdD4QLN47srLyt0fwtdRO
 EQH/SDQViTn2B2Bsneq2B66be7XKq1sFuNmAqoBzbKgApjJwLNWowC2DG2vTbij3WQBtCXYkAq5n
 qdsSIUDfBLQeCpAXOKc0w6lqYCc45xFkI1DQUPcav3MDSQInBKJR4hqnCgziFT0gp9sSoCS/4ykT
 UOLZIMB0PupGgG7SHYCrRfBihsOlAQITvMQYDtcGukiJiMTskSnA2vBaXShtC4jBBl7uKYwYKABR
 DHd5F3AambE1oELGvPPRJP8AiFkTjyCNXANbcWP0prcV0NS6FpYh8KQfyJgJnmmMHik0vmMYx5Mm
 uJqHmqhGTP95BP/Whf+ucgcq2x5ByJYNvwAXGwyBR1NZ3CN8zF817OrHPYg5gmG7Adxz1jE8pFQ8
 1onA7czXQQQkKxpwu9Ym55cf6h73Vs7RV4wAAAAldEVYdGRhdGU6Y3JlYXRlADIwMjItMDUtMTlU
 MjM6MDA6NDMrMDA6MDCvnVtRAAAAJXRFWHRkYXRlOm1vZGlmeQAyMDIyLTA1LTE5VDIzOjAwOjQz
 KzAwOjAw3sDj7QAAAABJRU5ErkJggg==
X-Now-Playing: Tuxedomoon's _Holy Wars_: "St. John"
Date: Fri, 20 May 2022 01:04:10 +0200
In-Reply-To: <831qwqdj2w.fsf@HIDDEN> (Eli Zaretskii's message of "Thu, 19 May
 2022 11:26:15 +0300")
Message-ID: <875ym19lat.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org",
 has NOT identified this incoming email as spam.  The original
 message has been attached to this so you can view it or label
 similar future email.  If you have any questions, see
 @@CONTACT_ADDRESS@@ for details.
 Content preview: Eli Zaretskii <eliz@HIDDEN> writes: > And if you are saying
 that the code in x-win.el should only affect the > display on which Emacs
 was started, then that would be an even more > seriously breaking change.
 Why should we assume that th [...] 
 Content analysis details:   (-2.9 points, 5.0 required)
 pts rule name              description
 ---- ---------------------- --------------------------------------------------
 -1.0 ALL_TRUSTED            Passed through trusted hosts only via SMTP
 -1.9 BAYES_00               BODY: Bayes spam probability is 0 to 1%
 [score: 0.0000]
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 32921
Cc: Po Lu <luangruo@HIDDEN>, 32921 <at> debbugs.gnu.org, jimis@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

Eli Zaretskii <eliz@HIDDEN> writes:

> And if you are saying that the code in x-win.el should only affect the
> display on which Emacs was started, then that would be an even more
> seriously breaking change.  Why should we assume that the user
> intended his/her X resources to be only honored on the (random)
> display where Emacs shows its first frame?  The files ~/.Xresources
> and ~/.Xdefaults are not specific to any display, AFAIU, they are
> global for the user.  Right?

As Po says, X resources are a per-display thing -- the user may have
wildly differing X resources on different displays, and the intention of
X is that programs should query the X resource database whenever a new
window (i.e., frame) is opened.

Which removing that code from x-win.el would do.

I think Po is right here -- that code snippet in x-win.el just looks
like a misunderstanding.  (We handle all other X resources correctly, it
just this one that we handle in this wrong manner.)

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#32921; Package emacs. Full text available.

Message received at 32921 <at> debbugs.gnu.org:


Received: (at 32921) by debbugs.gnu.org; 19 May 2022 22:58:47 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Thu May 19 18:58:47 2022
Received: from localhost ([127.0.0.1]:36801 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nrp6V-0003tA-6F
	for submit <at> debbugs.gnu.org; Thu, 19 May 2022 18:58:47 -0400
Received: from quimby.gnus.org ([95.216.78.240]:55826)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <larsi@HIDDEN>) id 1nrp6S-0003sw-6N
 for 32921 <at> debbugs.gnu.org; Thu, 19 May 2022 18:58:45 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org;
 s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date:
 References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding:
 Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender:
 Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:
 List-Subscribe:List-Post:List-Owner:List-Archive;
 bh=4fBxbOu05pLj398YW2h/t165AxATpZbSDNw3Lixevb0=; b=GIP4oVJFpygplQR2V7Ih85NqXy
 jE7yr4nwwBsbkKq7uDKnY/WeKtvgc/cxF/aAtYuFtDiyrxQV3bXRotpShAEf7YO4TAKR3rFaP7MBW
 fmganJbza3+gFi3ayIlardwUv8Hz+Wxp51fRHgAXMpJfpkPiWfkoiJ+kFzbhZaEI5xIs=;
Received: from [84.212.220.105] (helo=xo)
 by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.92) (envelope-from <larsi@HIDDEN>)
 id 1nrp6I-0007mL-TZ; Fri, 20 May 2022 00:58:37 +0200
From: Lars Ingebrigtsen <larsi@HIDDEN>
To: Eli Zaretskii <eliz@HIDDEN>
Subject: Re: bug#32921: emacsclient obeys Xresources even when launched with
 -nw
References: <alpine.LFD.2.21.1810031946120.6536@jimisX1>
 <87o7zvc8xi.fsf@HIDDEN> <835ym3f0xt.fsf@HIDDEN>
 <875ym3c7bj.fsf@HIDDEN> <834k1nezs3.fsf@HIDDEN>
 <87ee0raqy2.fsf@HIDDEN> <831qwrey97.fsf@HIDDEN>
Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwBAMAAAClLOS0AAAABGdBTUEAALGPC/xhBQAAACBj
 SFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAAJ1BMVEX9/f3S0tMgHx4O
 DAyPj5BSUVGwr7AtLCtgX19wb3C+v8KAf3////+zg4Q9AAAAAWJLR0QMgbNRYwAAAAd0SU1FB+YF
 ExYuNcOaN/MAAAGASURBVDjLvZJNT8JAEIZnE6hy2wZS4WjXhHjdsYI3iR+EKyWCNzCA4WbakHI0
 FCLe/AD0B/gn/HduW2y7pRx1mnab98nMuzuzACIIo+BH5qYwbqIfgWBvQFa7cuw4mAYLLJWBhXEw
 CBblheS4BEZE9ayuAe5RAkPQ1r45NWXQE9WOqAr5hiWDrngvjFbPXCdK0dztso68Z/abMgCFusjb
 1GWYAAD7TKcgrPUkgLuJ6ABW2iwBvuwWiIxyNZlRGtcAXLTP3WQpQr2M45WdBF6DTeRbuwraj5gK
 CNsBFPwL8CqBXKifxmUKeyHoxsElef/VDfkUB2GCQWWL6OD8XErJ45Z7zfuokTlWfVmrV4GolGYj
 4NsXRU0gbxMt1txKoHsbJzHZByX/5xFooRkDHDLBDA6hsGrExoGwmf0JeUIpIKw5YKlAuBdZKngA
 zU0FxrA/TQVYsdJLcRY8Omfi1vEInI0WnVln8T3/nM9nz4uPKMPSRTi6ZZWdsuVYgDviP8APOLuy
 Sfn2JkEAAAAldEVYdGRhdGU6Y3JlYXRlADIwMjItMDUtMTlUMjI6NDY6NTMrMDA6MDADZoGPAAAA
 JXRFWHRkYXRlOm1vZGlmeQAyMDIyLTA1LTE5VDIyOjQ2OjUzKzAwOjAwcjs5MwAAAABJRU5ErkJg
 gg==
X-Now-Playing: Winston Tong's _Theoretically Chinese_: "The Principles of
 Movement"
Date: Fri, 20 May 2022 00:58:34 +0200
In-Reply-To: <831qwrey97.fsf@HIDDEN> (Eli Zaretskii's message of "Wed, 18 May
 2022 17:00:52 +0300")
Message-ID: <87a6bd9lk5.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org",
 has NOT identified this incoming email as spam.  The original
 message has been attached to this so you can view it or label
 similar future email.  If you have any questions, see
 @@CONTACT_ADDRESS@@ for details.
 Content preview:  Eli Zaretskii <eliz@HIDDEN> writes: >> But are there many
 parameters like this? Most of the frame parameters >> are ignored on TTY...
 > > Many are ignored, but some are relevant: > > . foreground and background
 colors > . cursor blinkin [...] 
 Content analysis details:   (-2.9 points, 5.0 required)
 pts rule name              description
 ---- ---------------------- --------------------------------------------------
 -1.0 ALL_TRUSTED            Passed through trusted hosts only via SMTP
 -1.9 BAYES_00               BODY: Bayes spam probability is 0 to 1%
 [score: 0.0000]
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 32921
Cc: 32921 <at> debbugs.gnu.org, jimis@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

Eli Zaretskii <eliz@HIDDEN> writes:

>> But are there many parameters like this?  Most of the frame parameters
>> are ignored on TTY...
>
> Many are ignored, but some are relevant:
>
>   . foreground and background colors
>   . cursor blinking
>   . menuBar
>   . tabBar

Yes, I can see people wanting to have different frame parameters for
those in TTY vs. GUI, so I think it sounds like it would be worth
creating something here.  But it does look like a largish job -- we'd
have to go through all the places where default-frame-alist is altered
and see whether it should be window-system dependent or not.

For accesses, I think that's probably simpler: We could just replace all
instances where something is doing an `assq ... default-frame-alist'
with a helper function that does the right thing.

...

Oh!  `window-system-default-frame-alist' already exists!  Never mind.
So we could just alter the term/x-win code snippet.

(But I haven't read the rest of the thread here yet.)

>> I see.  I wondered whether this was for using X servers under Windows,
>> somehow...  (I think that existed a long time ago, at least?)
>
> It did?  I only know about X servers used to run X programs from
> remote Unix hosts.

Right, that must be what I vaguely remember, then -- it's been decades
since I encountered this.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#32921; Package emacs. Full text available.

Message received at 32921 <at> debbugs.gnu.org:


Received: (at 32921) by debbugs.gnu.org; 19 May 2022 13:56:09 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Thu May 19 09:56:09 2022
Received: from localhost ([127.0.0.1]:36294 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nrgdM-000244-S6
	for submit <at> debbugs.gnu.org; Thu, 19 May 2022 09:56:09 -0400
Received: from eggs.gnu.org ([209.51.188.92]:47230)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <eliz@HIDDEN>) id 1nrgdL-00023t-8h
 for 32921 <at> debbugs.gnu.org; Thu, 19 May 2022 09:56:08 -0400
Received: from fencepost.gnu.org ([2001:470:142:3::e]:57018)
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1nrgdE-0001F6-2k; Thu, 19 May 2022 09:56:01 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org;
 s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date:
 mime-version; bh=f2VNrzX6tcD22tSlaKZdy7Twp4yteGoCoiM4O7y1Nr4=; b=YigXZn67T1x8
 ABoHxl25zrAJQeO7VBIg/iTo9EaaporkbKeszun1sexHlR+My603XGJZNRYCpLHOtcTnNks9rtSbh
 qatDkr9UjwwM4a9mIoLpJUwWJ1vLhMj5D+sWyPCQCZd9NftXtWWhJ5nC89XoWtZPlPlXoUIN/grC4
 HTtjg7nGjbnp99j4oAYf9p6L9CM6qMM9uhEK4w++rpe7fN5v/nCGpcZGOQxjAgQbasCQQR2465CFs
 lqoTmN+4PSUdYi10OWfJ640QeUOurhjwRwqxLhxEtPYZ9PWuwXbvBgczNpzVqxL2w7yEGZhRT/4bx
 yz90W7efOUjEaBD7mopW5Q==;
Received: from [87.69.77.57] (port=1187 helo=home-c4e4a596f7)
 by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1nrgdC-0007ss-Rm; Thu, 19 May 2022 09:55:59 -0400
Date: Thu, 19 May 2022 16:55:54 +0300
Message-Id: <83pmk9d3th.fsf@HIDDEN>
From: Eli Zaretskii <eliz@HIDDEN>
To: Po Lu <luangruo@HIDDEN>
In-Reply-To: <877d6h1w01.fsf@HIDDEN> (message from Po Lu on Thu, 19 May
 2022 21:40:14 +0800)
Subject: Re: bug#32921: emacsclient obeys Xresources even when launched with
 -nw
References: <alpine.LFD.2.21.1810031946120.6536@jimisX1>
 <87o7zvc8xi.fsf@HIDDEN> <835ym3f0xt.fsf@HIDDEN>
 <875ym3c7bj.fsf@HIDDEN> <834k1nezs3.fsf@HIDDEN>
 <87ee0raqy2.fsf@HIDDEN> <87czgal2tt.fsf@HIDDEN>
 <838rqydmy8.fsf@HIDDEN> <878rqyklqj.fsf@HIDDEN>
 <831qwqdj2w.fsf@HIDDEN> <87fsl5sxse.fsf@HIDDEN>
 <83y1yxdffv.fsf@HIDDEN> <87czg93juo.fsf@HIDDEN>
 <83sfp5d7ad.fsf@HIDDEN> <87h75l1xeo.fsf@HIDDEN>
 <83r14pd5b6.fsf@HIDDEN> <877d6h1w01.fsf@HIDDEN>
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 32921
Cc: 32921 <at> debbugs.gnu.org, larsi@HIDDEN, jimis@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

> From: Po Lu <luangruo@HIDDEN>
> Cc: larsi@HIDDEN,  32921 <at> debbugs.gnu.org,  jimis@HIDDEN
> Date: Thu, 19 May 2022 21:40:14 +0800
> 
> Eli Zaretskii <eliz@HIDDEN> writes:
> 
> > That's what we are trying to understand, among other things.  I posted
> > one possible explanation.
> 
> I didn't really understand it, since there is no difference between
> "startup time" and "frame creation time": the X resources as known to
> Emacs do not change after the display connection is established.  They
> might change on the MS Windows registry emulation, but not on X.

No, there is a difference: when we change default-frame-alist at
startup time, that change is thereafter propagated to all future
frames, independently of what frame-creation-function will do when
each new frame is created.

> > Then I don't understand your objection at all: when Emacs starts up,
> > there's only one X server that can be relevant: the one where Emacs
> > shows its first frame.
> 
> My objection was that it behaves differently from the other X resources,
> in a way that is eventually overidden by `x-create-frame-with-faces'
> anyway.

The reverseVideo resource, like the -rv command-line argument, is
supposed to invert the colors that the user's customizations set.
Maybe this is why it is handled specially.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#32921; Package emacs. Full text available.

Message received at 32921 <at> debbugs.gnu.org:


Received: (at 32921) by debbugs.gnu.org; 19 May 2022 13:40:34 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Thu May 19 09:40:34 2022
Received: from localhost ([127.0.0.1]:34833 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nrgOH-0001G2-Vf
	for submit <at> debbugs.gnu.org; Thu, 19 May 2022 09:40:34 -0400
Received: from sonic312-23.consmr.mail.ne1.yahoo.com ([66.163.191.204]:34773)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <luangruo@HIDDEN>) id 1nrgOF-0001Fo-Nz
 for 32921 <at> debbugs.gnu.org; Thu, 19 May 2022 09:40:32 -0400
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048;
 t=1652967626; bh=b+Mv9cmEqe2VSkw9ulp2+rRHNKNR3J1cQOs/AWUzC7o=;
 h=From:To:Cc:Subject:References:Date:In-Reply-To:From:Subject:Reply-To;
 b=BFscd0hLJ5mM8v7lyxtJbq2rurzqoH+uJCVhmP+8q4ArkAbY/q+q5GQDJi9wPa9WbOlw6QhddBcYJv05XutlQniRT4yDk0+xb4LR+I9Dqq6QJ67jINILSD8qadPWFK7nOeECehdIJYQ0tTKwmaXv3Wh+qrcZoH9fjLTLZm712j5jPpUpuFwGCE30dqjRKJthIZ1l8PAmcyi3//shx2EkyCqFdMySrHLLk3u9D3Gb1tadyrqtCFe9BewZrlP8z7czDtqzySO6SiIP2gEmR7nKM5sPmC7i/+/Ekj68M/3AJdmzSF8ZX0SxuBlNY8u9Oa9qUH72U76hcXcQr2GegBXI9g==
X-SONIC-DKIM-SIGN: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048;
 t=1652967626; bh=YET9Ks+y/mIcRdSjBYoITHugP0sCZwWRgNDN9rXS7z7=;
 h=X-Sonic-MF:From:To:Subject:Date:From:Subject;
 b=aTeDK7RlNcmyFxWE3l95Y+Pl8XpXp0wKk2BdgBcb4/iecl8L32xDashougPQTMltUJjgN8qHl+r84rGVwZATOQcVgbqbQwaWU3ZsbNe8qkoQsy89SULgShQgUVpU7KT5WHiT5FT9q5l8MJUWOearniU4eR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ym6hCrH7OSWS1PVJSmuBO6D2u5w1PrufttJg5sK2qPidn5qBc7s
 LTH2xFoVwtB7n4riBN2VAwdBY3IYpk.5X.pyPdtjsRMVA_VGnU0qZ1EW1dF0fsEbahgsmswl_KiS
 ehs.RjNLSNFmd4c_pAvOFfSlDH5.Uh9iD7H6LCRWEZ5zEXyaRY8dfeIQm9e7qyc6kAkmBzW85ril
 GKWPCYPGVudFeqy1euNcYexDoPF5ja0cT5hhQkt5Z12xDo4dFNucbgbNdflOWJE0zspTorkEFb3y
 FQ.mBkjOeXXghKKYsBaoSNg4u6NmlGQbMD7oxTKCOBP.FJ4aB9ZNb4Z9Vc.Vpxjo_sr42ASmb8Pp
 YOsAF2VwsHsOivrgJDak6QrawYBmhQo7zGt7h3XgtGYd45SMUKFnOGH9cRbh5eg--
X-Sonic-MF: <luangruo@HIDDEN>
Received: from sonic.gate.mail.ne1.yahoo.com by
 sonic312.consmr.mail.ne1.yahoo.com with HTTP; Thu, 19 May 2022 13:40:26 +0000
Received: by hermes--canary-production-sg3-7959d4d9bd-zszfs (Yahoo Inc. Hermes
 SMTP Server) with ESMTPA ID 55720bd9eba6dc5901323e69be583bc0; 
 Thu, 19 May 2022 13:40:19 +0000 (UTC)
From: Po Lu <luangruo@HIDDEN>
To: Eli Zaretskii <eliz@HIDDEN>
Subject: Re: bug#32921: emacsclient obeys Xresources even when launched with
 -nw
References: <alpine.LFD.2.21.1810031946120.6536@jimisX1>
 <87o7zvc8xi.fsf@HIDDEN> <835ym3f0xt.fsf@HIDDEN>
 <875ym3c7bj.fsf@HIDDEN> <834k1nezs3.fsf@HIDDEN>
 <87ee0raqy2.fsf@HIDDEN> <87czgal2tt.fsf@HIDDEN>
 <838rqydmy8.fsf@HIDDEN> <878rqyklqj.fsf@HIDDEN>
 <831qwqdj2w.fsf@HIDDEN> <87fsl5sxse.fsf@HIDDEN>
 <83y1yxdffv.fsf@HIDDEN> <87czg93juo.fsf@HIDDEN>
 <83sfp5d7ad.fsf@HIDDEN> <87h75l1xeo.fsf@HIDDEN>
 <83r14pd5b6.fsf@HIDDEN>
Date: Thu, 19 May 2022 21:40:14 +0800
In-Reply-To: <83r14pd5b6.fsf@HIDDEN> (Eli Zaretskii's message of "Thu, 19 May
 2022 16:23:41 +0300")
Message-ID: <877d6h1w01.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.91 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Mailer: WebService/1.1.20225
 mail.backend.jedi.jws.acl:role.jedi.acl.token.atz.jws.hermes.yahoo
Content-Length: 1156
X-Spam-Score: -0.0 (/)
X-Debbugs-Envelope-To: 32921
Cc: 32921 <at> debbugs.gnu.org, larsi@HIDDEN, jimis@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.0 (-)

Eli Zaretskii <eliz@HIDDEN> writes:

> That's what we are trying to understand, among other things.  I posted
> one possible explanation.

I didn't really understand it, since there is no difference between
"startup time" and "frame creation time": the X resources as known to
Emacs do not change after the display connection is established.  They
might change on the MS Windows registry emulation, but not on X.

> I'm not sure this is 100% true.

Hmm, what other situations could there be?  Tooltip frames don't respect
`default-frame-alist' anyway, and I hope nobody out there is calling
`x-create-frame' directly.

> I don't know.  I guess for some kind of backward compatibility.  This
> is very old code.

My guess is that it was an oversight between 19.29 and 19.27.  But let's
see if anyone else knows what is going on.

> Then I don't understand your objection at all: when Emacs starts up,
> there's only one X server that can be relevant: the one where Emacs
> shows its first frame.

My objection was that it behaves differently from the other X resources,
in a way that is eventually overidden by `x-create-frame-with-faces'
anyway.

Thanks.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#32921; Package emacs. Full text available.

Message received at 32921 <at> debbugs.gnu.org:


Received: (at 32921) by debbugs.gnu.org; 19 May 2022 13:23:53 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Thu May 19 09:23:53 2022
Received: from localhost ([127.0.0.1]:34804 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nrg89-0000oh-9P
	for submit <at> debbugs.gnu.org; Thu, 19 May 2022 09:23:53 -0400
Received: from eggs.gnu.org ([209.51.188.92]:41044)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <eliz@HIDDEN>) id 1nrg87-0000oT-BL
 for 32921 <at> debbugs.gnu.org; Thu, 19 May 2022 09:23:51 -0400
Received: from fencepost.gnu.org ([2001:470:142:3::e]:56418)
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1nrg82-0004UX-0l; Thu, 19 May 2022 09:23:46 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org;
 s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date:
 mime-version; bh=FrEKW7TaDjgnUhl8hsuRMFJPcr6iJGlM44/ym+rewoc=; b=i2ZboCBeqCdY
 CcQHXufOCSwTQuAnyLob1gvyg9O1F2uJKQ+XG+ltHKbOH4MAh3AxveDSFb4PJS03yhRmecf+GSApU
 XFN4UycsrL7LXFtbzReP5dtnCWsOeyOTz6o5RVh7hXKocASYis/REqWXByI2iLHHpb8gZFu5JY4XY
 jIhiF+Gn1LdYOllincijyJ9wH+Pjl/dgdzNfL+H0yLomkiXT5i+gpAugBqe6aRvXzIJ1fTHTyKWKi
 pcp4+oxdRTWD/8jaM0CH8EpSeiZhRaXDHlNMiFn+ohHs1cTnae9Q8HGQ+TPBOYe8Lcd19+gSkMFqr
 TmFKOhuT2S9oQxk5YnRbYw==;
Received: from [87.69.77.57] (port=3190 helo=home-c4e4a596f7)
 by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1nrg81-00061M-Gg; Thu, 19 May 2022 09:23:45 -0400
Date: Thu, 19 May 2022 16:23:41 +0300
Message-Id: <83r14pd5b6.fsf@HIDDEN>
From: Eli Zaretskii <eliz@HIDDEN>
To: Po Lu <luangruo@HIDDEN>
In-Reply-To: <87h75l1xeo.fsf@HIDDEN> (message from Po Lu on Thu, 19 May
 2022 21:09:51 +0800)
Subject: Re: bug#32921: emacsclient obeys Xresources even when launched with
 -nw
References: <alpine.LFD.2.21.1810031946120.6536@jimisX1>
 <87o7zvc8xi.fsf@HIDDEN> <835ym3f0xt.fsf@HIDDEN>
 <875ym3c7bj.fsf@HIDDEN> <834k1nezs3.fsf@HIDDEN>
 <87ee0raqy2.fsf@HIDDEN> <87czgal2tt.fsf@HIDDEN>
 <838rqydmy8.fsf@HIDDEN> <878rqyklqj.fsf@HIDDEN>
 <831qwqdj2w.fsf@HIDDEN> <87fsl5sxse.fsf@HIDDEN>
 <83y1yxdffv.fsf@HIDDEN> <87czg93juo.fsf@HIDDEN>
 <83sfp5d7ad.fsf@HIDDEN> <87h75l1xeo.fsf@HIDDEN>
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 32921
Cc: 32921 <at> debbugs.gnu.org, larsi@HIDDEN, jimis@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

> From: Po Lu <luangruo@HIDDEN>
> Cc: larsi@HIDDEN,  32921 <at> debbugs.gnu.org,  jimis@HIDDEN
> Date: Thu, 19 May 2022 21:09:51 +0800
> 
> Eli Zaretskii <eliz@HIDDEN> writes:
> 
> > We already do that, see the information and the backtrace posted by
> > Lars a while ago.
> 
> Hmm... then why does this code still exist at all?

That's what we are trying to understand, among other things.  I posted
one possible explanation.

> x-create-frame-with-faces should take care of setting the `reverse'
> parameter entirely.

I'm not sure this is 100% true.

> Could you please explain what you meant by "startup timer" here?
> 
> > So the difference is between (a) taking notice of the reverseVideo
> > resource at startup timer as opposed to (b) at frame creation time, is
>               ^^^^^^^^^^^^^
> > that right?  If so, I think this might affect the use case whereby
> > someone changes the X resources after Emacs has already started, or
> > something?

It's a typo: I meant "at startup time".

> > The code in x-win.el does something beyond that: it caters for people
> > who have X resources specified on their user-private files, and want
> > those settings to be in effect on all displays.
> 
> But then why only a single resource, and not all of them?  Especially
> an obscure one like reverseVideo?

I don't know.  I guess for some kind of backward compatibility.  This
is very old code.

> > People who want Emacs to behave like you describe can simply remove
> > this setting from their ~/.Xdefaults.
> 
> That wouldn't be useful, since Emacs doesn't even load ~/.Xdefaults if
> the X server it connected to already has some resources loaded.

You assume that those hypothetical people didn't take care of that.

> > Not necessarily, because frame-parameters applied by
> > gui_default_parameter could override those we took from ~/.Xdefaults.
> 
> I meant the parameters applied by gui_default_parameter when the
> parameter is not present in `default-frame-alist' or the ALIST argument.

Then I don't understand your objection at all: when Emacs starts up,
there's only one X server that can be relevant: the one where Emacs
shows its first frame.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#32921; Package emacs. Full text available.

Message received at 32921 <at> debbugs.gnu.org:


Received: (at 32921) by debbugs.gnu.org; 19 May 2022 13:10:07 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Thu May 19 09:10:07 2022
Received: from localhost ([127.0.0.1]:34793 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nrfuo-0000Sk-MD
	for submit <at> debbugs.gnu.org; Thu, 19 May 2022 09:10:06 -0400
Received: from sonic303-21.consmr.mail.ne1.yahoo.com ([66.163.188.147]:41582)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <luangruo@HIDDEN>) id 1nrfun-0000S3-EK
 for 32921 <at> debbugs.gnu.org; Thu, 19 May 2022 09:10:05 -0400
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048;
 t=1652965800; bh=qPOXLmBtaQY2nARaTqXJxZGQoQbVEw0F1hyi648Q7SU=;
 h=From:To:Cc:Subject:References:Date:In-Reply-To:From:Subject:Reply-To;
 b=c5mXqOW+0aWqqefUgJjgVo73TWsCbZqoyPhPZ/o8Z6m2MxdWeYiB4DE6RvfLXLjKUe9S2DuN/IpTWBRVM7fpvHoQZ6PzOVC3RnHTHIdRV3+HKmSRWhFiKYm5DlQIHl+V7ohGYK1pKUKuYno3exj0mHho55YEF54K9yfAD3r6PtATl69dqPi4KsmH5SA+KXQmGCCW/6uCphAItpo51l+aIxVeJ1tZz6BjMVyBnY6T3PX5TSMuBin2UyWsoCJ/C+SJoqzwNJBZ1r/dCURPfhGkYg36GdmyMdEQaa74CW5lOb8c+9athQBEj40w9SwF7Xp1LfINMN3EdWFCqMniMCZAgQ==
X-SONIC-DKIM-SIGN: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048;
 t=1652965800; bh=eufE4qXCfNyJCr77VLvpPa+qmkaYwqn0ZY62e6etc+p=;
 h=X-Sonic-MF:From:To:Subject:Date:From:Subject;
 b=bN+8+2giotyueEg5pavH1RLK+SFwZPf27jgps3w6Ir/bUGQos1ijiV419VPuvDtGv/zxCg88IgwV7e+yGj5zRhyy3uoBtgS4a1iWxhmi0NRUk5WSFXdIrlRnW2F2aknfwDHcmWu2kmIxIUb+YE0ENQcN2PPM4j8Ya9r0oecxeORfn+vQVPOL9Wtdm9An6DRvro10b77UuLR148G6dVqqThgKpFO3I3gfzNszgorCDKj15FLgiXD1e76buKBlYMxdvQh3XOdDXZnPBTs3Jc3zXNY6RUvI35aOH2rpdZFOcpVZ1d31hGQxWY0epPP1Osi0n3j6a4gnKcVUn38bHZncuw==
X-YMail-OSG: ElRpwKIVM1kFs8oe7DSgv2u59fCcqTC0U6mhG1th5jMDVmH7_OM.30EoF3Nk.i5
 TigkAMt0rZAIL_f9u_MwYFy2ea71hij9_e6HHRmTUyYiL_wPigdgzttj6d9Yh7N2Rx8cGOB0F2bc
 OLldNnO9KKH2kJ9Xp6BT2GhP6wkADLbspcW_27_XdqJi973YKpmF7ekueJiQlOk9r5RCfW8LwgYZ
 EPj6K802Tlb8889frJTfqBpmo6bO.GhZA2Tmcy.EDpfGz5hm733_NS0DCyjIVjHoDpaCarRuZUpz
 38Vd4PDDTQvdFLinTLQl9SGJd.2Qv_fFDqx5oAL64X.uTnh3VaY8pgA4F7nKzrOfm.zZi08YuAUA
 72LUlwg7s2OO7fKNZ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0O42VwKojYVWVF.XiVCA01agcXGslaHsdCPxZ_e7SDW1gk7Pe2KCldwvo_Vs6P3RJh.2NtHLjL
 tMOGQ4VYDWDpqbOPhWGuZdeF2uiQbKqMl2ckhA6mlUPzektgEJyf.fv3v4aAdiBwPY0hakNSue_K
 01JmiRidl58SBYYisVvb_lVX3lODZrUJ_JhOazyX1DnTvPQ522YgbDkgQ85jwxLkSfNW_m8pz6ep
 mQmkOs8OV5wKB5ctvAWCKUD3Vn2HDMp2DOb7Wjk088KBm089OmeXiPlkBWtl5FlgrXZiZNC0DmNE
 UDlxd24nPrctFXyPcLK1bwCHiafw2deK.RNBUCAbgqcQDw0ZXUS5w2a94caU_Z5VoE_1YDhyIOAq
 2vzNsMvc8RfGq6qgo7TrdhneAIkyDwV1g6xWZueWoXMWa1rn7rrnNefatZdiD.xOpxsLf2q3hO6c
 WJuPuhkJY0_Qszu7nH63levHBTr2mOrTTmUZC3vNVVU_lyEwoDBXlfU5sXrOe1xt.hhM0cqVvvlB
 L.oR7jdSn9Dps8lUxGDY83TnE7mTLkvdYVe1AGiPND7mVU35hEPf0ztbJ0cPQJEa.PZk1R8UdaqL
 d8wH4A2SBALiHt8CYS8GgPWPV5fhzJIb1g6dKLTUL6IdxbuYHjm1yCzeOrmHc9m5zxQRFZ3JEESW
 V.gQaz7tcaeK4XFbiWg1C8eSfITxVH1571EfcW5A2aYmVpTgKPfaqJCkJxNDrI0B5n26owLOCtRh
 xjscURwQeUbjJF_C6S8iLm1pqdTZo6x6irpXSktqAb1akmCP2brn13AOZ9eupG9TjISBEI4z759S
 NwMvF0mpOsqm3QOTQ3BYjow_vDIS2XybBdo8nfwkJOr0pnpa6EUh0aBCD0xs9XMk-
X-Sonic-MF: <luangruo@HIDDEN>
Received: from sonic.gate.mail.ne1.yahoo.com by
 sonic303.consmr.mail.ne1.yahoo.com with HTTP; Thu, 19 May 2022 13:10:00 +0000
Received: by hermes--canary-production-sg3-7959d4d9bd-bjkcg (Yahoo Inc. Hermes
 SMTP Server) with ESMTPA ID 3bd6ef06ea25d9f6590ec137c6d82124; 
 Thu, 19 May 2022 13:09:55 +0000 (UTC)
From: Po Lu <luangruo@HIDDEN>
To: Eli Zaretskii <eliz@HIDDEN>
Subject: Re: bug#32921: emacsclient obeys Xresources even when launched with
 -nw
References: <alpine.LFD.2.21.1810031946120.6536@jimisX1>
 <87o7zvc8xi.fsf@HIDDEN> <835ym3f0xt.fsf@HIDDEN>
 <875ym3c7bj.fsf@HIDDEN> <834k1nezs3.fsf@HIDDEN>
 <87ee0raqy2.fsf@HIDDEN> <87czgal2tt.fsf@HIDDEN>
 <838rqydmy8.fsf@HIDDEN> <878rqyklqj.fsf@HIDDEN>
 <831qwqdj2w.fsf@HIDDEN> <87fsl5sxse.fsf@HIDDEN>
 <83y1yxdffv.fsf@HIDDEN> <87czg93juo.fsf@HIDDEN>
 <83sfp5d7ad.fsf@HIDDEN>
Date: Thu, 19 May 2022 21:09:51 +0800
In-Reply-To: <83sfp5d7ad.fsf@HIDDEN> (Eli Zaretskii's message of "Thu, 19 May
 2022 15:40:58 +0300")
Message-ID: <87h75l1xeo.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.91 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Mailer: WebService/1.1.20225
 mail.backend.jedi.jws.acl:role.jedi.acl.token.atz.jws.hermes.yahoo
Content-Length: 2790
X-Spam-Score: -0.0 (/)
X-Debbugs-Envelope-To: 32921
Cc: 32921 <at> debbugs.gnu.org, larsi@HIDDEN, jimis@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.0 (-)

Eli Zaretskii <eliz@HIDDEN> writes:

> We already do that, see the information and the backtrace posted by
> Lars a while ago.

Hmm... then why does this code still exist at all?
x-create-frame-with-faces should take care of setting the `reverse'
parameter entirely.

Could you please explain what you meant by "startup timer" here?

> So the difference is between (a) taking notice of the reverseVideo
> resource at startup timer as opposed to (b) at frame creation time, is
              ^^^^^^^^^^^^^
> that right?  If so, I think this might affect the use case whereby
> someone changes the X resources after Emacs has already started, or
> something?

Though I doubt this really matters, since X resources cannot change
after Emacs starts.

> The code in x-win.el does something beyond that: it caters for people
> who have X resources specified on their user-private files, and want
> those settings to be in effect on all displays.

But then why only a single resource, and not all of them?  Especially
an obscure one like reverseVideo?

BTW, I think I found out why this situation is.  Before Emacs 19.29,
reverseVideo and selectionTimeout were both set up in x-win.el assuming
that there would only ever be a single display, just like the other
frame parameters in Fx_create_frame.

When support for multiple displays was added in 19.29, the changes to
make X resources affecting frame parameters specific to each display
were made to the C code in Fx_create_frame, but not to the two
parameters set in Lisp.  Whether or not that was done intentionally is
anyone's guess, but I think it was a bug, or an oversight.

> (And besides, what is the chance that someone will want different
> values of reverseVideo on different displays?  I think the chances for
> that are nil.)

Many other programs accept a resource named reverseVideo (it and -rv are
a very standard knobs for X programs), so I can imagine someone placing:

  *.reverseVideo: on

in the X resources for an X server with dark window decorations, and
vice versa.  Emacs should create frames with the colors specified on
each server it is connected to.

> Because we will otherwise break a long-standing behavior.

[...]

> People who want Emacs to behave like you describe can simply remove
> this setting from their ~/.Xdefaults.

That wouldn't be useful, since Emacs doesn't even load ~/.Xdefaults if
the X server it connected to already has some resources loaded.  Doing
that is the job of the session script(s) that started the X server.

> Not necessarily, because frame-parameters applied by
> gui_default_parameter could override those we took from ~/.Xdefaults.

I meant the parameters applied by gui_default_parameter when the
parameter is not present in `default-frame-alist' or the ALIST argument.

Thanks.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#32921; Package emacs. Full text available.

Message received at 32921 <at> debbugs.gnu.org:


Received: (at 32921) by debbugs.gnu.org; 19 May 2022 12:41:09 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Thu May 19 08:41:09 2022
Received: from localhost ([127.0.0.1]:34752 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nrfSn-00084h-Ft
	for submit <at> debbugs.gnu.org; Thu, 19 May 2022 08:41:09 -0400
Received: from eggs.gnu.org ([209.51.188.92]:60610)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <eliz@HIDDEN>) id 1nrfSm-00084V-9f
 for 32921 <at> debbugs.gnu.org; Thu, 19 May 2022 08:41:08 -0400
Received: from fencepost.gnu.org ([2001:470:142:3::e]:55976)
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1nrfSg-00065E-SH; Thu, 19 May 2022 08:41:02 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org;
 s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date:
 mime-version; bh=qaX2E4ObZVtqBaoRMnnb2GYZoBjViLeUpHS3qf1PHEI=; b=Q9A1Lpwe9fU/
 sqD7Pz+uWHAcC05OqY0Z1rzpg+Gw4wdZxmem2iHCXI9bLsh8MUQsIdnQA/sUxh7W3jGOdxxrdj6Q3
 dEUt1tMs4HRcyBIONQgydHh+8iNAhm9LENKpfrUOp5rlPW47IMt33oSFjLiQGw814AAMwo8TM7RwK
 bCDEfKApVUtbHLoHFuAQQqM1ThoN3dqImheoWQ4VAd2VYOzaSUfzTlijOaNCL/m5qyONE6XJPWJBa
 WzXjRA/iriM42a62AxlVP4yz28H+cVNEZX3Cp3U2bWSpKiAhscm2frJYB9+5ZbQJZ402egz+7Fnye
 gXsxgfF+WiKsR+KxscAPUQ==;
Received: from [87.69.77.57] (port=4302 helo=home-c4e4a596f7)
 by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1nrfSf-0006hd-RR; Thu, 19 May 2022 08:41:02 -0400
Date: Thu, 19 May 2022 15:40:58 +0300
Message-Id: <83sfp5d7ad.fsf@HIDDEN>
From: Eli Zaretskii <eliz@HIDDEN>
To: Po Lu <luangruo@HIDDEN>
In-Reply-To: <87czg93juo.fsf@HIDDEN> (message from Po Lu on Thu, 19 May
 2022 18:19:43 +0800)
Subject: Re: bug#32921: emacsclient obeys Xresources even when launched with
 -nw
References: <alpine.LFD.2.21.1810031946120.6536@jimisX1>
 <87o7zvc8xi.fsf@HIDDEN> <835ym3f0xt.fsf@HIDDEN>
 <875ym3c7bj.fsf@HIDDEN> <834k1nezs3.fsf@HIDDEN>
 <87ee0raqy2.fsf@HIDDEN> <87czgal2tt.fsf@HIDDEN>
 <838rqydmy8.fsf@HIDDEN> <878rqyklqj.fsf@HIDDEN>
 <831qwqdj2w.fsf@HIDDEN> <87fsl5sxse.fsf@HIDDEN>
 <83y1yxdffv.fsf@HIDDEN> <87czg93juo.fsf@HIDDEN>
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 32921
Cc: 32921 <at> debbugs.gnu.org, larsi@HIDDEN, jimis@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

> From: Po Lu <luangruo@HIDDEN>
> Cc: larsi@HIDDEN,  32921 <at> debbugs.gnu.org,  jimis@HIDDEN
> Date: Thu, 19 May 2022 18:19:43 +0800
> 
> Eli Zaretskii <eliz@HIDDEN> writes:
> 
> > How do you mean "never"?  We have here the code in x-win.el which does
> > that and is very old, so "never" doesn't seem to be a good description
> > of the situation.  And multi-TTY support has nothing to do with
> > multiple X displays.  AFAIU, you suggested to take the X resources
> > into consideration only for the first X display on which Emacs opens
> > its first frame.  What does this have to do with multi-TTY?
> 
> No, I suggested to take the value of Emacs.reverseVideo of each display
> (yes, they are different between different displays) into account only
> for frames created that display.

We already do that, see the information and the backtrace posted by
Lars a while ago.

The code in x-win.el does something beyond that: it caters for people
who have X resources specified on their user-private files, and want
those settings to be in effect on all displays.

(And besides, what is the chance that someone will want different
values of reverseVideo on different displays?  I think the chances for
that are nil.)

> > This is completely irrelevant.  We supported X resources in Emacs
> > forever, and I see no reason to unsupport them now.  We need to
> > discuss this under the assumption that ~/.Xresources and ~/.Xdefaults
> > will continue to have the same effect on Emacs as they did before, at
> > least optionally if not by default.  Thus, suggestions to toss that
> > support are non-starters from where I stand.
> 
> Why?

Because we will otherwise break a long-standing behavior.

> My point was that X resources in Emacs are loaded from the X
> server, and as such reverseVideo could be different from one display to
> the other.  This works fine with frame parameters that are set with
> gui_default_parameter, since that calls gui_display_get_resource with
> the dpyinfo the frame is on.  However, the existing code applies the
> value of reverseVideo of the first display to all frames, even those
> created on subsequently opened displays, which means the `reverse' frame
> parameter of those frames will not match the value of Emacs.reverseVideo
> on any display other than the first display that was created.

People who want Emacs to behave like you describe can simply remove
this setting from their ~/.Xdefaults.

> > What about the suggestion to have specially-named frame parameters in
> > default-frame-alist, which are defined from X resources and only
> > applied to GUI frames?
> 
> That would work incorrectly if Emacs was connected to two different X
> servers, each with different values of reverseVideo.

Not necessarily, because frame-parameters applied by
gui_default_parameter could override those we took from ~/.Xdefaults.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#32921; Package emacs. Full text available.

Message received at 32921 <at> debbugs.gnu.org:


Received: (at 32921) by debbugs.gnu.org; 19 May 2022 10:20:06 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Thu May 19 06:20:06 2022
Received: from localhost ([127.0.0.1]:34530 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nrdGH-000882-Ph
	for submit <at> debbugs.gnu.org; Thu, 19 May 2022 06:20:06 -0400
Received: from sonic313-56.consmr.mail.ne1.yahoo.com ([66.163.185.31]:39952)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <luangruo@HIDDEN>) id 1nrdGF-00087R-W5
 for 32921 <at> debbugs.gnu.org; Thu, 19 May 2022 06:20:04 -0400
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048;
 t=1652955597; bh=k2AdsEMnhnN27sks12JKVcngcDJJ+D7kWOBohT52QlI=;
 h=From:To:Cc:Subject:References:Date:In-Reply-To:From:Subject:Reply-To;
 b=fE4eMQFYt89r+FRLZpe1uDzS1i1SaB+43gMvpWyNQ/u7alxwnFF4g58597vdc8P+O08cKf4Wu40h42c27W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mail.ne1.yahoo.com with HTTP; Thu, 19 May 2022 10:19:57 +0000
Received: by hermes--canary-production-sg3-7959d4d9bd-426jq (Yahoo Inc. Hermes
 SMTP Server) with ESMTPA ID 0ffdd89f7c0eb1cb7770ea878db03c20; 
 Thu, 19 May 2022 10:19:50 +0000 (UTC)
From: Po Lu <luangruo@HIDDEN>
To: Eli Zaretskii <eliz@HIDDEN>
Subject: Re: bug#32921: emacsclient obeys Xresources even when launched with
 -nw
References: <alpine.LFD.2.21.1810031946120.6536@jimisX1>
 <87o7zvc8xi.fsf@HIDDEN> <835ym3f0xt.fsf@HIDDEN>
 <875ym3c7bj.fsf@HIDDEN> <834k1nezs3.fsf@HIDDEN>
 <87ee0raqy2.fsf@HIDDEN> <87czgal2tt.fsf@HIDDEN>
 <838rqydmy8.fsf@HIDDEN> <878rqyklqj.fsf@HIDDEN>
 <831qwqdj2w.fsf@HIDDEN> <87fsl5sxse.fsf@HIDDEN>
 <83y1yxdffv.fsf@HIDDEN>
Date: Thu, 19 May 2022 18:19:43 +0800
In-Reply-To: <83y1yxdffv.fsf@HIDDEN> (Eli Zaretskii's message of "Thu, 19 May
 2022 12:44:52 +0300")
Message-ID: <87czg93juo.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.91 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Mailer: WebService/1.1.20225
 mail.backend.jedi.jws.acl:role.jedi.acl.token.atz.jws.hermes.yahoo
Content-Length: 1938
X-Spam-Score: -0.0 (/)
X-Debbugs-Envelope-To: 32921
Cc: 32921 <at> debbugs.gnu.org, larsi@HIDDEN, jimis@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.0 (-)

Eli Zaretskii <eliz@HIDDEN> writes:

> How do you mean "never"?  We have here the code in x-win.el which does
> that and is very old, so "never" doesn't seem to be a good description
> of the situation.  And multi-TTY support has nothing to do with
> multiple X displays.  AFAIU, you suggested to take the X resources
> into consideration only for the first X display on which Emacs opens
> its first frame.  What does this have to do with multi-TTY?

No, I suggested to take the value of Emacs.reverseVideo of each display
(yes, they are different between different displays) into account only
for frames created that display.

> This is completely irrelevant.  We supported X resources in Emacs
> forever, and I see no reason to unsupport them now.  We need to
> discuss this under the assumption that ~/.Xresources and ~/.Xdefaults
> will continue to have the same effect on Emacs as they did before, at
> least optionally if not by default.  Thus, suggestions to toss that
> support are non-starters from where I stand.

Why?  My point was that X resources in Emacs are loaded from the X
server, and as such reverseVideo could be different from one display to
the other.  This works fine with frame parameters that are set with
gui_default_parameter, since that calls gui_display_get_resource with
the dpyinfo the frame is on.  However, the existing code applies the
value of reverseVideo of the first display to all frames, even those
created on subsequently opened displays, which means the `reverse' frame
parameter of those frames will not match the value of Emacs.reverseVideo
on any display other than the first display that was created.

> What about the suggestion to have specially-named frame parameters in
> default-frame-alist, which are defined from X resources and only
> applied to GUI frames?

That would work incorrectly if Emacs was connected to two different X
servers, each with different values of reverseVideo.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#32921; Package emacs. Full text available.

Message received at 32921 <at> debbugs.gnu.org:


Received: (at 32921) by debbugs.gnu.org; 19 May 2022 09:45:13 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Thu May 19 05:45:13 2022
Received: from localhost ([127.0.0.1]:34511 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nrciO-0007CH-6J
	for submit <at> debbugs.gnu.org; Thu, 19 May 2022 05:45:13 -0400
Received: from eggs.gnu.org ([209.51.188.92]:51068)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <eliz@HIDDEN>) id 1nrciL-0007BT-Ux
 for 32921 <at> debbugs.gnu.org; Thu, 19 May 2022 05:45:02 -0400
Received: from fencepost.gnu.org ([2001:470:142:3::e]:53948)
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1nrciG-0001Qk-H4; Thu, 19 May 2022 05:44:56 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org;
 s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date:
 mime-version; bh=egBBEAom73OD5MytIwlP9S87w/pu/KSU6GKUOv442h0=; b=rKuIs+z+/wZH
 gQiFZuJ6el1Wf81JcwYceCCGJHQfz5M5+63PxfiKlZ+yhkCuWykyBdvZLuUjuexazrQQOMQ0OqRHZ
 977etzfY3b2rXcWb6QoBkUD796DMM1NwhzwVp4mZ3wd9wdj9jMXWbu1eKD6J9j4W93uQn+i/dekS9
 9W1GLt5aWJ2MHUhodP61erL5On15KCKtENZIrVjh898PmXJv2WdTvt+p0SZmIYv/UR+BBXYEgXPdC
 05eedca2aDHidUvks4AmxJk9V3WIcDbqq3WP7qUB+A9fmGs+QcA6gZySeqxJ/jnphkzX2/eL+zvre
 59lEJFFjhxWK3095RdVW+w==;
Received: from [87.69.77.57] (port=1508 helo=home-c4e4a596f7)
 by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1nrciG-000800-0J; Thu, 19 May 2022 05:44:56 -0400
Date: Thu, 19 May 2022 12:44:52 +0300
Message-Id: <83y1yxdffv.fsf@HIDDEN>
From: Eli Zaretskii <eliz@HIDDEN>
To: Po Lu <luangruo@HIDDEN>
In-Reply-To: <87fsl5sxse.fsf@HIDDEN> (message from Po Lu on Thu, 19 May
 2022 16:59:29 +0800)
Subject: Re: bug#32921: emacsclient obeys Xresources even when launched with
 -nw
References: <alpine.LFD.2.21.1810031946120.6536@jimisX1>
 <87o7zvc8xi.fsf@HIDDEN> <835ym3f0xt.fsf@HIDDEN>
 <875ym3c7bj.fsf@HIDDEN> <834k1nezs3.fsf@HIDDEN>
 <87ee0raqy2.fsf@HIDDEN> <87czgal2tt.fsf@HIDDEN>
 <838rqydmy8.fsf@HIDDEN> <878rqyklqj.fsf@HIDDEN>
 <831qwqdj2w.fsf@HIDDEN> <87fsl5sxse.fsf@HIDDEN>
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 32921
Cc: 32921 <at> debbugs.gnu.org, larsi@HIDDEN, jimis@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

> From: Po Lu <luangruo@HIDDEN>
> Cc: larsi@HIDDEN,  32921 <at> debbugs.gnu.org,  jimis@HIDDEN
> Date: Thu, 19 May 2022 16:59:29 +0800
> 
> Eli Zaretskii <eliz@HIDDEN> writes:
> 
> > We may be miscommunicating.  The offending code in x-win.el is called
> > at startup, only once, and sets up default-frame-alist for all the
> > future frames, including those on displays this Emacs session did not
> > yet open and knows nothing about.  How would you define
> > default-frame-alist that is specific to those as-yet-unknown displays?
> 
> I would leave it empty.

That means we stop supporting X resources, more or less.

> > And if you are saying that the code in x-win.el should only affect the
> > display on which Emacs was started, then that would be an even more
> > seriously breaking change.  Why should we assume that the user
> > intended his/her X resources to be only honored on the (random)
> > display where Emacs shows its first frame?  The files ~/.Xresources
> > and ~/.Xdefaults are not specific to any display, AFAIU, they are
> > global for the user.  Right?
> 
> Emacs _never_ honored any other X resource that happened to be on the
> first display for every display, and I have a feeling this code was a
> mistake left over from the refactoring of `x-win.el' when multi-TTY was
> developed.

How do you mean "never"?  We have here the code in x-win.el which does
that and is very old, so "never" doesn't seem to be a good description
of the situation.  And multi-TTY support has nothing to do with
multiple X displays.  AFAIU, you suggested to take the X resources
into consideration only for the first X display on which Emacs opens
its first frame.  What does this have to do with multi-TTY?

> Emacs, like all other X programs, takes resources from several different
> sources:
> 
>   - The system's locale-specific X resources.  This is normally empty on
>     modern systems.
> 
>   - The user's personal X resource files for Emacs.  This is also mostly
>     empty on modern systems.
> 
>   - The user's X defaults that were loaded into the X server.  Only if
>     the no X resources were loaded into the X server will Emacs try to
>     load them itself from ~/.Xdefaults.
> 
>   - The environment defaults.  Also empty on modern systems.
> 
> This is why X resources are typically specific to each X server, which
> is also why Emacs keeps a different resource database for each display
> connection, and does not try to apply resources (other than
> `reverseVideo') from one display connection to another.

This is completely irrelevant.  We supported X resources in Emacs
forever, and I see no reason to unsupport them now.  We need to
discuss this under the assumption that ~/.Xresources and ~/.Xdefaults
will continue to have the same effect on Emacs as they did before, at
least optionally if not by default.  Thus, suggestions to toss that
support are non-starters from where I stand.

What about the suggestion to have specially-named frame parameters in
default-frame-alist, which are defined from X resources and only
applied to GUI frames?




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#32921; Package emacs. Full text available.

Message received at 32921 <at> debbugs.gnu.org:


Received: (at 32921) by debbugs.gnu.org; 19 May 2022 08:59:50 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Thu May 19 04:59:50 2022
Received: from localhost ([127.0.0.1]:34475 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nrc0c-00062h-3I
	for submit <at> debbugs.gnu.org; Thu, 19 May 2022 04:59:50 -0400
Received: from sonic304-20.consmr.mail.ne1.yahoo.com ([66.163.191.146]:46876)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <luangruo@HIDDEN>) id 1nrc0a-00062S-Ks
 for 32921 <at> debbugs.gnu.org; Thu, 19 May 2022 04:59:48 -0400
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048;
 t=1652950783; bh=82fqh/EG1CzBYEsgqZnEnunYrIyie7S5iE2SmPDAe9k=;
 h=From:To:Cc:Subject:References:Date:In-Reply-To:From:Subject:Reply-To;
 b=kwY3vSQ0MQO5r03oP/VPtnmVHhKmSYrMiTZjWPrxohfT4patezMuVyPC8dGxxGk4AheopyGMukAc1+rAZlmXrsT6bc0arJM1PR6uxndy0BIy9NMzqpuNpgavGjw5WEI42F/yd6AqG7ygs9C4e74+VBixsyVL8GrsOmaCETU3ZkXwZRdlRIc0f+eIYPPk3YpnpI/wcd9XcgqGKRIMcEBDR5fC0ssvjlWJqKCqdwf4eHQxdtRHZmYxdv/PrT8zko6IRozQiGsJdCU1xU5NSOkHOfu8Ggn9IMD69dsHN6VDef3dm8LUDE4IFF2HNql35IbJXG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
 SNBdELm9rz5vD733.Ol9PW_vWHICEsO6fN8MSIYKgcCdjZjnRg_LEnDT76xCPs9XC1zdtVC61R9H
 FeASRVZAMRtaSMKep4qU82F7EETFjVg5jbs9wQkAG1b0waa0U0orli8cTT37cZw0phE.Bxsy6IME
 mm_FD6HRB05U675_ALzQyIECqqNzjJVO6JfCpmFQrNZuYQcB3XYdVcvWCZZKYz.fy93r6OS7jGWn
 mcVdvmLj9vCttcFukuL2_QtQnKrX547WA_aEx3rcYs0nDNGZO_5tmicQUdxEQNbC9rJWlobJrvat
 Zw.XV8Oz0fYZ1YL9TCd13N5clC_xeCVYAYTOYyBSYAY2L96paL4ctqfk.DlLPxNFklpWqJ0F0ojR
 3TZFcG9lu3HggJUMSF9g3zP9N4J4Q5OBuQSRZHRwynceYDNB6MjoW7MhlsUS.jnPotUMu7rz2btu
 kXTGInfWzFNqJnCEUG4Ni74ZxoUj1QccxkKziB9rpIidCFlRvQkUlyXwX0AjBn8o.7Q48f11rMh1
 ZE3J889ax6Su9FbNC9ZT.nl_rZkvo1Me7vuB2Z6gchYdLZv6ozeUtPj6jefzaHsFsroJ9FUHktlE
 qhH4iSZWr.tCPixobfgEM9Z2Y2L5wfWEryqKZwVEQmp2mykLYgR9Z2sWq5rcnSxwBldas9R0biCG
 aetkpdmTWtjDQG4ATx7cEf4nh7Z3T2mmcm0rfwZLjqJ6llzcMXlYMDGDbIz4-
X-Sonic-MF: <luangruo@HIDDEN>
Received: from sonic.gate.mail.ne1.yahoo.com by
 sonic304.consmr.mail.ne1.yahoo.com with HTTP; Thu, 19 May 2022 08:59:43 +0000
Received: by hermes--canary-production-sg3-7959d4d9bd-b4hml (Yahoo Inc. Hermes
 SMTP Server) with ESMTPA ID 30ef9b5b36024781c1086912d9a3d53e; 
 Thu, 19 May 2022 08:59:38 +0000 (UTC)
From: Po Lu <luangruo@HIDDEN>
To: Eli Zaretskii <eliz@HIDDEN>
Subject: Re: bug#32921: emacsclient obeys Xresources even when launched with
 -nw
References: <alpine.LFD.2.21.1810031946120.6536@jimisX1>
 <87o7zvc8xi.fsf@HIDDEN> <835ym3f0xt.fsf@HIDDEN>
 <875ym3c7bj.fsf@HIDDEN> <834k1nezs3.fsf@HIDDEN>
 <87ee0raqy2.fsf@HIDDEN> <87czgal2tt.fsf@HIDDEN>
 <838rqydmy8.fsf@HIDDEN> <878rqyklqj.fsf@HIDDEN>
 <831qwqdj2w.fsf@HIDDEN>
Date: Thu, 19 May 2022 16:59:29 +0800
In-Reply-To: <831qwqdj2w.fsf@HIDDEN> (Eli Zaretskii's message of "Thu, 19 May
 2022 11:26:15 +0300")
Message-ID: <87fsl5sxse.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.91 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Mailer: WebService/1.1.20225
 mail.backend.jedi.jws.acl:role.jedi.acl.token.atz.jws.hermes.yahoo
Content-Length: 1859
X-Spam-Score: -0.0 (/)
X-Debbugs-Envelope-To: 32921
Cc: 32921 <at> debbugs.gnu.org, larsi@HIDDEN, jimis@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.0 (-)

Eli Zaretskii <eliz@HIDDEN> writes:

> We may be miscommunicating.  The offending code in x-win.el is called
> at startup, only once, and sets up default-frame-alist for all the
> future frames, including those on displays this Emacs session did not
> yet open and knows nothing about.  How would you define
> default-frame-alist that is specific to those as-yet-unknown displays?

I would leave it empty.

> And if you are saying that the code in x-win.el should only affect the
> display on which Emacs was started, then that would be an even more
> seriously breaking change.  Why should we assume that the user
> intended his/her X resources to be only honored on the (random)
> display where Emacs shows its first frame?  The files ~/.Xresources
> and ~/.Xdefaults are not specific to any display, AFAIU, they are
> global for the user.  Right?

Emacs _never_ honored any other X resource that happened to be on the
first display for every display, and I have a feeling this code was a
mistake left over from the refactoring of `x-win.el' when multi-TTY was
developed.

Emacs, like all other X programs, takes resources from several different
sources:

  - The system's locale-specific X resources.  This is normally empty on
    modern systems.

  - The user's personal X resource files for Emacs.  This is also mostly
    empty on modern systems.

  - The user's X defaults that were loaded into the X server.  Only if
    the no X resources were loaded into the X server will Emacs try to
    load them itself from ~/.Xdefaults.

  - The environment defaults.  Also empty on modern systems.

This is why X resources are typically specific to each X server, which
is also why Emacs keeps a different resource database for each display
connection, and does not try to apply resources (other than
`reverseVideo') from one display connection to another.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#32921; Package emacs. Full text available.

Message received at 32921 <at> debbugs.gnu.org:


Received: (at 32921) by debbugs.gnu.org; 19 May 2022 08:26:29 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Thu May 19 04:26:28 2022
Received: from localhost ([127.0.0.1]:34436 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nrbUK-00059A-JT
	for submit <at> debbugs.gnu.org; Thu, 19 May 2022 04:26:28 -0400
Received: from eggs.gnu.org ([209.51.188.92]:38360)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <eliz@HIDDEN>) id 1nrbUH-00058w-JW
 for 32921 <at> debbugs.gnu.org; Thu, 19 May 2022 04:26:26 -0400
Received: from fencepost.gnu.org ([2001:470:142:3::e]:53338)
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1nrbUC-0007C8-83; Thu, 19 May 2022 04:26:20 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org;
 s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date:
 mime-version; bh=jiJ6aTgN9/2piZnsgvHGEiIbqqN80s+dayKNNOvMXXM=; b=gaqUQLPIs7ZQ
 F7Tab+JOZBOFHORDYuMOiq1bSJTbjBAgiQG2B4mKQWx4mcwYDsoa6Ud/2FAG2xwparmI2Z/9e/f0i
 AWXPnYx6ZXj2knHWCal6Q0ojWTDVGvL6nhiEqz3Hxrq+wM4XODWDoRyhlqIOUCxGDKhvbpNZk6uG8
 zj0cLhBrmxfdxvx8R9oLGyKN65Pw1jDaPvj8egG+aS+/FwmzV7jOZQ5uZkffH55uORS1HJf+8eM5I
 Uh8gfgOn9k81nenZb/iudeIFYW7ky2nrkb29JYdQsukO0Znj5+K1EDdctYjlGCsdT8hRJ8SiDuKxI
 nYECf+YR/fEjxvvyK6Mhrg==;
Received: from [87.69.77.57] (port=4651 helo=home-c4e4a596f7)
 by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1nrbUB-0004rK-Kf; Thu, 19 May 2022 04:26:20 -0400
Date: Thu, 19 May 2022 11:26:15 +0300
Message-Id: <831qwqdj2w.fsf@HIDDEN>
From: Eli Zaretskii <eliz@HIDDEN>
To: Po Lu <luangruo@HIDDEN>
In-Reply-To: <878rqyklqj.fsf@HIDDEN> (message from Po Lu on Thu, 19 May
 2022 15:47:00 +0800)
Subject: Re: bug#32921: emacsclient obeys Xresources even when launched with
 -nw
References: <alpine.LFD.2.21.1810031946120.6536@jimisX1>
 <87o7zvc8xi.fsf@HIDDEN> <835ym3f0xt.fsf@HIDDEN>
 <875ym3c7bj.fsf@HIDDEN> <834k1nezs3.fsf@HIDDEN>
 <87ee0raqy2.fsf@HIDDEN> <87czgal2tt.fsf@HIDDEN>
 <838rqydmy8.fsf@HIDDEN> <878rqyklqj.fsf@HIDDEN>
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 32921
Cc: 32921 <at> debbugs.gnu.org, larsi@HIDDEN, jimis@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

> From: Po Lu <luangruo@HIDDEN>
> Cc: larsi@HIDDEN,  32921 <at> debbugs.gnu.org,  jimis@HIDDEN
> Date: Thu, 19 May 2022 15:47:00 +0800
> 
> Eli Zaretskii <eliz@HIDDEN> writes:
> 
> > It cannot be terminal-local, I think, because we want it to be in
> > effect for future terminals as well.
> 
> But why?  Under X, the resource database loaded by Emacs is normally
> specific to each display.  (Emacs only loads the users X resource file
> manually if it was never previously loaded into the X server.)  I think
> what the code in x-win.el does means that only one display's
> `reverseVideo' resource will be respected at any given time, while each
> display's X resources are documented to only apply to frames created on
> that display.

We may be miscommunicating.  The offending code in x-win.el is called
at startup, only once, and sets up default-frame-alist for all the
future frames, including those on displays this Emacs session did not
yet open and knows nothing about.  How would you define
default-frame-alist that is specific to those as-yet-unknown displays?

And if you are saying that the code in x-win.el should only affect the
display on which Emacs was started, then that would be an even more
seriously breaking change.  Why should we assume that the user
intended his/her X resources to be only honored on the (random)
display where Emacs shows its first frame?  The files ~/.Xresources
and ~/.Xdefaults are not specific to any display, AFAIU, they are
global for the user.  Right?




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#32921; Package emacs. Full text available.

Message received at 32921 <at> debbugs.gnu.org:


Received: (at 32921) by debbugs.gnu.org; 19 May 2022 07:47:19 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Thu May 19 03:47:19 2022
Received: from localhost ([127.0.0.1]:34368 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nrasR-00048s-JE
	for submit <at> debbugs.gnu.org; Thu, 19 May 2022 03:47:19 -0400
Received: from sonic311-23.consmr.mail.ne1.yahoo.com ([66.163.188.204]:34170)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <luangruo@HIDDEN>) id 1nrasP-00048d-6q
 for 32921 <at> debbugs.gnu.org; Thu, 19 May 2022 03:47:18 -0400
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048;
 t=1652946431; bh=T0B3LGcB3g6BIHc0Fh5NownKxuuEGucbT1dsSwmmtTg=;
 h=From:To:Cc:Subject:References:Date:In-Reply-To:From:Subject:Reply-To;
 b=rXG2zGWGjeFZM0ZSLpUgWMmbGvNfvPD04F11nT1JTewhcyE5nDl/G7WNuEuKk8kzhFu6uKnKomGqAhPWgwYaxrhhG1XFXa65AXr4InOHX1uhL6A/GK8EX5koFjo7SfiuXmR2Joz6Tr+1UXtRNdLJwjr6DPh6f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m
 kg7cA_UnJL0Nnna01W06ERsxNkkzocSRzjX7HPRNQFw3.Ij3Kgp6TeQzBGuDvEHuHysZ2ocCSL18
 dIwlSOVhqTi9ZGqBBxcJa6bAa5T7DVqqcsdrz2GPn.C_XX3Fko4XNbbKbBy_pIxtcgCGlFxVkWWW
 nU7zKkH2EAL2vGEsIcCnCLzhjTif8Hv.sSs42CxNe71VFqAlpgXn_dW3lbv1Wcp1UU2nek3bwIIG
 VhsoyWzh1O_80KRd4uHGYrErZtWx6i7Bq2t_b8kswtiq4yJ_W.uRY_tebkPhxlodwI7aPtVN49IG
 GmlPHfMsArjOdDbUkGxE6C.ZGyb9RzlDj3wTZXACXk9nzX972oPjCjQgnYdWXznYIUD0W67ap9vI
 HEQpgVM0sf2Pz6FS8ErX68xwLu1K1tY9GnSyU_up59r7vds3UVmnqPm0Q1M2k8KWk.YXFEuNXE.u
 E27Hb67SC8R9fg9n9h6IDwZi4uhtQg03uGc9R4GATru62JHA_vkGUHhfKdbCldK2bp5Bjus02ZVg
 2ZBilaGjAxtCK8ChC2QLxQWg6gcwXYgz0u_90jF.LyUEI_8WR2EVkagVcDH2sHVctG82FJ7G29gl
 uApjsav5kBJGOcmTKZllKEsd_hEp60svTBVwlbD1G7QSldi1aR59r4rMLa6Mk0MiRlY_Mb.TCr0J
 V0gr5RLxF41SNy9llwDRs_fUWkkfkh6H.cLP_dyCYBoIhSNQbLiI.f0wqDyzVI7ONg1g2C2dSpwy
 z7xOrzGH9X3Lihd8ZRyWeCKjQTXo01blV2sPIaJyblqJqY2MmjwmCPi1A_Xvl.CVB6yJrWZeE6dR
 4qEFXu2x5rq3OcBrcDcgwYVzZGNl9f0MluODC_tT.4_dfLe2EFwHSnqy4q0ozSpXPyA--
X-Sonic-MF: <luangruo@HIDDEN>
Received: from sonic.gate.mail.ne1.yahoo.com by
 sonic311.consmr.mail.ne1.yahoo.com with HTTP; Thu, 19 May 2022 07:47:11 +0000
Received: by hermes--canary-production-sg3-7959d4d9bd-lwwxg (Yahoo Inc. Hermes
 SMTP Server) with ESMTPA ID 7e38053bcf9929d595a791c812b082f9; 
 Thu, 19 May 2022 07:47:05 +0000 (UTC)
From: Po Lu <luangruo@HIDDEN>
To: Eli Zaretskii <eliz@HIDDEN>
Subject: Re: bug#32921: emacsclient obeys Xresources even when launched with
 -nw
References: <alpine.LFD.2.21.1810031946120.6536@jimisX1>
 <87o7zvc8xi.fsf@HIDDEN> <835ym3f0xt.fsf@HIDDEN>
 <875ym3c7bj.fsf@HIDDEN> <834k1nezs3.fsf@HIDDEN>
 <87ee0raqy2.fsf@HIDDEN> <87czgal2tt.fsf@HIDDEN>
 <838rqydmy8.fsf@HIDDEN>
Date: Thu, 19 May 2022 15:47:00 +0800
In-Reply-To: <838rqydmy8.fsf@HIDDEN> (Eli Zaretskii's message of "Thu, 19 May
 2022 10:02:39 +0300")
Message-ID: <878rqyklqj.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.91 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Mailer: WebService/1.1.20225
 mail.backend.jedi.jws.acl:role.jedi.acl.token.atz.jws.hermes.yahoo
Content-Length: 586
X-Spam-Score: -0.0 (/)
X-Debbugs-Envelope-To: 32921
Cc: 32921 <at> debbugs.gnu.org, larsi@HIDDEN, jimis@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.0 (-)

Eli Zaretskii <eliz@HIDDEN> writes:

> It cannot be terminal-local, I think, because we want it to be in
> effect for future terminals as well.

But why?  Under X, the resource database loaded by Emacs is normally
specific to each display.  (Emacs only loads the users X resource file
manually if it was never previously loaded into the X server.)  I think
what the code in x-win.el does means that only one display's
`reverseVideo' resource will be respected at any given time, while each
display's X resources are documented to only apply to frames created on
that display.

Thanks.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#32921; Package emacs. Full text available.

Message received at 32921 <at> debbugs.gnu.org:


Received: (at 32921) by debbugs.gnu.org; 19 May 2022 07:02:52 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Thu May 19 03:02:52 2022
Received: from localhost ([127.0.0.1]:34300 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nraBP-00033f-Sr
	for submit <at> debbugs.gnu.org; Thu, 19 May 2022 03:02:52 -0400
Received: from eggs.gnu.org ([209.51.188.92]:51104)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <eliz@HIDDEN>) id 1nraBN-00033P-6k
 for 32921 <at> debbugs.gnu.org; Thu, 19 May 2022 03:02:50 -0400
Received: from fencepost.gnu.org ([2001:470:142:3::e]:52130)
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1nraBH-0003FV-OJ; Thu, 19 May 2022 03:02:43 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org;
 s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date:
 mime-version; bh=uDkezK3+HbwMdqLv/HGaZr4RTqSu3Vlv5Un1HJiHorc=; b=fiyWHmNWEOT2
 IakMd0N+rh9hLipOIjQ+Lh7gHlNYzSDyQ9PD26LsJ5xDR2/aypbTKgG3OEakJHqFq3d2ESxxZZx0x
 Hn5JCRkuPdHyNTsNy6kgAxXfZmT3Pf2AL4cZkASUvY1tJfcN09I23+T/9Vpk7BFIt2hP1PVG3SbqD
 5fSl5T0e0pdMwbyu1eCVGJ1C4ED964gU9o9ZZnqDLwI2TW84tJDhrjK8hAbVovwJh/iNnwROB47Xv
 2gK/ejOKJU50r1MdY9eauPASvWwmPdyEwcg1pEDlNTcs4k45OfELFKaNjaWz4LQlTJONwvF6wv6SF
 /mD7FInvqCYgSYu9qiM8wQ==;
Received: from [87.69.77.57] (port=3520 helo=home-c4e4a596f7)
 by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1nraBH-000592-Bz; Thu, 19 May 2022 03:02:43 -0400
Date: Thu, 19 May 2022 10:02:39 +0300
Message-Id: <838rqydmy8.fsf@HIDDEN>
From: Eli Zaretskii <eliz@HIDDEN>
To: Po Lu <luangruo@HIDDEN>
In-Reply-To: <87czgal2tt.fsf@HIDDEN> (message from Po Lu on Thu, 19 May
 2022 09:37:50 +0800)
Subject: Re: bug#32921: emacsclient obeys Xresources even when launched with
 -nw
References: <alpine.LFD.2.21.1810031946120.6536@jimisX1>
 <87o7zvc8xi.fsf@HIDDEN> <835ym3f0xt.fsf@HIDDEN>
 <875ym3c7bj.fsf@HIDDEN> <834k1nezs3.fsf@HIDDEN>
 <87ee0raqy2.fsf@HIDDEN> <87czgal2tt.fsf@HIDDEN>
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 32921
Cc: 32921 <at> debbugs.gnu.org, larsi@HIDDEN, jimis@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

> From: Po Lu <luangruo@HIDDEN>
> Cc: Eli Zaretskii <eliz@HIDDEN>,  32921 <at> debbugs.gnu.org,  jimis@HIDDEN
> Date: Thu, 19 May 2022 09:37:50 +0800
> 
> What we actually need is not to remove that code, but to add a
> terminal-local version of `default-frame-alist': as-is I think the code
> will probably also end up overwriting the default value of
> `inverse-video' when connecting to a new display with a different value
> of that resource.

It cannot be terminal-local, I think, because we want it to be in
effect for future terminals as well.

In frameset.el, we have a solution for a similar problem: instead of
setting the literal frame-parameter PARAM, we set a specially-named
parameter GUI:PARAM.  Then, when we need to actually create a frame,
we consult those GUI:PARAM parameters, and apply them as needed.

So my proposal is to modify window-system-initialization in x-win.el
to define special XRESOURCE:FOO parameters in default-frame-alist,
instead of defining FOO parameters themselves, and then change the GUI
frame-parameter handlers to define the FOO parameters from the values
of those XRESOURCE:FOO parameters.  (We only need this special
handling for frame parameters that are not ignored on TTY frames.)

Does this make sense?




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#32921; Package emacs. Full text available.

Message received at 32921 <at> debbugs.gnu.org:


Received: (at 32921) by debbugs.gnu.org; 19 May 2022 01:38:13 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Wed May 18 21:38:13 2022
Received: from localhost ([127.0.0.1]:34014 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nrV79-0002yD-PY
	for submit <at> debbugs.gnu.org; Wed, 18 May 2022 21:38:13 -0400
Received: from sonic301-30.consmr.mail.ne1.yahoo.com ([66.163.184.199]:43098)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <luangruo@HIDDEN>) id 1nrV78-0002xj-2e
 for 32921 <at> debbugs.gnu.org; Wed, 18 May 2022 21:38:06 -0400
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048;
 t=1652924280; bh=cH8HFoSnZyAgnx2l0jaFXC8dnPMvot+qVnLEAosjyFI=;
 h=From:To:Cc:Subject:References:Date:In-Reply-To:From:Subject:Reply-To;
 b=mBjpoI9WDVLWmqE36+E/BPxIZPHiqJ6Qkr9k9epsZuo3Cng/xQBC3WpmDu15yXe8DFibYE+UmKPTpF82+QKVNyc076xKL64/JPDNIlJm6gBN0dzuArPgpHCMP98MB4CrJFeN2nyfX18UsTXdX+UkzTFi6EEyKzHXU5rZ3C/3O4/mCvgOLmwoVBD8KH2fcUDfluiaxGZVY6O8JVQ8clCU3dXS3rg8nysG2iz/tVVrW9Vg5JrdtOgU3xCdj9IM8EJ8YnxBtvvhvkknczlsjD/FO57cuvMWfr7d6OF84MG3nV7arK6b181jlzCuo3v1Lm0KrjoIop7ZTrx1I54eOhMfrA==
X-SONIC-DKIM-SIGN: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048;
 t=1652924280; bh=7JZu/B4SRIfCU9GXiTT1cxM8qaP9ff6WSHbPswkGa2/=;
 h=X-Sonic-MF:From:To:Subject:Date:From:Subject;
 b=FnqGZaPYNxEtXvC6aOvK+4l+jYaE7bqv8QJa2nYNLiXM/5A6IfkLVpUKeRiPlFgm/Ud2MDX290c6M/2P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HH
 LqxG36oBeAQKUY.4MnPOIq7koRzl1MCfSIP_Kqj91ckVobIjTKk0BmRq3NnYhzMafTX_jfZoH_qu
 XmbDZk7Z33BbHcyL6UMCqiUSlZKhf6ySSt1mrFfvf5W_bljLuYmDXwUdYbpcU.ceIlKbXDEF8ylk
 sYMU_ndDhfc9VfQhzJ6P6bRDXIwJf74YtV7eavf.wDZSdZ6NHgkh0_W5Qvds7JO8Q3cuxKy9K3Mr
 keFxN02F_ZzicDCIFzrGKCkMdOshyUKPQgV3ksVndj157CTpx5RCeovzfmN8U0SU29APG2KpgxXV
 tG_y3C8X4bELkU3uaMDd9on_hNTwdNP7Yvzt0kiw_Jd.2prm2OzZBvdMndygkCotvzxMo5rCNduQ
 Blc9LW5CELkBIMh50lY.PWVsWMFAXRVpGDtxXyLmnlrazDJGbMLQoLYEIZPnKi_LKmGmAZ6K69V3
 7VZETr4KKKm2dsYtG.LGWKbAfatVdWFhN3KhOCyVxi8d4BuSc55ZgnDE3R9PPGg--
X-Sonic-MF: <luangruo@HIDDEN>
Received: from sonic.gate.mail.ne1.yahoo.com by
 sonic301.consmr.mail.ne1.yahoo.com with HTTP; Thu, 19 May 2022 01:38:00 +0000
Received: by hermes--canary-production-sg3-7959d4d9bd-whrqc (Yahoo Inc. Hermes
 SMTP Server) with ESMTPA ID e07ef18ec00f53b87cbed80c5fe842a0; 
 Thu, 19 May 2022 01:37:55 +0000 (UTC)
From: Po Lu <luangruo@HIDDEN>
To: Lars Ingebrigtsen <larsi@HIDDEN>
Subject: Re: bug#32921: emacsclient obeys Xresources even when launched with
 -nw
References: <alpine.LFD.2.21.1810031946120.6536@jimisX1>
 <87o7zvc8xi.fsf@HIDDEN> <835ym3f0xt.fsf@HIDDEN>
 <875ym3c7bj.fsf@HIDDEN> <834k1nezs3.fsf@HIDDEN>
 <87ee0raqy2.fsf@HIDDEN>
Date: Thu, 19 May 2022 09:37:50 +0800
In-Reply-To: <87ee0raqy2.fsf@HIDDEN> (Lars Ingebrigtsen's message of "Wed,
 18 May 2022 15:52:21 +0200")
Message-ID: <87czgal2tt.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.91 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Mailer: WebService/1.1.20225
 mail.backend.jedi.jws.acl:role.jedi.acl.token.atz.jws.hermes.yahoo
Content-Length: 841
X-Spam-Score: -0.0 (/)
X-Debbugs-Envelope-To: 32921
Cc: 32921 <at> debbugs.gnu.org, Eli Zaretskii <eliz@HIDDEN>, jimis@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.0 (-)

Lars Ingebrigtsen <larsi@HIDDEN> writes:

> Yes, it would change that behaviour...  but I think we'd want that?  If
> the user changes reverseVideo, then I think it's natural to expect
> subsequent frames to heed that.  (Not that I think that's very
> important -- people generally don't do that.)

Changing X resources while Emacs is running is impossble anyway without
reconnecting to that display, since we run through various resource
databases, add our own resources, and merge them into a single database
later, instead of using any of them as-is.

What we actually need is not to remove that code, but to add a
terminal-local version of `default-frame-alist': as-is I think the code
will probably also end up overwriting the default value of
`inverse-video' when connecting to a new display with a different value
of that resource.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#32921; Package emacs. Full text available.

Message received at 32921 <at> debbugs.gnu.org:


Received: (at 32921) by debbugs.gnu.org; 18 May 2022 14:01:19 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Wed May 18 10:01:19 2022
Received: from localhost ([127.0.0.1]:33045 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nrKEo-0002nH-Lg
	for submit <at> debbugs.gnu.org; Wed, 18 May 2022 10:01:19 -0400
Received: from eggs.gnu.org ([209.51.188.92]:51366)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <eliz@HIDDEN>) id 1nrKEm-0002gG-Km
 for 32921 <at> debbugs.gnu.org; Wed, 18 May 2022 10:01:17 -0400
Received: from fencepost.gnu.org ([2001:470:142:3::e]:58406)
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1nrKEf-00083h-Ia; Wed, 18 May 2022 10:01:11 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org;
 s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date:
 mime-version; bh=my3dwzOXIbAUuC/QXyI1jIutgyujeK3ymuBW9kqkDiU=; b=HtLoosGxywVq
 cHkQoa0iZlC/i+nJiTib5+iiUToYw5nRzsNvDjcktZPa7iIy9hMexWv/uPTAm7pZVss0aFamSuwlX
 KgMYmQMiZSgKtKk1KKyZjNdGjj9RjEbAKt01CfCbxtR9zZTDwgQCLaW67LmEF+FMSlmxhyFTWm/WF
 JzKTe2ble6I/6dZDonF2+4sogjjjvQMNmhBvZRjDMMhB6H7JDFVvaGYKLwJ2/49GzkVMD6nNQ/aLI
 wwJru/IGVZ/vJOvXF+sER5WQqWdyp14vILnAQrvm3kkV+YCwdMSTF83D8/zw35XG3JVYazHVzpRH0
 7hjtPQcYjS8yRxiYRCDfSQ==;
Received: from [87.69.77.57] (port=4564 helo=home-c4e4a596f7)
 by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1nrKEU-0002ix-MH; Wed, 18 May 2022 10:01:06 -0400
Date: Wed, 18 May 2022 17:00:52 +0300
Message-Id: <831qwrey97.fsf@HIDDEN>
From: Eli Zaretskii <eliz@HIDDEN>
To: Lars Ingebrigtsen <larsi@HIDDEN>
In-Reply-To: <87ee0raqy2.fsf@HIDDEN> (message from Lars Ingebrigtsen on Wed, 
 18 May 2022 15:52:21 +0200)
Subject: Re: bug#32921: emacsclient obeys Xresources even when launched with
 -nw
References: <alpine.LFD.2.21.1810031946120.6536@jimisX1>
 <87o7zvc8xi.fsf@HIDDEN> <835ym3f0xt.fsf@HIDDEN>
 <875ym3c7bj.fsf@HIDDEN> <834k1nezs3.fsf@HIDDEN> <87ee0raqy2.fsf@HIDDEN>
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 32921
Cc: 32921 <at> debbugs.gnu.org, jimis@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

> From: Lars Ingebrigtsen <larsi@HIDDEN>
> Cc: jimis@HIDDEN,  32921 <at> debbugs.gnu.org
> Date: Wed, 18 May 2022 15:52:21 +0200
> 
> Eli Zaretskii <eliz@HIDDEN> writes:
> 
> > So the difference is between (a) taking notice of the reverseVideo
> > resource at startup timer as opposed to (b) at frame creation time, is
> > that right?  If so, I think this might affect the use case whereby
> > someone changes the X resources after Emacs has already started, or
> > something?
> 
> Yes, it would change that behaviour...  but I think we'd want that?  If
> the user changes reverseVideo, then I think it's natural to expect
> subsequent frames to heed that.  (Not that I think that's very
> important -- people generally don't do that.)

It's a change in long-standing behavior, and someone out there is
bound to want it.

> > Maybe it would be safer to add a special frame-parameter which will
> > record the fact that some parameters came from X resources, and will
> > then refrain from applying those parameters to TTY frames?  Or maybe
> > we should have some other special construct in default-frame-alist
> > that prevents some parameters from being applied to TTY frames?
> > Because I think reverseVideo is just one example of such parameters.
> 
> Yes, a default-frame-parameters-for-window-system (or something like
> that) variable might make sense in general.  Then users could specify
> these things separately for TTY and GUI.
> 
> But are there many parameters like this?  Most of the frame parameters
> are ignored on TTY...

Many are ignored, but some are relevant:

  . foreground and background colors
  . cursor blinking
  . menuBar
  . tabBar

> > Yes, we emulate X resources using the Registry on MS-Windows (although
> > I think this is largely unknown and unused).
> 
> I see.  I wondered whether this was for using X servers under Windows,
> somehow...  (I think that existed a long time ago, at least?)

It did?  I only know about X servers used to run X programs from
remote Unix hosts.  And there's a Cygwin build of Emacs, of course,
but that runs as if on a Unix host.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#32921; Package emacs. Full text available.

Message received at 32921 <at> debbugs.gnu.org:


Received: (at 32921) by debbugs.gnu.org; 18 May 2022 13:52:33 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Wed May 18 09:52:33 2022
Received: from localhost ([127.0.0.1]:59550 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nrK6K-0000rq-OM
	for submit <at> debbugs.gnu.org; Wed, 18 May 2022 09:52:32 -0400
Received: from quimby.gnus.org ([95.216.78.240]:40096)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <larsi@HIDDEN>) id 1nrK6J-0000rd-Kh
 for 32921 <at> debbugs.gnu.org; Wed, 18 May 2022 09:52:32 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org;
 s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date:
 References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding:
 Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender:
 Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:
 List-Subscribe:List-Post:List-Owner:List-Archive;
 bh=uI507t96NJlQUdI7ukGRu/V1HKLsJbp3ew+8ueGTskA=; b=m5JI0CdJUKSzdGs4pPSxeD3Z9m
 RxZI2S0I/ew4gpyegjorzYlwKc8BBeIXFODYW5Ldleq2hFIEXoppRWHb7mnCv3g6Nnpow+q0h9SOf
 ADABz4ZtNmSLQDxKl7A7I/3yR1W3h2efwIWjQZOBvpqPdqwjo5aTTqKfy30xOKzS5RZ0=;
Received: from [84.212.220.105] (helo=xo)
 by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.92) (envelope-from <larsi@HIDDEN>)
 id 1nrK6A-0007wX-FH; Wed, 18 May 2022 15:52:24 +0200
From: Lars Ingebrigtsen <larsi@HIDDEN>
To: Eli Zaretskii <eliz@HIDDEN>
Subject: Re: bug#32921: emacsclient obeys Xresources even when launched with
 -nw
References: <alpine.LFD.2.21.1810031946120.6536@jimisX1>
 <87o7zvc8xi.fsf@HIDDEN> <835ym3f0xt.fsf@HIDDEN>
 <875ym3c7bj.fsf@HIDDEN> <834k1nezs3.fsf@HIDDEN>
X-Now-Playing: Porridge Radio's _Every Bad_: "Lilac"
Date: Wed, 18 May 2022 15:52:21 +0200
In-Reply-To: <834k1nezs3.fsf@HIDDEN> (Eli Zaretskii's message of "Wed, 18 May
 2022 16:27:56 +0300")
Message-ID: <87ee0raqy2.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org",
 has NOT identified this incoming email as spam.  The original
 message has been attached to this so you can view it or label
 similar future email.  If you have any questions, see
 @@CONTACT_ADDRESS@@ for details.
 Content preview: Eli Zaretskii <eliz@HIDDEN> writes: > So the difference is
 between (a) taking notice of the reverseVideo > resource at startup timer
 as opposed to (b) at frame creation time, is > that right? If so, I think
 this might affect the use cas [...] 
 Content analysis details:   (-2.9 points, 5.0 required)
 pts rule name              description
 ---- ---------------------- --------------------------------------------------
 -1.0 ALL_TRUSTED            Passed through trusted hosts only via SMTP
 -1.9 BAYES_00               BODY: Bayes spam probability is 0 to 1%
 [score: 0.0000]
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 32921
Cc: 32921 <at> debbugs.gnu.org, jimis@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

Eli Zaretskii <eliz@HIDDEN> writes:

> So the difference is between (a) taking notice of the reverseVideo
> resource at startup timer as opposed to (b) at frame creation time, is
> that right?  If so, I think this might affect the use case whereby
> someone changes the X resources after Emacs has already started, or
> something?

Yes, it would change that behaviour...  but I think we'd want that?  If
the user changes reverseVideo, then I think it's natural to expect
subsequent frames to heed that.  (Not that I think that's very
important -- people generally don't do that.)

> Maybe it would be safer to add a special frame-parameter which will
> record the fact that some parameters came from X resources, and will
> then refrain from applying those parameters to TTY frames?  Or maybe
> we should have some other special construct in default-frame-alist
> that prevents some parameters from being applied to TTY frames?
> Because I think reverseVideo is just one example of such parameters.

Yes, a default-frame-parameters-for-window-system (or something like
that) variable might make sense in general.  Then users could specify
these things separately for TTY and GUI.

But are there many parameters like this?  Most of the frame parameters
are ignored on TTY...

>> It might not be redundant on Windows, which presumably doesn't call
>> these X functions, but does heed reverseVideo in the w32 version of
>> window-system-initialization.
>
> Yes, we emulate X resources using the Registry on MS-Windows (although
> I think this is largely unknown and unused).

I see.  I wondered whether this was for using X servers under Windows,
somehow...  (I think that existed a long time ago, at least?)

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#32921; Package emacs. Full text available.

Message received at 32921 <at> debbugs.gnu.org:


Received: (at 32921) by debbugs.gnu.org; 18 May 2022 13:28:29 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Wed May 18 09:28:29 2022
Received: from localhost ([127.0.0.1]:59444 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nrJj2-0004DP-Sy
	for submit <at> debbugs.gnu.org; Wed, 18 May 2022 09:28:29 -0400
Received: from eggs.gnu.org ([209.51.188.92]:42520)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <eliz@HIDDEN>) id 1nrJj0-0004DC-I6
 for 32921 <at> debbugs.gnu.org; Wed, 18 May 2022 09:28:27 -0400
Received: from fencepost.gnu.org ([2001:470:142:3::e]:57838)
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1nrJig-0001nh-9b; Wed, 18 May 2022 09:28:20 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org;
 s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date:
 mime-version; bh=HrNa2wMPiprjbt2NDk5nRCfez+Ay3IiYf/FQrTRPXvo=; b=KLwaKUobie2p
 wV3SDrf5I16J/wRQkVkdwvaS6O7awY6xqFAiOhayDRulqyK64+p5TViWGfUKZi4T+Au5fM3bD1g7u
 T0Poj2vUPmzdXI8C6kmMC6AY+kiOsIPcfjh7O0rQzboHBH5DvEelHdOp1Mf554jidLo8c5PZ8Tolp
 gYKdsaIcE4stdPDQTJuL5NJPhaxXlL9GDTBnDgsjDUUlV5HddmYwwQ+jlHyJprdh4j80BDNIjRgun
 Nf8KFeC+r+BURFGjGFjqx4KM0Ifko86hCnwDOSJQsJ74Aw92N+hg1/qxbc8PQ0EHV63+3HNoEnMeW
 QB8iTiXpAafoF24LH8ayfA==;
Received: from [87.69.77.57] (port=2544 helo=home-c4e4a596f7)
 by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1nrJid-0004cu-LB; Wed, 18 May 2022 09:28:05 -0400
Date: Wed, 18 May 2022 16:27:56 +0300
Message-Id: <834k1nezs3.fsf@HIDDEN>
From: Eli Zaretskii <eliz@HIDDEN>
To: Lars Ingebrigtsen <larsi@HIDDEN>
In-Reply-To: <875ym3c7bj.fsf@HIDDEN> (message from Lars Ingebrigtsen on Wed, 
 18 May 2022 15:13:20 +0200)
Subject: Re: bug#32921: emacsclient obeys Xresources even when launched with
 -nw
References: <alpine.LFD.2.21.1810031946120.6536@jimisX1>
 <87o7zvc8xi.fsf@HIDDEN> <835ym3f0xt.fsf@HIDDEN> <875ym3c7bj.fsf@HIDDEN>
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 32921
Cc: 32921 <at> debbugs.gnu.org, jimis@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

> From: Lars Ingebrigtsen <larsi@HIDDEN>
> Cc: jimis@HIDDEN,  32921 <at> debbugs.gnu.org
> Date: Wed, 18 May 2022 15:13:20 +0200
> 
> Eli Zaretskii <eliz@HIDDEN> writes:
> 
> > Which sequence of calls ends up calling x-handle-reverse-video, and
> > what is the trigger for that sequence of calls?
> 
> It's:
> 
> Debugger entered: nil
>   x-handle-reverse-video(#<frame GNU Emacs at xo 0x55a6e4722360> ((vertical-scroll-bars) (height . 53) (width . 81) (reverse . t) (cursor-color . "red") (cursor-type . box) (mouse-color . "red") (horizontal-scroll-bars)))
>   x-create-frame-with-faces(((vertical-scroll-bars) (height . 53) (width . 81) (reverse . t) (cursor-color . "red") (cursor-type . box) (mouse-color . "red") (horizontal-scroll-bars)))
>   #f(compiled-function (params) #<bytecode -0x1d5f77f46341f751>)(((vertical-scroll-bars) (height . 53) (width . 81) (reverse . t) (cursor-color . "red") (cursor-type . box) (mouse-color . "red") (horizontal-scroll-bars)))
>   apply(#f(compiled-function (params) #<bytecode -0x1d5f77f46341f751>) ((vertical-scroll-bars) (height . 53) (width . 81) (reverse . t) (cursor-color . "red") (cursor-type . box) (mouse-color . "red") (horizontal-scroll-bars)))
>   frame-creation-function(((vertical-scroll-bars) (height . 53) (width . 81) (reverse . t) (cursor-color . "red") (cursor-type . box) (mouse-color . "red") (horizontal-scroll-bars)))
>   make-frame()

So the difference is between (a) taking notice of the reverseVideo
resource at startup timer as opposed to (b) at frame creation time, is
that right?  If so, I think this might affect the use case whereby
someone changes the X resources after Emacs has already started, or
something?

> > (These kinds of changes in code that was there for decades give me the
> > creeps.)
> 
> Indeed.  I tried to do some VC history spelunking for why we're
> apparently checking reverseVideo redundantly in this way, but I came up
> short.

Maybe it would be safer to add a special frame-parameter which will
record the fact that some parameters came from X resources, and will
then refrain from applying those parameters to TTY frames?  Or maybe
we should have some other special construct in default-frame-alist
that prevents some parameters from being applied to TTY frames?
Because I think reverseVideo is just one example of such parameters.

> It might not be redundant on Windows, which presumably doesn't call
> these X functions, but does heed reverseVideo in the w32 version of
> window-system-initialization.

Yes, we emulate X resources using the Registry on MS-Windows (although
I think this is largely unknown and unused).




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#32921; Package emacs. Full text available.

Message received at 32921 <at> debbugs.gnu.org:


Received: (at 32921) by debbugs.gnu.org; 18 May 2022 13:13:34 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Wed May 18 09:13:34 2022
Received: from localhost ([127.0.0.1]:59399 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nrJUb-0001eR-ND
	for submit <at> debbugs.gnu.org; Wed, 18 May 2022 09:13:33 -0400
Received: from quimby.gnus.org ([95.216.78.240]:39652)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <larsi@HIDDEN>) id 1nrJUZ-0001eC-8L
 for 32921 <at> debbugs.gnu.org; Wed, 18 May 2022 09:13:31 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org;
 s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date:
 References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding:
 Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender:
 Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:
 List-Subscribe:List-Post:List-Owner:List-Archive;
 bh=EkPqLO11VqMJDWmR+dWf2v/TGSZk1/7FULJjlD0/fHU=; b=kSXuNXBewr3fT3WNIkwti1HCjg
 WxqrJSd5ugnzROzejWhElTcgS3ULeXCzO/+aPaBbToLX10WbIAOGo7rGCYENW8JbwdplocZB+JUG3
 rJrcEXnwlfcEtTv9IKBjeu5C+sDZkG4JDMFaf3ZTBZfVEiA9Y2LNWzAdcYMuihW14dXo=;
Received: from [84.212.220.105] (helo=xo)
 by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.92) (envelope-from <larsi@HIDDEN>)
 id 1nrJUP-0007Ya-V0; Wed, 18 May 2022 15:13:24 +0200
From: Lars Ingebrigtsen <larsi@HIDDEN>
To: Eli Zaretskii <eliz@HIDDEN>
Subject: Re: bug#32921: emacsclient obeys Xresources even when launched with
 -nw
References: <alpine.LFD.2.21.1810031946120.6536@jimisX1>
 <87o7zvc8xi.fsf@HIDDEN> <835ym3f0xt.fsf@HIDDEN>
Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwBAMAAAClLOS0AAAABGdBTUEAALGPC/xhBQAAACBj
 SFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAAElBMVEUmIyBCPjvb2NWC
 fnxaVlP///8D7NzBAAAAAWJLR0QF+G/pxwAAAAd0SU1FB+YFEg0KAiIAWK4AAAFbSURBVDjLxZJh
 bsMwCIVBywHMxgmcHGCNfYBSc/8zDezUsdto2r9RVVX5DLxnAxhzbJFV1EOgBj5iB3QNkhIF6IEl
 9hIhog50j2NJA8t9mYCXWLPl2z5AvdWabXIFd5YExKcq5bU2Kxl0ULXxTjZFAmQXxynWKatmQFcZ
 6o+pKmmPJcUtnEobUH2sJHo7U82lTSs5IN/G0whkPenLhpGcWcKjK6uD45owcB/mALwCUcMyXKSp
 NxGWV9ZJGnFzi+S+wwQomD+XGF4qiOr1eQmegFmFWKjmazwtstm3b7DjXivHs1cgyAp2shY8RxgQ
 A/IEw3B/OlUwhqO/CiSpXwaeirGuWdE63J2EXqBtAQ8wjHBiPuq6jdbtv7Dt87SHHTmcL8rTbf11
 zpOWtmwCr31Y057f0q0m5Yv8aPa3wKuMXB793OgC2NPtG73nP2J79Cls02DJfgF/kPbf8QN9MkfQ
 q5Pp+wAAACV0RVh0ZGF0ZTpjcmVhdGUAMjAyMi0wNS0xOFQxMzoxMDowMiswMDowMJ4nNZUAAAAl
 dEVYdGRhdGU6bW9kaWZ5ADIwMjItMDUtMThUMTM6MTA6MDIrMDA6MDDveo0pAAAAAElFTkSuQmCC
X-Now-Playing: Nils Petter =?utf-8?Q?Molv=C3=A6r's?= _Solid Ether_: "Tragamar"
Date: Wed, 18 May 2022 15:13:20 +0200
In-Reply-To: <835ym3f0xt.fsf@HIDDEN> (Eli Zaretskii's message of "Wed, 18 May
 2022 16:02:54 +0300")
Message-ID: <875ym3c7bj.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org",
 has NOT identified this incoming email as spam.  The original
 message has been attached to this so you can view it or label
 similar future email.  If you have any questions, see
 @@CONTACT_ADDRESS@@ for details.
 Content preview: Eli Zaretskii <eliz@HIDDEN> writes: > Which sequence of
 calls
 ends up calling x-handle-reverse-video, and > what is the trigger for that
 sequence of calls? It's: 
 Content analysis details:   (-2.9 points, 5.0 required)
 pts rule name              description
 ---- ---------------------- --------------------------------------------------
 -1.0 ALL_TRUSTED            Passed through trusted hosts only via SMTP
 -1.9 BAYES_00               BODY: Bayes spam probability is 0 to 1%
 [score: 0.0000]
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 32921
Cc: 32921 <at> debbugs.gnu.org, jimis@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

Eli Zaretskii <eliz@HIDDEN> writes:

> Which sequence of calls ends up calling x-handle-reverse-video, and
> what is the trigger for that sequence of calls?

It's:

Debugger entered: nil
  x-handle-reverse-video(#<frame GNU Emacs at xo 0x55a6e4722360> ((vertical-scroll-bars) (height . 53) (width . 81) (reverse . t) (cursor-color . "red") (cursor-type . box) (mouse-color . "red") (horizontal-scroll-bars)))
  x-create-frame-with-faces(((vertical-scroll-bars) (height . 53) (width . 81) (reverse . t) (cursor-color . "red") (cursor-type . box) (mouse-color . "red") (horizontal-scroll-bars)))
  #f(compiled-function (params) #<bytecode -0x1d5f77f46341f751>)(((vertical-scroll-bars) (height . 53) (width . 81) (reverse . t) (cursor-color . "red") (cursor-type . box) (mouse-color . "red") (horizontal-scroll-bars)))
  apply(#f(compiled-function (params) #<bytecode -0x1d5f77f46341f751>) ((vertical-scroll-bars) (height . 53) (width . 81) (reverse . t) (cursor-color . "red") (cursor-type . box) (mouse-color . "red") (horizontal-scroll-bars)))
  frame-creation-function(((vertical-scroll-bars) (height . 53) (width . 81) (reverse . t) (cursor-color . "red") (cursor-type . box) (mouse-color . "red") (horizontal-scroll-bars)))
  make-frame()

> (These kinds of changes in code that was there for decades give me the
> creeps.)

Indeed.  I tried to do some VC history spelunking for why we're
apparently checking reverseVideo redundantly in this way, but I came up
short.

It might not be redundant on Windows, which presumably doesn't call
these X functions, but does heed reverseVideo in the w32 version of
window-system-initialization.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#32921; Package emacs. Full text available.

Message received at 32921 <at> debbugs.gnu.org:


Received: (at 32921) by debbugs.gnu.org; 18 May 2022 13:03:20 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Wed May 18 09:03:20 2022
Received: from localhost ([127.0.0.1]:59355 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nrJKh-0001NK-Re
	for submit <at> debbugs.gnu.org; Wed, 18 May 2022 09:03:20 -0400
Received: from eggs.gnu.org ([209.51.188.92]:36872)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <eliz@HIDDEN>) id 1nrJKg-0001N7-6b
 for 32921 <at> debbugs.gnu.org; Wed, 18 May 2022 09:03:18 -0400
Received: from fencepost.gnu.org ([2001:470:142:3::e]:57204)
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1nrJKZ-0005ya-CC; Wed, 18 May 2022 09:03:12 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org;
 s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date:
 mime-version; bh=dP97aS5Bcb6koOnfqhFTFvoAUFHmGSmvZff65krnlj0=; b=B82tmgr7lZap
 3SgdhHnzSb1JYimtwagqEv1ZzKioPxwGEpWwQ36pLU7Ss7RYAcvfL0Sw2tI0/d/GnxhL5U2TysxS2
 2i7zh9wR/u4KvSA0FxS2Ha3eAoyvWtdGJgioYxzMLizJ4brUuz0+8aQmBnDzmcsMY5P5uJEto0M8V
 5FkHyRDPKSFVKZ1mkV/djfFxLoJvvmt8/S0LCtJL6P1qe6xCE8WzetoHqLa4lK88OCLcNaXDzzNUK
 /mS9ap4lnz0GSyAJlVUV+8AKA2NNU2fLeBD89MJGbjnLJjyoVQ3668mXdTuVTZ8dIn+sZ3RYoLT1r
 eoHZBqLJ76qCkK3oJ4on7A==;
Received: from [87.69.77.57] (port=4982 helo=home-c4e4a596f7)
 by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1nrJKQ-0004BC-VS; Wed, 18 May 2022 09:03:08 -0400
Date: Wed, 18 May 2022 16:02:54 +0300
Message-Id: <835ym3f0xt.fsf@HIDDEN>
From: Eli Zaretskii <eliz@HIDDEN>
To: Lars Ingebrigtsen <larsi@HIDDEN>
In-Reply-To: <87o7zvc8xi.fsf@HIDDEN> (message from Lars Ingebrigtsen on Wed, 
 18 May 2022 14:38:33 +0200)
Subject: Re: bug#32921: emacsclient obeys Xresources even when launched with
 -nw
References: <alpine.LFD.2.21.1810031946120.6536@jimisX1>
 <87o7zvc8xi.fsf@HIDDEN>
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 32921
Cc: 32921 <at> debbugs.gnu.org, jimis@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

> Cc: 32921 <at> debbugs.gnu.org
> From: Lars Ingebrigtsen <larsi@HIDDEN>
> Date: Wed, 18 May 2022 14:38:33 +0200
> 
> Dimitrios Apostolou <jimis@HIDDEN> writes:
> 
> > I have set the Xresource *reverseVideo to true, and as expected emacs
> > reverses the colours when launched under X, and does not when launched
> > with -nw thus keeping the terminal colour selections.
> >
> > However emacsclient obeys the Xresources even when launched with
> > -nw. This leads to colour reversal in text mode, which is unwanted
> > since the xterm has already been configured as desired.
> 
> (I'm going through old bug reports that unfortunately weren't resolved
> at the time.)
> 
> This behaviour is still present in Emacs 29.  This seems to be stemming
> from this:
> 
>   ;; Check the reverseVideo resource.
>   (let ((case-fold-search t))
>     (let ((rv (x-get-resource "reverseVideo" "ReverseVideo")))
>       (if (and rv
> 	       (string-match "^\\(true\\|yes\\|on\\)$" rv))
> 	  (setq default-frame-alist
> 		(cons '(reverse . t) default-frame-alist)))))
> 
> in term/x-win.el -- it sets reverse for all new frames, so when the -nw
> frame appears, it also gets reverted (which isn't what we want, I
> think).
> 
> If I just remove this, then everything still works fine (and the -nw
> client problem disappears), because:
> 
> (defun x-handle-reverse-video (frame parameters)
>   "Handle the reverse-video frame parameter and X resource.
> `x-create-frame' does not handle this one."
>   (when (cdr (or (assq 'reverse parameters)
> 		 (let ((resource (x-get-resource "reverseVideo"
> 						 "ReverseVideo")))
> 
> So it's always handled anyway, and the default-frame-alist setting is
> just counter-productive, I think?
> 
> Does anybody see any possible negative consequences of just removing
> that code from x-win.el?

Which sequence of calls ends up calling x-handle-reverse-video, and
what is the trigger for that sequence of calls?

(These kinds of changes in code that was there for decades give me the
creeps.)




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#32921; Package emacs. Full text available.
Added tag(s) moreinfo. Request was from Lars Ingebrigtsen <larsi@HIDDEN> to control <at> debbugs.gnu.org. Full text available.

Message received at 32921 <at> debbugs.gnu.org:


Received: (at 32921) by debbugs.gnu.org; 18 May 2022 12:38:45 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Wed May 18 08:38:45 2022
Received: from localhost ([127.0.0.1]:59309 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nrIwv-0004mG-IH
	for submit <at> debbugs.gnu.org; Wed, 18 May 2022 08:38:45 -0400
Received: from quimby.gnus.org ([95.216.78.240]:39314)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <larsi@HIDDEN>) id 1nrIws-0004lw-VC
 for 32921 <at> debbugs.gnu.org; Wed, 18 May 2022 08:38:43 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org;
 s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date:
 References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding:
 Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender:
 Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:
 List-Subscribe:List-Post:List-Owner:List-Archive;
 bh=+qXQNQaqWgdOYcVKgaVOuxii2ZY1xQDq+L/aTpR+glk=; b=tB23cGjb0wOcyUt4Cadb8Lr/G0
 aKn0ZNxdzeHR7GTTAk+G+invogF7wZbAPEzrI0atDm1amOsJhVUfgZfZOmo5NX6K0BUZXjOF3yGJL
 CNk6sRSCWornkVGo6JRPFmAB7ej0ak5oLMz70Bk7DQtsf/Thd09qIGjh/3yQQish2sZU=;
Received: from [84.212.220.105] (helo=xo)
 by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.92) (envelope-from <larsi@HIDDEN>)
 id 1nrIwk-0007G0-Eo; Wed, 18 May 2022 14:38:36 +0200
From: Lars Ingebrigtsen <larsi@HIDDEN>
To: Dimitrios Apostolou <jimis@HIDDEN>
Subject: Re: bug#32921: emacsclient obeys Xresources even when launched with
 -nw
References: <alpine.LFD.2.21.1810031946120.6536@jimisX1>
X-Now-Playing: Richard and Linda Thompson's _Hard Luck Stories (5): The
 Madness of Love: Live 1975 & 1977_: "A Bird In Gods Garden (Live At The
 Theatre Royal, London 01.05.1977)"
Date: Wed, 18 May 2022 14:38:33 +0200
In-Reply-To: <alpine.LFD.2.21.1810031946120.6536@jimisX1> (Dimitrios
 Apostolou's message of "Wed, 3 Oct 2018 19:49:31 +0200 (CEST)")
Message-ID: <87o7zvc8xi.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org",
 has NOT identified this incoming email as spam.  The original
 message has been attached to this so you can view it or label
 similar future email.  If you have any questions, see
 @@CONTACT_ADDRESS@@ for details.
 Content preview: Dimitrios Apostolou <jimis@HIDDEN> writes: > I have set the
 Xresource *reverseVideo to true, and as expected emacs > reverses the colours
 when launched under X, and does not when launched > with -nw thus keeping
 the terminal colour selections. [...] 
 Content analysis details:   (-2.9 points, 5.0 required)
 pts rule name              description
 ---- ---------------------- --------------------------------------------------
 -1.0 ALL_TRUSTED            Passed through trusted hosts only via SMTP
 -1.9 BAYES_00               BODY: Bayes spam probability is 0 to 1%
 [score: 0.0000]
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 32921
Cc: 32921 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

Dimitrios Apostolou <jimis@HIDDEN> writes:

> I have set the Xresource *reverseVideo to true, and as expected emacs
> reverses the colours when launched under X, and does not when launched
> with -nw thus keeping the terminal colour selections.
>
> However emacsclient obeys the Xresources even when launched with
> -nw. This leads to colour reversal in text mode, which is unwanted
> since the xterm has already been configured as desired.

(I'm going through old bug reports that unfortunately weren't resolved
at the time.)

This behaviour is still present in Emacs 29.  This seems to be stemming
from this:

  ;; Check the reverseVideo resource.
  (let ((case-fold-search t))
    (let ((rv (x-get-resource "reverseVideo" "ReverseVideo")))
      (if (and rv
	       (string-match "^\\(true\\|yes\\|on\\)$" rv))
	  (setq default-frame-alist
		(cons '(reverse . t) default-frame-alist)))))

in term/x-win.el -- it sets reverse for all new frames, so when the -nw
frame appears, it also gets reverted (which isn't what we want, I
think).

If I just remove this, then everything still works fine (and the -nw
client problem disappears), because:

(defun x-handle-reverse-video (frame parameters)
  "Handle the reverse-video frame parameter and X resource.
`x-create-frame' does not handle this one."
  (when (cdr (or (assq 'reverse parameters)
		 (let ((resource (x-get-resource "reverseVideo"
						 "ReverseVideo")))

So it's always handled anyway, and the default-frame-alist setting is
just counter-productive, I think?

Does anybody see any possible negative consequences of just removing
that code from x-win.el?

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#32921; Package emacs. Full text available.

Message received at submit <at> debbugs.gnu.org:


Received: (at submit) by debbugs.gnu.org; 3 Oct 2018 17:49:56 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Wed Oct 03 13:49:56 2018
Received: from localhost ([127.0.0.1]:35920 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1g7lHY-0006On-2P
	for submit <at> debbugs.gnu.org; Wed, 03 Oct 2018 13:49:56 -0400
Received: from eggs.gnu.org ([208.118.235.92]:38948)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <jimis@HIDDEN>) id 1g7lHU-0006OY-SY
 for submit <at> debbugs.gnu.org; Wed, 03 Oct 2018 13:49:53 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
 (envelope-from <jimis@HIDDEN>) id 1g7lHO-00005o-Fx
 for submit <at> debbugs.gnu.org; Wed, 03 Oct 2018 13:49:47 -0400
X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org
X-Spam-Level: 
X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM
 autolearn=disabled version=3.3.2
Received: from lists.gnu.org ([2001:4830:134:3::11]:50530)
 by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32)
 (Exim 4.71) (envelope-from <jimis@HIDDEN>) id 1g7lHO-00005T-8p
 for submit <at> debbugs.gnu.org; Wed, 03 Oct 2018 13:49:46 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:48513)
 by lists.gnu.org with esmtp (Exim 4.71)
 (envelope-from <jimis@HIDDEN>) id 1g7lHK-0001Ij-1C
 for bug-gnu-emacs@HIDDEN; Wed, 03 Oct 2018 13:49:46 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
 (envelope-from <jimis@HIDDEN>) id 1g7lHD-0008TL-O3
 for bug-gnu-emacs@HIDDEN; Wed, 03 Oct 2018 13:49:42 -0400
Received: from mout.gmx.net ([212.227.17.20]:60207)
 by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
 (Exim 4.71) (envelope-from <jimis@HIDDEN>) id 1g7lHD-0008SY-E7
 for bug-gnu-emacs@HIDDEN; Wed, 03 Oct 2018 13:49:35 -0400
Received: from jimisX1 ([84.209.119.197]) by mail.gmx.com (mrgmx103
 [212.227.17.168]) with ESMTPSA (Nemesis) id 0MMkgl-1g4lff0WyN-008Yoy for
 <bug-gnu-emacs@HIDDEN>; Wed, 03 Oct 2018 19:49:32 +0200
Received: from jimisX1 ([84.209.119.197]) by mail.gmx.com (mrgmx103
 [212.227.17.168]) with ESMTPSA (Nemesis) id 0MMkgl-1g4lff0WyN-008Yoy for
 <bug-gnu-emacs@HIDDEN>; Wed, 03 Oct 2018 19:49:32 +0200
Date: Wed, 3 Oct 2018 19:49:31 +0200 (CEST)
From: Dimitrios Apostolou <jimis@HIDDEN>
To: bug-gnu-emacs@HIDDEN
Subject: emacsclient obeys Xresources even when launched with -nw
Message-ID: <alpine.LFD.2.21.1810031946120.6536@jimisX1>
User-Agent: Alpine 2.21 (LFD 202 2017-01-01)
MIME-Version: 1.0
Content-Type: text/plain; format=flowed; charset=US-ASCII
X-Provags-ID: V03:K1:NARWPcDiqG+EplfRIFkEP6UwDW/ij6g8wtXDS6o1byOo+iOLUve
 Sw6YKap+Yp1XKF00L64LQaALgOy9UcafLn8Tp/lsgRIrMTUuqaAGA5CHUlszJ8w2/GsfkIJ
 AwkzGzkk8V1vFUXmlu+nn7DzWgnmdKfOFkRYltAdRtZIQHyLAFAHrlxcTcRUJajkNGpWr1I
 O0cYzdqtgrwdnOZOZ6XsQ==
X-UI-Out-Filterresults: notjunk:1;V01:K0:obe5E6ol1VA=:pb92TRFBHJRMPhFkdztuUq
 5aY8mfHPfep2bGYkYuixgRKHr2pqE3ooaLkzZwzSHvcb9YVqJyn5sjfTMjXhANJU+LgIL9nYE
 1YE4o2AARYze+wFCB4rJvZuplI2SrWzfgSfF2TAKvZxgzzLk226M4P793x3pmAELdAGO9bF1h
 TKIpK7exzjqqVUDxTVviWT87HiHTtLSXVoXtiOEYrX7CdI7AKTIFYMw6jUkOwuO6rn4s3ItWu
 pYAOrp47PvyB3h+n35RWuKd3bDTpjhtRa6VmMu8A0NDxeUgfeqjF6bIig3YQm+ZtsV4Py2JqT
 5tbeWIN0RH2T52wzMMYmVswJ28vTXFqeD0jHbQIg4AXppjcziUfC0jn1L8r4m0wv6KZe/Rqcu
 jVbTArRlZKvkMDE+8dSaQQrnIrbNns19WY1JGSfTm0Rxc9n9P7C7f++E33u/iZDIjf7m+pVsT
 f8HacaFhkk5HdZ4PWKQxW+8awgfM30NQtgM+s3g5fOTzir8SukXbUdAB31KLLdFIoO+C1NUCE
 mwan7npZJ+aQiavD57dZaKfOQJiKnTNs1TGAoCczthcAXiuidNsMaf52pGmi1may9e/+eMU+1
 xO1o1J54Tuv3J4BXM1vXnSFGqz2oFfTVA290euLit62LrYiLWeCZq8C03D2cBcleM3mKWQSlA
 Mqg5eewTrqO5mpXYksNL7iP+Hetmg7cc7p490YHb5zm4p1bM3PFyYoNOlcz0xzo1gGfSCZNBN
 w9icaJSKJo51rgEyp0msVDPmtfPz2erypFnft2Tw2JcGdc66wpdj6QfZjkE/BqlkL3359T0qT
 tXFo8F0gMSph7cTKT04Qi1Zhp9XvSFmbbuTJvbJzzwa45bQHxw=
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x
X-Received-From: 2001:4830:134:3::11
X-Spam-Score: -4.1 (----)
X-Debbugs-Envelope-To: submit
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -5.1 (-----)

GNU Emacs 26.1 (build 1, x86_64-redhat-linux-gnu, GTK+ Version 3.22.30) of 2018-06-26

I have set the Xresource *reverseVideo to true, and as expected emacs 
reverses the colours when launched under X, and does not when launched 
with -nw thus keeping the terminal colour selections.

However emacsclient obeys the Xresources even when launched with -nw. This 
leads to colour reversal in text mode, which is unwanted since the xterm 
has already been configured as desired.

It seems the reason is that emacs-server loads the Xresources and sets 
some internal state that instructs all new emacsclient instances to 
reverse colours, regardless of them being an X client app or not.


A very quick way to reproduce and see the different behaviour of emacs and 
emacsclient is to run the following commands:

emacs -xrm 'emacs*reverseVideo: true' --exec \
      '(progn (setq server-name "reverseVideo_TRUE_server")
              (server-start)
              (insert server-name))' &
emacs -xrm 'emacs*reverseVideo: false' --exec \
      '(progn (setq server-name "reverseVideo_FALSE_server")
              (server-start)
              (insert server-name))' &
sleep 2
xterm -e emacsclient -nw -s reverseVideo_TRUE_server  &
xterm -e emacsclient -nw -s reverseVideo_FALSE_server &


Credits to Javier who posted this script at [1]. Please read the full 
thread for more information on the topic.

[1] http://lists.gnu.org/archive/html/help-gnu-emacs/2018-09/msg00193.html


Thanks,
Dimitris





Acknowledgement sent to Dimitrios Apostolou <jimis@HIDDEN>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs@HIDDEN. Full text available.
Report forwarded to bug-gnu-emacs@HIDDEN:
bug#32921; Package emacs. Full text available.
Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.
Last modified: Sun, 19 Jun 2022 13:45:02 UTC

GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997 nCipher Corporation Ltd, 1994-97 Ian Jackson.