gui of canvas is from the canvas crate now

This commit is contained in:
Priec
2025-07-29 19:54:29 +02:00
parent a1fa42e204
commit aec5f80879
13 changed files with 370 additions and 53 deletions

View File

@@ -11,6 +11,10 @@ pub mod config;
pub mod suggestions;
pub mod dispatcher;
// GUI module (optional, enabled with "gui" feature)
#[cfg(feature = "gui")]
pub mod gui;
// Re-export the main types for easy use
pub use state::{CanvasState, ActionContext};
pub use actions::{CanvasAction, ActionResult, execute_edit_action, execute_canvas_action};
@@ -18,6 +22,10 @@ pub use modes::{AppMode, ModeManager, HighlightState};
pub use suggestions::SuggestionState;
pub use dispatcher::ActionDispatcher;
// Re-export GUI types when available
#[cfg(feature = "gui")]
pub use gui::{CanvasTheme, render_canvas};
// High-level convenience API
pub mod prelude {
pub use crate::{
@@ -33,4 +41,7 @@ pub mod prelude {
HighlightState,
SuggestionState,
};
#[cfg(feature = "gui")]
pub use crate::{CanvasTheme, render_canvas};
}