The text_height()
function adjusts the line height of text within a tag
element.
Arguments
- x
A tag element or .style pronoun.
- height
A character string specifying a line height. One of,
"sm"
"small"
"base"
"lg"
"large"
See also
Other text utilities:
text_alignment()
,
text_break()
,
text_color()
,
text_decoration()
,
text_selection()
,
text_style()
,
text_transform()
,
text_weight()
,
text_wrap()
Examples
library(htmltools)
p(
.style %>%
text_height("base"),
"This is the browser's default line height spacing.",
"Make sure there are multiple lines of text in a paragraph.",
"Otherwise, the changes applied by these utilities are not visible."
)
#> <p class="lh-base">
#> This is the browser's default line height spacing.
#> Make sure there are multiple lines of text in a paragraph.
#> Otherwise, the changes applied by these utilities are not visible.
#> </p>