* TikZ is colored despite having \setupcolors[state=stop]
@ 2015-03-10 11:10 Norbert Melzer
2015-03-10 11:24 ` Hans Hagen
0 siblings, 1 reply; 4+ messages in thread
From: Norbert Melzer @ 2015-03-10 11:10 UTC (permalink / raw)
To: ntg-context
[-- Attachment #1.1: Type: text/plain, Size: 625 bytes --]
I've posted the same question on TE already:
http://tex.stackexchange.com/questions/232158/tikz-is-colored-despite-having-setupcolorsstate-stop
Text of the question:
In the following MWE I get a red square, but I want it to be gray, as in
the also provided LaTeX-document:
```tex
% ConTeXt MWE
\setupcolors[state=stop]
\usemodule[tikz]
\starttext
\tikz{\draw[color=red,fill] (0,0) rectangle (1,1)}
\stoptext
```
```
% LaTeX-document wich does what I want
\PassOptionsToPackage{gray}{xcolor}
\documentclass{article}
\usepackage{tikz}
\begin{document}
\tikz{\draw[color=red,fill] (0,0) rectangle (1,1)}
\end{document}
```
[-- Attachment #1.2: Type: text/html, Size: 1036 bytes --]
[-- Attachment #2: Type: text/plain, Size: 485 bytes --]
___________________________________________________________________________________
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
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: TikZ is colored despite having \setupcolors[state=stop]
2015-03-10 11:10 TikZ is colored despite having \setupcolors[state=stop] Norbert Melzer
@ 2015-03-10 11:24 ` Hans Hagen
2015-03-10 11:28 ` Norbert Melzer
0 siblings, 1 reply; 4+ messages in thread
From: Hans Hagen @ 2015-03-10 11:24 UTC (permalink / raw)
To: ntg-context
On 3/10/2015 12:10 PM, Norbert Melzer wrote:
> I've posted the same question on TE already:
> http://tex.stackexchange.com/questions/232158/tikz-is-colored-despite-having-setupcolorsstate-stop
>
> Text of the question:
>
> In the following MWE I get a red square, but I want it to be gray, as in
> the also provided LaTeX-document:
>
> ```tex
> % ConTeXt MWE
> \setupcolors[state=stop]
> \usemodule[tikz]
>
> \starttext
> \tikz{\draw[color=red,fill] (0,0) rectangle (1,1)}
> \stoptext
> ```
>
> ```
> % LaTeX-document wich does what I want
> \PassOptionsToPackage{gray}{xcolor}
> \documentclass{article}
> \usepackage{tikz}
> \begin{document}
> \tikz{\draw[color=red,fill] (0,0) rectangle (1,1)}
> \end{document}
> ```
The state=stop will only affect tikz when it uses the context color
handling. One of the relevant status variables is:
\c_colo_enabled
\ifcase\c_colo_enabled
yes
\else
no
\fi
assuming that _ is a character
-----------------------------------------------------------------
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
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: TikZ is colored despite having \setupcolors[state=stop]
2015-03-10 11:24 ` Hans Hagen
@ 2015-03-10 11:28 ` Norbert Melzer
2015-03-10 12:28 ` Hans Hagen
0 siblings, 1 reply; 4+ messages in thread
From: Norbert Melzer @ 2015-03-10 11:28 UTC (permalink / raw)
To: mailing list for ConTeXt users
[-- Attachment #1.1: Type: text/plain, Size: 1289 bytes --]
2015-03-10 12:24 GMT+01:00 Hans Hagen <pragma@wxs.nl>:
> On 3/10/2015 12:10 PM, Norbert Melzer wrote:
>
>> I've posted the same question on TE already:
>> http://tex.stackexchange.com/questions/232158/tikz-is-
>> colored-despite-having-setupcolorsstate-stop
>>
>> Text of the question:
>>
>> In the following MWE I get a red square, but I want it to be gray, as in
>> the also provided LaTeX-document:
>>
>> ```tex
>> % ConTeXt MWE
>> \setupcolors[state=stop]
>> \usemodule[tikz]
>>
>> \starttext
>> \tikz{\draw[color=red,fill] (0,0) rectangle (1,1)}
>> \stoptext
>> ```
>>
>> ```
>> % LaTeX-document wich does what I want
>> \PassOptionsToPackage{gray}{xcolor}
>> \documentclass{article}
>> \usepackage{tikz}
>> \begin{document}
>> \tikz{\draw[color=red,fill] (0,0) rectangle (1,1)}
>> \end{document}
>> ```
>>
>
> The state=stop will only affect tikz when it uses the context color
> handling.
How can I convince TikZ to use ConTeXts colorhandling?
> One of the relevant status variables is:
>
> \c_colo_enabled
>
> \ifcase\c_colo_enabled
> yes
> \else
> no
> \fi
>
> assuming that _ is a character
>
I don't understand what you exactly want to tell me with this. I assume you
don't mean to copy-paste that literally into my env-file, but what to do
exactly with that snippet?
[-- Attachment #1.2: Type: text/html, Size: 2176 bytes --]
[-- Attachment #2: Type: text/plain, Size: 485 bytes --]
___________________________________________________________________________________
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
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: TikZ is colored despite having \setupcolors[state=stop]
2015-03-10 11:28 ` Norbert Melzer
@ 2015-03-10 12:28 ` Hans Hagen
0 siblings, 0 replies; 4+ messages in thread
From: Hans Hagen @ 2015-03-10 12:28 UTC (permalink / raw)
To: ntg-context
> How can I convince TikZ to use ConTeXts colorhandling?
>
> One of the relevant status variables is:
>
> \c_colo_enabled
>
> \ifcase\c_colo_enabled
> yes
> \else
> no
> \fi
>
> assuming that _ is a character
>
>
> I don't understand what you exactly want to tell me with this. I assume
> you don't mean to copy-paste that literally into my env-file, but what
> to do exactly with that snippet?
it shows away to test of color is enabled ... just an example of usage
... it's up to tikz folks to use it or not ... so nothing for you to do
Hans
-----------------------------------------------------------------
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
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2015-03-10 12:28 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-03-10 11:10 TikZ is colored despite having \setupcolors[state=stop] Norbert Melzer
2015-03-10 11:24 ` Hans Hagen
2015-03-10 11:28 ` Norbert Melzer
2015-03-10 12:28 ` Hans Hagen
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).