On Tuesday 04 March 2008 (12:34:47), Peter Dalgaard wrote:
> Martin Kaffanke wrote:
> > Hi there!
> >
> > I use an gnome-terminal for using R.  When I resize the termial to the
> > maximum size, R uses only the left side of the window.  Can I tell R to
> > use the whole window somehow?
>
> This seems to do it:
>
> options(width=Sys.getenv("COLUMNS"))
>
> (Surprisingly, at least to me, the COLUMNS environment variable appears
> to be automagically updated by gnome-terminal even after R is started. I
> was expecting to have to play with system("tset") and suchlike.)

That seems to work also with KDE's "Konsole". 

It may be worthwile considering
to implement some automatic width-adjustment like:

.adjustwidth <- function(...){
        options(width=Sys.getenv("COLUMNS"))
        TRUE
}

addTaskCallback(.adjustwidth)

After that, the output width is adapted to the actual terminal width
each time one hits return.


Just my 20 cents.
Best,
Martin

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to