From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.ciao.gmane.io!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.devel Subject: Re: "Why is emacs so square?" Date: Fri, 17 Apr 2020 18:38:30 +0300 Message-ID: <83wo6eazrd.fsf@gnu.org> References: <8wXYP4GY9hwW-9mYv6_LGMETZ8Vz3Ob1Bec6yh6kPT7yxjTkxA3V6dXY4ELra9tYiJUxJmgXKSIEX4w8HFiPRoeGVSQHDSoBVy1voj1e3Qo=@protonmail.com> <87wo6h1kwl.fsf@emailmessageidheader.nil> <83k12hgt43.fsf@gnu.org> <838siwhmco.fsf@gnu.org> <0348a76e-d55a-2e75-8ed1-1beaa6649ed6@gmail.com> <837dyfe45q.fsf@gnu.org> <245308ec-5154-7d4b-dba4-0b21f42a0e95@gmail.com> <835zdze1gs.fsf@gnu.org> <51cb2788-3086-367d-ec05-ea324da49a12@gmail.com> <83imhyd1w1.fsf@gnu.org> <83f35fb6-806e-1b28-da76-31919a398045@gmail.com> <833692cgr4.fsf@gnu.org> <6479af83-2cab-05b0-3042-8030ec3f1e1d@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="ciao.gmane.io:159.69.161.202"; logging-data="98832"; mail-complaints-to="usenet@ciao.gmane.io" Cc: emacs-devel@gnu.org To: =?utf-8?Q?Cl=C3=A9ment?= Pit-Claudel Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Fri Apr 17 17:40:24 2020 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jPT6L-000PWV-KN for ged-emacs-devel@m.gmane-mx.org; Fri, 17 Apr 2020 17:40:21 +0200 Original-Received: from localhost ([::1]:48711 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jPT6K-0003vg-M4 for ged-emacs-devel@m.gmane-mx.org; Fri, 17 Apr 2020 11:40:20 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:54041) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jPT4l-0001LW-KU for emacs-devel@gnu.org; Fri, 17 Apr 2020 11:38:44 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:38680) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1jPT4l-0001mX-Gd; Fri, 17 Apr 2020 11:38:43 -0400 Original-Received: from [176.228.60.248] (port=4370 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1jPT4k-0003MQ-I7; Fri, 17 Apr 2020 11:38:43 -0400 In-Reply-To: <6479af83-2cab-05b0-3042-8030ec3f1e1d@gmail.com> (message from =?utf-8?Q?Cl=C3=A9ment?= Pit-Claudel on Fri, 17 Apr 2020 11:27:56 -0400) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:247175 Archived-At: > Cc: emacs-devel@gnu.org > From: Clément Pit-Claudel > Date: Fri, 17 Apr 2020 11:27:56 -0400 > > > I don't know. AFAIK, we don't have infrastructure for deciding when > > stuff like that needs to be re-evaluated and how to use different > > results for different frames. If someone wants to work on such > > infrastructure, I think it will bring us a step closer to being able > > to support different GUI frame types (like GTK, w32, NS, etc.) in the > > same session. > > I may be missing something, but I don't think such infrastructure is needed here — we already have most of what's needed with conditional faces. Faces were always per-frame (although when you customize a face, it changes on all frames), but faces are just the tip of the iceberg. The general problem with GUI features is much wider. I thought you were talking about the more general problem. > The attached patch gets us 90% of the way, with the only remaining issue being wrapping buttons in square brackets on text terminals. > > (defface custom-button-pressed > '((((type x w32 ns) (class color)) > :box (:line-width 2 :style pressed-button) > :background "lightgrey" :foreground "black") > - (t :inverse-video t)) > + (t :inherit custom-button-pressed-unraised)) > "Face for pressed custom buttons if `custom-raised-buttons' is non-nil." > :version "21.1" > :group 'custom-faces) Why a separate face, instead of a separate definition of the same face for non-GUI displays? Anyway, the condition should not be on frame types, but rather on capabilities, IMO.