ladybird/Libraries/LibWeb/SVG/SVGGeometryElement.h
Shannon Booth f87041bf3a LibGC+Everywhere: Factor out a LibGC from LibJS
Resulting in a massive rename across almost everywhere! Alongside the
namespace change, we now have the following names:

 * JS::NonnullGCPtr -> GC::Ref
 * JS::GCPtr -> GC::Ptr
 * JS::HeapFunction -> GC::Function
 * JS::CellImpl -> GC::Cell
 * JS::Handle -> GC::Root
2024-11-15 14:49:20 +01:00

32 lines
835 B
C++

/*
* Copyright (c) 2020, Matthew Olsson <mattco@serenityos.org>
*
* SPDX-License-Identifier: BSD-2-Clause
*/
#pragma once
#include <LibWeb/Geometry/DOMPoint.h>
#include <LibWeb/SVG/SVGGraphicsElement.h>
namespace Web::SVG {
// https://svgwg.org/svg2-draft/types.html#InterfaceSVGGeometryElement
class SVGGeometryElement : public SVGGraphicsElement {
WEB_PLATFORM_OBJECT(SVGGeometryElement, SVGGraphicsElement);
public:
virtual GC::Ptr<Layout::Node> create_layout_node(CSS::StyleProperties) override;
virtual Gfx::Path get_path(CSSPixelSize viewport_size) = 0;
float get_total_length();
GC::Ref<Geometry::DOMPoint> get_point_at_length(float distance);
protected:
SVGGeometryElement(DOM::Document& document, DOM::QualifiedName qualified_name);
virtual void initialize(JS::Realm&) override;
};
}