Skip to main content

Crate scarab_plugin_api

Crate scarab_plugin_api 

Source
Expand description

Scarab Plugin API

This crate provides the core plugin API for the Scarab terminal emulator. It defines traits, types, and utilities for building 3rd-party plugins.

§ECS-Safe Host Bindings

Fusabi plugins interact with Scarab’s ECS through the host_bindings module, which provides safe APIs with capability checks, quotas, and rate limiting.

See host_bindings::HostBindings for the main entry point.

Re-exports§

pub use config::PluginConfig;
pub use config::PluginDiscovery;
pub use context::PluginContext;
pub use copy_mode::get_selection_bounds;
pub use copy_mode::normalize_selection;
pub use copy_mode::CopyModeCursor;
pub use copy_mode::CopyModeState;
pub use copy_mode::SearchDirection;
pub use copy_mode::SearchMatch;
pub use copy_mode::SearchState;
pub use copy_mode::Selection;
pub use copy_mode::SelectionMode;
pub use delight::Achievement;
pub use delight::PluginMood;
pub use error::PluginError;
pub use error::Result;
pub use events::EventArgs;
pub use events::EventData;
pub use events::EventHandler;
pub use events::EventRegistry;Deprecated
pub use events::EventResult;
pub use events::EventType;
pub use events::HandlerEntry;
pub use host_bindings::HostBindingLimits;
pub use host_bindings::HostBindings;
pub use host_bindings::NavKeymap;
pub use host_bindings::NavStyle;
pub use host_bindings::ResourceUsage;
pub use host_bindings::DEFAULT_MAX_FOCUSABLES;
pub use host_bindings::DEFAULT_MAX_OVERLAYS;
pub use host_bindings::DEFAULT_MAX_STATUS_ITEMS;
pub use host_bindings::DEFAULT_RATE_LIMIT;
pub use key_tables::ActivateKeyTableMode;
pub use key_tables::ClipboardKind;
pub use key_tables::CopyModeAction;
pub use key_tables::Direction;
pub use key_tables::KeyAction;
pub use key_tables::KeyCode;
pub use key_tables::KeyCombo;
pub use key_tables::KeyModifiers;
pub use key_tables::KeyTable;
pub use key_tables::KeyTableActivation;
pub use key_tables::KeyTableStack;
pub use key_tables::LeaderKeyConfig;
pub use key_tables::LeaderKeyState;
pub use key_tables::SearchAction;
pub use key_tables::SplitDirection;
pub use manifest::Capability;
pub use manifest::FusabiModule;
pub use manifest::ManifestError;
pub use manifest::PluginManifest;
pub use menu::MenuAction;
pub use menu::MenuItem;
pub use navigation::validate_focusable;
pub use navigation::NavigationExt;
pub use navigation::PluginFocusable;
pub use navigation::PluginFocusableAction;
pub use navigation::PluginNavCapabilities;
pub use navigation::ValidationError;
pub use object_model::ObjectError;
pub use object_model::ObjectHandle;
pub use object_model::ObjectRegistry;
pub use object_model::ObjectType;
pub use object_model::RegistryEntry;
pub use plugin::Plugin;
pub use plugin::PluginMetadata;
pub use status_bar::AnsiColor;
pub use status_bar::Color;
pub use status_bar::RenderItem;
pub use status_bar::StatusBarSide;
pub use status_bar::StatusBarUpdate;
pub use status_bar::UnderlineStyle;
pub use types::Action;
pub use types::HookType;
pub use types::PluginInfo;

Modules§

config
Plugin configuration loading and discovery
context
Plugin context providing access to terminal state
copy_mode
Copy Mode & Advanced Selection
delight
Delightful messages, ASCII art, and celebrations for the plugin system
error
Error types for plugin operations
events
Rich Event System
host_bindings
ECS-safe host bindings for Fusabi plugins
key_tables
Key Tables & Modal Editing
manifest
Plugin manifest schema and validation
menu
Plugin menu system for the Scarab Dock
navigation
Navigation API for plugins
object_model
Object Model for exposing terminal state to Fusabi scripts
plugin
Core plugin trait and metadata definitions
status_bar
Status Bar Rendering API for Scarab terminal emulator
types
Common types used throughout the plugin API

Constants§

API_VERSION
Current plugin API version