silcrow.Rd
Print a section symbol
silcrow(section_number = "", nbsp = section_number != "")
section_number | Numeric or character value to print after the symbol. Can also be a vector of such values. |
---|---|
nbsp | Logical. Include a non-breaking space between the symbol and the section number? Defaults to TRUE if there is a section number. |
Character (UTF-8): A silcrow and, if indicated, a section number.
For multiple sections, two silcrows are traditionally used.
Accordingly, the function returns two silcrows if section_number
includes an en-dash, a comma, or (not recommended) a hyphen,
or if section_number
is a vector of length greater than one.
In that last scenario, sections will be separated by commas and spaces.
silcrow()#> [1] "§"silcrow(8.1)#> [1] "§ 8.1"silcrow("8.1.1")#> [1] "§ 8.1.1"silcrow("8.1.1", nbsp = FALSE)#> [1] "§8.1.1"#> [1] "§ 8.1–8.2"silcrow("8.1 - 8.2") # hyphen not recommended; use en-dash for ranges#> [1] "§§ 8.1 - 8.2"silcrow("8.1, 8.7")#> [1] "§§ 8.1, 8.7"#> [1] "§§ 8.1, 8.7"