# `Toddy.Iced.Alignment`
[🔗](https://github.com/toddy-ui/toddy-elixir/blob/v0.3.0/lib/toddy/iced/alignment.ex#L1)

Alignment values for `align_x` and `align_y` widget props.

Horizontal: `:left`, `:center`, `:right` (aliases: `:start` = `:left`, `:end` = `:right`).
Vertical: `:top`, `:center`, `:bottom` (aliases: `:start` = `:top`, `:end` = `:bottom`).

# `horizontal`

```elixir
@type horizontal() :: :left | :center | :right | :start | :end
```

# `t`

```elixir
@type t() :: horizontal() | vertical()
```

# `vertical`

```elixir
@type vertical() :: :top | :center | :bottom | :start | :end
```

# `encode`

```elixir
@spec encode(alignment :: t()) :: String.t()
```

Encodes an alignment value to the wire format.

## Examples

    iex> Toddy.Iced.Alignment.encode(:left)
    "left"

    iex> Toddy.Iced.Alignment.encode(:center)
    "center"

    iex> Toddy.Iced.Alignment.encode(:right)
    "right"

    iex> Toddy.Iced.Alignment.encode(:top)
    "top"

    iex> Toddy.Iced.Alignment.encode(:bottom)
    "bottom"

    iex> Toddy.Iced.Alignment.encode(:start)
    "start"

    iex> Toddy.Iced.Alignment.encode(:end)
    "end"

---

*Consult [api-reference.md](api-reference.md) for complete listing*
