help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: control margins for output graphics


From: CdeMills
Subject: Re: control margins for output graphics
Date: Thu, 13 Oct 2011 00:32:52 -0700 (PDT)

fv2005 wrote:
> 
> Hi!
> How can I control the edges of an image saved with the command "print"?
> Obvoiusly, i can crop that image latter, but i want to have all
> graphics at same size, and cropping by hand don't give me desired
> result.
> 

Simple. Thanks to previous posts on this ML, here is a way to do:
set (0, "defaultfigurepapertype", "a4");
set (0, "defaultfigurepapersize", [210 297]/25.4);
set (0, "defaultfigurepaperposition", [10 10 190 277]/25.4);

The two first lines set the paper size to European A4 210x297 mm; you may
skip that if you want to use US letter size. The third line set the margins:
bottom right (x, y) - top left (x, y). In this case, each margin is 10 mm;
if you want a half inch, simply put
set (0, "defaultfigurepaperposition", [.5 .5 7.5 10]);
Those commands must occur before any figure is opened. There are set at the
root of the graphic objects tree; each new figure will inherit from it.

Regards

Pascal

--
View this message in context: 
http://octave.1599824.n4.nabble.com/control-margins-for-output-graphics-tp3899322p3900774.html
Sent from the Octave - General mailing list archive at Nabble.com.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]