Skip to content

Commit

Permalink
even more flags and Rmd regeneration
Browse files Browse the repository at this point in the history
  • Loading branch information
ErdaradunGaztea committed Jun 25, 2024
1 parent 5477fc5 commit 0d9a114
Show file tree
Hide file tree
Showing 9 changed files with 47 additions and 14 deletions.
2 changes: 1 addition & 1 deletion NEWS.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# gglgbtq (development version)

* Added `scale_color_lgbtq()` and `scale_fill_lgbtq()` for convenience.
* Implemented the following palettes: `acesthetic`, `analterous`, `asensual`, `ace_spectrum`, `aro_spectrum`, `aroace`, `androsexual`, `gynesexual`, `helian`, `lunarian`, `solarian`, `stellarian`, `amatopunk`, `bear`, `butch`, `femme`, `otter`.
* Implemented the following palettes: `acesthetic`, `analterous`, `asensual`, `ace_spectrum`, `aro_spectrum`, `aroace`, `androsexual`, `gynesexual`, `abrosexual`, `helian`, `lunarian`, `solarian`, `stellarian`, `amatopunk`, `bear`, `butch`, `femme`, `otter`, `queerhet`.

# gglgbtq 0.1.1

Expand Down
7 changes: 7 additions & 0 deletions R/data.R
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,9 @@ pride_data <- list(
gynesexual = list(
colors = c("#F3A9B6", "#903F2A", "#5A953B")
),
abrosexual = list(
colors = c("#37CBBD", "#95E9B1", "#FFFFFF", "#FEA396", "#F35777")
),
lesbian_7 = list(
colors = c("#A60061", "#B95594", "#D162A8", "#FFFFFF", "#E5ADD1", "#C64D53", "#8C1801")
),
Expand Down Expand Up @@ -124,5 +127,9 @@ pride_data <- list(
),
otter = list(
colors = c("#23A8FA", "#9AD7FC", "#FFFFFF", "#B4B4B4", "#2A2A2A")
),
# Uncategorized
queerhet = list(
colors = c("#4E8492", "#6CCB99", "#727D6E", "#DAC686", "#B86962")
)
)
1 change: 1 addition & 0 deletions R/themes-extract.R
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ extract_theme <- function(palette) {
"intersex" = ,
"pansexual" = ,
"philadelphia" = ,
"queerhet" = ,
"rainbow" = theme_lgbtq_white,
"agender" = theme_agender,
"demiboy" = theme_demiboy,
Expand Down
11 changes: 6 additions & 5 deletions README.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -54,15 +54,15 @@ data <- data.frame(
ggplot(data, aes(x = x, y = y, fill = group)) +
geom_bar(stat = "identity", position = "dodge") +
scale_fill_manual(values = palette_lgbtq("pansexual"))
scale_fill_lgbtq("pansexual")
```

Use matching `theme_lgbtq()` to make colors stand out the most:

```{r ggplot2_theme, fig.height=3}
ggplot(data, aes(x = x, y = y, fill = group)) +
geom_bar(stat = "identity", position = "dodge") +
scale_fill_manual(values = palette_lgbtq("pansexual")) +
scale_fill_lgbtq("pansexual") +
theme_lgbtq("pansexual")
```

Expand All @@ -71,16 +71,17 @@ ggplot(data, aes(x = x, y = y, fill = group)) +
```{r ggplot2_theme_custom, fig.height=3}
ggplot(data, aes(x = x, y = y, fill = group)) +
geom_bar(stat = "identity", position = "dodge") +
scale_fill_manual(values = palette_lgbtq("pansexual")) +
scale_fill_lgbtq("pansexual") +
theme_lgbtq("pansexual", legend.position = "left")
```

Almost all ggplot2 uses of `palette_lgbtq()` will be with `color` and `fill` scales, so the `scale_color_lgbtq()` and `scale_fill_lgbtq()` functions provide a shorthand and more descriptive notation:
Almost all ggplot2 uses of `palette_lgbtq()` will be with `color` and `fill` scales, so the `scale_color_lgbtq()` and `scale_fill_lgbtq()` functions provide a shorthand and more descriptive notation; there's nothing stopping you, however, from passing them manually or using in any other package, though the ggplot2 dependency might be a pretty large one.

```{r ggplot2_scale, fig.height=3}
ggplot(data, aes(x = x, y = y, fill = group)) +
geom_bar(stat = "identity", position = "dodge") +
scale_fill_lgbtq("pansexual")
scale_fill_manual(values = palette_lgbtq("pansexual")) +
theme_lgbtq("pansexual", legend.position = "left")
```

## Gallery
Expand Down
18 changes: 11 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ To list all available palettes, call:

``` r
show_pride()
## # A tibble: 37 × 2
## # A tibble: 41 × 2
## palettes lengths
## <chr> <int>
## 1 rainbow 6
Expand All @@ -44,7 +44,7 @@ show_pride()
## 8 nonbinary 4
## 9 philadelphia 8
## 10 progress 11
## # ℹ 27 more rows
## # ℹ 31 more rows
```

The most common use case is to use palettes with ggplot2:
Expand All @@ -61,7 +61,7 @@ data <- data.frame(

ggplot(data, aes(x = x, y = y, fill = group)) +
geom_bar(stat = "identity", position = "dodge") +
scale_fill_manual(values = palette_lgbtq("pansexual"))
scale_fill_lgbtq("pansexual")
```

![](README_files/figure-gfm/ggplot2-1.png)<!-- -->
Expand All @@ -71,7 +71,7 @@ Use matching `theme_lgbtq()` to make colors stand out the most:
``` r
ggplot(data, aes(x = x, y = y, fill = group)) +
geom_bar(stat = "identity", position = "dodge") +
scale_fill_manual(values = palette_lgbtq("pansexual")) +
scale_fill_lgbtq("pansexual") +
theme_lgbtq("pansexual")
```

Expand All @@ -83,20 +83,24 @@ it’s fully customizable:
``` r
ggplot(data, aes(x = x, y = y, fill = group)) +
geom_bar(stat = "identity", position = "dodge") +
scale_fill_manual(values = palette_lgbtq("pansexual")) +
scale_fill_lgbtq("pansexual") +
theme_lgbtq("pansexual", legend.position = "left")
```

![](README_files/figure-gfm/ggplot2_theme_custom-1.png)<!-- -->

Almost all ggplot2 uses of `palette_lgbtq()` will be with `color` and
`fill` scales, so the `scale_color_lgbtq()` and `scale_fill_lgbtq()`
functions provide a shorthand and more descriptive notation:
functions provide a shorthand and more descriptive notation; there’s
nothing stopping you, however, from passing them manually or using in
any other package, though the ggplot2 dependency might be a pretty large
one.

``` r
ggplot(data, aes(x = x, y = y, fill = group)) +
geom_bar(stat = "identity", position = "dodge") +
scale_fill_lgbtq("pansexual")
scale_fill_manual(values = palette_lgbtq("pansexual")) +
theme_lgbtq("pansexual", legend.position = "left")
```

![](README_files/figure-gfm/ggplot2_scale-1.png)<!-- -->
Expand Down
Binary file modified README_files/figure-gfm/ggplot2_scale-1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 2 additions & 0 deletions man/palette_lgbtq.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions man/theme_lgbtq.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

18 changes: 17 additions & 1 deletion vignettes/gallery.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -166,6 +166,12 @@ palette_lgbtq("gynesexual")

A "gynesexual" person is attracted to women or feminine-presenting people. This term is superior to "straight [man]" and "lesbian", since it does not imply anything about person's gender and is usable by non-binary people as well.

```{r abrosexual}
palette_lgbtq("abrosexual")
```

Abrosexuality is defined by the fluctuations of one's sexual orientation, whether constant or occasional. It doesn't specify where on the sexuality spectrum these fluctuations occur.

```{r lesbian_7}
palette_lgbtq("lesbian_7")
```
Expand Down Expand Up @@ -252,6 +258,8 @@ palette_lgbtq("bigender")

## Subcultures

While somebody's sexual orientation isn't that person's lifestyle (even though there are people suggesting otherwise), the terms here describe the way certain people express and identify themselves in strong connection with their sexuality. In a way, this is the closest to "lifestyle" you can get here.

```{r amatopunk}
palette_lgbtq("amatopunk")
```
Expand Down Expand Up @@ -280,6 +288,14 @@ palette_lgbtq("femme")
palette_lgbtq("otter")
```

Since "bear" triggers a natural association with a high-volume person, as explained before, the "otter" is its low-volume counterpart; retaining the other characteristics referring to maleness, gayness, and hairiness.

## Uncategorized

All the terms that do not fit elsewhere. Currently empty.
All the terms that do not fit elsewhere.

```{r queerhet}
palette_lgbtq("queerhet")
```

Queerhets use this term to signalize that allocishets are not the only heterosexual people in the existence. There exist people who are both straight and queer -- by being either transgender or A-spec.

0 comments on commit 0d9a114

Please sign in to comment.