import { RGBA } from "./lib/RGBA";
import { type RenderLib, type VisualCursor, type LineInfo } from "./zig";
import { type Pointer } from "bun:ffi";
import type { EditBuffer } from "./edit-buffer";
export interface Viewport {
    offsetY: number;
    offsetX: number;
    height: number;
    width: number;
}
export type { VisualCursor };
export declare class EditorView {
    private lib;
    private viewPtr;
    private editBuffer;
    private _destroyed;
    private _extmarksController?;
    constructor(lib: RenderLib, ptr: Pointer, editBuffer: EditBuffer);
    static create(editBuffer: EditBuffer, viewportWidth: number, viewportHeight: number): EditorView;
    private guard;
    get ptr(): Pointer;
    setViewportSize(width: number, height: number): void;
    getViewport(): Viewport;
    setScrollMargin(margin: number): void;
    setWrapMode(mode: "none" | "char" | "word"): void;
    getVirtualLineCount(): number;
    getTotalVirtualLineCount(): number;
    setSelection(start: number, end: number, bgColor?: RGBA, fgColor?: RGBA): void;
    resetSelection(): void;
    getSelection(): {
        start: number;
        end: number;
    } | null;
    hasSelection(): boolean;
    setLocalSelection(anchorX: number, anchorY: number, focusX: number, focusY: number, bgColor?: RGBA, fgColor?: RGBA): boolean;
    resetLocalSelection(): void;
    getSelectedText(): string;
    getCursor(): {
        row: number;
        col: number;
    };
    getText(): string;
    getVisualCursor(): VisualCursor;
    moveUpVisual(): void;
    moveDownVisual(): void;
    deleteSelectedText(): void;
    setCursorByOffset(offset: number): void;
    getNextWordBoundary(): VisualCursor;
    getPrevWordBoundary(): VisualCursor;
    getEOL(): VisualCursor;
    getLineInfo(): LineInfo;
    getLogicalLineInfo(): LineInfo;
    get extmarks(): any;
    setPlaceholderStyledText(chunks: {
        text: string;
        fg?: RGBA;
        bg?: RGBA;
        attributes?: number;
    }[]): void;
    destroy(): void;
}
