You are viewing a plain text version of this content. The canonical link for it is here.
Posted to batik-users@xmlgraphics.apache.org by Andreas Neumann <a....@carto.net> on 2007/10/29 21:27:06 UTC

printing from squiggle, getting rid of the printer margins

Hello,

I have a small problem with printing from Squiggle.

I often generate content that needs to be very precise when it comes to 
scale. I want to use the printing dialogue in squiggle. However, 
Squiggle insists on scaling the content down (using the printer margins) 
which reduces the whole graphics. As an example, I specify the following 
root element like follows:

<svg xmlns="http://www.w3.org/2000/svg" 
xmlns:xlink="http://www.w3.org/1999/xlink" width="210mm" height="297mm" 
viewBox="0 0 210 297">

and no content is running into the printer margin, so I end up with a 
scaling of 95.8xxx

Is there a trick for avoiding such scaling? If not, would it be possible 
to modify the printing dialogue and add a scaling option or a checkbox 
to print at 100%/no scaling? Or a checkbox that says something "don't 
use printer margins"

Thanks a lot,
Andreas

-- 
--
Andreas Neumann
Böschacherstrasse 6
CH-8624 Grüt (Gossau ZH)
Switzerland
Phone: ++41-44-2736668
Email: a.neumann@carto.net

Web: http://www.carto.net/neumann/
SVG Examples: http://www.carto.net/papers/svg/samples/
SVG.Open: http://www.svgopen.org/

---------------------------------------------------------------------
To unsubscribe, e-mail: batik-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: batik-users-help@xmlgraphics.apache.org


Re: printing from squiggle, getting rid of the printer margins

Posted by th...@kodak.com.
Hi Andreas,

Andreas Neumann <a....@carto.net> wrote on 10/29/2007 04:27:06 PM:

> I often generate content that needs to be very precise when it comes to 
> scale. I want to use the printing dialogue in squiggle. However, 
> Squiggle insists on scaling the content down (using the printer margins) 

> which reduces the whole graphics.

[...]

> Is there a trick for avoiding such scaling?

   The PrintTranscoder has a 'SCALE_TO_PAGE' Hint
that I believe turns off this scaling.  You can also
set the Print Margins through hints.

   Actually, I thought the print dialogs had a way that you
could specify the print margins yourself.

> If not, would it be possible 
> to modify the printing dialogue and add a scaling option or a checkbox 
> to print at 100%/no scaling? Or a checkbox that says something "don't 
> use printer margins"

    So this is trickier since we use the JDK provided print dialogs.
There is probably a way to add such a checkbox but I don't know what
it is.  The other option would be for us to add a third(!) print dialog
just to present such options...

    Another option would be to use the PrintTranscoder directly,
where you can set the above hints on the command line.