MingaEditor.RenderPipeline.Scroll.WindowScroll (Minga v0.1.0)

Copy Markdown View Source

Per-window data consumed by the pure scroll and content stages.

Bundles the viewport, buffer snapshot, cursor positions, gutter dimensions, buffer options, and pre-fetched signs for one window. Downstream render stages consume this struct instead of making GenServer calls.

Summary

Types

t()

@type t() :: %MingaEditor.RenderPipeline.Scroll.WindowScroll{
  buf_version: non_neg_integer(),
  content_epoch: non_neg_integer(),
  content_w: pos_integer(),
  cursor_byte_col: non_neg_integer(),
  cursor_col: non_neg_integer(),
  cursor_line: non_neg_integer(),
  first_line: non_neg_integer(),
  full_refresh: boolean(),
  git_signs: %{required(non_neg_integer()) => atom()},
  gutter_w: non_neg_integer(),
  has_sign_column: boolean(),
  is_active: boolean(),
  line_number_style: atom(),
  lines: [String.t()],
  preview_matches: list(),
  snapshot: Minga.Buffer.RenderSnapshot.t(),
  total_visual_rows: non_neg_integer() | nil,
  viewport: MingaEditor.Viewport.t(),
  visible_line_map:
    [MingaEditor.FoldMap.VisibleLines.line_entry()]
    | [MingaEditor.DisplayMap.entry()]
    | nil,
  width_oracle: Minga.Core.WidthOracle.t(),
  win_id: MingaEditor.Window.id(),
  win_layout: MingaEditor.Layout.window_layout(),
  window: MingaEditor.Window.t(),
  wrap_on: boolean()
}