Re: [NTG-context] ntg-context Digest, Vol 99, Issue 40

2012-09-14 Thread pol stra

Troy Henderson said:

I tested this on a black-on-transparent EPS that was created via MetaPost, and 
it seems to work fine.  If you are not using Linux (or Unix or Mac OS X), let 
me know and I can probably put together a quick HTML page to do this on my 
server.
Thanks for the invitation. Fortunatly I’m using GNU/Linux.


 cat foo.eps | sed -e s/0 0 0 setrgbcolor/1 1 1 setrgbcolor/g  bar.eps

It simply translates the (0,0,0) triplet (which is black) to the (1,1,1) 
triplet (which is white).  This is very simplistic and may not do all that you 
want.

Unfortunatly there is no such a sequence in my file:

grep setrgbcolor a1.EPS 
/setcmykcolor{1 sub 4 1 roll 3{3 index add neg dup 0 lt{pop 0}if 3 1 
roll}repeat setrgbcolor pop}wd
/sw/setlinewidth ld/scap/setlinecap ld/sj/setlinejoin ld/sm/setmiterlimit 
ld/sd/setdash ld/rgb/setrgbcolor ld/crgb/currentrgbcolor ld/cmyk/setcmykcolor 
ld/gs/gsave ld/gr/grestore ld

But thank you for gave a try.
  ___
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
___

Re: [NTG-context] ntg-context Digest, Vol 99, Issue 40

2012-09-14 Thread Troy Henderson

 Unfortunatly there is no such a sequence in my file:

 grep setrgbcolor a1.EPS
 /setcmykcolor{1 sub 4 1 roll 3{3 index add neg dup 0 lt{pop 0}if 3 1
 roll}repeat setrgbcolor pop}wd
 /sw/setlinewidth ld/scap/setlinecap ld/sj/setlinejoin ld/sm/setmiterlimit
 ld/sd/setdash ld/rgb/setrgbcolor ld/crgb/currentrgbcolor
 ld/cmyk/setcmykcolor ld/gs/gsave ld/gr/grestore ld

 But thank you for gave a try.


I doubted that it would work, but thought that I would try just the same.
It may still be able to be done by converting it to SVG, editing
(automagically), and then converting back.  If you are able, upload the EPS
to

http://www.tlhiv.org/upload/

and I will place around with it.

Troy
___
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
___

Re: [NTG-context] ntg-context Digest, Vol 99, Issue 40

2012-09-14 Thread Troy Henderson
I put together this little utility for converting a color EPS/PDF/SVG to
grayscale.

http://www.tlhiv.org/grayscale/

Selecting invert swaps colors from white to black and black to white.
So, using a black/white graphic on a transparent background should
transform it to a white/black graphic on a transparent background.

Testing is certainly necessary.

Troy
___
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
___