The R Project SVN R

Rev

Rev 25278 | Rev 31995 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 25278 Rev 25323
Line 1... Line 1...
1
\name{grid.frame}
1
\name{grid.frame}
2
\alias{grid.frame}
2
\alias{grid.frame}
3
%- Also NEED an `\alias' for EACH other topic documented here.
-
 
4
\title{ Create a Frame for Packing Objects }
3
\title{ Create a Frame for Packing Objects }
5
\description{
4
\description{
6
  This function, together with \code{grid.pack} is part of a
5
  This function, together with \code{grid.pack} is part of a
7
  GUI-builder-like interface to constructing graphical images.
6
  GUI-builder-like interface to constructing graphical images.
8
  The idea is that you create a frame with this function then
7
  The idea is that you create a frame with this function then
9
  use \code{grid.pack} to pack objects into the frame.
8
  use \code{grid.pack} to pack objects into the frame.
10
}
9
}
11
\usage{
10
\usage{
12
grid.frame(layout=NULL, vp=NULL, gp=gpar(), draw=FALSE)
11
grid.frame(layout=NULL, vp=NULL, gp=gpar(), draw=FALSE)
13
}
12
}
14
%- maybe also `usage' for other objects documented here.
-
 
15
\arguments{
13
\arguments{
16
  \item{layout}{ A Grid layout, or NULL. This can be used to initialise
14
  \item{layout}{ A Grid layout, or NULL. This can be used to initialise
17
    the frame with a number of rows and columns, with initial widths
15
    the frame with a number of rows and columns, with initial widths
18
    and heights, etc. }
16
    and heights, etc. }
19
  \item{vp}{ An object of class \code{viewport}, or NULL. }
17
  \item{vp}{ An object of class \code{viewport}, or NULL. }
Line 26... Line 24...
26
}
24
}
27
\value{
25
\value{
28
  An object of class \code{"grob"}.
26
  An object of class \code{"grob"}.
29
}
27
}
30
\author{ Paul Murrell }
28
\author{ Paul Murrell }
-
 
29
\seealso{
31
\seealso{ \code{\link{grid.pack}} }
30
  \code{\link{grid.pack}}
32
 
31
}
33
\examples{
32
\examples{
34
grid.newpage()
33
grid.newpage()
35
gf <- grid.frame(draw=TRUE)
34
gf <- grid.frame(draw=TRUE)
36
grid.pack(gf, grid.rect(draw=FALSE, gp=gpar(fill="grey")))
35
grid.pack(gf, grid.rect(draw=FALSE, gp=gpar(fill="grey")))
37
grid.pack(gf, grid.text("hi there", draw=FALSE), side="right")
36
grid.pack(gf, grid.text("hi there", draw=FALSE), side="right")
38
}
37
}
39
\keyword{ dplot }%-- one or more ...
38
\keyword{dplot}