nvim_oxi_api/opts/
set_highlight.rs1use types::Object;
2use types::{Boolean, Integer, String as NvimString};
3
4#[derive(Clone, Debug, Default, PartialEq, macros::OptsBuilder)]
5#[repr(C)]
6pub struct SetHighlightOpts {
7 #[builder(mask)]
8 mask: u64,
9
10 #[builder(argtype = "bool")]
11 bold: Boolean,
12
13 #[builder(argtype = "bool")]
14 standout: Boolean,
15
16 #[builder(argtype = "bool")]
17 strikethrough: Boolean,
18
19 #[builder(argtype = "bool")]
20 underline: Boolean,
21
22 #[builder(argtype = "bool")]
23 undercurl: Boolean,
24
25 #[builder(argtype = "bool")]
26 underdouble: Boolean,
27
28 #[builder(argtype = "bool")]
29 underdotted: Boolean,
30
31 #[builder(argtype = "bool")]
32 underdashed: Boolean,
33
34 #[builder(argtype = "bool")]
35 italic: Boolean,
36
37 #[builder(argtype = "bool")]
38 reverse: Boolean,
39
40 #[builder(argtype = "bool")]
41 altfont: Boolean,
42
43 #[builder(argtype = "bool")]
44 nocombine: Boolean,
45
46 #[builder(method = "builder", argtype = "bool")]
47 default: Boolean,
51
52 #[builder(argtype = "&str", inline = "types::String::from({0}).into()")]
53 cterm: Object,
54
55 #[builder(argtype = "&str", inline = "types::String::from({0}).into()")]
56 foreground: Object,
57
58 #[builder(skip)]
59 fg: Object,
60
61 #[builder(argtype = "&str", inline = "types::String::from({0}).into()")]
62 background: Object,
63
64 #[builder(skip)]
65 bg: Object,
66
67 #[builder(argtype = "&str", inline = "types::String::from({0}).into()")]
68 ctermfg: Object,
69
70 #[builder(argtype = "&str", inline = "types::String::from({0}).into()")]
71 ctermbg: Object,
72
73 #[builder(argtype = "&str", inline = "types::String::from({0}).into()")]
74 special: Object,
75
76 #[builder(skip)]
77 sp: Object,
78
79 #[cfg(not(feature = "neovim-0-11"))] #[builder(
81 generics = "Hl: crate::HlGroup",
82 argtype = "Hl",
83 inline = r#"{ let Ok(hl_id) = {0}.to_hl_id() else { return self; }; hl_id.into() }"#
84 )]
85 link: Object,
86
87 #[cfg(feature = "neovim-0-11")] #[builder(
89 generics = "Hl: crate::HlGroup",
90 argtype = "Hl",
91 inline = r#"{ let Ok(hl_id) = {0}.to_hl_id() else { return self; }; hl_id }"#
92 )]
93 link: types::HlGroupId,
94
95 #[cfg(not(feature = "neovim-0-11"))] #[builder(skip)]
97 global_link: Object,
98
99 #[cfg(feature = "neovim-0-11")] #[builder(skip)]
101 global_link: types::HlGroupId,
102
103 #[builder(argtype = "bool")]
104 fallback: Boolean,
105
106 #[builder(argtype = "u8", inline = "{0} as Integer")]
107 blend: Integer,
108
109 #[builder(argtype = "bool")]
110 fg_indexed: Boolean,
111
112 #[builder(argtype = "bool")]
113 bg_indexed: Boolean,
114
115 #[builder(argtype = "bool")]
116 force: Boolean,
117
118 #[builder(skip)]
119 url: NvimString,
120}