Skip to content

Commit abf16f9

Browse files
authored
Tweak to font update post (#718)
1 parent 9eb073e commit abf16f9

File tree

2 files changed

+3
-8
lines changed

2 files changed

+3
-8
lines changed

content/blog/text-rendering-updates/index.Rmd

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ In addition to this function, systemfonts also comes with `scan_local_fonts()` t
6363
While it is nice to have good access to the font files on your computer, the files has to come from somewhere. Nowadays that *somewhere* is usually [Google Fonts](https://fonts.google.com) or some other online font repository. systemfonts is now aware of a few of these repositories (Google Fonts and [Font Squirrel](https://www.fontsquirrel.com) for now), and can search and download from these (using `search_web_fonts()`, `get_from_google_fonts()`, and `get_from_font_squirrel()`). The downloaded fonts are automatically added using `add_fonts()` so they are immediately available, and by default they are placed in `~/fonts` so that they persist across R sessions and projects.
6464

6565
```{r}
66-
#| eval: false
66+
#| eval: false
6767
# Search and download fonts
6868
systemfonts::get_from_font_squirrel("Quicksand")
6969
systemfonts::get_from_google_fonts("Rubik Moonrocks")
@@ -156,7 +156,7 @@ library(marquee)
156156
# Create a style specific for rtl text
157157
rtl_style <- classic_style(
158158
text_direction = "rtl", # Forces bidi text to be assembled from right to left
159-
adjust = "auto", # Will convert itself to "right"
159+
align = "auto", # Will convert itself to "right"
160160
ltr = FALSE # Will move bullet padding and bar along quote blocks to the right
161161
)
162162
```

content/blog/text-rendering-updates/index.md

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,6 @@ While it is nice to have good access to the font files on your computer, the fil
6060

6161

6262
``` r
63-
#| eval: false
6463
# Search and download fonts
6564
systemfonts::get_from_font_squirrel("Quicksand")
6665
systemfonts::get_from_google_fonts("Rubik Moonrocks")
@@ -160,15 +159,11 @@ library(marquee)
160159
# Create a style specific for rtl text
161160
rtl_style <- classic_style(
162161
text_direction = "rtl", # Forces bidi text to be assembled from right to left
163-
adjust = "auto", # Will convert itself to "right"
162+
align = "auto", # Will convert itself to "right"
164163
ltr = FALSE # Will move bullet padding and bar along quote blocks to the right
165164
)
166165
```
167166

168-
```
169-
## Error in base_style(family = body_font, size = base_size, ...): unused argument (adjust = "auto")
170-
```
171-
172167
## A marquee for Everyone
173168

174169
Speaking of marquee, the biggest obstacle it has put in front of its users is that it is build on very new features in R. The ability to write text by placing glyphs one at a time was only added in R 4.2 and not every graphics device supports it yet (worse still, the implementation in the default macOS quartz device caused the session to crash). Again, ragg is your friend, but the Cairo devices also has excellent support.

0 commit comments

Comments
 (0)