Skip to content

Commit

Permalink
Merge pull request #264 from meluskyc/bug/263-nvim092
Browse files Browse the repository at this point in the history
Fix blank UI with neovim 0.92
  • Loading branch information
Yatao Li authored Mar 23, 2024
2 parents 2e4087d + 70c4c53 commit ee4316c
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions def.fs
Original file line number Diff line number Diff line change
Expand Up @@ -218,6 +218,7 @@ type GridLine =
row: int
col_start: int
cells: GridCell[]
wrap: bool
}

[<Struct>]
Expand Down Expand Up @@ -624,8 +625,11 @@ let parse_grid_cell (x: obj) =

let parse_grid_line (x: obj) =
match x with
| ObjArray [| (Integer32 grid); (Integer32 row) ; (Integer32 col_start) ; P(parse_grid_cell)cells |]
-> Some {grid = grid; row=row; col_start=col_start; cells=cells}
| ObjArray [| (Integer32 grid); (Integer32 row) ; (Integer32 col_start) ; P(parse_grid_cell)cells ; (Bool wrap) |]
-> Some {grid = grid; row=row; col_start=col_start; cells=cells; wrap=wrap}
// neovim < 0.92 doesn't pass wrap
| ObjArray [| (Integer32 grid); (Integer32 row) ; (Integer32 col_start) ; P(parse_grid_cell)cells |]
-> Some {grid = grid; row=row; col_start=col_start; cells=cells; wrap=false}
| _ -> None

let parse_win_pos (x: obj) =
Expand Down

0 comments on commit ee4316c

Please sign in to comment.