From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: =?UTF-8?Q?Micha=C5=82_Nazarewicz?= Newsgroups: gmane.emacs.devel Subject: Would True Colour to ANSI 8-bit palette conversion be useful Date: Fri, 14 Jun 2024 06:01:19 -0400 Message-ID: Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="13854"; mail-complaints-to="usenet@ciao.gmane.io" To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Fri Jun 14 12:02:40 2024 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 1sI3lY-0003MK-0m for ged-emacs-devel@m.gmane-mx.org; Fri, 14 Jun 2024 12:02:40 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1sI3ka-0005Vd-QL; Fri, 14 Jun 2024 06:01:40 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1sI3kW-0005VK-2w for emacs-devel@gnu.org; Fri, 14 Jun 2024 06:01:36 -0400 Original-Received: from mail-ot1-f50.google.com ([209.85.210.50]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1sI3kT-0005MM-BW for emacs-devel@gnu.org; Fri, 14 Jun 2024 06:01:35 -0400 Original-Received: by mail-ot1-f50.google.com with SMTP id 46e09a7af769-6f9b0e8877eso30034a34.2 for ; Fri, 14 Jun 2024 03:01:31 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1718359290; x=1718964090; h=content-transfer-encoding:to:subject:message-id:date:from :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=YGLBAEH0cUq5/DZCsyd0HJuLVKfGwC1koaQv8Jx5PC8=; b=o5umiFrTTidG7h6y2xlBnqZxaOc6igbMSh4FbceuLF64lUk27hLOgNaokx1I8MzG/i PFVuoEjv4CMFEPCcBvNKOvztG8aywb1rkzlZ7uBtkDw+8RtCoKEBqj8jTnog1GiT7mwK 5jGAAD5cwWk841kBgqvfffTNLqGcuF37ncJTgMiMtsJqATZTX6IylHRqvfUWunI/G7id DMHlL/JYxIqcJzHXQAusyyArGIo/CnJNFOy4+DOBHBqTExkOGJBGlSyF//jysi9bIN52 9mbmMAgs96vkHFCSVtMmm3HlksNs+TFbQUWxdkQ7h68Cb9PppItIYHsoRjcS3E5LpVlM at9g== X-Gm-Message-State: AOJu0YzDyHe/jFtcbAk2FWvWlr/nNv3wrszp7w6Vptr5uC4x1WvC+UX7 +n2ZlL7dg7eVP5zuEdKwV9b4eLIsCRP+cENjnYLDH3FeC6DLjS4b9dj8Nm4jMAZdIWLLEvGUHBO 4j1JLLFUqHjoDF3TYqWcR61B5vKnwlrKC X-Google-Smtp-Source: AGHT+IFqYrLcuzXjJVrXb4PqsIp3fMoN+gN6WsgF/bGDT+BrjrZFVo1F8ifcbNMz/3993529mWvV/7EftLSLqcC9+08= X-Received: by 2002:a05:6830:3c82:b0:6f9:62af:a442 with SMTP id 46e09a7af769-6fb931825c9mr2232645a34.0.1718359289875; Fri, 14 Jun 2024 03:01:29 -0700 (PDT) Received-SPF: pass client-ip=209.85.210.50; envelope-from=mnazarewicz@gmail.com; helo=mail-ot1-f50.google.com X-Spam_score_int: -16 X-Spam_score: -1.7 X-Spam_bar: - X-Spam_report: (-1.7 / 5.0 requ) BAYES_00=-1.9, FREEMAIL_FORGED_FROMDOMAIN=0.001, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.25, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=no autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 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-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:320059 Archived-At: A while back I wrote https://github.com/mina86/ansi_colours which takes 24-bit RGB colour and spits out the best matching entry from ANSI 8-bit palette. I=E2=80=99ve recently looked through NEWS and noticed changes related to the true colour support on the terminal. This got me wondering whether a feature to do True Colour -> ANSI conversion would be useful somewhere in Emacs. The typical usage is where the user specifies 24-bit colour but the terminal supports the 8-bit palette only. I don=E2=80=99t use Emacs in terminal nor do I run terminal inside Emacs, s= o honestly I=E2=80=99ve no idea if that would be useful. --=20 Best regards =E3=83=9F=E3=83=8F=E3=82=A6 =E2=80=9C=F0=9D=93=B6=F0=9D=93=B2=F0=9D=93=B7= =F0=9D=93=AA86=E2=80=9D =E3=83=8A=E3=82=B6=E3=83=AC=E3=83=B4=E3=82=A4=E3=83= =84 =C2=ABIf at first you don=E2=80=99t succeed, give up skydiving=C2=BB