ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: Hans Hagen <pragma@wxs.nl>
To: ntg-context@ntg.nl
Subject: Re: Feature Request: define colour in relation to existing colour
Date: Wed, 21 Aug 2013 14:10:47 +0200	[thread overview]
Message-ID: <5214AE47.7000405@wxs.nl> (raw)
In-Reply-To: <20130821111100.GC18239@homerow>

On 8/21/2013 1:11 PM, Marco Patzer wrote:
> On 2013–08–21 Hans Hagen wrote:
>
>> On 8/21/2013 2:25 AM, Thangalin wrote:
>>> Hi,
>>>
>>> What would it take to extend \definecolor so that:
>>>
>>>    \definecolor[ColourA][ColourB][t=0.5, a=1]
>>>
>>> defines a new colour (ColourB) based on an existing colour (ColourA)?
>>>
>>> I know that \definespotcolor[ColourA][ColourB][t=0.5, a=1] works, but
>>> it seems like \definecolor would also be a natural fit.
>>
>> hm, afaik no one ever needed that (normally one defines colors once
>> on top of the document and there are seldom many of them)
>>
>> anyhow, as general inheritance is pretty fuzzy i.e. cloning a spot
>> color and changing some rgb component or cloning a cmyk color and
>> setting rgb components it will not be a feature of definecolor
>>
>> I've added \defineprocesscolor that cna be used as follows:
>
> Are you sure it's a good idea to add another colour definition
> mechanism? Then we have
>
>    \definecolor

the one i use

>    \defineglobalcolor

the one no-one uses

>    \definenamedcolor

just a sort of synonym one might forget about (compatibility)

>    \definespotcolor
>    \definemultitonecolor

special color spaces

>    \defineprocesscolor

the one users might use

> This is getting a little confusing, in my opinion. If the only
> difference between \definespotcolor and \defineprocesscolor is the
> colour space check, can't that be dealt with using a key-value
> setting?

some are made for speed (when one changes colors a lot in local / 
grouped cases)

> Probably a little late to discuss this, but I also don't see why
> \definespotcolor got its own command. A simpler approach: If two
> arguments to \definecolor are provided you define a colour, if three
> arguments are provided you define a tint of a colour.

well, more checking etc .. also some historic reasons as spot colors are 
rather special in the sense that they have to built on others .. seldom 
used anyway i guess


-----------------------------------------------------------------
                                           Hans Hagen | PRAGMA ADE
               Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
     tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com
                                              | www.pragma-pod.nl
-----------------------------------------------------------------
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


  reply	other threads:[~2013-08-21 12:10 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-08-21  0:25 Thangalin
2013-08-21  8:55 ` Hans Hagen
2013-08-21 11:11   ` Marco Patzer
2013-08-21 12:10     ` Hans Hagen [this message]
2013-08-21 14:23     ` Aditya Mahajan
2013-08-21 15:18       ` Hans Hagen
2013-08-21 15:28         ` Aditya Mahajan
2013-08-21 18:27   ` Thangalin
2013-08-21 22:06     ` Hans Hagen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=5214AE47.7000405@wxs.nl \
    --to=pragma@wxs.nl \
    --cc=ntg-context@ntg.nl \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).