Debian Codegraph @

man/brushOpts.Rd

raw
1 % Generated by roxygen2: do not edit by hand
2 % Please edit documentation in R/image-interact-opts.R
3 \name{brushOpts}
4 \alias{brushOpts}
5 \title{Create an object representing brushing options}
6 \usage{
7 brushOpts(
8 id,
9 fill = "#9cf",
10 stroke = "#036",
11 opacity = 0.25,
12 delay = 300,
13 delayType = c("debounce", "throttle"),
14 clip = TRUE,
15 direction = c("xy", "x", "y"),
16 resetOnNew = FALSE
17 )
18 }
19 \arguments{
20 \item{id}{Input value name. For example, if the value is \code{"plot_brush"},
21 then the coordinates will be available as \code{input$plot_brush}. Multiple
22 \code{imageOutput}/\code{plotOutput} calls may share the same \code{id}
23 value; brushing one image or plot will cause any other brushes with the
24 same \code{id} to disappear.}
25
26 \item{fill}{Fill color of the brush. If \code{'auto'}, it derives from the link
27 color of the plot's HTML container (if \strong{thematic} is enabled, and \code{accent}
28 is a non-\code{'auto'} value, that color is used instead).}
29
30 \item{stroke}{Outline color of the brush. If \code{'auto'}, it derives from the
31 foreground color of the plot's HTML container (if \strong{thematic} is enabled,
32 and \code{fg} is a non-\code{'auto'} value, that color is used instead).}
33
34 \item{opacity}{Opacity of the brush}
35
36 \item{delay}{How long to delay (in milliseconds) when debouncing or
37 throttling, before sending the brush data to the server.}
38
39 \item{delayType}{The type of algorithm for limiting the number of brush
40 events. Use \code{"throttle"} to limit the number of brush events to one
41 every \code{delay} milliseconds. Use \code{"debounce"} to suspend events
42 while the cursor is moving, and wait until the cursor has been at rest for
43 \code{delay} milliseconds before sending an event.}
44
45 \item{clip}{Should the brush area be clipped to the plotting area? If FALSE,
46 then the user will be able to brush outside the plotting area, as long as
47 it is still inside the image.}
48
49 \item{direction}{The direction for brushing. If \code{"xy"}, the brush can be
50 drawn and moved in both x and y directions. If \code{"x"}, or \code{"y"},
51 the brush wil work horizontally or vertically.}
52
53 \item{resetOnNew}{When a new image is sent to the browser (via
54 \code{\link[=renderImage]{renderImage()}}), should the brush be reset? The default,
55 \code{FALSE}, is useful if you want to update the plot while keeping the
56 brush. Using \code{TRUE} is useful if you want to clear the brush whenever
57 the plot is updated.}
58 }
59 \description{
60 This generates an object representing brushing options, to be passed as the
61 \code{brush} argument of \code{\link[=imageOutput]{imageOutput()}} or
62 \code{\link[=plotOutput]{plotOutput()}}.
63 }
64 \seealso{
65 \code{\link[=clickOpts]{clickOpts()}} for clicking events.
66 }