From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.ciao.gmane.io!not-for-mail From: =?UTF-8?Q?Cl=c3=a9ment_Pit-Claudel?= Newsgroups: gmane.emacs.devel Subject: Re: "Why is emacs so square?" Date: Fri, 17 Apr 2020 13:57:05 -0400 Message-ID: <3604def6-82c0-1af2-baff-b32e426d642f@gmail.com> 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> <83wo6eazrd.fsf@gnu.org> <8001bd11-b552-e94e-d15a-30f9bd34f71b@gmail.com> <83sgh2av7x.fsf@gnu.org> <21e1fef1-63a8-815a-1293-45ee79ffcabc@gmail.com> <83lfmuatvu.fsf@gnu.org> 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="58478"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.7.0 Cc: emacs-devel@gnu.org To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Fri Apr 17 19:58:04 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 1jPVFb-000F2k-9G for ged-emacs-devel@m.gmane-mx.org; Fri, 17 Apr 2020 19:58:03 +0200 Original-Received: from localhost ([::1]:50306 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jPVFa-0008Jw-By for ged-emacs-devel@m.gmane-mx.org; Fri, 17 Apr 2020 13:58:02 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:33836) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jPVEl-0007fT-M9 for emacs-devel@gnu.org; Fri, 17 Apr 2020 13:57:12 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1jPVEi-0004CS-GX for emacs-devel@gnu.org; Fri, 17 Apr 2020 13:57:11 -0400 Original-Received: from mail-qt1-x831.google.com ([2607:f8b0:4864:20::831]:41115) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1jPVEi-0004Bp-Cz; Fri, 17 Apr 2020 13:57:08 -0400 Original-Received: by mail-qt1-x831.google.com with SMTP id l60so2676741qtd.8; Fri, 17 Apr 2020 10:57:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=ajUQOzKm9RmSxDTOFCui+lXucjLAwjO6trokGsKCfa8=; b=kijLNsSVVleqePQ64A7En/n3bb9qN3k7UaPFBIlp2iIYPDZNE9pvMN/UiAnLmZUqZe LsPCRR8ELIFArJFLbcUSjDwPBt/VP4B69H6ve01gyscKNZwR82wM2o5J/Kzo7J9l8lXD sfGajqpolN1BqZJr7Qj0MvmExkK/F2fXvj5qNr7h4t65zNtubgOwAdxQKdmK+5O9PHeo Ftfxp2TMSxsSnyVmNGTHg6HmL///naMqXkIUX2eCOO1nYYKvNEskV3opKFeBbYif6I1j yIOSPGKfa8HCd1rELJprlJrq+QJohxFYhjlUHVeNtaF3eq+bgY0FZF+ZhiFhQHrbprbi p7Fw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=ajUQOzKm9RmSxDTOFCui+lXucjLAwjO6trokGsKCfa8=; b=mb4UpK+LpIQcVB5mcelobF9qOIzHYr3V6KinNdU7zKO9i3GO6SkeyNYvyJBLWzJP6c LhUkRMfvIWmWH5Yc1r3Vdv2gjZ2Duqi6gq8nWcUAOagkQKJk2GBfU6aFp06zqswHBa3w pqhFBP0swb+mrf19YunhNk1HuTXVG6QMyYPXXxfnLfdR1HE2c4tY1ecaBOubtzzBuLGi 4cGsGtJXBkDOmlIzcJMdflTl4pU4ZarzzrAkvxR7mkhnd4/a3U7BkSRpr0KZVy85U6HL 5DEcAAxeRuzqHBKV6d1SwRSL8rZvK0V+b8ewMZS547Xry6kMjWN7B4AOo5AJHL0WCtXn zm4A== X-Gm-Message-State: AGi0PuaJVqFUkeHJGA6xLE4wQEU6MUX/IYGm/3Mp5Cq8xiJXm4jdNmet Cou9r38E6Vuy5Lr1wUefCbmAhVqR X-Google-Smtp-Source: APiQypKrfrW4/PtYsrug7NOhQugcprA7B1sCQYDrCCzR/LCR0pdTfT5ljCvaiXKjRGnFpoi2rXQcPg== X-Received: by 2002:ac8:17c7:: with SMTP id r7mr4124517qtk.356.1587146227223; Fri, 17 Apr 2020 10:57:07 -0700 (PDT) Original-Received: from ?IPv6:2601:184:4180:66e7:da2:5c19:86dd:363e? ([2601:184:4180:66e7:da2:5c19:86dd:363e]) by smtp.googlemail.com with ESMTPSA id c27sm18640297qte.49.2020.04.17.10.57.06 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Fri, 17 Apr 2020 10:57:06 -0700 (PDT) In-Reply-To: <83lfmuatvu.fsf@gnu.org> Content-Language: en-GB X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2607:f8b0:4864:20::831 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:247192 Archived-At: On 17/04/2020 13.45, Eli Zaretskii wrote: >> Cc: emacs-devel@gnu.org >> From: Clément Pit-Claudel >> Date: Fri, 17 Apr 2020 13:40:29 -0400 >> >> There is a way to change the color, backgorund, etc. of a bit of text depending on the properties of the display it is on, through the face-specs of defface. Is there a similar facility for showing or hiding a piece of text depending on properties of the frame it's shown on? I tried using a conditional 'display property, but that doesn't seem to work. > > I don't think I understand the problem. Faces can have different > definitions on different frames, so what is the problem, exactly? The problem is to indicate that a string is a button on a text terminal. Currently, custom does this by writing the string "[button]" with an underline on text terminals, and "button" with a raised look on graphical terminals. This is done by inserting different text in the buffer depending on whether the display supports the `:box' face property. Because of this, a customization buffer created on a text terminal shows "[button]" instead of "button" when displayed on a graphical terminal. The question is: is there a way to insert something in a buffer that will display as "[button]" when shown on a text terminal and as "button" when shown on a graphical terminal? I thought of using something like (propertize "[" 'display '(when (display-graphic-p) . "")), but it doesn't work well: when the buffer is shown on two frames (one graphical, one non-graphical), it doesn't look right in both.