From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-3.4 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,FREEMAIL_FROM,HTML_MESSAGE,MAILING_LIST_MULTI, RCVD_IN_DNSWL_MED,UNPARSEABLE_RELAY autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 5230 invoked from network); 22 Oct 2020 19:59:27 -0000 Received: from zero.zsh.org (2a02:898:31:0:48:4558:7a:7368) by inbox.vuxu.org with ESMTPUTF8; 22 Oct 2020 19:59:27 -0000 ARC-Seal: i=1; cv=none; a=rsa-sha256; d=zsh.org; s=rsa-20200801; t=1603396767; b=doaFpNgMdz1NS8x2mRc+YqWvpyC53mLLP0rfduce2yhlyen13AjBvkTxjpgM4P2ql0wwofDeLN 6PFbq3VYaNgdlB8Ws2oxJVnX1YvxirJZpCw0e+HOD5I4OyDVH1bEbYmkik0NZwEFMRJW1p6cjx GQAXlc3ss+kuGOthZnjwnpSBdt+zigkubISH8Z0dcO16u53D33121r8z+Fv8Tar8N8LjSrD4ar UjpFBb1ELyfMKSfALalSIZZY9kdmteNvjlAXhbgbTh/+Nh7TfuJJL7/jnyU/9hxqR75UR+5l/P zEOuxmpsGXiqNOOBWiQbBKJre+2FTKcjAWs3/8ou0UUErA==; ARC-Authentication-Results: i=1; zsh.org; iprev=pass (mail-lj1-f177.google.com) smtp.remote-ip=209.85.208.177; dkim=pass header.d=gmail.com header.s=20161025 header.a=rsa-sha256; dmarc=pass header.from=gmail.com; arc=none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed; d=zsh.org; s=rsa-20200801; t=1603396767; bh=3vrs9NvKiobaNbF/0hzoQ+Lpp4oLhhyfiCtphKMby5Q=; h=List-Archive:List-Owner:List-Post:List-Unsubscribe:List-Subscribe:List-Help: List-Id:Sender:Content-Type:Cc:To:Subject:Message-ID:Date:From:In-Reply-To: References:MIME-Version:DKIM-Signature:DKIM-Signature; b=p/UEOTB+GPpeMf5f6LkgB8LFr8DHbc5IEgg7bvBsDqfvUscwhVXXxUd+Tzn2e62ZzFcHIF0Sde c8zO0f6ZVpmUJRQXUKh/K1psQCejlzcBFmS8oEwKugxglDTxmCvcbslGKa5EZ5a4d2X5ql0GlP yHUXCjLsKmCOylclMB8gafW5KjvK/WBlQDHuAGJ3jdWACGOMrRf/oJRPN6JhStqRO2rHXsJnd4 SVYXnL0UArqN6pfcOTxugiHfx9bnpMBCyMO+3epic+B6/wRjck9d6yDhoEleekfgWcM2REZlM4 9vzQUe4EtBHqFr3TCQQYBFOdWPUB7IGwcZW/VvyYx0yEcw==; DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=zsh.org; s=rsa-20200801; h=List-Archive:List-Owner:List-Post:List-Unsubscribe: List-Subscribe:List-Help:List-Id:Sender:Content-Type:Cc:To:Subject:Message-ID :Date:From:In-Reply-To:References:MIME-Version:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID; bh=mAQh/q4jLS01Lstpwkkk6rJmqXcbNCFOrvmmP30JPU8=; b=GkFC1YuL39Krzr4wUst+Mn+f8y nHsTJeFLYgINKxEi9i32wBz3SRVWjO27F/GJJHbiwuua4PADjq+MUCj4XHbN0JllOAYrxTDUW6tKD uPFlaIQGvmbgyXvfxmFcB63Lhk9W1qG6DayRFMf/7TcAPKdywPH6lB6IIdgjeXv0G34sJAjQdkP2T MJ2VOjJHewhUqI4pjprgYmkRc1NbB8GWBmdHMbYGa/gOyMpir5DzZ/IB0FSEtqvWLlLoOruONTvwm a1+P/mUSTXFJiNISHUuECf6ihW9hpXoFsI4R80srtxZdSVzNQlHx7og6EVMEsFrsVq5z4SJm57Z4P 9GGLKSRQ==; Received: from authenticated user by zero.zsh.org with local id 1kVgkA-000OdR-OG; Thu, 22 Oct 2020 19:59:26 +0000 Authentication-Results: zsh.org; iprev=pass (mail-lj1-f177.google.com) smtp.remote-ip=209.85.208.177; dkim=pass header.d=gmail.com header.s=20161025 header.a=rsa-sha256; dmarc=pass header.from=gmail.com; arc=none Received: from mail-lj1-f177.google.com ([209.85.208.177]:38532) by zero.zsh.org with esmtps (TLS1.3:TLS_AES_128_GCM_SHA256:128) id 1kVgju-000OVR-LA; Thu, 22 Oct 2020 19:59:11 +0000 Received: by mail-lj1-f177.google.com with SMTP id m20so3286118ljj.5 for ; Thu, 22 Oct 2020 12:59:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=mAQh/q4jLS01Lstpwkkk6rJmqXcbNCFOrvmmP30JPU8=; b=YTNP54qzbtSWnhn+rbWN+eBFA9AVwmT0NghUjjlR/5vgSrdv0Tk5DMhL9ZjSEh7YuT 1Wv7YiRgkiUPhDOBCTwVwWIAx4tbZfiQ0gLUigAhcss5aj/yIIFS33VEPlE8+kx2fXuz iwSHh+BtaTOLSnwgqAOm8bA9DrjlGLzqwC9gOI97RAXQ12JmSJGKD+KJrafY0xkLF7TZ Ksk2qw5yGkI6uNevzJnqVqL+Gv21j17YFHOPOJQyLbNlbKJBgJNWKIFOlMO6n196aInY YzGN1C+N7+bODI6satUbs+9X9va5ROv7QbNbIqzc5edxV0cQhq2Ulkvm1UdNPeLikRkP AgFw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=mAQh/q4jLS01Lstpwkkk6rJmqXcbNCFOrvmmP30JPU8=; b=Gsf/4ZWZwh/669K52lQHNhG8TPI7FCsYpyZ+GK+bNVHTNjW3GlWwCMFaWCh0ZkQFZK Cd7IyBa2Q4Ey6v7k78D6GhutIDcpoUHXRY4531B0+WldFyCGgoei1Eubncl3nUJAnFxi ycXTlHF11XjeZTky1vFQh8yrIySp9c1xTpfNTKlEQy2Mgs6kdByER36Kpg1Q83yZ7Nu1 6j0QDjTabgmlGfCV3bS6XxTSuwBEGMFxYGCvi72/Krhd5vbu+DaEYIDOF2ClRwT6ccJ+ A2r4nFWLWCOsT2gLFnjABa9U/s0qHnEit9wg34Kmr40YkKcDGC+nrTSnUEOxLhcEHU/s XuQg== X-Gm-Message-State: AOAM531dxJrRdZWYDKS1iWqUbuvsRs0ymW3uW85fWDh+bVRgTOvw38nZ zv65UfEkrJMnU9k414ea1T89znAHLXGZwAHGGtE= X-Google-Smtp-Source: ABdhPJzPd6RbmlneNjZZy1n/RHH2c5p2nUMRqhND98Bcvo8Cv5xWQ5oF+8oiVSNrtm5e5oacKSDaU1QlyexmOvN5Ke8= X-Received: by 2002:a2e:9942:: with SMTP id r2mr1539047ljj.409.1603396749820; Thu, 22 Oct 2020 12:59:09 -0700 (PDT) MIME-Version: 1.0 References: <20201014204621.4cf5b2b0@tarpaulin.shahaf.local2> In-Reply-To: From: Marlon Richert Date: Thu, 22 Oct 2020 22:58:58 +0300 Message-ID: Subject: Re: region_highlight converts `fg=default` to `none`, which is not the same To: Bart Schaefer Cc: Daniel Shahaf , Roman Perepelitsa , Zsh hackers list Content-Type: multipart/alternative; boundary="000000000000b510e405b247e5a3" X-Seq: 47478 Archived-At: X-Loop: zsh-workers@zsh.org Errors-To: zsh-workers-owner@zsh.org Precedence: list Precedence: bulk Sender: zsh-workers-request@zsh.org X-no-archive: yes List-Id: List-Help: List-Subscribe: List-Unsubscribe: List-Post: List-Owner: List-Archive: Archived-At: --000000000000b510e405b247e5a3 Content-Type: text/plain; charset="UTF-8" While we're on the topic of `region_highlight`, here's another problem I've noticed with it: `standout` (3) is rendered as `reverse` (7), even though my terminal is perfectly capable of rendering italic. When I use `\e[3m` in `$PS1` or `$ZLS_COLORS`, it renders fine as italic. There's no reason to convert it. On Fri, 16 Oct 2020 at 18:51, Bart Schaefer wrote: > On Fri, Oct 16, 2020 at 6:29 AM Daniel Shahaf > wrote: > > > > The inconsistent augmentation semantics have bugged me since I first ran > > into them. I'd love to see them rationalized. > > As I recall one of the problems with this is (as Roman mentioned) > there is no way to selectively turn off many of the attributes. That > is, there's no way to tell the terminal "revert to the previous value > of X", instead we have to keep track of that and explicitly assert > "set X to Y". In some cases even that's not enough, and the only > right approach is to clear all attributes and then reassert all > attributes. This shortcoming is directly reflected in the selection > of names/values in Functions/Misc/colors, where I also summarized the > ECMA standard in comments. (There's probably a newer standard at this > point.) > --000000000000b510e405b247e5a3 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
While we're on the topic of `region_highlight`, here&#= 39;s another problem I've noticed with it: `standout` (3) is rendered a= s `reverse` (7), even though my terminal is perfectly capable of rendering = italic. When I use `\e[3m` in `$PS1` or `$ZLS_COLORS`, it renders fine as i= talic. There's no reason to convert it.

On Fri, 16 Oct 2020 at 18:51, Bart= Schaefer <schaefer@brassla= ntern.com> wrote:
On Fri, = Oct 16, 2020 at 6:29 AM Daniel Shahaf <d.s@daniel.shahaf.name> wrote:
>
> The inconsistent augmentation semantics have bugged me since I first r= an
> into them.=C2=A0 I'd love to see them rationalized.

As I recall one of the problems with this is (as Roman mentioned)
there is no way to selectively turn off many of the attributes.=C2=A0 That<= br> is, there's no way to tell the terminal "revert to the previous va= lue
of X", instead we have to keep track of that and explicitly assert
"set X to Y".=C2=A0 In some cases even that's not enough, and= the only
right approach is to clear all attributes and then reassert all
attributes.=C2=A0 This shortcoming is directly reflected in the selection of names/values in Functions/Misc/colors, where I also summarized the
ECMA standard in comments.=C2=A0 (There's probably a newer standard at = this
point.)
--000000000000b510e405b247e5a3--