2020-06-08 00:10:45 +03:00
|
|
|
/*
|
|
|
|
* Copyright (c) 2020, Andreas Kling <kling@serenityos.org>
|
|
|
|
*
|
2021-04-22 11:24:48 +03:00
|
|
|
* SPDX-License-Identifier: BSD-2-Clause
|
2020-06-08 00:10:45 +03:00
|
|
|
*/
|
|
|
|
|
|
|
|
#pragma once
|
|
|
|
|
2021-04-26 18:36:40 +03:00
|
|
|
#include <LibWeb/DOM/ExceptionOr.h>
|
2020-07-26 16:08:16 +03:00
|
|
|
#include <LibWeb/HTML/HTMLElement.h>
|
2021-05-02 19:43:42 +03:00
|
|
|
#include <LibWeb/HTML/HTMLTableCaptionElement.h>
|
2021-04-26 18:36:40 +03:00
|
|
|
#include <LibWeb/HTML/HTMLTableRowElement.h>
|
2020-06-08 00:10:45 +03:00
|
|
|
|
2020-07-28 19:20:36 +03:00
|
|
|
namespace Web::HTML {
|
2020-06-08 00:10:45 +03:00
|
|
|
|
2020-06-12 23:52:38 +03:00
|
|
|
class HTMLTableElement final : public HTMLElement {
|
2020-06-08 00:10:45 +03:00
|
|
|
public:
|
2020-07-27 07:04:26 +03:00
|
|
|
using WrapperType = Bindings::HTMLTableElementWrapper;
|
|
|
|
|
2021-02-07 13:20:15 +03:00
|
|
|
HTMLTableElement(DOM::Document&, QualifiedName);
|
2020-06-08 00:10:45 +03:00
|
|
|
virtual ~HTMLTableElement() override;
|
2020-06-12 23:52:38 +03:00
|
|
|
|
2021-05-02 19:43:42 +03:00
|
|
|
RefPtr<HTMLTableCaptionElement> caption();
|
|
|
|
void set_caption(HTMLTableCaptionElement&);
|
|
|
|
NonnullRefPtr<HTMLTableCaptionElement> create_caption();
|
|
|
|
void delete_caption();
|
|
|
|
|
2021-04-26 18:36:40 +03:00
|
|
|
NonnullRefPtr<DOM::HTMLCollection> rows();
|
|
|
|
DOM::ExceptionOr<NonnullRefPtr<HTMLTableRowElement>> insert_row(long index);
|
|
|
|
DOM::ExceptionOr<void> delete_row(long index);
|
|
|
|
|
2020-06-12 23:52:38 +03:00
|
|
|
private:
|
2020-07-26 21:01:35 +03:00
|
|
|
virtual void apply_presentational_hints(CSS::StyleProperties&) const override;
|
2020-06-08 00:10:45 +03:00
|
|
|
};
|
|
|
|
|
|
|
|
}
|