#pragma once

#include <daguerre/fixed-font.hpp>
#include <pake/widget.hpp>

namespace pake::widgets {

  class fixed_text : public widget {

    const daguerre::fixed_font<bool> *font;
    daguerre::hilbert_color bg, fg;
    std::string text;

    int width, height;
    halign ha;
    valign va;

  public:
    //TODO: look up font in some kind of catalogue
    fixed_text(
      std::string &&text,
      const daguerre::fixed_font<bool> *font,
      daguerre::hilbert_color bg,
      daguerre::hilbert_color fg,
      halign ha, valign va);

    virtual void render(
      dirtiable_image &onto, int x_off, int y_off, bool force) override;

    virtual void notify_size(int width, int height) override;

  };

}
