

{"id":12965,"date":"2021-02-19T16:59:48","date_gmt":"2021-02-19T21:59:48","guid":{"rendered":"https:\/\/rud.is\/b\/?p=12965"},"modified":"2021-02-19T17:01:16","modified_gmt":"2021-02-19T22:01:16","slug":"getting-into-the-rhythm-of-chart-typography-with-ragg-and-hrbragg-a-k-a-its-ragg-time","status":"publish","type":"post","link":"https:\/\/rud.is\/b\/2021\/02\/19\/getting-into-the-rhythm-of-chart-typography-with-ragg-and-hrbragg-a-k-a-its-ragg-time\/","title":{"rendered":"Getting Into the Rhythm of Chart Typography with {ragg} and {hrbragg} (a.k.a. It&#8217;s {ragg}-time}"},"content":{"rendered":"<p>Horrible puns aside, hopefully everyone saw the news, earlier this week, from @thomasp85 on the <a href=\"https:\/\/www.tidyverse.org\/blog\/2021\/02\/modern-text-features\/\">evolution of modern typographic capabilities<\/a> in the R ecosystem. Thomas (and some cohorts) has been working on {systemfonts}, {ragg}, and {textshaping} for quite a while now, and the \u2014 shall we say <em>tidyglyphs<\/em> ecosystem \u2014 is super-ready for prime time.<\/p>\n<p>Thomas covered <em>a seriously large amount of ground<\/em> in his post, so please take some time to digest that before continuing.<\/p>\n<p>Back? ??<\/p>\n<p>While it is possible to mangage typographic needs with the foundry tools provided via the font-rendering package-triad, one would be hard-pressed to say that the following is &#8220;fun&#8221;, or even truly manageable coding:<\/p>\n<pre><code class=\"language-r\">library(systemfonts)\n\nregister_variant(\n  name = \"some-unique-prefix Inter some-style-01\",\n  weight = \"normal\",\n  features = font_feature(\n    poss = 1, ibly = 1, many = 1, \n    four = 1, char = 1, open = 1,\n    type = 1, code = 1, spec = 1\n  )\n)\n\n# remember that name\n\nregister_variant(\n  name = \"some-unique-prefix Inter some-style-02\",\n  weight = \"normal\",\n  features = font_feature(\n    poss = 1, ibly = 1, many = 1, \n    four = 1, char = 1, open = 1,\n    type = 1, code = 1, spec = 1\n  )\n)\n\n# remember that name \n\n# add a dozen more lines ...\n\nggplot() +\n   geom_text(family = \"oops-i-just-misspelled-the-family-name-*again*\", ...) \n<\/code><\/pre>\n<p>We&#8217;ve been given the power to level up our chart typography, but it&#8217;s sort of where literal typesetters (the ones who put blocks of type into a press) were and we can totally make our lives easier and charts prettier with the help of a new package \u2014 {hrbragg} <a href=\"https:\/\/git.rud.is\/hrbrmstr\/hrbragg\">https:\/\/git.rud.is\/hrbrmstr\/hrbragg<\/a> \u2014 which is somewhat of a bridge between {ragg}, {systemfonts}, {textshaping} and a surprisingly popular package of mine: {hrbrthemes}. {hrbragg} is separate from {hrbrthemes} since this new typographic ecosystem is fairly restricted to {ragg} graphics devices (<em>for the moment<\/em>, as Thomas alluded the other day), and the new themes provided in {hrbragg} are a bit of a level-up from those in its sibling package.<\/p>\n<h3>Feature Management<\/h3>\n<p>At the heart of {systemfonts} lies the ability to tweak font features and bend them to your will. This <a href=\"https:\/\/ilovetypography.com\/OpenType\/opentype-features.html\">somewhat old post<\/a> shows why these tweaks exist and delves (but not <em>too<\/em> deeply) into the details of them, down to the four-letter codes that are used to represent and work with a given feature. But, what does <code>calt<\/code> mean? And, what is this <code>tnum<\/code> fellow you&#8217;ll be seeing a great deal of in R-land over the coming months? While one <em>could<\/em> leave the comfort of RStudio, VS Code, or vim to visit one of the reference links in Thomas&#8217; package or {hrbragg}, I&#8217;ve included the most recent copy of tag-code<->full-tag-name<->short-tab-description in {hrbragg} as a usable data frame so you can treat it like the data it is!<\/p>\n<pre><code class=\"language-r\">library(systemfonts) # access to and tweaking OTFs!\nlibrary(textshaping) # lets us treat type as data\nlibrary(ragg)        # because it'll be lonely w\/o the other two\nlibrary(hrbragg)     # remotes::install_git(\"https:\/\/git.rud.is\/hrbrmstr\/hrbragg.git\")\nlibrary(tidyverse)   # nice printing, {ggplot2}, and b\/c we'll do some font data wrangling\n\ndata(\"feature_dict\")\n\nfeature_dict\n## # A tibble: 122 x 3\n##    tag   long_name                   description                                                                                             \n##    &lt;chr&gt; &lt;chr&gt;                       &lt;chr&gt;                                                                                                   \n##  1 aalt  Access All Alternates       Special feature: used to present user with choice all alternate forms of the character                  \n##  2 abvf  Above-base Forms            Replaces the above-base part of a vowel sign. For Khmer and similar scripts.                            \n##  3 abvm  Above-base Mark Positioning Positions a mark glyph above a base glyph.                                                              \n##  4 abvs  Above-base Substitutions    Ligates a consonant with an above-mark.                                                                 \n##  5 afrc  Alternative Fractions       Converts figures separated by slash with alternative stacked fraction form                              \n##  6 akhn  Akhand                      Hindi for unbreakable.  Ligates consonant+halant+consonant, usually only for k-ss and j-ny combinations.\n##  7 blwf  Below-base Forms            Replaces halant+consonant combination with a subscript form.                                            \n##  8 blwm  Below-base Mark Positioning Positions a mark glyph below a base glyph                                                               \n##  9 blws  Below-base Substitutions    Ligates a consonant with a below-mark.                                                                  \n## 10 c2pc  Capitals to Petite Caps     Substitutes capital letters with petite caps                                                            \n## # \u2026 with 112 more rows\n<\/code><\/pre>\n<p>You can also use <code>help(\"opentype_typographic_features\")<\/code> to see an R help page with the same information. That page also has links external resource, one of which is a detailed manual of each feature with use-cases (in the event even the short-description is not as helpful as it could be).<\/p>\n<p>Before one can think about using the bare-metal <code>register_variant(..., font_feature(...))<\/code> duo, one has to know what features a particular type family supports. We can retrieve the feature codes with <code>textshaping::get_font_features()<\/code> and look them up in this data frame to get an at-a-glance view:<\/p>\n<pre><code class=\"language-r\"># old school subsetting ftw!\nfeature_dict[feature_dict$tag %in% textshaping::get_font_features(\"Inter\")[[1]],]\n## # A tibble: 19 x 3\n##    tag   long_name                   description                                                                                                                 \n##    &lt;chr&gt; &lt;chr&gt;                       &lt;chr&gt;                                                                                                                       \n##  1 aalt  Access All Alternates       Special feature: used to present user with choice all alternate forms of the character                                      \n##  2 calt  Contextual Alternates       Applies a second substitution feature based on a match of a character pattern within a context of surrounding patterns      \n##  3 case  Case Sensitive Forms        Replace characters, especially punctuation, with forms better suited for all-capital text, cf. titl                         \n##  4 ccmp  Glyph Composition\/Decompos\u2026 Either calls a ligature replacement on a sequence of characters or replaces a character with a sequence of glyphs. Provides\u2026\n##  5 cpsp  Capital Spacing             Adjusts spacing between letters in all-capitals text                                                                        \n##  6 dlig  Discretionary Ligatures     Ligatures to be applied at the user's discretion                                                                            \n##  7 dnom  Denominator                 Converts to appropriate fraction denominator form, invoked by frac                                                          \n##  8 frac  Fractions                   Converts figures separated by slash with diagonal fraction                                                                  \n##  9 kern  Kerning                     Fine horizontal positioning of one glyph to the next, based on the shapes of the glyphs                                     \n## 10 locl  Localized Forms             Substitutes character with the preferred form based on script language                                                      \n## 11 mark  Mark Positioning            Fine positioning of a mark glyph to a base character                                                                        \n## 12 numr  Numerator                   Converts to appropriate fraction numerator form, invoked by frac                                                            \n## 13 ordn  Ordinals                    Replaces characters with ordinal forms for use after numbers                                                                \n## 14 pnum  Proportional Figures        Replaces numerals with glyphs of proportional width, often also onum                                                        \n## 15 salt  Stylistic Alternates        Either replaces with, or displays list of, stylistic alternatives for a character                                           \n## 16 subs  Subscript                   Replaces character with subscript version, cf. numr                                                                         \n## 17 sups  Superscript                 Replaces character with superscript version, cf. dnom                                                                       \n## 18 tnum  Tabular Figures             Replaces numerals with glyphs of uniform width, often also lnum                                                             \n## 19 zero  Slashed Zero                Replaces 0 figure with slashed 0        \n<\/code><\/pre>\n<p>Most of those will not be super-useful (yet) but there are three key features that I believe one needs when picking a font for a chart:<\/p>\n<ul>\n<li>One of the <code>*lig<\/code>s (because <a href=\"https:\/\/practicaltypography.com\/ligatures-in-programming-fonts-hell-no.html#:~:text=Ligatures%20are%20special%20characters%20in,pros%20would%20call%20a%20glyph\">ligatures<\/a>.) are so gosh darn cool, pretty, and useful)<\/li>\n<li><code>tnum<\/code> for tabular numbers (essential in axis value display, and more)<\/li>\n<li><code>kern<\/code> for sweet, sweet <a href=\"https:\/\/www.figma.com\/dictionary\/kerning\/\">letterspacing, or <em>kerning<\/em><\/a><\/li>\n<\/ul>\n<p>Since I&#8217;ve just made up a rule, let&#8217;s see how many fonts I have that support said rule:<\/p>\n<pre><code class=\"language-r\">(fam &lt;- unique(system_fonts()[[\"family\"]])) %&gt;% \n  get_font_features() %&gt;% \n  set_names(fam) %&gt;% \n  keep(~sum(c(\n    any(grepl(\"kern\", .)), \n    any(grepl(\"tnum\", .)),\n    any(grepl(\".lig|liga\", .)) \n    )) == 3\n  ) %&gt;% \n  names() %&gt;% \n  sort()\n##  [1] \"Barlow\"                 \"Goldman Sans\"           \"Goldman Sans Condensed\" \"Grantha Sangam MN\"     \n##  [5] \"Inter\"                  \"Kohinoor Devanagari\"    \"Mukta Mahee\"            \"Museo Slab\"            \n##  [9] \"Neufile Grotesk\"        \"Roboto\"                 \"Roboto Black\"           \"Roboto Condensed\"      \n## [13] \"Roboto Light\"           \"Roboto Medium\"          \"Roboto Thin\"            \"Tamil Sangam MN\"       \n## [17] \"Trattatello\"           \n<\/code><\/pre>\n<p>I do have more, but they&#8217;re on a different Mac ?.<\/p>\n<p>{hrbragg} comes with Inter, Goldman Sans, and Roboto Condensed, so let&#8217;s explore one of them \u2014\u00a0Inter \u2014 and see how we might be able to make it useful but not tedious. The supported features of Inter are above and here are the family members:<\/p>\n<pre><code class=\"language-r\">system_fonts() %&gt;% \n  filter(family == \"Inter\") %&gt;% \n  select(name, family, style, weight, width, italic, monospace)\n##  A tibble: 18 x 7\n##    name                   family style              weight     width  italic monospace\n##    &lt;chr&gt;                  &lt;chr&gt;  &lt;chr&gt;              &lt;ord&gt;      &lt;ord&gt;  &lt;lgl&gt;  &lt;lgl&gt;    \n##  1 Inter-ExtraLight       Inter  Extra Light        light      normal FALSE  FALSE    \n##  2 Inter-MediumItalic     Inter  Medium Italic      medium     normal TRUE   FALSE    \n##  3 Inter-ExtraLightItalic Inter  Extra Light Italic light      normal TRUE   FALSE    \n##  4 Inter-Bold             Inter  Bold               bold       normal FALSE  FALSE    \n##  5 Inter-ThinItalic       Inter  Thin Italic        ultralight normal TRUE   FALSE    \n##  6 Inter-SemiBold         Inter  Semi Bold          semibold   normal FALSE  FALSE    \n##  7 Inter-BoldItalic       Inter  Bold Italic        bold       normal TRUE   FALSE    \n##  8 Inter-Italic           Inter  Italic             normal     normal TRUE   FALSE    \n##  9 Inter-Medium           Inter  Medium             medium     normal FALSE  FALSE    \n## 10 Inter-BlackItalic      Inter  Black Italic       heavy      normal TRUE   FALSE    \n## 11 Inter-Light            Inter  Light              normal     normal FALSE  FALSE    \n## 12 Inter-SemiBoldItalic   Inter  Semi Bold Italic   semibold   normal TRUE   FALSE    \n## 13 Inter-Regular          Inter  Regular            normal     normal FALSE  FALSE    \n## 14 Inter-ExtraBoldItalic  Inter  Extra Bold Italic  ultrabold  normal TRUE   FALSE    \n## 15 Inter-LightItalic      Inter  Light Italic       normal     normal TRUE   FALSE    \n## 16 Inter-Thin             Inter  Thin               ultralight normal FALSE  FALSE    \n## 17 Inter-ExtraBold        Inter  Extra Bold         ultrabold  normal FALSE  FALSE    \n## 18 Inter-Black            Inter  Black              heavy      normal FALSE  FALSE    \n<\/code><\/pre>\n<p>Nobody. I mean, <em>nobody<\/em> wants to type eighteen+ font variant registration statements, which is why {hrbragg} comes with <code>reconfigure_font()<\/code>. Just give it the family name, the features you want supported, and it will take care of the tedium for you:<\/p>\n<pre><code class=\"language-r\">reconfigure_font(\n  prefix = \"hrbragg-pkg\",\n  family = \"Inter\",\n  width = \"normal\",\n  ligatures = \"discretionary\",\n  calt = 1, tnum = 1, case = 1,\n  dlig = 1, ss01 = 1, kern = 1,\n  zero = 0, salt = 0\n) -&gt; customized_inter\n\n# I'll have a proper print method for this soon\n\nstr(customized_inter, 1)\n## List of 17\n##  $ ultralight_italic: chr \"clever-prefix Inter Thin Italic\"\n##  $ ultralight       : chr \"clever-prefix Inter Thin\"\n##  $ light            : chr \"clever-prefix Inter Extra Light\"\n##  $ light_italic     : chr \"clever-prefix Inter Extra Light Italic\"\n##  $ normal_italic    : chr \"clever-prefix Inter Light Italic\"\n##  $ normal_light     : chr \"clever-prefix Inter Light\"\n##  $ normal           : chr \"clever-prefix Inter Regular\"\n##  $ medium_italic    : chr \"clever-prefix Inter Medium Italic\"\n##  $ medium           : chr \"clever-prefix Inter Medium\"\n##  $ semibold         : chr \"clever-prefix Inter Semi Bold\"\n##  $ semibold_italic  : chr \"clever-prefix Inter Semi Bold Italic\"\n##  $ bold             : chr \"clever-prefix Inter Bold\"\n##  $ bold_italic      : chr \"clever-prefix Inter Bold Italic\"\n##  $ ultrabold_italic : chr \"clever-prefix Inter Extra Bold Italic\"\n##  $ ultrabold        : chr \"clever-prefix Inter Extra Bold\"\n##  $ heavy_italic     : chr \"clever-prefix Inter Black Italic\"\n##  $ heavy            : chr \"clever-prefix Inter Black\"\n##  - attr(*, \"family\")= chr \"Inter\"\n<\/code><\/pre>\n<p>The <code>reconfigure_font()<\/code> function applies the feature settings to all the family members, gives each a name with the stated prefix and provides a return value that supports <em>autocompletion of the name<\/em> in smart IDEs and practically negates the need to type out long, unique font names, like this:<\/p>\n<pre><code class=\"language-r\">ggplot() +\n  geom_text(\n    aes(1, 2, label = \"Welcome to a &lt;- customized -&gt; Inter!\"),\n    size = 6, family = customized_inter$ultrabold\n  ) +\n  theme_void()\n<\/code><\/pre>\n<p><a href=\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/customized-inter.png?ssl=1\"><img data-recalc-dims=\"1\" loading=\"lazy\" decoding=\"async\" data-attachment-id=\"12966\" data-permalink=\"https:\/\/rud.is\/b\/2021\/02\/19\/getting-into-the-rhythm-of-chart-typography-with-ragg-and-hrbragg-a-k-a-its-ragg-time\/customized-inter\/\" data-orig-file=\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/customized-inter.png?fit=1342%2C382&amp;ssl=1\" data-orig-size=\"1342,382\" data-comments-opened=\"1\" data-image-meta=\"{&quot;aperture&quot;:&quot;0&quot;,&quot;credit&quot;:&quot;&quot;,&quot;camera&quot;:&quot;&quot;,&quot;caption&quot;:&quot;&quot;,&quot;created_timestamp&quot;:&quot;0&quot;,&quot;copyright&quot;:&quot;&quot;,&quot;focal_length&quot;:&quot;0&quot;,&quot;iso&quot;:&quot;0&quot;,&quot;shutter_speed&quot;:&quot;0&quot;,&quot;title&quot;:&quot;&quot;,&quot;orientation&quot;:&quot;0&quot;}\" data-image-title=\"customized-inter\" data-image-description=\"\" data-image-caption=\"\" data-large-file=\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/customized-inter.png?fit=510%2C145&amp;ssl=1\" src=\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/customized-inter.png?resize=510%2C145&#038;ssl=1\" alt=\"\" width=\"510\" height=\"145\" class=\"aligncenter size-full wp-image-12966\" srcset=\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/customized-inter.png?w=1342&amp;ssl=1 1342w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/customized-inter.png?resize=300%2C85&amp;ssl=1 300w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/customized-inter.png?resize=530%2C151&amp;ssl=1 530w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/customized-inter.png?resize=150%2C43&amp;ssl=1 150w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/customized-inter.png?resize=768%2C219&amp;ssl=1 768w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/customized-inter.png?resize=500%2C142&amp;ssl=1 500w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/customized-inter.png?resize=1200%2C342&amp;ssl=1 1200w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/customized-inter.png?resize=400%2C114&amp;ssl=1 400w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/customized-inter.png?resize=800%2C228&amp;ssl=1 800w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/customized-inter.png?resize=200%2C57&amp;ssl=1 200w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/customized-inter.png?w=1020&amp;ssl=1 1020w\" sizes=\"auto, (max-width: 510px) 100vw, 510px\" \/><\/a><\/p>\n<p>Note that we have a lovely emboldened font with clean ligatures without much work at all! (I should mention that if a prefix is not specified, a UUID is chosen instead since we don&#8217;t really care about the elongated names anymore).<\/p>\n<p>While we&#8217;ve streamlined things a bit already, we can do even better.<\/p>\n<h3>Font-centric Themes<\/h3>\n<p>Just like {hrbrthemes}, {hrbragg} comes with some font\/typographic-centric themes. We&#8217;ll focus on the one with Inter for the blog post. For the moment, you&#8217;ll need to <code>install_inter()<\/code> (you likely got prompted to do that if you already installed the package). This requirement will go away soon, but you&#8217;ll want to use Inter everywhere anyway, so I&#8217;d keep it installed.<\/p>\n<p>Once that&#8217;s done, you&#8217;re ready to use <code>theme_inter()<\/code>.<\/p>\n<p>What&#8217;s that you say? Don&#8217;t we need to create a font variant first?<\/p>\n<p>Would <em>I<\/em> do that to you? Never! {hrbragg} comes with a preconfigured <code>inter_pkg<\/code> font variant (which I&#8217;ll be tweaking a bit over the weekend for some edge cases) that pairs nicely with <code>theme_inter()<\/code>. Here it is in action with an old friend of ours:<\/p>\n<pre><code class=\"language-r\">ggplot() +\n  geom_point(\n    data = mtcars,\n    aes(mpg, wt, color = factor(cyl))\n  ) +\n  geom_label(\n    aes(\n      x = 15, y = 5.48,\n      label = \"&lt;- A fairly useless annotation\\n       that uses the custom Inter\\n          variant by default.\"\n    ),\n    label.size = 0, hjust = 0, vjust = 1\n  ) +\n  labs(\n    x = \"Fuel efficiency (mpg)\", y = \"Weight (tons)\",\n    title = \"Seminal ggplot2 scatterplot example\",\n    subtitle = \"A plot that is only useful for demonstration purposes\",\n    caption = \"Brought to you by the letter 'g'\"\n  ) -&gt; gg1\n\ngg1 + theme_inter(grid = \"XY\", mode = \"light\") \n<\/code><\/pre>\n<p><a href=\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-light-mode-01-1.png?ssl=1\"><img data-recalc-dims=\"1\" loading=\"lazy\" decoding=\"async\" data-attachment-id=\"12968\" data-permalink=\"https:\/\/rud.is\/b\/2021\/02\/19\/getting-into-the-rhythm-of-chart-typography-with-ragg-and-hrbragg-a-k-a-its-ragg-time\/readme-light-mode-01-1\/\" data-orig-file=\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-light-mode-01-1.png?fit=1344%2C960&amp;ssl=1\" data-orig-size=\"1344,960\" data-comments-opened=\"1\" data-image-meta=\"{&quot;aperture&quot;:&quot;0&quot;,&quot;credit&quot;:&quot;&quot;,&quot;camera&quot;:&quot;&quot;,&quot;caption&quot;:&quot;&quot;,&quot;created_timestamp&quot;:&quot;0&quot;,&quot;copyright&quot;:&quot;&quot;,&quot;focal_length&quot;:&quot;0&quot;,&quot;iso&quot;:&quot;0&quot;,&quot;shutter_speed&quot;:&quot;0&quot;,&quot;title&quot;:&quot;&quot;,&quot;orientation&quot;:&quot;0&quot;}\" data-image-title=\"README-light-mode-01-1\" data-image-description=\"\" data-image-caption=\"\" data-large-file=\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-light-mode-01-1.png?fit=510%2C365&amp;ssl=1\" src=\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-light-mode-01-1.png?resize=510%2C364&#038;ssl=1\" alt=\"\" width=\"510\" height=\"364\" class=\"aligncenter size-full wp-image-12968\" srcset=\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-light-mode-01-1.png?w=1344&amp;ssl=1 1344w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-light-mode-01-1.png?resize=300%2C214&amp;ssl=1 300w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-light-mode-01-1.png?resize=530%2C379&amp;ssl=1 530w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-light-mode-01-1.png?resize=150%2C107&amp;ssl=1 150w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-light-mode-01-1.png?resize=768%2C549&amp;ssl=1 768w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-light-mode-01-1.png?resize=500%2C357&amp;ssl=1 500w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-light-mode-01-1.png?resize=1200%2C857&amp;ssl=1 1200w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-light-mode-01-1.png?resize=400%2C286&amp;ssl=1 400w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-light-mode-01-1.png?resize=800%2C571&amp;ssl=1 800w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-light-mode-01-1.png?resize=200%2C143&amp;ssl=1 200w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-light-mode-01-1.png?w=1020&amp;ssl=1 1020w\" sizes=\"auto, (max-width: 510px) 100vw, 510px\" \/><\/a><\/p>\n<p>Wonderful kerning, a custom-built arrow due to fantastic, built-in ligatures, and spiffy tabular numbers. Gorgeous!<\/p>\n<p>What was that you just asked? <em>What&#8217;s up with that <code>mode = \"light\"<\/code>?<\/em>. Did I forget to mention that all the {hrbragg} themes come with dark-mode support built in? My sincerest apologies. Choosing <code>mode = \"dark\"<\/code> will use a (configuratble) dark theme and using <code>mode = \"rstudio\"<\/code> (if you&#8217;re an RStudio user) will have the charts take on the IDE theme setting automagically. Here&#8217;s dark mode:<\/p>\n<pre><code class=\"language-r\">gg1 + theme_inter(grid = \"XY\", mode = \"dark\") \n<\/code><\/pre>\n<p><a href=\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-dark-mode-01-1.png?ssl=1\"><img data-recalc-dims=\"1\" loading=\"lazy\" decoding=\"async\" data-attachment-id=\"12970\" data-permalink=\"https:\/\/rud.is\/b\/2021\/02\/19\/getting-into-the-rhythm-of-chart-typography-with-ragg-and-hrbragg-a-k-a-its-ragg-time\/readme-dark-mode-01-1\/\" data-orig-file=\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-dark-mode-01-1.png?fit=1344%2C960&amp;ssl=1\" data-orig-size=\"1344,960\" data-comments-opened=\"1\" data-image-meta=\"{&quot;aperture&quot;:&quot;0&quot;,&quot;credit&quot;:&quot;&quot;,&quot;camera&quot;:&quot;&quot;,&quot;caption&quot;:&quot;&quot;,&quot;created_timestamp&quot;:&quot;0&quot;,&quot;copyright&quot;:&quot;&quot;,&quot;focal_length&quot;:&quot;0&quot;,&quot;iso&quot;:&quot;0&quot;,&quot;shutter_speed&quot;:&quot;0&quot;,&quot;title&quot;:&quot;&quot;,&quot;orientation&quot;:&quot;0&quot;}\" data-image-title=\"README-dark-mode-01-1\" data-image-description=\"\" data-image-caption=\"\" data-large-file=\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-dark-mode-01-1.png?fit=510%2C365&amp;ssl=1\" src=\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-dark-mode-01-1.png?resize=510%2C364&#038;ssl=1\" alt=\"\" width=\"510\" height=\"364\" class=\"aligncenter size-full wp-image-12970\" srcset=\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-dark-mode-01-1.png?w=1344&amp;ssl=1 1344w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-dark-mode-01-1.png?resize=300%2C214&amp;ssl=1 300w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-dark-mode-01-1.png?resize=530%2C379&amp;ssl=1 530w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-dark-mode-01-1.png?resize=150%2C107&amp;ssl=1 150w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-dark-mode-01-1.png?resize=768%2C549&amp;ssl=1 768w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-dark-mode-01-1.png?resize=500%2C357&amp;ssl=1 500w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-dark-mode-01-1.png?resize=1200%2C857&amp;ssl=1 1200w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-dark-mode-01-1.png?resize=400%2C286&amp;ssl=1 400w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-dark-mode-01-1.png?resize=800%2C571&amp;ssl=1 800w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-dark-mode-01-1.png?resize=200%2C143&amp;ssl=1 200w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-dark-mode-01-1.png?w=1020&amp;ssl=1 1020w\" sizes=\"auto, (max-width: 510px) 100vw, 510px\" \/><\/a><\/p>\n<p>The font+theme pairs automatically work and reconfigure all the ggplot2 aesthetic defaults accordingly. Since this makes heavy use of <code>update_geom_defaults()<\/code> I&#8217;ve included a (very necessary) <code>reset_ggplot2_defaults()<\/code> to get things back to normal when you need to.<\/p>\n<p>Note that you can use <code>adaptive_color()<\/code> to help enable dark\/light-mode color switching for your own pairings, and <code>theme_background_color()<\/code> or <code>theme_foreground_color<\/code> to utilize the (reconfigurable) default fore- and background theme colors.<\/p>\n<h3>Try before you buy\u2026into using a given font<\/h3>\n<p>One can&#8217;t know ahead of time whether a font is going to work well, and you might want go get a feel for how a given set of family variants work for you. To that end, I&#8217;ve made it possible to preview any font you&#8217;ve reconfigured with <code>reconfigure_font()<\/code> via <code>preview_variant()<\/code>. It uses some pre-set text that exercises the key features I&#8217;ve outlined, but you can sub your own for them if you want to look at something in particular. Let&#8217;s give <code>inter_pkg<\/code> a complete look:<\/p>\n<pre><code class=\"language-r\">preview_variant(inter_pkg)\n<\/code><\/pre>\n<p><a href=\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-preview-00-1.png?ssl=1\"><img data-recalc-dims=\"1\" loading=\"lazy\" decoding=\"async\" data-attachment-id=\"12971\" data-permalink=\"https:\/\/rud.is\/b\/2021\/02\/19\/getting-into-the-rhythm-of-chart-typography-with-ragg-and-hrbragg-a-k-a-its-ragg-time\/readme-preview-00-1\/\" data-orig-file=\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-preview-00-1.png?fit=1200%2C2600&amp;ssl=1\" data-orig-size=\"1200,2600\" data-comments-opened=\"1\" data-image-meta=\"{&quot;aperture&quot;:&quot;0&quot;,&quot;credit&quot;:&quot;&quot;,&quot;camera&quot;:&quot;&quot;,&quot;caption&quot;:&quot;&quot;,&quot;created_timestamp&quot;:&quot;0&quot;,&quot;copyright&quot;:&quot;&quot;,&quot;focal_length&quot;:&quot;0&quot;,&quot;iso&quot;:&quot;0&quot;,&quot;shutter_speed&quot;:&quot;0&quot;,&quot;title&quot;:&quot;&quot;,&quot;orientation&quot;:&quot;0&quot;}\" data-image-title=\"README-preview-00-1\" data-image-description=\"\" data-image-caption=\"\" data-large-file=\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-preview-00-1.png?fit=473%2C1024&amp;ssl=1\" src=\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-preview-00-1.png?resize=510%2C1105&#038;ssl=1\" alt=\"\" width=\"510\" height=\"1105\" class=\"aligncenter size-full wp-image-12971\" srcset=\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-preview-00-1.png?w=1200&amp;ssl=1 1200w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-preview-00-1.png?resize=138%2C300&amp;ssl=1 138w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-preview-00-1.png?resize=473%2C1024&amp;ssl=1 473w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-preview-00-1.png?resize=69%2C150&amp;ssl=1 69w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-preview-00-1.png?resize=768%2C1664&amp;ssl=1 768w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-preview-00-1.png?resize=709%2C1536&amp;ssl=1 709w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-preview-00-1.png?resize=945%2C2048&amp;ssl=1 945w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-preview-00-1.png?resize=500%2C1083&amp;ssl=1 500w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-preview-00-1.png?resize=150%2C325&amp;ssl=1 150w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-preview-00-1.png?resize=400%2C867&amp;ssl=1 400w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-preview-00-1.png?resize=800%2C1733&amp;ssl=1 800w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-preview-00-1.png?resize=200%2C433&amp;ssl=1 200w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-preview-00-1.png?w=1020&amp;ssl=1 1020w\" sizes=\"auto, (max-width: 510px) 100vw, 510px\" \/><\/a><\/p>\n<p>We can look at another one that we&#8217;ll create now (I did not realize this font had tabular numbers until Thomas built all these wonderful toys to play with!):<\/p>\n<pre><code class=\"language-r\">reconfigure_font(\n  family = \"Trattatello\",\n  width = \"normal\",\n  ligatures = \"discretionary\",\n  calt = 1, tnum = 1, case = 1,\n  dlig = 1, kern = 1,\n  zero = 0, salt = 0\n) -&gt; trat\n\npreview_variant(trat)\n<\/code><\/pre>\n<p><a href=\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-preview-01-1.png?ssl=1\"><img data-recalc-dims=\"1\" loading=\"lazy\" decoding=\"async\" data-attachment-id=\"12972\" data-permalink=\"https:\/\/rud.is\/b\/2021\/02\/19\/getting-into-the-rhythm-of-chart-typography-with-ragg-and-hrbragg-a-k-a-its-ragg-time\/readme-preview-01-1\/\" data-orig-file=\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-preview-01-1.png?fit=800%2C600&amp;ssl=1\" data-orig-size=\"800,600\" data-comments-opened=\"1\" data-image-meta=\"{&quot;aperture&quot;:&quot;0&quot;,&quot;credit&quot;:&quot;&quot;,&quot;camera&quot;:&quot;&quot;,&quot;caption&quot;:&quot;&quot;,&quot;created_timestamp&quot;:&quot;0&quot;,&quot;copyright&quot;:&quot;&quot;,&quot;focal_length&quot;:&quot;0&quot;,&quot;iso&quot;:&quot;0&quot;,&quot;shutter_speed&quot;:&quot;0&quot;,&quot;title&quot;:&quot;&quot;,&quot;orientation&quot;:&quot;0&quot;}\" data-image-title=\"README-preview-01-1\" data-image-description=\"\" data-image-caption=\"\" data-large-file=\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-preview-01-1.png?fit=510%2C383&amp;ssl=1\" src=\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-preview-01-1.png?resize=510%2C383&#038;ssl=1\" alt=\"\" width=\"510\" height=\"383\" class=\"aligncenter size-full wp-image-12972\" srcset=\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-preview-01-1.png?w=800&amp;ssl=1 800w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-preview-01-1.png?resize=300%2C225&amp;ssl=1 300w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-preview-01-1.png?resize=530%2C398&amp;ssl=1 530w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-preview-01-1.png?resize=150%2C113&amp;ssl=1 150w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-preview-01-1.png?resize=768%2C576&amp;ssl=1 768w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-preview-01-1.png?resize=500%2C375&amp;ssl=1 500w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-preview-01-1.png?resize=400%2C300&amp;ssl=1 400w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-preview-01-1.png?resize=200%2C150&amp;ssl=1 200w\" sizes=\"auto, (max-width: 510px) 100vw, 510px\" \/><\/a><\/p>\n<h3>FIN<\/h3>\n<p>The {hrbragg} package is not even 24 hours old yet, so there are breaking changes and many new, heh, <em>features<\/em> still to come, but please \u2014\u00a0as usual \u2014 kick the tyres and post questions, feedback, contributions, or suggestions wherever you&#8217;re most comfortable (the package is on most of the popular social coding sites).<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Horrible puns aside, hopefully everyone saw the news, earlier this week, from @thomasp85 on the evolution of modern typographic capabilities in the R ecosystem. Thomas (and some cohorts) has been working on {systemfonts}, {ragg}, and {textshaping} for quite a while now, and the \u2014 shall we say tidyglyphs ecosystem \u2014 is super-ready for prime time. [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":12970,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"jetpack_post_was_ever_published":false,"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"activitypub_content_warning":"","activitypub_content_visibility":"","activitypub_max_image_attachments":3,"activitypub_interaction_policy_quote":"anyone","activitypub_status":"","footnotes":""},"categories":[711,91],"tags":[],"class_list":["post-12965","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-fonts","category-r"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.3 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Getting Into the Rhythm of Chart Typography with {ragg} and {hrbragg} (a.k.a. It&#039;s {ragg}-time} - rud.is<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/rud.is\/b\/2021\/02\/19\/getting-into-the-rhythm-of-chart-typography-with-ragg-and-hrbragg-a-k-a-its-ragg-time\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Getting Into the Rhythm of Chart Typography with {ragg} and {hrbragg} (a.k.a. It&#039;s {ragg}-time} - rud.is\" \/>\n<meta property=\"og:description\" content=\"Horrible puns aside, hopefully everyone saw the news, earlier this week, from @thomasp85 on the evolution of modern typographic capabilities in the R ecosystem. Thomas (and some cohorts) has been working on {systemfonts}, {ragg}, and {textshaping} for quite a while now, and the \u2014 shall we say tidyglyphs ecosystem \u2014 is super-ready for prime time. [&hellip;]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/rud.is\/b\/2021\/02\/19\/getting-into-the-rhythm-of-chart-typography-with-ragg-and-hrbragg-a-k-a-its-ragg-time\/\" \/>\n<meta property=\"og:site_name\" content=\"rud.is\" \/>\n<meta property=\"article:published_time\" content=\"2021-02-19T21:59:48+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2021-02-19T22:01:16+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-dark-mode-01-1.png?fit=1344%2C960&ssl=1\" \/>\n\t<meta property=\"og:image:width\" content=\"1344\" \/>\n\t<meta property=\"og:image:height\" content=\"960\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"hrbrmstr\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"hrbrmstr\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"11 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/rud.is\\\/b\\\/2021\\\/02\\\/19\\\/getting-into-the-rhythm-of-chart-typography-with-ragg-and-hrbragg-a-k-a-its-ragg-time\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/rud.is\\\/b\\\/2021\\\/02\\\/19\\\/getting-into-the-rhythm-of-chart-typography-with-ragg-and-hrbragg-a-k-a-its-ragg-time\\\/\"},\"author\":{\"name\":\"hrbrmstr\",\"@id\":\"https:\\\/\\\/rud.is\\\/b\\\/#\\\/schema\\\/person\\\/d7cb7487ab0527447f7fda5c423ff886\"},\"headline\":\"Getting Into the Rhythm of Chart Typography with {ragg} and {hrbragg} (a.k.a. It&#8217;s {ragg}-time}\",\"datePublished\":\"2021-02-19T21:59:48+00:00\",\"dateModified\":\"2021-02-19T22:01:16+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/rud.is\\\/b\\\/2021\\\/02\\\/19\\\/getting-into-the-rhythm-of-chart-typography-with-ragg-and-hrbragg-a-k-a-its-ragg-time\\\/\"},\"wordCount\":1183,\"commentCount\":1,\"publisher\":{\"@id\":\"https:\\\/\\\/rud.is\\\/b\\\/#\\\/schema\\\/person\\\/d7cb7487ab0527447f7fda5c423ff886\"},\"image\":{\"@id\":\"https:\\\/\\\/rud.is\\\/b\\\/2021\\\/02\\\/19\\\/getting-into-the-rhythm-of-chart-typography-with-ragg-and-hrbragg-a-k-a-its-ragg-time\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/i0.wp.com\\\/rud.is\\\/b\\\/wp-content\\\/uploads\\\/2021\\\/02\\\/README-dark-mode-01-1.png?fit=1344%2C960&ssl=1\",\"articleSection\":[\"fonts\",\"R\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\\\/\\\/rud.is\\\/b\\\/2021\\\/02\\\/19\\\/getting-into-the-rhythm-of-chart-typography-with-ragg-and-hrbragg-a-k-a-its-ragg-time\\\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/rud.is\\\/b\\\/2021\\\/02\\\/19\\\/getting-into-the-rhythm-of-chart-typography-with-ragg-and-hrbragg-a-k-a-its-ragg-time\\\/\",\"url\":\"https:\\\/\\\/rud.is\\\/b\\\/2021\\\/02\\\/19\\\/getting-into-the-rhythm-of-chart-typography-with-ragg-and-hrbragg-a-k-a-its-ragg-time\\\/\",\"name\":\"Getting Into the Rhythm of Chart Typography with {ragg} and {hrbragg} (a.k.a. It's {ragg}-time} - rud.is\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/rud.is\\\/b\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/rud.is\\\/b\\\/2021\\\/02\\\/19\\\/getting-into-the-rhythm-of-chart-typography-with-ragg-and-hrbragg-a-k-a-its-ragg-time\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/rud.is\\\/b\\\/2021\\\/02\\\/19\\\/getting-into-the-rhythm-of-chart-typography-with-ragg-and-hrbragg-a-k-a-its-ragg-time\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/i0.wp.com\\\/rud.is\\\/b\\\/wp-content\\\/uploads\\\/2021\\\/02\\\/README-dark-mode-01-1.png?fit=1344%2C960&ssl=1\",\"datePublished\":\"2021-02-19T21:59:48+00:00\",\"dateModified\":\"2021-02-19T22:01:16+00:00\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/rud.is\\\/b\\\/2021\\\/02\\\/19\\\/getting-into-the-rhythm-of-chart-typography-with-ragg-and-hrbragg-a-k-a-its-ragg-time\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/rud.is\\\/b\\\/2021\\\/02\\\/19\\\/getting-into-the-rhythm-of-chart-typography-with-ragg-and-hrbragg-a-k-a-its-ragg-time\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/rud.is\\\/b\\\/2021\\\/02\\\/19\\\/getting-into-the-rhythm-of-chart-typography-with-ragg-and-hrbragg-a-k-a-its-ragg-time\\\/#primaryimage\",\"url\":\"https:\\\/\\\/i0.wp.com\\\/rud.is\\\/b\\\/wp-content\\\/uploads\\\/2021\\\/02\\\/README-dark-mode-01-1.png?fit=1344%2C960&ssl=1\",\"contentUrl\":\"https:\\\/\\\/i0.wp.com\\\/rud.is\\\/b\\\/wp-content\\\/uploads\\\/2021\\\/02\\\/README-dark-mode-01-1.png?fit=1344%2C960&ssl=1\",\"width\":1344,\"height\":960},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/rud.is\\\/b\\\/2021\\\/02\\\/19\\\/getting-into-the-rhythm-of-chart-typography-with-ragg-and-hrbragg-a-k-a-its-ragg-time\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/rud.is\\\/b\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Getting Into the Rhythm of Chart Typography with {ragg} and {hrbragg} (a.k.a. It&#8217;s {ragg}-time}\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/rud.is\\\/b\\\/#website\",\"url\":\"https:\\\/\\\/rud.is\\\/b\\\/\",\"name\":\"rud.is\",\"description\":\"&quot;In God we trust. All others must bring data&quot;\",\"publisher\":{\"@id\":\"https:\\\/\\\/rud.is\\\/b\\\/#\\\/schema\\\/person\\\/d7cb7487ab0527447f7fda5c423ff886\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/rud.is\\\/b\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":[\"Person\",\"Organization\"],\"@id\":\"https:\\\/\\\/rud.is\\\/b\\\/#\\\/schema\\\/person\\\/d7cb7487ab0527447f7fda5c423ff886\",\"name\":\"hrbrmstr\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/i0.wp.com\\\/rud.is\\\/b\\\/wp-content\\\/uploads\\\/2023\\\/10\\\/ukr-shield.png?fit=460%2C460&ssl=1\",\"url\":\"https:\\\/\\\/i0.wp.com\\\/rud.is\\\/b\\\/wp-content\\\/uploads\\\/2023\\\/10\\\/ukr-shield.png?fit=460%2C460&ssl=1\",\"contentUrl\":\"https:\\\/\\\/i0.wp.com\\\/rud.is\\\/b\\\/wp-content\\\/uploads\\\/2023\\\/10\\\/ukr-shield.png?fit=460%2C460&ssl=1\",\"width\":460,\"height\":460,\"caption\":\"hrbrmstr\"},\"logo\":{\"@id\":\"https:\\\/\\\/i0.wp.com\\\/rud.is\\\/b\\\/wp-content\\\/uploads\\\/2023\\\/10\\\/ukr-shield.png?fit=460%2C460&ssl=1\"},\"description\":\"Don't look at me\u2026I do what he does \u2014 just slower. #rstats avuncular \u2022 ?Resistance Fighter \u2022 Cook \u2022 Christian \u2022 [Master] Chef des Donn\u00e9es de S\u00e9curit\u00e9 @ @rapid7\",\"sameAs\":[\"http:\\\/\\\/rud.is\"],\"url\":\"https:\\\/\\\/rud.is\\\/b\\\/author\\\/hrbrmstr\\\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Getting Into the Rhythm of Chart Typography with {ragg} and {hrbragg} (a.k.a. It's {ragg}-time} - rud.is","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/rud.is\/b\/2021\/02\/19\/getting-into-the-rhythm-of-chart-typography-with-ragg-and-hrbragg-a-k-a-its-ragg-time\/","og_locale":"en_US","og_type":"article","og_title":"Getting Into the Rhythm of Chart Typography with {ragg} and {hrbragg} (a.k.a. It's {ragg}-time} - rud.is","og_description":"Horrible puns aside, hopefully everyone saw the news, earlier this week, from @thomasp85 on the evolution of modern typographic capabilities in the R ecosystem. Thomas (and some cohorts) has been working on {systemfonts}, {ragg}, and {textshaping} for quite a while now, and the \u2014 shall we say tidyglyphs ecosystem \u2014 is super-ready for prime time. [&hellip;]","og_url":"https:\/\/rud.is\/b\/2021\/02\/19\/getting-into-the-rhythm-of-chart-typography-with-ragg-and-hrbragg-a-k-a-its-ragg-time\/","og_site_name":"rud.is","article_published_time":"2021-02-19T21:59:48+00:00","article_modified_time":"2021-02-19T22:01:16+00:00","og_image":[{"width":1344,"height":960,"url":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-dark-mode-01-1.png?fit=1344%2C960&ssl=1","type":"image\/png"}],"author":"hrbrmstr","twitter_card":"summary_large_image","twitter_misc":{"Written by":"hrbrmstr","Est. reading time":"11 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/rud.is\/b\/2021\/02\/19\/getting-into-the-rhythm-of-chart-typography-with-ragg-and-hrbragg-a-k-a-its-ragg-time\/#article","isPartOf":{"@id":"https:\/\/rud.is\/b\/2021\/02\/19\/getting-into-the-rhythm-of-chart-typography-with-ragg-and-hrbragg-a-k-a-its-ragg-time\/"},"author":{"name":"hrbrmstr","@id":"https:\/\/rud.is\/b\/#\/schema\/person\/d7cb7487ab0527447f7fda5c423ff886"},"headline":"Getting Into the Rhythm of Chart Typography with {ragg} and {hrbragg} (a.k.a. It&#8217;s {ragg}-time}","datePublished":"2021-02-19T21:59:48+00:00","dateModified":"2021-02-19T22:01:16+00:00","mainEntityOfPage":{"@id":"https:\/\/rud.is\/b\/2021\/02\/19\/getting-into-the-rhythm-of-chart-typography-with-ragg-and-hrbragg-a-k-a-its-ragg-time\/"},"wordCount":1183,"commentCount":1,"publisher":{"@id":"https:\/\/rud.is\/b\/#\/schema\/person\/d7cb7487ab0527447f7fda5c423ff886"},"image":{"@id":"https:\/\/rud.is\/b\/2021\/02\/19\/getting-into-the-rhythm-of-chart-typography-with-ragg-and-hrbragg-a-k-a-its-ragg-time\/#primaryimage"},"thumbnailUrl":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-dark-mode-01-1.png?fit=1344%2C960&ssl=1","articleSection":["fonts","R"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/rud.is\/b\/2021\/02\/19\/getting-into-the-rhythm-of-chart-typography-with-ragg-and-hrbragg-a-k-a-its-ragg-time\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/rud.is\/b\/2021\/02\/19\/getting-into-the-rhythm-of-chart-typography-with-ragg-and-hrbragg-a-k-a-its-ragg-time\/","url":"https:\/\/rud.is\/b\/2021\/02\/19\/getting-into-the-rhythm-of-chart-typography-with-ragg-and-hrbragg-a-k-a-its-ragg-time\/","name":"Getting Into the Rhythm of Chart Typography with {ragg} and {hrbragg} (a.k.a. It's {ragg}-time} - rud.is","isPartOf":{"@id":"https:\/\/rud.is\/b\/#website"},"primaryImageOfPage":{"@id":"https:\/\/rud.is\/b\/2021\/02\/19\/getting-into-the-rhythm-of-chart-typography-with-ragg-and-hrbragg-a-k-a-its-ragg-time\/#primaryimage"},"image":{"@id":"https:\/\/rud.is\/b\/2021\/02\/19\/getting-into-the-rhythm-of-chart-typography-with-ragg-and-hrbragg-a-k-a-its-ragg-time\/#primaryimage"},"thumbnailUrl":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-dark-mode-01-1.png?fit=1344%2C960&ssl=1","datePublished":"2021-02-19T21:59:48+00:00","dateModified":"2021-02-19T22:01:16+00:00","breadcrumb":{"@id":"https:\/\/rud.is\/b\/2021\/02\/19\/getting-into-the-rhythm-of-chart-typography-with-ragg-and-hrbragg-a-k-a-its-ragg-time\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/rud.is\/b\/2021\/02\/19\/getting-into-the-rhythm-of-chart-typography-with-ragg-and-hrbragg-a-k-a-its-ragg-time\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/rud.is\/b\/2021\/02\/19\/getting-into-the-rhythm-of-chart-typography-with-ragg-and-hrbragg-a-k-a-its-ragg-time\/#primaryimage","url":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-dark-mode-01-1.png?fit=1344%2C960&ssl=1","contentUrl":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-dark-mode-01-1.png?fit=1344%2C960&ssl=1","width":1344,"height":960},{"@type":"BreadcrumbList","@id":"https:\/\/rud.is\/b\/2021\/02\/19\/getting-into-the-rhythm-of-chart-typography-with-ragg-and-hrbragg-a-k-a-its-ragg-time\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/rud.is\/b\/"},{"@type":"ListItem","position":2,"name":"Getting Into the Rhythm of Chart Typography with {ragg} and {hrbragg} (a.k.a. It&#8217;s {ragg}-time}"}]},{"@type":"WebSite","@id":"https:\/\/rud.is\/b\/#website","url":"https:\/\/rud.is\/b\/","name":"rud.is","description":"&quot;In God we trust. All others must bring data&quot;","publisher":{"@id":"https:\/\/rud.is\/b\/#\/schema\/person\/d7cb7487ab0527447f7fda5c423ff886"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/rud.is\/b\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":["Person","Organization"],"@id":"https:\/\/rud.is\/b\/#\/schema\/person\/d7cb7487ab0527447f7fda5c423ff886","name":"hrbrmstr","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/10\/ukr-shield.png?fit=460%2C460&ssl=1","url":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/10\/ukr-shield.png?fit=460%2C460&ssl=1","contentUrl":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/10\/ukr-shield.png?fit=460%2C460&ssl=1","width":460,"height":460,"caption":"hrbrmstr"},"logo":{"@id":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/10\/ukr-shield.png?fit=460%2C460&ssl=1"},"description":"Don't look at me\u2026I do what he does \u2014 just slower. #rstats avuncular \u2022 ?Resistance Fighter \u2022 Cook \u2022 Christian \u2022 [Master] Chef des Donn\u00e9es de S\u00e9curit\u00e9 @ @rapid7","sameAs":["http:\/\/rud.is"],"url":"https:\/\/rud.is\/b\/author\/hrbrmstr\/"}]}},"jetpack_featured_media_url":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2021\/02\/README-dark-mode-01-1.png?fit=1344%2C960&ssl=1","jetpack_shortlink":"https:\/\/wp.me\/p23idr-3n7","jetpack_likes_enabled":true,"jetpack-related-posts":[{"id":6255,"url":"https:\/\/rud.is\/b\/2017\/09\/15\/its-a-fake-%f0%9f%93%a6-revisiting-trust-in-foss-ecosystems\/","url_meta":{"origin":12965,"position":0},"title":"It&#8217;s a FAKE (?)! Revisiting Trust In FOSS Ecosystems","author":"hrbrmstr","date":"2017-09-15","format":false,"excerpt":"I've blathered about trust before 1 2, but said blatherings were in a \"what if\" context. Unfortunately, the if has turned into a when, which begged for further blathering on a recent FOSS ecosystem cybersecurity incident. The gg_spiffy @thomasp85 linked to a post by the SK-CSIRT detailing the discovery and\u2026","rel":"","context":"In &quot;R&quot;","block_context":{"text":"R","link":"https:\/\/rud.is\/b\/category\/r\/"},"img":{"alt_text":"","src":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2017\/09\/download_counts_per_day-1.png?fit=1200%2C818&ssl=1&resize=350%2C200","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2017\/09\/download_counts_per_day-1.png?fit=1200%2C818&ssl=1&resize=350%2C200 1x, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2017\/09\/download_counts_per_day-1.png?fit=1200%2C818&ssl=1&resize=525%2C300 1.5x, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2017\/09\/download_counts_per_day-1.png?fit=1200%2C818&ssl=1&resize=700%2C400 2x, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2017\/09\/download_counts_per_day-1.png?fit=1200%2C818&ssl=1&resize=1050%2C600 3x"},"classes":[]},{"id":11648,"url":"https:\/\/rud.is\/b\/2018\/11\/14\/use-github-vulnerability-alerts-to-keep-users-of-your-r-packages-safe\/","url_meta":{"origin":12965,"position":1},"title":"Use GitHub Vulnerability Alerts to Keep Users of Your R Packages Safe","author":"hrbrmstr","date":"2018-11-14","format":false,"excerpt":"Despite their now inherent evil status, GitHub has some tools other repository aggregators do not. One such tool is the free vulnerability alert service which will scan repositories for outdated+vulnerable dependencies. Now, \"R\" is nowhere near a first-class citizen in the internet writ large, including software development tooling (e.g. the\u2026","rel":"","context":"In &quot;Cybersecurity&quot;","block_context":{"text":"Cybersecurity","link":"https:\/\/rud.is\/b\/category\/cybersecurity\/"},"img":{"alt_text":"","src":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2018\/11\/Screen-Shot-2018-11-14-at-08.43.14.png?fit=1200%2C424&ssl=1&resize=350%2C200","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2018\/11\/Screen-Shot-2018-11-14-at-08.43.14.png?fit=1200%2C424&ssl=1&resize=350%2C200 1x, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2018\/11\/Screen-Shot-2018-11-14-at-08.43.14.png?fit=1200%2C424&ssl=1&resize=525%2C300 1.5x, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2018\/11\/Screen-Shot-2018-11-14-at-08.43.14.png?fit=1200%2C424&ssl=1&resize=700%2C400 2x, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2018\/11\/Screen-Shot-2018-11-14-at-08.43.14.png?fit=1200%2C424&ssl=1&resize=1050%2C600 3x"},"classes":[]},{"id":4385,"url":"https:\/\/rud.is\/b\/2016\/05\/10\/new-rstats-podcast-r-world-news\/","url_meta":{"origin":12965,"position":2},"title":"New #rstats Podcast &#8211; R World News","author":"hrbrmstr","date":"2016-05-10","format":false,"excerpt":"Keeping up with R-related news on Twitter, GitHub, CRAN & even R-Bloggers (et al) can be an all-encompassing task that may be fun, but doesn't always make it easy to get work done. There is so much going on in the R community that we (myself and @jayjacobs) felt there\u2026","rel":"","context":"In &quot;R&quot;","block_context":{"text":"R","link":"https:\/\/rud.is\/b\/category\/r\/"},"img":{"alt_text":"","src":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2016\/05\/r-world-news.png?fit=1200%2C860&ssl=1&resize=350%2C200","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2016\/05\/r-world-news.png?fit=1200%2C860&ssl=1&resize=350%2C200 1x, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2016\/05\/r-world-news.png?fit=1200%2C860&ssl=1&resize=525%2C300 1.5x, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2016\/05\/r-world-news.png?fit=1200%2C860&ssl=1&resize=700%2C400 2x, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2016\/05\/r-world-news.png?fit=1200%2C860&ssl=1&resize=1050%2C600 3x"},"classes":[]},{"id":11765,"url":"https:\/\/rud.is\/b\/2019\/01\/14\/splashr-0-6-0-now-uses-the-cran-nascent-stevedore-package-for-docker-orchestration\/","url_meta":{"origin":12965,"position":3},"title":"splashr 0.6.0 Now Uses the CRAN-nascent stevedore Package for Docker Orchestration","author":"hrbrmstr","date":"2019-01-14","format":false,"excerpt":"The splashr package [srht|GL|GH] \u2014 an alternative to Selenium for javascript-enabled\/browser-emulated web scraping \u2014 is now at version 0.6.0 (still in dev-mode but on its way to CRAN in the next 14 days). The major change from version 0.5.x (which never made it to CRAN) is a swap out of\u2026","rel":"","context":"In &quot;R&quot;","block_context":{"text":"R","link":"https:\/\/rud.is\/b\/category\/r\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":3732,"url":"https:\/\/rud.is\/b\/2015\/10\/22\/installing-r-on-os-x-100-homebrew-edition\/","url_meta":{"origin":12965,"position":4},"title":"Installing R on OS X &#8211; &#8220;100% Homebrew Edition&#8221;","author":"hrbrmstr","date":"2015-10-22","format":false,"excerpt":"In a previous post I provided \"mouse-heavy\" instructions for getting R running on your Mac. A few of the comments suggested that an \"all Homebrew\" solution may be preferable for some folks. Now, there are issues with this since getting \"support\" for what may be R issues will be very\u2026","rel":"","context":"In &quot;OS X&quot;","block_context":{"text":"OS X","link":"https:\/\/rud.is\/b\/category\/os-x\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":4148,"url":"https:\/\/rud.is\/b\/2016\/03\/18\/hy-phen-ate-all-the-things-in-r\/","url_meta":{"origin":12965,"position":5},"title":"Hy-phen-ate All The Things! (in R)","author":"hrbrmstr","date":"2016-03-18","format":false,"excerpt":"`hyphenatr`--what may be my smallest package ever--has just hit [CRAN](https:\/\/cloud.r-project.org\/web\/packages\/hyphenatr\/). It, well, _hyphenates_ words using [`libhyphen`](https:\/\/cloud.r-project.org\/web\/packages\/hyphenatr\/index.html) (a.k.a. `libhnj`). There are no external dependencies (i.e. no `brew install`, `apt get`, et. al. required) and it compiles on _everything_ CRAN supports _including_ Windows. I started coding this to see if it could\u2026","rel":"","context":"In &quot;R&quot;","block_context":{"text":"R","link":"https:\/\/rud.is\/b\/category\/r\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]}],"jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/rud.is\/b\/wp-json\/wp\/v2\/posts\/12965","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/rud.is\/b\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/rud.is\/b\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/rud.is\/b\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/rud.is\/b\/wp-json\/wp\/v2\/comments?post=12965"}],"version-history":[{"count":0,"href":"https:\/\/rud.is\/b\/wp-json\/wp\/v2\/posts\/12965\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/rud.is\/b\/wp-json\/wp\/v2\/media\/12970"}],"wp:attachment":[{"href":"https:\/\/rud.is\/b\/wp-json\/wp\/v2\/media?parent=12965"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/rud.is\/b\/wp-json\/wp\/v2\/categories?post=12965"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/rud.is\/b\/wp-json\/wp\/v2\/tags?post=12965"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}