glyph_info | R Documentation |
This function allows you to extract information about the individual glyphs
in a font, based on a specified size. All size related measures are in
pixel-units. The function is vectorised to the length of the glyphs
vector.
glyph_info(
glyphs,
family = "",
italic = FALSE,
bold = FALSE,
size = 12,
res = 72,
path = NULL,
index = 0
)
glyphs |
A vector of glyphs. Strings will be split into separate glyphs automatically |
family |
The name of the font families to match |
italic |
logical indicating the font slant |
bold |
logical indicating whether the font weight |
size |
The pointsize of the font to use for size related measures |
res |
The ppi of the size related mesures |
path , index |
path an index of a font file to circumvent lookup based on family and style |
A data.frame with information about each glyph, containing the following columns:
The glyph as a character
The index of the glyph in the font file
The width of the glyph
The height of the glyph
The horizontal distance from the origin to the leftmost part of the glyph
The vertical distance from the origin to the top part of the glyph
The horizontal distance to move the cursor after adding the glyph
The vertical distance to move the cursor after adding the glyph
The tight bounding box surrounding the glyph
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.