
SPDX License Identifiers are a more compact / standardized way of representing file license information. See: https://spdx.dev/resources/use/#identifiers This was done with the `ambr` search and replace tool. ambr --no-parent-ignore --key-from-file --rep-from-file key.txt rep.txt *
34 lines
789 B
C++
34 lines
789 B
C++
/*
|
|
* Copyright (c) 2018-2020, Andreas Kling <kling@serenityos.org>
|
|
*
|
|
* SPDX-License-Identifier: BSD-2-Clause
|
|
*/
|
|
|
|
#pragma once
|
|
|
|
#include <AK/FlyString.h>
|
|
#include <AK/String.h>
|
|
#include <LibWeb/DOM/CharacterData.h>
|
|
|
|
namespace Web::DOM {
|
|
|
|
class Text final : public CharacterData {
|
|
public:
|
|
using WrapperType = Bindings::TextWrapper;
|
|
|
|
explicit Text(Document&, const String&);
|
|
virtual ~Text() override;
|
|
|
|
// ^Node
|
|
virtual FlyString node_name() const override { return "#text"; }
|
|
virtual bool is_editable() const override { return m_always_editable || CharacterData::is_editable(); }
|
|
|
|
void set_always_editable(bool b) { m_always_editable = b; }
|
|
|
|
private:
|
|
virtual RefPtr<Layout::Node> create_layout_node() override;
|
|
|
|
bool m_always_editable { false };
|
|
};
|
|
|
|
}
|