1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-21 12:25:07 +00:00
serenity/Libraries/LibHTML/Layout/LayoutReplaced.h
Andreas Kling f52f2736e1 LibHTML: Add is<ElementType> and to<ElementType> helper functions
These will help us write node-type-aware template functions.
2019-10-06 20:38:26 +02:00

17 lines
534 B
C++

#include <LibHTML/DOM/Element.h>
#include <LibHTML/Layout/LayoutNode.h>
class LayoutReplaced : public LayoutNode {
public:
LayoutReplaced(const Element&, NonnullRefPtr<StyleProperties>);
virtual ~LayoutReplaced() override;
const Element& node() const { return to<Element>(*LayoutNode::node()); }
virtual bool is_replaced() const final { return true; }
private:
virtual const char* class_name() const override { return "LayoutReplaced"; }
virtual void split_into_lines(LayoutBlock& container) override;
};