#ifndef MICROTEX_ATOM_BOX_H #define MICROTEX_ATOM_BOX_H #include "atom/atom.h" #include "atom/atom_row.h" #include "graphic/graphic_basic.h" namespace microtex { /** An atom representing a boxed base atom */ class FBoxAtom : public Atom { protected: sptr _base; color _bg, _line; public: FBoxAtom() = delete; explicit FBoxAtom(const sptr& base, color bg = MT_TRANSPARENT, color line = MT_TRANSPARENT) { if (base == nullptr) _base = sptrOf(); else { _base = base; _type = base->_type; } _bg = bg; _line = line; } sptr createBox(Env& env) override; }; /** An atom representing a boxed base atom */ class DoubleFramedAtom : public FBoxAtom { public: DoubleFramedAtom() = delete; explicit DoubleFramedAtom(const sptr& base) : FBoxAtom(base) {} sptr createBox(Env& env) override; }; /** An atom representing a box-shadowed atom */ class ShadowAtom : public FBoxAtom { public: ShadowAtom() = delete; explicit ShadowAtom(const sptr& base) : FBoxAtom(base) {} sptr createBox(Env& env) override; }; /** * An atom representing a oval-boxed base atom */ class OvalAtom : public FBoxAtom { public: static float _multiplier; static float _diameter; OvalAtom() = delete; explicit OvalAtom(const sptr& base) : FBoxAtom(base) {} sptr createBox(Env& env) override; }; } // namespace microtex #endif // MICROTEX_ATOM_BOX_H