Image.Options.Meme (image v0.59.0)

View Source

Options and option validation for Image.meme/2.

Summary

Types

Valid font weights

Options applicable to Image.meme/3

Valid type transforms

Types

font_weight()

@type font_weight() :: :ultralight | :light | :normal | :bold | :ultrabold | :heavy

Valid font weights

meme_options()

@type meme_options() ::
  [
    text: String.t(),
    font: String.t(),
    weight: font_weight(),
    color: Image.Color.t(),
    outline_color: Image.Color.t(),
    justify: boolean(),
    transform: text_transform(),
    width: pos_integer()
  ]
  | map()

Options applicable to Image.meme/3

text_transform()

@type text_transform() :: :capitalize | :upcase | :downcase | :none

Valid type transforms

Functions

default_margin(image)

no_such_font_file(file)

validate_options(options)

validate_options(image, options)

Validate the options for Image.meme/3.

See Image.Options.Meme.meme_options/0.