Skip to content

Commit c51164c

Browse files
committed
Update the documentation for the overlay position
1 parent 62d9663 commit c51164c

5 files changed

Lines changed: 51 additions & 13 deletions

File tree

R/funs.R

Lines changed: 19 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
#' @description
44
#' To specify the position when creating an overlay object that will be attached to BPMN \code{Shape} elements in the diagram.
55
#'
6-
#' \code{overlay_shape_position} includes the following positions:
6+
#' @section \code{overlay_shape_position} includes the following positions:
77
#'
88
#' - \code{"top-left"}
99
#' - \code{"top-right"}
@@ -14,8 +14,16 @@
1414
#' - \code{"middle-left"}
1515
#' - \code{"middle-right"}
1616
#'
17+
#' @details
1718
#' Use these constants as the \code{position} argument in the \code{\link{create_overlay}} function.
1819
#'
20+
#' @examples
21+
#' # Create an overlay at the top-left corner of a shape
22+
#' overlay <- create_overlay(elementId = 1, label = "My label", position = overlay_shape_position[1])
23+
#'
24+
#' @seealso
25+
#' \code{\link{create_overlay}}
26+
#'
1927
#' @export
2028
overlay_shape_position <-
2129
c(
@@ -34,13 +42,21 @@ overlay_shape_position <-
3442
#' @description
3543
#' To specify the position when creating an overlay object that will be attached to BPMN \code{Edge} elements in the diagram.
3644
#'
37-
#' \code{overlay_edge_position} includes the following positions:
45+
#' @section \code{overlay_edge_position} includes the following positions:
3846
#' - \code{"start"}
3947
#' - \code{"end"}
4048
#' - \code{"middle"}
4149
#'
50+
#' @details
4251
#' Use these constants as the \code{position} argument in the \code{\link{create_overlay}} function.
43-
#'
52+
#'
53+
#' @examples
54+
#' # Create an overlay at the starting point of an edge
55+
#' overlay <- create_overlay(elementId = 1, label = "My label", position = overlay_edge_position[1])
56+
#'
57+
#' @seealso
58+
#' \code{\link{create_overlay}}
59+
#'
4460
#' @export
4561
overlay_edge_position <- c("start", "end", "middle")
4662

man/create_overlay.Rd

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

man/create_overlay_style.Rd

Lines changed: 4 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

man/overlay_edge_position.Rd

Lines changed: 13 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

man/overlay_shape_position.Rd

Lines changed: 13 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)