Skip to main content

Crate hjkl_info_popup

Crate hjkl_info_popup 

Source
Expand description

Renderer-agnostic info popup data model.

Provides InfoPopup — the state for a centered floating overlay used by :reg, :marks, :jumps, :changes, and the K-key LSP hover info path. No rendering types are referenced; the TUI adapter lives in hjkl-info-popup-tui.

§Quick start

use hjkl_info_popup::{InfoPopup, InfoPosition, ContentKind};

let popup = InfoPopup::new("registers", "\"a  hello\n\"b  world");
assert_eq!(popup.title, " registers ");
assert!(!popup.dismissed);
assert_eq!(popup.lines().count(), 2);

Structs§

InfoPopup
All state needed to display a centered info popup overlay.
InfoRect
Bounding rect returned by geometry.
InfoViewport
Viewport dimensions for popup placement.

Enums§

ContentKind
How the popup content should be interpreted by the renderer.
InfoPosition
How the popup is positioned within the available area.

Functions§

geometry
Compute the bounding rect for an InfoPopup within viewport.