Skip to content

Commit ee96a37

Browse files
committed
Rename proto2 to ggproto
1 parent 7d4c556 commit ee96a37

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

86 files changed

+196
-196
lines changed

DESCRIPTION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ URL: http://ggplot2.org, https://github.com/hadley/ggplot2
4141
BugReports: https://github.com/hadley/ggplot2/issues
4242
LazyData: true
4343
Collate:
44-
'proto2.r'
44+
'ggproto.r'
4545
'aaa-.r'
4646
'aaa-constants.r'
4747
'aes-calculated.r'

NAMESPACE

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
# Generated by roxygen2 (4.1.1): do not edit by hand
22

3-
S3method("$",proto2)
3+
S3method("$",ggproto)
44
S3method("+",gg)
55
S3method("[",uneval)
6-
S3method("[[",proto2)
6+
S3method("[[",ggproto)
77
S3method(as.character,uneval)
8-
S3method(as.list,proto2)
8+
S3method(as.list,ggproto)
99
S3method(autoplot,default)
1010
S3method(coord_aspect,default)
1111
S3method(coord_aspect,fixed)
@@ -73,8 +73,8 @@ S3method(facet_vars,null)
7373
S3method(facet_vars,wrap)
7474
S3method(finite.cases,data.frame)
7575
S3method(format,facet)
76-
S3method(format,proto2)
77-
S3method(format,proto2_method)
76+
S3method(format,ggproto)
77+
S3method(format,ggproto_method)
7878
S3method(fortify,"NULL")
7979
S3method(fortify,Line)
8080
S3method(fortify,Lines)
@@ -130,8 +130,8 @@ S3method(predictdf,loess)
130130
S3method(print,element)
131131
S3method(print,facet)
132132
S3method(print,ggplot)
133-
S3method(print,proto2)
134-
S3method(print,proto2_method)
133+
S3method(print,ggproto)
134+
S3method(print,ggproto_method)
135135
S3method(print,rel)
136136
S3method(print,scale)
137137
S3method(print,theme)
@@ -282,6 +282,7 @@ export(ggplot)
282282
export(ggplotGrob)
283283
export(ggplot_build)
284284
export(ggplot_gtable)
285+
export(ggproto)
285286
export(ggsave)
286287
export(ggtitle)
287288
export(guide_colorbar)
@@ -291,7 +292,7 @@ export(guides)
291292
export(is.coord)
292293
export(is.facet)
293294
export(is.ggplot)
294-
export(is.proto2)
295+
export(is.ggproto)
295296
export(is.theme)
296297
export(label_both)
297298
export(label_bquote)
@@ -316,7 +317,6 @@ export(position_jitter)
316317
export(position_jitterdodge)
317318
export(position_nudge)
318319
export(position_stack)
319-
export(proto2)
320320
export(qplot)
321321
export(quickplot)
322322
export(rel)

NEWS

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -62,8 +62,8 @@ ggplot2 1.0.1.9xxx
6262

6363
* `lims()` makes it easy to set the limits of any axis (#1138).
6464

65-
* Switched away from proto and reference class objects to proto2. This makes it
66-
easier to extend ggplot2, because proto2 supports clean cross-package
65+
* Switched away from proto and reference class objects to ggproto. This makes it
66+
easier to extend ggplot2, because ggproto supports clean cross-package
6767
inheritance.
6868

6969
* Fixed segment annotations not transforming with scales (@BrianDiggs, #859)

R/aaa-.r

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
#' @include proto2.r
1+
#' @include ggproto.r
22
NULL
33

4-
#' Base proto2 classes for ggplot2
4+
#' Base ggproto classes for ggplot2
55
#'
66
#' If you are creating a new geom, stat or positions in another package, you'll
77
#' need to extend from \code{ggplot2::Geom}, \code{ggplot2::Stat} or
@@ -10,10 +10,10 @@ NULL
1010
#' @export Geom Stat Position
1111
#' @aliases Geom Stat Position
1212
#' @keywords internal
13-
#' @name ggplot2-proto2
13+
#' @name ggplot2-ggproto
1414
NULL
1515

16-
TopLevel <- proto2("TopLevel", NULL,
16+
TopLevel <- ggproto("TopLevel", NULL,
1717
find = function(self, name) {
1818
# Convert name to camel case
1919
name <- camelize(name, first = TRUE)

R/annotation-custom.r

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ annotation_custom <- function (grob, xmin = -Inf, xmax = Inf, ymin = -Inf, ymax
5555
)
5656
}
5757

58-
GeomCustomAnn <- proto2("GeomCustomAnn", Geom,
58+
GeomCustomAnn <- ggproto("GeomCustomAnn", Geom,
5959
draw_groups = function(data, scales, coordinates, grob, xmin, xmax,
6060
ymin, ymax, ...) {
6161
if (!inherits(coordinates, "cartesian")) {

R/annotation-logticks.r

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -108,7 +108,7 @@ annotation_logticks <- function (base = 10, sides = "bl", scaled = TRUE,
108108
)
109109
}
110110

111-
GeomLogticks <- proto2("GeomLogticks", Geom,
111+
GeomLogticks <- ggproto("GeomLogticks", Geom,
112112
draw_groups = function(data, scales, coordinates, base = 10, sides = "bl",
113113
scaled = TRUE, short = unit(0.1, "cm"), mid = unit(0.2, "cm"),
114114
long = unit(0.3, "cm"), ...)

R/annotation-map.r

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ annotation_map <- function(map, ...) {
4242
)
4343
}
4444

45-
GeomAnnotationMap <- proto2("GeomAnnotationMap", GeomMap,
45+
GeomAnnotationMap <- ggproto("GeomAnnotationMap", GeomMap,
4646
draw_groups = function(data, scales, coordinates, map, ...) {
4747
# Munch, then set up id variable for polygonGrob -
4848
# must be sequential integers

R/annotation-raster.r

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ annotation_raster <- function (raster, xmin, xmax, ymin, ymax,
6262

6363
}
6464

65-
GeomRasterAnn <- proto2("GeomRasterAnn", GeomRaster,
65+
GeomRasterAnn <- ggproto("GeomRasterAnn", GeomRaster,
6666
reparameterise = function(df, params) df,
6767

6868
draw_groups = function(data, scales, coordinates, raster, xmin, xmax,

R/geom-.r

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#' @include legend-draw.r
22

3-
Geom <- proto2("Geom", TopLevel,
3+
Geom <- ggproto("Geom", TopLevel,
44
type = "geom",
55

66
required_aes = c(),

R/geom-abline.r

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ geom_abline <- function(mapping = NULL, data = NULL, show_guide = FALSE, ...,
100100
)
101101
}
102102

103-
GeomAbline <- proto2("GeomAbline", Geom,
103+
GeomAbline <- ggproto("GeomAbline", Geom,
104104
draw = function(data, scales, coordinates, ...) {
105105
ranges <- coord_range(coordinates, scales)
106106

0 commit comments

Comments
 (0)