Re: [NTG-context] \externalfigure and file size

2012-01-20 Thread luigi scarso
On Fri, Jan 20, 2012 at 2:30 AM, Kip Warner k...@thevertigo.com wrote:

 On Fri, 2012-01-20 at 02:03 +0100, Mojca Miklavec wrote:
  Yes, but this is only true as long as your graphic can be represented
  reliably in the target format. And yours cannot.

 Hey Mojca. Yes, that makes sense now. I had assumed incorrectly that PDF
 implemented everything SVG does.


You can also try the reverse way with ipe
http://ipe7.sourceforge.net/
and then convert the pdf in svg with inkscape or iperender

-- 
luigi
___
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] \externalfigure and file size

2012-01-20 Thread Hans Hagen

On 20-1-2012 01:51, Marco wrote:


ConTeXt doesn't seem to list inkscape as a dependency on
my distro:


Inkscape should not be a dependency of ConTeXt. 99.9% work
very well without inkscape. But it could be mentioned as a
“Recommendation”, as  a hint  that its  installation would
increase the functionality.


There is no such depedency .. actually, i found it rather impossible to 
get an inkscape running on a headless linux box as there is some 
depedency on X (last time I tried). In a similar fashion there is no 
dependency on GhostScript or GraphicMagick or Zint.


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
___

Re: [NTG-context] include file in xml processing

2012-01-20 Thread Meer, H. van der
I have seen that I can load a file (containing ConTeXt code) with
\startxmlsetups xmlcommon:texinclude
\writestatus{TEST HVDM}{file: \xmlatt{#1}{file}}
\xmlload{#1}{\xmlatt{#1}{file}}
\stopxmlsetups

But how to use these loaded data? I want them included in ConTeXt-processing 
like this but it doesn't work:
texinclude file=filename/
tex
\useMPgraphic{xyz}{param=285}
/tex
The tex node is just a wrapper around \xmlcontext{#1}{.}

Someone who can put me on the right track?

Hans van der Meer



On 19 jan. 2012, at 21:38, Hans van der Meer wrote:

I have the following setup for use of ConTeXt code in an xml-processing setup:

% Usage: tex ... /tex
\startxmlsetups xmlcommon:tex
\ignorespaces
\xmlstripnolines{#1}{.} % need to strip sufficient space characters
\xmlcontext{#1}{.}
\stopxmlsetups

Since I need some MetaPost drawings repeatedly I thought to include those from 
a separate file:
tex
\input thedirectory/thefile
\useMPgraphic{lfsr}{stages=285}
/tex

The file is read, but typeset as is, MetaPost processing does not occur. By the 
way, inserting the MetaPost code in place of the \input works ok.

I also tried \usemodule[thedirectory/thefile] instead, but then nearly 
everything MetaPost encounters is undefined.

Does someone know how to get the file inclusion right?

Hans van der Meer



___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nlmailto: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
___

___
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] \externalfigure and file size

2012-01-20 Thread Marco
On 2012-01-19 Kip Warner k...@thevertigo.com wrote:

 On a related note, what  is the difference between these
 three statements?

 \setupbackend[level=9]

I have no idea, I never used it.

 \pdfcompresslevel9

AFAIK  it  compresses  the  text  objects.  9  is  maximum
compression. It's a low level command.

 \maximumpdfcompression

\normalprotected\def\maximumpdfcompression{%
\pdfobjcompresslevel\plusnine  \pdfcompresslevel\plusnine }

Sets the text and object  compression to the maximum value
(which is  9). The  command is considered  to be  a higher
level command, see

http://archive.contextgarden.net/message/20111229.184755.b0199f53.en.html

Marco


___
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] \externalfigure and file size

2012-01-20 Thread Hans Hagen

On 20-1-2012 11:18, Marco wrote:


Sets the text and object  compression to the maximum value
(which is  9). The  command is considered  to be  a higher
level command, see

http://archive.contextgarden.net/message/20111229.184755.b0199f53.en.html


keep in mind that on the average the defaults are a good compromise 
between speed and bytes (both in writing and reading)


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
___


Re: [NTG-context] endnotes, imposition and recurselevel

2012-01-20 Thread Hans Hagen

On 20-1-2012 08:07, Michael Guravage wrote:

I am typesetting an article where the footnotes should be collected as
endnotes. I am also using imposition to arrange the article as a booklet.

When using the default location 'page', footnotes work as expected. But
when I change the location to 'text' and use \placefootnotes to produce the
endnotes, the compilation fails. Here is an example document that attempts
the same thing.  Note that the paragraph/footnote loop is performed nine
times. If you compile as is, i.e., no imposition, everything works as
expected. But add --mode=imposition to apply imposition and the compilation
fails.

Now decrease the number of iterations from nine to eight and the behaviour
is reversed. The imposition will succeed and the straight compile will
fail. Stranger yet, If you remove the subject structure, compiling with
eight iterations succeeds with or without imposition, and compiling with
nine iterations fails with or without imposition.  This all happens in the
ConTeXt from 2011.07.26. Switching to the ConTeXt from 2012.01.16
everything compiles, but the runs using imposition produce only blank pages.

Regardless of what I try, I cannot get endnotes and imposition to
cooperate. Any help would be greatly appreciated.

\showframe
\doifmode{imposition}
{\setuppapersize[A5,portrait][A4,landscape]
  \setuparranging[2UP,doublesided]}

\setupfootnotes[location={text,none}]

\starttext
   \startsubject[title=First]
 \dorecurse{9}{\input tufte\footnote{The quick brown fox jumps over the
lazy dog.}\par}
   \stopsubject
   \startsubject[title=Second]
 \placefootnotes
   \stopsubject
\stoptext


do you run with --arrange --mode=imposition ?

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


[NTG-context] checking attributes

2012-01-20 Thread Meer, H. van der
Is the following impossible? The aim is checking the value of an attribute on a 
node:

\xmlfilter{#1}{/content[@type ==\whatever]/command(xmlcommon:content)}
It seems the \whatever macro is not expanded.

How to?

Hans van der Meer



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


[NTG-context] Command \thanks from LaTeX

2012-01-20 Thread Wagner Macedo
Hello,

Searching for a \thanks equivalent command on ConTeXt, I ended up on
http://wiki.contextgarden.net/LaTeX_Thanks.

But I didn't like that solution, because the author footnote is placed on a
new area instead the same as text footnotes.

So I made a simple solution, that the author footnotes is placed in the
same area and doesn't interfere on real counter. I want here to share my
solution, below you can see it.

\definestartstop[author]
  [before={\savenumber[footnote]
\resetnumber[footnote]
\start
\let\thanks\footnote
\setupfootnotes[numberconversion=set 2]},
   after={\stop
\restorenumber[footnote]}]

It can be used as that:

\startauthor
  Wagner Macedo\thanks{Brazilian citizen}
\stopauthor

Of course, I could did a \author command, but I generally prefer to use
start/stop blocks.

What do you think? This could be improved?
___
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] checking attributes

2012-01-20 Thread Hans Hagen

On 20-1-2012 16:38, Meer, H. van der wrote:

Is the following impossible? The aim is checking the value of an attribute on a 
node:

\xmlfilter{#1}{/content[@type ==\whatever]/command(xmlcommon:content)}
It seems the \whatever macro is not expanded.

How to?


should work ok so, is \whatever defined?


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


Re: [NTG-context] Problem with letter module

2012-01-20 Thread Romain Diss
Le vendredi 20 janvier 2012, Wolfgang Schuster a écrit :
 Am 20.01.2012 um 00:20 schrieb Romain Diss:
  Le vendredi 20 janvier 2012, Wolfgang Schuster a écrit :
  Am 19.01.2012 um 23:57 schrieb Romain Diss:
  Do you use TeXLive or the ConTeXt Suite (minimals)?
  
  I use the latest beta of the ConTeXt Suite (minimals):
  (...)
  Can show your log file, you should see something like this:
  (...)
  Here is what the log looks like:
  (...)
 The right files are loaded, i was curious because you wrote this earlier:
 
 1. When I run context on a context letter input (like the previous minimal
 example), the log let me suppose that the \usemodule[letter] command loads
 the t-letter.mkii instead of the t-letter.mkiv. Is this the case and why.
 Moreover, t-letter.mkiv goal seems to only print an error message, even if
 my context version is more recent than the one recommended.
 
 t-letter.mkii or t-letter.mkiv aren’t loaded with the context suite, both
 files are only used with texlive 2011 but a recent context doesn’t use
 them.
Excuse me. I think I misunderstood the way the module was loaded.

Just by curiosity, if none of the t-letter.* files are loaded, how does context 
know that it have to load the s-cor-* files when I type \usemodule[letter]?

All the best

-- 
Romain Diss
romain.d...@yahoo.fr
___
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] \externalfigure and file size

2012-01-20 Thread Kip Warner
On Fri, 2012-01-20 at 09:55 +0100, luigi scarso wrote:
 You can also try the reverse way with ipe
 http://ipe7.sourceforge.net/
 and then convert the pdf in svg with inkscape or iperender

Thanks Luigi.

-- 
Kip Warner -- Software Engineer
OpenPGP encrypted/signed mail preferred
http://www.thevertigo.com


signature.asc
Description: This is a digitally signed message part
___
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] \externalfigure and file size

2012-01-20 Thread Kip Warner
On Fri, 2012-01-20 at 10:08 +0100, Hans Hagen wrote:
 There is no such depedency .. actually, i found it rather impossible to 
 get an inkscape running on a headless linux box as there is some 
 depedency on X (last time I tried). In a similar fashion there is no 
 dependency on GhostScript or GraphicMagick or Zint.

So what does ConTeXt do when it typesets an \externalfigure? Does it
always use inkscape, or only sometimes?

-- 
Kip Warner -- Software Engineer
OpenPGP encrypted/signed mail preferred
http://www.thevertigo.com


signature.asc
Description: This is a digitally signed message part
___
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] \externalfigure and file size

2012-01-20 Thread luigi scarso
On Sat, Jan 21, 2012 at 12:04 AM, Kip Warner k...@thevertigo.com wrote:

 On Fri, 2012-01-20 at 09:55 +0100, luigi scarso wrote:
  You can also try the reverse way with ipe
  http://ipe7.sourceforge.net/
  and then convert the pdf in svg with inkscape or iperender

 Thanks Luigi.

Uh uh .. I forget Metapost.
Metapost can ouput svg files.
-- 
luigi
___
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] \externalfigure and file size

2012-01-20 Thread Wagner Macedo
I just tested now. With Inkscape 0.48.2 r9819, I could do the conversion
job on pure console.

But, on the other hand, as nothing is perfect, to install Inkscape, it's
needed many X dependencies.

On 20 January 2012 06:08, Hans Hagen pra...@wxs.nl wrote:

 There is no such depedency .. actually, i found it rather impossible to
 get an inkscape running on a headless linux box as there is some depedency
 on X (last time I tried).
___
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] \externalfigure and file size

2012-01-20 Thread Hans Hagen

On 21-1-2012 00:05, Kip Warner wrote:

On Fri, 2012-01-20 at 10:08 +0100, Hans Hagen wrote:

There is no such depedency .. actually, i found it rather impossible to
get an inkscape running on a headless linux box as there is some
depedency on X (last time I tried). In a similar fashion there is no
dependency on GhostScript or GraphicMagick or Zint.


So what does ConTeXt do when it typesets an \externalfigure? Does it
always use inkscape, or only sometimes?


no, png, jpg and pdf are supported directly (as is mp) but fo rother 
formats it will either try to find a replacement (there is a whole chain 
of lookups) or it will try to run one of the configured converters ... with


\enabletrackers[graphics.*]

you can see what happens



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


Re: [NTG-context] \externalfigure and file size

2012-01-20 Thread luigi scarso
On Sat, Jan 21, 2012 at 1:07 AM, Hans Hagen pra...@wxs.nl wrote:

 On 21-1-2012 00:05, Kip Warner wrote:

 On Fri, 2012-01-20 at 10:08 +0100, Hans Hagen wrote:

 There is no such depedency .. actually, i found it rather impossible to
 get an inkscape running on a headless linux box as there is some
 depedency on X (last time I tried). In a similar fashion there is no
 dependency on GhostScript or GraphicMagick or Zint.


 So what does ConTeXt do when it typesets an \externalfigure? Does it
 always use inkscape, or only sometimes?


 no, png, jpg and pdf are supported directly (as is mp) but fo rother
 formats it will either try to find a replacement (there is a whole chain of
 lookups) or it will try to run one of the configured converters ... with

and swf, even if I have not full tested (basically you can test only with
acroreader 10)

-- 
luigi
___
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] \externalfigure and file size

2012-01-20 Thread Hans Hagen

On 21-1-2012 01:12, luigi scarso wrote:

On Sat, Jan 21, 2012 at 1:07 AM, Hans Hagenpra...@wxs.nl  wrote:


On 21-1-2012 00:05, Kip Warner wrote:


On Fri, 2012-01-20 at 10:08 +0100, Hans Hagen wrote:


There is no such depedency .. actually, i found it rather impossible to
get an inkscape running on a headless linux box as there is some
depedency on X (last time I tried). In a similar fashion there is no
dependency on GhostScript or GraphicMagick or Zint.



So what does ConTeXt do when it typesets an \externalfigure? Does it
always use inkscape, or only sometimes?



no, png, jpg and pdf are supported directly (as is mp) but fo rother
formats it will either try to find a replacement (there is a whole chain of
lookups) or it will try to run one of the configured converters ... with


and swf, even if I have not full tested (basically you can test only with
acroreader 10)


sure, a few of those 'supported media types' are also dealt with (in 
fact I think that one can embed svg in a pdf document given some plugin


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
___


Re: [NTG-context] Problem with letter module

2012-01-20 Thread Hans Hagen

On 20-1-2012 22:44, Romain Diss wrote:


Just by curiosity, if none of the t-letter.* files are loaded, how does context
know that it have to load the s-cor-* files when I type \usemodule[letter]?


cont-fil.mkiv

(one of the oldest features around)

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
___


Re: [NTG-context] \externalfigure and file size

2012-01-20 Thread Marco
On 2012-01-20 Kip Warner k...@thevertigo.com wrote:

 So what does ConTeXt do when it typesets an \externalfigure?
 Does it always use inkscape, or only sometimes?

If the  image type is  supported by the TeX  engine (jpeg,
png, pdf, mps) it is directly included. SVG files inkscape
is  called to  convert  the  SVG to  PDF.  For EPS  images
ghostscript is used:

strace results:

execve(/usr/bin/gs, [gs, -q, -sDEVICE=pdfwrite,
-dNOPAUSE, -dNOCACHE, -dBATCH,
-dAutoRotatePages=/None, -dPDFSETTINGS=/prepress,
-dEPSCrop, -sOutputFile=m_k_i_v_graph.pdf,
graph.eps, -c, quit], [/* 55 vars */]) 

Marco


___
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] \externalfigure and file size

2012-01-20 Thread Kip Warner
On Sat, 2012-01-21 at 01:22 +0100, Marco wrote:
 On 2012-01-20 Kip Warner k...@thevertigo.com wrote:
 
  So what does ConTeXt do when it typesets an \externalfigure?
  Does it always use inkscape, or only sometimes?
 
 If the  image type is  supported by the TeX  engine (jpeg,
 png, pdf, mps) it is directly included. SVG files inkscape
 is  called to  convert  the  SVG to  PDF.  For EPS  images
 ghostscript is used:
 
 strace results:
 
 execve(/usr/bin/gs, [gs, -q, -sDEVICE=pdfwrite,
   -dNOPAUSE, -dNOCACHE, -dBATCH,
   -dAutoRotatePages=/None, -dPDFSETTINGS=/prepress,
   -dEPSCrop, -sOutputFile=m_k_i_v_graph.pdf,
   graph.eps, -c, quit], [/* 55 vars */]) 

Right, but since the average end user probably won't know that, doesn't
that still suggest Inkscape be listed as a dependency?

-- 
Kip Warner -- Software Engineer
OpenPGP encrypted/signed mail preferred
http://www.thevertigo.com


signature.asc
Description: This is a digitally signed message part
___
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] \externalfigure and file size

2012-01-20 Thread Marco
On 2012-01-20 Kip Warner k...@thevertigo.com wrote:

 On Sat, 2012-01-21 at 01:22 +0100, Marco wrote:
  On 2012-01-20 Kip Warner k...@thevertigo.com wrote:
  
   So what does ConTeXt do when it typesets an \externalfigure?
   Does it always use inkscape, or only sometimes?
  
  If the  image type is  supported by the TeX  engine (jpeg,
  png, pdf, mps) it is directly included. SVG files inkscape
  is  called to  convert  the  SVG to  PDF.  For EPS  images
  ghostscript is used:
  
  strace results:
  
  execve(/usr/bin/gs, [gs, -q, -sDEVICE=pdfwrite,
  -dNOPAUSE, -dNOCACHE, -dBATCH,
  -dAutoRotatePages=/None, -dPDFSETTINGS=/prepress,
  -dEPSCrop, -sOutputFile=m_k_i_v_graph.pdf,
  graph.eps, -c, quit], [/* 55 vars */]) 
 
 Right, but since the average end user probably won't know that, doesn't
 that still suggest Inkscape be listed as a dependency?

As  I  mentioned before  99.9%  of  the system  work  fine
without additional  programs. You need inkscape  only when
you  want to  include  SVG images.  Having  inkscape as  a
dependency  means a  huge  bunch of  data  and disk  space
(inkscape incl. all dependencies like X,…).

However, these external helpers (like ghostscript as well)
should be listed as a recommendation or suggestion [not as
dependency]).  In  that case  the  user  is notified  that
he/she might get a benefit installing these programs.

Marco


___
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] \externalfigure and file size

2012-01-20 Thread Kip Warner
On Sat, 2012-01-21 at 01:42 +0100, Marco wrote:
 On 2012-01-20 Kip Warner k...@thevertigo.com wrote:
 
  On Sat, 2012-01-21 at 01:22 +0100, Marco wrote:
   On 2012-01-20 Kip Warner k...@thevertigo.com wrote:
   
So what does ConTeXt do when it typesets an \externalfigure?
Does it always use inkscape, or only sometimes?
   
   If the  image type is  supported by the TeX  engine (jpeg,
   png, pdf, mps) it is directly included. SVG files inkscape
   is  called to  convert  the  SVG to  PDF.  For EPS  images
   ghostscript is used:
   
   strace results:
   
   execve(/usr/bin/gs, [gs, -q, -sDEVICE=pdfwrite,
 -dNOPAUSE, -dNOCACHE, -dBATCH,
 -dAutoRotatePages=/None, -dPDFSETTINGS=/prepress,
 -dEPSCrop, -sOutputFile=m_k_i_v_graph.pdf,
 graph.eps, -c, quit], [/* 55 vars */]) 
  
  Right, but since the average end user probably won't know that, doesn't
  that still suggest Inkscape be listed as a dependency?
 
 No, not as dependency. As  I mentioned before 99.9% of the
 system  work fine  without additional  programs. You  need
 inkscape only when you want  to include SVG images. Having
 inkscape as  a dependency means  a huge bunch of  data and
 disk space (inkscape incl. all dependencies like X,¿).
 
 However, these external helpers (like ghostscript as well)
 should be  listed as  a recommendation  [not dependency]),
 that  way the  user is  notified that  he/she might  get a
 benefit installing these programs.
 
 Marco
 

Understood. I've copied the package maintainer for a popular ConTeXt
Ubuntu PPA.

-- 
Kip Warner -- Software Engineer
OpenPGP encrypted/signed mail preferred
http://www.thevertigo.com


signature.asc
Description: This is a digitally signed message part
___
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] \externalfigure and file size

2012-01-20 Thread Hans Hagen

On 21-1-2012 01:27, Kip Warner wrote:

On Sat, 2012-01-21 at 01:22 +0100, Marco wrote:

On 2012-01-20 Kip Warnerk...@thevertigo.com  wrote:


So what does ConTeXt do when it typesets an \externalfigure?
Does it always use inkscape, or only sometimes?


If the  image type is  supported by the TeX  engine (jpeg,
png, pdf, mps) it is directly included. SVG files inkscape
is  called to  convert  the  SVG to  PDF.  For EPS  images
ghostscript is used:

strace results:

execve(/usr/bin/gs, [gs, -q, -sDEVICE=pdfwrite,
-dNOPAUSE, -dNOCACHE, -dBATCH,
-dAutoRotatePages=/None, -dPDFSETTINGS=/prepress,
-dEPSCrop, -sOutputFile=m_k_i_v_graph.pdf,
graph.eps, -c, quit], [/* 55 vars */])


Right, but since the average end user probably won't know that, doesn't
that still suggest Inkscape be listed as a dependency?


no, because not all users use svg (just an not all users use fonts 
defined in type-* files) and also because inkscape is close to 
impossible to install without x present which would render context 
'unuseable due to a depency not being resolved'


(in fact there is then also a dependency on a viewer)

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
___


Re: [NTG-context] \externalfigure and file size

2012-01-20 Thread Hans Hagen

On 21-1-2012 01:40, Marco wrote:


However, these external helpers (like ghostscript as well)
should be listed as a recommendation or suggestion [not as
dependency]).  In  that case  the  user  is notified  that
he/she might get a benefit installing these programs.


maybe a wiki page is a good start for that

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


Re: [NTG-context] \externalfigure and file size

2012-01-20 Thread luigi scarso
On Sat, Jan 21, 2012 at 1:27 AM, Kip Warner k...@thevertigo.com wrote:

 Right, but since the average end user probably won't know that, doesn't
 that still suggest Inkscape be listed as a dependency?

 hm,  no.
Suppose this situation: me and you agree on a context beta version and a
pdf reader and you send me your tex file with
1) a png/jpeg image or a pdf file as externalfigure. Then my pdf and your
pdf must be the same, and on average the reader will show the same result.
Otherwise probably is a bug.
2) a swf. Then my pdf and your pdf must be the same, but probably the
reader will not show the same result -- basically only acroread is able to
show swf inside a pdf, and it depends to the OS and version
3) a svg image. PDF spec. doesn't support SVG, so we must also agree on the
same program to convert the svg into a bitmap or vector image, and this is
a problem: as you have seen, the conversion require a bit of experience.
After all, it's not strange if inkscape 0.40 and 0.48 display the same svg
in different way --- and the same for the pdfs.

Actually, only an expert user can use inkscape to automatically convert an
svg to pdf/png without (appreciable) errors, and this kind of user is also
able to install the correct version of inkscape (which is much easier to
install under windows then linux,btw). So, if you are creating a svg by
tourself, it's better to check that the pdf and png are the same if you
want to be sure that your image will be printed/display correctly --- there
aren't so many programs that completely support the svg standard.

ConTeXt then helps this kind of expert user because they are able a
priori  to understand if a svg image is problematic or not .


-- 
luigi
___
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] \externalfigure and file size

2012-01-20 Thread Wagner Macedo
On Debian Packages, at least, we can declare, basically, 3 levels of
dependencies, according to
http://www.debian.org/doc/debian-policy/ch-relationships.html#s-binarydeps

1) Depends - absolute dependency. Or else, packages that is strictly
necessary to works well.
2) Recommends - strong, but not absolute dependency.
3) Suggests - used to declare that one package may be more useful with one
or more others.

So, I think Inkscape would fit well as 'context' Suggests.

--
Wagner Macedo


On 20 January 2012 21:54, Hans Hagen pra...@wxs.nl wrote:

 no, because not all users use svg (just an not all users use fonts defined
 in type-* files) and also because inkscape is close to impossible to
 install without x present which would render context 'unuseable due to a
 depency not being resolved'
___
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
___