Skip to content

Commit 2a01b56

Browse files
committed
structure scale-.R with section titles
1 parent b17cf00 commit 2a01b56

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

R/scale-.R

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -460,6 +460,7 @@ is.scale <- function(x) inherits(x, "Scale")
460460
#' `self$rescaler`), `minor` (the rescaled value of `minor_source`, ignoring
461461
#' `self$rescaler`), `range` (the range that was passed in to `break_info()`),
462462
#' `labels` (the label values, one for each element in `breaks`).
463+
# Scale -------------------------------------------------------------------
463464
#'
464465
#' - `axis_order()` One of `c("primary", "secondary")` or `c("secondary", "primary")`
465466
#'
@@ -664,6 +665,7 @@ has_default_transform <- function(scale) {
664665
transform_method <- environment(scale$transform)$f
665666
identical(default_transform, transform_method) || identical(identity, transform_method)
666667
}
668+
# ScaleContinuous ---------------------------------------------------------
667669

668670
#' @rdname ggplot2-ggproto
669671
#' @format NULL
@@ -947,6 +949,7 @@ ScaleContinuous <- ggproto("ScaleContinuous", Scale,
947949
}
948950
)
949951

952+
# ScaleDiscrete -----------------------------------------------------------
950953

951954
#' @rdname ggplot2-ggproto
952955
#' @format NULL
@@ -1178,6 +1181,8 @@ ScaleDiscrete <- ggproto("ScaleDiscrete", Scale,
11781181
}
11791182
)
11801183

1184+
# ScaleBinned -------------------------------------------------------------
1185+
11811186
#' @rdname ggplot2-ggproto
11821187
#' @format NULL
11831188
#' @usage NULL
@@ -1420,6 +1425,7 @@ ScaleBinned <- ggproto("ScaleBinned", Scale,
14201425
}
14211426
)
14221427

1428+
# Helpers -----------------------------------------------------------------
14231429
# In place modification of a scale to change the primary axis
14241430
scale_flip_position <- function(scale) {
14251431
scale$position <- opposite_position(scale$position)

0 commit comments

Comments
 (0)