Description Usage Arguments Examples
The gseparator
widget provides a horizontal or vertical
line to visually divide child components of its parent
container. In addition to box containers this can be used within
toolbars (where one uses parent
and not container
).
1 2 3 | gseparator(horizontal = TRUE, container = NULL, ..., toolkit = guiToolkit())
.gseparator(toolkit, horizontal = TRUE, container = NULL, ...)
|
horizontal |
Logical. Is separator drawn horizontally? |
container |
A parent container. When a widget is created it can be incorporated into the widget heirarchy by passing in a parent container at construction time. (For some toolkits this is not optional, e.g. gWidgets2tcltk or gWidgets2WWW2.) |
... |
These values are passed to the |
toolkit |
Each widget constructor is passed in the toolkit it
will use. This is typically done using the default, which will
lookup the toolkit through |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 | ## Not run:
w <- gwindow("Within page", visible=FALSE)
g <- gvbox(container=w)
glabel("Lorem ipsum ...", cont=g)
gseparator(cont=g)
bg <- ggroup(cont=g); addSpring(bg)
gbutton("dismiss", container=bg, handler=function(h,...) dispose(w))
visible(w) <- TRUE
w1 <- gwindow("within layout", visible=FALSE)
lyt <- glayout(container=w1)
lyt[1,1] <- "label"
lyt[2,1:2] <- gseparator(container=lyt)
lyt[3,2] <- "asdf"
visible(w1) <- TRUE
w2 <- gwindow("Within toolbar", visible=FALSE)
l <- list(file=gaction("File", parent=w2),
sep=gseparator(parent=w2),
quit=gaction("quit", parent=w2))
gtoolbar(l, cont=w2)
glabel("Lorem ipsum ...", container=w2)
visible(w2) <- TRUE
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.