|
|
Donner SVG Editor & Engine
SVG-native editor and embeddable SVG2 + CSS3 engine in C++20, with GPU (WebGPU) and compact CPU renderers, built for correctness, security, and performance.
|
#include <cstddef>#include <optional>#include <span>#include <vector>#include "donner/base/Box.h"#include "donner/base/Path.h"#include "donner/base/Vector2.h"#include "donner/editor/GlTextureCache.h"#include "donner/editor/MenuBarPresenter.h"#include "donner/editor/OverlayRenderer.h"#include "donner/editor/PresentedFrameComposer.h"#include "donner/editor/SelectTool.h"#include "donner/editor/ViewportInteractionController.h"#include "donner/editor/ViewportState.h"Classes | |
| struct | donner::editor::RenderPanePresenterState |
| class | donner::editor::RenderPanePresenter |
Namespaces | |
| namespace | donner |
| Top-level Donner namespace, which is split into different sub-namespaces such as donner::svg and donner::css. | |
Functions | |
| bool | donner::editor::ShouldPresentCompositedTile (const GlTextureCache::TileView &tile, Entity suppressedLayerEntity, bool suppressDragTargetTiles=false) |
| Return true when a composited tile should be drawn in the render pane. | |
| bool | donner::editor::TileMatchesActiveDragPreview (const GlTextureCache::TileView &tile, const std::optional< SelectTool::ActiveDragPreview > &activeDragPreview) |
Return true when tile should receive the current active-drag transform. | |
| bool | donner::editor::HasPresentableDragTargetTile (const GlTextureCache &textures, const std::optional< SelectTool::ActiveDragPreview > &activeDragPreview, Entity suppressedLayerEntity, bool suppressDragTargetTiles=false) |
| Return true when the presenter can move the active drag target in the current tile set. | |
| bool | donner::editor::ShouldPresentOverviewTiles (bool activeTilesViewportBounded, std::span< const GlTextureCache::TileView > overviewTiles) |
| Return true when retained overview tiles should be drawn behind the active tile set. | |
| bool | donner::editor::PresentedTileQuadIntersectsScreenRect (const PresentedTileQuad &tileQuad, const Box2d &screenRect) |
| Return true when a presented tile quad has visible overlap with a screen rect. | |
| std::optional< Box2d > | donner::editor::PresentedImageClipRect (const Box2d &paneRect, const Box2d &imageRect) |
| Return the screen-space clip rect for presented document pixels. | |
Variables | |
| constexpr double | donner::editor::kRenderPaneCheckerboardSize = 16.0 |
| constexpr double | donner::editor::kFramebufferCheckerboardSize = kRenderPaneCheckerboardSize |
|
nodiscard |
Return true when the presenter can move the active drag target in the current tile set.
| textures | Presentation texture cache. |
| activeDragPreview | Active drag preview driving presenter-side transforms. |
| suppressedLayerEntity | Promoted entity hidden from presentation. |
| suppressDragTargetTiles | True when drag target tiles are globally hidden. |
|
nodiscard |
Return the screen-space clip rect for presented document pixels.
| paneRect | Screen-space render-pane bounds. |
| imageRect | Screen-space artboard/image bounds. |
|
nodiscard |
Return true when a presented tile quad has visible overlap with a screen rect.
| tileQuad | Output-space tile quad from ComputePresentedTileQuad. |
| screenRect | Screen-space clip rect, usually the render pane bounds. |
|
nodiscard |
Return true when a composited tile should be drawn in the render pane.
| tile | Tile view published by GlTextureCache. |
| suppressedLayerEntity | Promoted entity whose cached or immediate pixels should not be drawn while selection chrome remains visible. Null leaves all entity-owned tiles eligible. |
| suppressDragTargetTiles | True when the current selected element is display:none and legacy/metadata-missing elevated drag-target tiles should be hidden as a fallback. |
|
nodiscard |
Return true when retained overview tiles should be drawn behind the active tile set.
Overview infill is only coherent under viewport-bounded active tiles. Full-document active tiles already represent the current presentation, so drawing an older retained overview underneath can reintroduce stale pixels during a transform drag.
| activeTilesViewportBounded | True when the active tile set covers only the viewport. |
| overviewTiles | Retained full-document overview tiles. |
|
nodiscard |
Return true when tile should receive the current active-drag transform.
Selection prewarm renders can publish layer tiles before the user starts dragging. Those tiles are valid drag presentation candidates even though their worker-side isDragTarget bit was false at prewarm time.
| tile | Tile view published by GlTextureCache. |
| activeDragPreview | Active drag preview driving presenter-side transforms. |