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.
Loading...
Searching...
No Matches
EditorApp.h File Reference

RenderSession - the headless render-session core used by REPL and tooling. Owns the current document state (URI, raw bytes, rendered bitmap) and exposes a narrow state-transition API that higher layers can call into. More...

#include <cstdint>
#include <filesystem>
#include <string>
#include <string_view>
#include <vector>
#include "donner/svg/renderer/Renderer.h"
Include dependency graph for EditorApp.h:

Classes

struct  donner::editor::app::SourceLoadOptions
 Configuration knobs for loading SVG source bytes. More...
struct  donner::editor::app::RenderSessionOptions
struct  donner::editor::app::RenderSessionSnapshot
 Snapshot of the most recent navigation result. All fields are read-only after EditorApp::navigate returns - subsequent navigations produce a new snapshot. More...
class  donner::editor::app::RenderSession

Namespaces

namespace  donner
 Top-level Donner namespace, which is split into different sub-namespaces such as donner::svg and donner::css.

Enumerations

enum class  donner::editor::app::RenderSessionStatus {
  kEmpty ,
  kLoading ,
  kRendered ,
  kFetchError ,
  kParseError ,
  kRenderError
}
 High-level state the editor can be in. The REPL uses this to decide what status chip / prompt decoration to show the user. More...

Detailed Description

RenderSession - the headless render-session core used by REPL and tooling. Owns the current document state (URI, raw bytes, rendered bitmap) and exposes a narrow state-transition API that higher layers can call into.

This is deliberately UI-free: no ImGui, no GLFW, no GL, no stdin/stdout. The UI layer takes an EditorApp& and drives it - tests can do the same. right now the only mutation the MVP supports is "navigate to a new URI and re-render."

Rendering is performed in-process through svg::Renderer.

Enumeration Type Documentation

◆ RenderSessionStatus

High-level state the editor can be in. The REPL uses this to decide what status chip / prompt decoration to show the user.

Enumerator
kEmpty 

No document loaded yet.

kLoading 

Navigation in flight (rare - rendering is synchronous today).

kRendered 

A bitmap is available and was rendered cleanly.

kFetchError 

Source loading failed. Previous bitmap is retained.

kParseError 

Parser returned an error. Previous bitmap is retained.

kRenderError 

Rasterization failed post-parse. Previous bitmap is retained.