SVGGeometryPaintable.h 753 B

123456789101112131415161718192021222324252627282930
  1. /*
  2. * Copyright (c) 2022, Andreas Kling <kling@serenityos.org>
  3. *
  4. * SPDX-License-Identifier: BSD-2-Clause
  5. */
  6. #pragma once
  7. #include <LibWeb/Layout/SVGGeometryBox.h>
  8. #include <LibWeb/Painting/SVGGraphicsPaintable.h>
  9. namespace Web::Painting {
  10. class SVGGeometryPaintable final : public SVGGraphicsPaintable {
  11. JS_CELL(SVGGeometryPaintable, SVGGraphicsPaintable);
  12. public:
  13. static JS::NonnullGCPtr<SVGGeometryPaintable> create(Layout::SVGGeometryBox const&);
  14. virtual Optional<HitTestResult> hit_test(CSSPixelPoint, HitTestType) const override;
  15. virtual void paint(PaintContext&, PaintPhase) const override;
  16. Layout::SVGGeometryBox const& layout_box() const;
  17. protected:
  18. SVGGeometryPaintable(Layout::SVGGeometryBox const&);
  19. };
  20. }