help-octave
[Top][All Lists]
Advanced

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

Re: plot orientation feature; plot filling page


From: Ben Abbott
Subject: Re: plot orientation feature; plot filling page
Date: Wed, 18 Nov 2009 07:52:50 -0500

On Nov 18, 2009, at 12:37 AM, octaveUser wrote:

> I'm trying to do something simple, print a file to a certain paper size and
> have the plot fill the whole page. In matlab this is done in the following
> way: >orient tall, will fill a portrait page, >orient ladscape will flip the
> plot 90degrees and fill the page.  Octave prints with the plot only filling
> a box in the center of the page with large margins at the top and bottom.
> The plotting to pdf finally works great, it just seems like it would be
> really usefull to have the plot fill the page. I understand I have to
> interact with gnuplot to get this done. This is the number one feature
> request I have, a simple way to make a plot fill a page, and rotate the plot
> and have it fit the page. Was there an easy way to do this I missed. Thanks,
> octave is wonderful.   

Currently Octave's orient() function does not recognize the "tall" option, and 
the "landscape", "portrait" options do not flip the "papersize" (1x2) vector. 
So there are both a missing feature and a bug.

To do what you want,

# equivalent to "orient tall"
papersize = get (gcf, "papersize"); # presently the paper units must be inches
border = 0.25;
set (gcf, "paperposition", [border, border, (papersize - 2*border)])

# To change orientation
orientation = get (gcf, "paperorientation");
papersize = get (gcf, "papersize");
paperposition = get (gcf, "paperposition");
set (gcf, "paperposition", paperposition([2, 1, 4, 3]);
set (gcf, "papersize", papersize ([2, 1]);
set (gcf, "paperorientation", setdiff ({"landscape", "portrait"}, orientation);

I'll prepare a changeset today.

Ben



reply via email to

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