FontMetrics.shorten
You're seeing just the function
shorten
, go back to FontMetrics module for more information.
Specs
shorten( String.t() | [integer()], max_width :: number(), pixels :: number(), metrics :: t(), opts :: Keyword.t() ) :: String.t() | [integer()]
Shorten a string to fit a given width
Options
Supported options:
:kern
- The default value isfalse
.:terminator
- The default value is"…"
.
returns string