[Xy-pic] pdflatex & xypic in miktex ++ defining colors

Ross Moore ross at ics.mq.edu.au
Mon Oct 22 23:01:30 CEST 2007


Hello Jonny,

On 23/10/2007, at 4:03 AM, Jonny Smith wrote:

> Hi,
>
> I have 2 little questions and was wondering if someone could help  
> me out...
>
> 1) pdflatex and xypic on miktex and winedt.
>
> I am using miktex 2.7 and winedt and wanna pdflatex my posters.  
> Like many other users latex, dvips, and ps2pdf is not preferred. At
>
> http://www.esm.psu.edu/mac-tex/MacOSX-TeX-Digests/2002/MacOSX- 
> TeX_Digest_04-21-02.html
>
> I was reading some instruction on how to make that work. I did the  
> windows equivalent, i.e. copied all the xy*.tex files into the folder
>
> C:\programs\MiKTeX2.7Basic\tex\generic
>
> and did
>
> \usepackage[xypdf,all,color]{xy}

This will work only if you have installed the support files that
are contained in this archive:

     http://www-texdev.ics.mq.edu.au/xypic/xypdf.tar.gz

>
>
> in the header of my latex file. When pdflatexing It would then  
> complain saying
>
> ! Xy-pic error: No `xypdf@' option.
> \xyerror@ ...#2}\fi \errmessage {Xy-pic error: #1}
>                                                   }
> l.75
>
> Do you know what to do?


Install the files from the  xypdf.tar.gz  archive.
These can go into the same place as other Xy-pic files,
or into a local  texmf/  tree, within an appropriate
hierarchy of directories to match the system texmf/ tree.


>
>
> 2) I was playing with those color options, wanted to define some  
> colors doing
>
> \xdefinecolor{mygreen}{cmyk}{0.92,0,0.87,0.09}
>
> as well as
>
> \newxycolor{mygreen}{0.92,0,0.87}
> ...
>
> \xy
> (0,-30)*+[F**:mygreen:<10pt>]{
>           X = \dots
> }};
> \endxy
>
> Turns out that this box is filled entirely black. Another box
>
> (0,-60)*+[F**:red:<10pt>]{
>           X = \dots
> }};
>
> in this file, however, becomes red as supposed to. Was then having
>
> \usepackage{xcolor}
> \usepackage[dvips,all,color]{xy}
>
> in the header.
>
> Similarly, the line
>
> \newxyColor{lightred}{0.7}{red}{}

That 'red' is wrong.
That slot is for a color model, such as  rgb, gray, cmyk.

You want:

   \newxyColor{lightred}{0.7 0. 0.}{rgb}{}

But that won't be a light red, it is darker
than full-on red:    1 0 0 setrgbcolor .

If you are thinking about 70% red, then
better would be:

   \newxyColor{lightred}{1.0 0.3 0.3}{rgb}{}

or

   \newxyColor{lightred}{1.0 0.7 0.7}{rgb}{}

I doubt that either of these is actually what you want.
Perhaps this is better:

   \newxyColor{lightred}{1.0 0.5 0.5}{rgb}{}



>
>
> I found at
>
> http://tug.org/mailman/htdig/xy-pic/2003-June/000166.html
>
> was not doing any better and and after latexing it gave
>
> Error: /undefined in TeXcolorred

Certainly.
There is no predefined  red  color model.
This should be:
   TeXcolorrgb   or  TeXcolorgray  or  TeXcolorcmyk .

>
> Operand stack:
>    --dict:1155/1684(ro)(G)--   0.7
> Execution stack:
>    %interp_exit   .runexec2   --nostringval--   --nostringval--   -- 
> nostringval--   2   %stopped_push   --nostringval--   -- 
> nostringval--   --nostringval--   false   1   %stopped_push    
> 1893   1   3
>
> and things in YAP. I'm kinda surprised this is not working as I was  
> reading some earlier postings for instance at
>
> http://tug.org/mailman/htdig/xy-pic/2004-November/000287.html
>
> reporting positive results...
>
> If you have an idea on how to fix it ... that'd be appreciated.  
> Thanks,
>
> Joe


Hope this helps,

	Ross Moore

------------------------------------------------------------------------
Ross Moore                                         ross at maths.mq.edu.au
Mathematics Department                             office: E7A-419
Macquarie University                               tel: +61 +2 9850 8955
Sydney, Australia  2109                            fax: +61 +2 9850 8114
------------------------------------------------------------------------




More information about the xy-pic mailing list