/**
 * Canvas Manager
 *
 * Manages visual workspace canvases, elements, and operations.
 */
import { EventEmitter } from 'events';
import type { Canvas, CanvasConfig, CanvasElement, CanvasElementType, Position, Size, ExportOptions } from './types.js';
/**
 * Canvas Manager
 */
export declare class CanvasManager extends EventEmitter {
    private canvases;
    private history;
    private historyIndex;
    /**
     * Create a new canvas
     */
    createCanvas(config?: Partial<CanvasConfig>): Canvas;
    /**
     * Get a canvas by ID
     */
    getCanvas(canvasId: string): Canvas | undefined;
    /**
     * Get all canvases
     */
    getAllCanvases(): Canvas[];
    /**
     * Delete a canvas
     */
    deleteCanvas(canvasId: string): boolean;
    /**
     * Update canvas configuration
     */
    updateCanvasConfig(canvasId: string, config: Partial<CanvasConfig>): void;
    /**
     * Add an element to canvas
     */
    addElement(canvasId: string, element: Omit<CanvasElement, 'id' | 'createdAt' | 'updatedAt' | 'zIndex'>): CanvasElement;
    /**
     * Update an element
     */
    updateElement(canvasId: string, elementId: string, updates: Partial<CanvasElement>): CanvasElement | null;
    /**
     * Delete an element
     */
    deleteElement(canvasId: string, elementId: string): boolean;
    /**
     * Get an element by ID
     */
    getElement(canvasId: string, elementId: string): CanvasElement | undefined;
    /**
     * Get elements by type
     */
    getElementsByType(canvasId: string, type: CanvasElementType): CanvasElement[];
    /**
     * Move an element
     */
    moveElement(canvasId: string, elementId: string, position: Position): CanvasElement | null;
    /**
     * Resize an element
     */
    resizeElement(canvasId: string, elementId: string, size: Size): CanvasElement | null;
    /**
     * Snap position to grid
     */
    private snapToGrid;
    /**
     * Snap size to grid
     */
    private snapSizeToGrid;
    /**
     * Select an element
     */
    selectElement(canvasId: string, elementId: string, addToSelection?: boolean): void;
    /**
     * Deselect an element
     */
    deselectElement(canvasId: string, elementId: string): void;
    /**
     * Clear selection
     */
    clearSelection(canvasId: string): void;
    /**
     * Get selected elements
     */
    getSelectedElements(canvasId: string): CanvasElement[];
    /**
     * Bring element to front
     */
    bringToFront(canvasId: string, elementId: string): void;
    /**
     * Send element to back
     */
    sendToBack(canvasId: string, elementId: string): void;
    /**
     * Add history entry
     */
    private addHistoryEntry;
    /**
     * Undo last action
     */
    undo(canvasId: string): boolean;
    /**
     * Redo last undone action
     */
    redo(canvasId: string): boolean;
    /**
     * Check if can undo
     */
    canUndo(canvasId: string): boolean;
    /**
     * Check if can redo
     */
    canRedo(canvasId: string): boolean;
    /**
     * Render canvas to terminal (ASCII/ANSI)
     */
    renderToTerminal(canvasId: string, width?: number, height?: number): string;
    /**
     * Render canvas to HTML
     */
    renderToHTML(canvasId: string): string;
    /**
     * Convert element to HTML
     */
    private elementToHTML;
    /**
     * Export canvas
     */
    export(canvasId: string, options: ExportOptions): Promise<Buffer | string>;
    /**
     * Render to SVG
     */
    private renderToSVG;
    /**
     * Convert element to SVG
     */
    private elementToSVG;
    /**
     * Import canvas from JSON
     */
    importCanvas(json: string): Canvas;
    /**
     * Shutdown and cleanup
     */
    shutdown(): void;
}
/**
 * Get canvas manager instance
 */
export declare function getCanvasManager(): CanvasManager;
/**
 * Reset canvas manager
 */
export declare function resetCanvasManager(): void;
export default CanvasManager;
