mirror of
https://github.com/RGBCube/serenity
synced 2025-05-16 23:05:08 +00:00

This means we can instantiate them for pseudo-elements, which don't have an associated Element. They all pass it to their parent as a `Layout::Node*` and handle a lack of `layout_node()` already so this won't affect any functionality.
25 lines
523 B
C++
25 lines
523 B
C++
/*
|
|
* Copyright (c) 2018-2020, Andreas Kling <kling@serenityos.org>
|
|
*
|
|
* SPDX-License-Identifier: BSD-2-Clause
|
|
*/
|
|
|
|
#pragma once
|
|
|
|
#include <LibWeb/Layout/Box.h>
|
|
|
|
namespace Web::Layout {
|
|
|
|
class InlineNode : public NodeWithStyleAndBoxModelMetrics {
|
|
public:
|
|
InlineNode(DOM::Document&, DOM::Element*, NonnullRefPtr<CSS::StyleProperties>);
|
|
virtual ~InlineNode() override;
|
|
|
|
virtual void paint(PaintContext&, PaintPhase) override;
|
|
|
|
private:
|
|
template<typename Callback>
|
|
void for_each_fragment(Callback);
|
|
};
|
|
|
|
}
|