From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Yilkal Argaw Newsgroups: gmane.emacs.devel Subject: Re: Adding some convenience functions to color.el Date: Fri, 9 Jun 2023 10:26:57 +0300 Message-ID: References: <83v8fx15wq.fsf@gnu.org> Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="000000000000e8cde305fdad4b55" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="9076"; mail-complaints-to="usenet@ciao.gmane.io" Cc: emacs-devel@gnu.org To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Fri Jun 09 09:28:21 2023 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 1q7WXk-00028z-Ny for ged-emacs-devel@m.gmane-mx.org; Fri, 09 Jun 2023 09:28:20 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1q7WWj-0005Te-Lb; Fri, 09 Jun 2023 03:27:17 -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 1q7WWh-0005TN-AV for emacs-devel@gnu.org; Fri, 09 Jun 2023 03:27:15 -0400 Original-Received: from mail-oi1-x236.google.com ([2607:f8b0:4864:20::236]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1q7WWf-00038b-NY; Fri, 09 Jun 2023 03:27:15 -0400 Original-Received: by mail-oi1-x236.google.com with SMTP id 5614622812f47-39ca2539200so42805b6e.1; Fri, 09 Jun 2023 00:27:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1686295628; x=1688887628; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=FuE/4joBbfK8V5mnHMovvBqf+MHubFH+22uOZztGqfA=; b=k4NbACOXDxjElke3v9bMemSEu6V7oSOxfP9+kEZUbENFUSu2+seJNNNiTP13lmPPLp a718qJ54xDoDKLLwpGk/BdcRE9cbEgrumwnBBroc7jTd0jUdNRvJvxz99S9y2ZdYFPK9 N6DG9vff/uI39fE5S/9/HhVUyDEBjQBKhp7TGY1y2QUAH5JjRbc/hwGyhFczlB7tw2Ch epg6fMhFJfTG50zEcyrUFgh6EY8+ulgQ1lkaZxxT/3nG/V6qcgCW690OlKt+3uNz96/R aEsOhnbclHB89lKhe8pml5VCZKjAA+KEYdxsnq6LWhf8MYLQZ+pOhN50Ygcktx7KqFx2 RVaQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1686295628; x=1688887628; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=FuE/4joBbfK8V5mnHMovvBqf+MHubFH+22uOZztGqfA=; b=Y1zEzZHtJb39paYLF6oSIwHiXlK0ZRRuvyx2EBiXQ2Yyk91EaJ3Rl9lwhwxhTuyEta pZxgSCWN5+Tsqo2IjjFZb/BMHdOpFMven5Fq4B1u9ufIbghFR6rqDeXf6EyeiSK1zC6K B+ka1ysUH++qxm5yJ6pn1SsZL18YvJTfKPTjM4Qu6rwmHLYV2t4Y7naFm+2k/Kdrevc+ oaEDlCcZh1KJVYGCjQQK5wAY6HINv+2KJcAQR+W+y6B48vMqhJ9/S9DCnEzuxIzwjYlo nghDoVngo3UsCoJ8Wk7342GTZwoeRUGuNLeDHulWe597GRv4+5TTLAChfkMK3S1MniHS hj+A== X-Gm-Message-State: AC+VfDxA/zFN7RdAWJtXWeT7V4AJGdLY7qsg4CmUgnssYe6QJ104r54p +0TDZj1txnfDj5ItASGCUnZA8KYWOsW4lQ9slsATMcxSV97CAg== X-Google-Smtp-Source: ACHHUZ43B0QR4DXkCi/3qLqv6AG0ye4iGNtAW9wxpym7sVEb89lCLRw+LMi9c85TadLfdeoQ6/hMuBHORpKXy0R5j64= X-Received: by 2002:aca:ea44:0:b0:394:5dc9:d097 with SMTP id i65-20020acaea44000000b003945dc9d097mr2437484oih.3.1686295628269; Fri, 09 Jun 2023 00:27:08 -0700 (PDT) In-Reply-To: <83v8fx15wq.fsf@gnu.org> Received-SPF: pass client-ip=2607:f8b0:4864:20::236; envelope-from=yilkalargawworkneh@gmail.com; helo=mail-oi1-x236.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham 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:306706 Archived-At: --000000000000e8cde305fdad4b55 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable > From: Eli Zaretskii > We already have color-dark-p (and color-name-to-rgb to complement it), > so I'm not sure I understand the rationale for these functions. Can > you explain more why you needed them? Sorry I totally missed color-dark-p. I did not check faces.el and color-dark-p was in faces.el. Having color-name-to-hsl is just a convenience function to make it easier when working in some color spaces. Because some operations are easier in certain color spaces. On Fri, Jun 9, 2023 at 9:55=E2=80=AFAM Eli Zaretskii wrote: > > From: Yilkal Argaw > > Date: Fri, 9 Jun 2023 02:57:41 +0300 > > > > Today I was messing around with some theme that made use of color.el > and I noticed some functions > > that might be of use could be added to color.el to help with the > conditionally assigning setting some > > colors based on lightness or darkness of some other color. I wondered i= f > it might be useful to other > > users and if it might be worth adding it to color.el. I > > We already have color-dark-p (and color-name-to-rgb to complement it), > so I'm not sure I understand the rationale for these functions. Can > you explain more why you needed them? > --000000000000e8cde305fdad4b55 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
=C2=A0 > From: Eli Zaretskii <eliz@gnu.org>
=C2=A0 > We already have color-da= rk-p (and color-name-to-rgb to complement it),
=C2=A0=C2=A0 > so I= 9;m not sure I understand the rationale for these functions.=C2=A0 Can
= =C2=A0=C2=A0 > you explain more why you needed them?

Sorry= I totally missed color-dark-p. I did not check faces.el and color-dark-p w= as in faces.el.
Having color-name-to-hsl = is just a convenience function to make it easier when working in some
=
color spaces. Because some operations are easier i= n certain color spaces.


--000000000000e8cde305fdad4b55--