mirror of
https://github.com/noib3/nvim-oxi.git
synced 2025-07-07 13:25:18 +00:00
Fix Nightly (#219)
This commit is contained in:
parent
6f5f735099
commit
f751ef4324
4 changed files with 60 additions and 21 deletions
|
@ -1,6 +1,8 @@
|
|||
use types::{Array, Integer};
|
||||
|
||||
use crate::trait_utils::StringOrListOfStrings;
|
||||
#[cfg(feature = "neovim-nightly")]
|
||||
use crate::types::VirtLinesOverflow;
|
||||
use crate::types::{ExtmarkHlMode, ExtmarkVirtTextPosition};
|
||||
|
||||
/// Options passed to [`Buffer::set_extmark()`](crate::Buffer::set_extmark).
|
||||
|
@ -425,6 +427,12 @@ pub struct SetExtmarkOpts {
|
|||
#[builder(argtype = "bool")]
|
||||
virt_lines_leftcol: types::Boolean,
|
||||
|
||||
/// Controls how to handle virtual lines wider than the window.
|
||||
#[cfg_attr(docsrs, doc(cfg(feature = "neovim-nightly")))]
|
||||
#[cfg(feature = "neovim-nightly")]
|
||||
#[builder(argtype = "VirtLinesOverflow", inline = "{0}.into()")]
|
||||
virt_lines_overflow: types::String,
|
||||
|
||||
/// Whether the extmark should not be placed if the line or column value is
|
||||
/// past the end of the buffer or end of the line, respectively. Defaults
|
||||
/// to `true`.
|
||||
|
@ -479,6 +487,13 @@ pub struct SetExtmarkOpts {
|
|||
)]
|
||||
conceal: types::String,
|
||||
|
||||
/// When called, lines in the range are not drawn at all (according to
|
||||
/// `conceallevel`); the next unconcealed line is drawn instead.
|
||||
#[cfg_attr(docsrs, doc(cfg(feature = "neovim-nightly")))]
|
||||
#[cfg(feature = "neovim-nightly")]
|
||||
#[builder(argtype = "()", inline = "{let _ = {0}; types::String::new()}")]
|
||||
conceal_lines: types::String,
|
||||
|
||||
#[builder(argtype = "bool")]
|
||||
spell: types::Boolean,
|
||||
|
||||
|
|
|
@ -43,6 +43,8 @@ mod statusline_highlight_infos;
|
|||
mod statusline_infos;
|
||||
mod ui_infos;
|
||||
mod viml_ast_node;
|
||||
#[cfg(feature = "neovim-nightly")] // On Nightly.
|
||||
mod virt_lines_overflow;
|
||||
#[cfg(feature = "neovim-0-10")] // On 0.10 and nightly.
|
||||
mod win_text_height_infos;
|
||||
mod window_anchor;
|
||||
|
@ -97,6 +99,8 @@ pub use statusline_highlight_infos::*;
|
|||
pub use statusline_infos::*;
|
||||
pub use ui_infos::*;
|
||||
pub use viml_ast_node::*;
|
||||
#[cfg(feature = "neovim-nightly")] // On Nightly.
|
||||
pub use virt_lines_overflow::VirtLinesOverflow;
|
||||
#[cfg(feature = "neovim-0-10")] // On 0.10 and nightly.
|
||||
pub use win_text_height_infos::*;
|
||||
pub use window_anchor::*;
|
||||
|
|
20
crates/api/src/types/virt_lines_overflow.rs
Normal file
20
crates/api/src/types/virt_lines_overflow.rs
Normal file
|
@ -0,0 +1,20 @@
|
|||
#[derive(Debug, Copy, Clone, PartialEq, Eq)]
|
||||
pub enum VirtLinesOverflow {
|
||||
Scroll,
|
||||
Trunc,
|
||||
}
|
||||
|
||||
impl VirtLinesOverflow {
|
||||
fn as_str(&self) -> &'static str {
|
||||
match self {
|
||||
Self::Scroll => "scroll",
|
||||
Self::Trunc => "trunk",
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
impl From<VirtLinesOverflow> for types::String {
|
||||
fn from(virt_lines_overflow: VirtLinesOverflow) -> Self {
|
||||
virt_lines_overflow.as_str().into()
|
||||
}
|
||||
}
|
42
flake.lock
generated
42
flake.lock
generated
|
@ -40,11 +40,11 @@
|
|||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1736143030,
|
||||
"narHash": "sha256-+hu54pAoLDEZT9pjHlqL9DNzWz0NbUn8NEAHP7PQPzU=",
|
||||
"lastModified": 1738453229,
|
||||
"narHash": "sha256-7H9XgNiGLKN1G1CgRh0vUL4AheZSYzPm+zmZ7vxbJdo=",
|
||||
"owner": "hercules-ci",
|
||||
"repo": "flake-parts",
|
||||
"rev": "b905f6fc23a9051a6e1b741e1438dbfc0634c6de",
|
||||
"rev": "32ea77a06711b758da0ad9bd6a844c5740a87abd",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
@ -62,11 +62,11 @@
|
|||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1736143030,
|
||||
"narHash": "sha256-+hu54pAoLDEZT9pjHlqL9DNzWz0NbUn8NEAHP7PQPzU=",
|
||||
"lastModified": 1738453229,
|
||||
"narHash": "sha256-7H9XgNiGLKN1G1CgRh0vUL4AheZSYzPm+zmZ7vxbJdo=",
|
||||
"owner": "hercules-ci",
|
||||
"repo": "flake-parts",
|
||||
"rev": "b905f6fc23a9051a6e1b741e1438dbfc0634c6de",
|
||||
"rev": "32ea77a06711b758da0ad9bd6a844c5740a87abd",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
@ -146,11 +146,11 @@
|
|||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1736917206,
|
||||
"narHash": "sha256-JTBWmyGf8K1Rwb+gviHIUzRJk/sITtT+72HXFkTZUjo=",
|
||||
"lastModified": 1739595404,
|
||||
"narHash": "sha256-0CjCfbq0yHWexOrpO06e2WU1r5JAqR6ffy1zgM3NksI=",
|
||||
"owner": "hercules-ci",
|
||||
"repo": "hercules-ci-effects",
|
||||
"rev": "afd0a42e8c61ebb56899315ee4084a8b2e4ff425",
|
||||
"rev": "06519cec8fb32d219006da6eacd255504a9996af",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
@ -172,11 +172,11 @@
|
|||
"treefmt-nix": "treefmt-nix"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1737614530,
|
||||
"narHash": "sha256-s5+trj2UfrIWlrCm+hKDB5+36kY5scH9MxM9zfU+4qc=",
|
||||
"lastModified": 1740647326,
|
||||
"narHash": "sha256-sna9JSHxSGqb2y+qW4cX8Tjd/jJm0gJbwnsd7RPu3H4=",
|
||||
"owner": "nix-community",
|
||||
"repo": "neovim-nightly-overlay",
|
||||
"rev": "7d9aaf2f175602b8511e4c5134c4a975628c6948",
|
||||
"rev": "18b8e8cca2aa0a21ded8a42423df4fb9efd24117",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
@ -189,11 +189,11 @@
|
|||
"neovim-src": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1737560784,
|
||||
"narHash": "sha256-bW3ub7hI5Ml+4cFErZvlbbQNDmmycoroRYYAegj33qo=",
|
||||
"lastModified": 1740610854,
|
||||
"narHash": "sha256-pQ8BBwNdVjbiK3YgQc6twbL/1crXtM/jM9whvc6T9i8=",
|
||||
"owner": "neovim",
|
||||
"repo": "neovim",
|
||||
"rev": "af0ef2ac9dd19b7c4005a3197334d3e7d554646c",
|
||||
"rev": "3cce6570312830dfab9efd9d521125f0049ad55f",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
@ -204,11 +204,11 @@
|
|||
},
|
||||
"nixpkgs": {
|
||||
"locked": {
|
||||
"lastModified": 1737469691,
|
||||
"narHash": "sha256-nmKOgAU48S41dTPIXAq0AHZSehWUn6ZPrUKijHAMmIk=",
|
||||
"lastModified": 1740560979,
|
||||
"narHash": "sha256-Vr3Qi346M+8CjedtbyUevIGDZW8LcA1fTG0ugPY/Hic=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "9e4d5190a9482a1fb9d18adf0bdb83c6e506eaab",
|
||||
"rev": "5135c59491985879812717f4c9fea69604e7f26f",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
@ -248,11 +248,11 @@
|
|||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1737483750,
|
||||
"narHash": "sha256-5An1wq5U8sNycOBBg3nsDDgpwBmR9liOpDGlhliA6Xo=",
|
||||
"lastModified": 1739829690,
|
||||
"narHash": "sha256-mL1szCeIsjh6Khn3nH2cYtwO5YXG6gBiTw1A30iGeDU=",
|
||||
"owner": "numtide",
|
||||
"repo": "treefmt-nix",
|
||||
"rev": "f2cc121df15418d028a59c9737d38e3a90fbaf8f",
|
||||
"rev": "3d0579f5cc93436052d94b73925b48973a104204",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue