aboutsummaryrefslogtreecommitdiff
path: root/helix-term/src
diff options
context:
space:
mode:
authorChrHorn2022-07-02 11:59:46 +0000
committerGitHub2022-07-02 11:59:46 +0000
commit9f43dbc45d254ff860f7d33db201b2f0a6073195 (patch)
tree96b730b359c77b38f1026dcc05f341b7a910d4ea /helix-term/src
parent6e2aaed5c2cbcedc9ee4e225510cae4f357888aa (diff)
Highlight whole row in picker menus (#2939)
Diffstat (limited to 'helix-term/src')
-rw-r--r--helix-term/src/ui/picker.rs11
1 files changed, 10 insertions, 1 deletions
diff --git a/helix-term/src/ui/picker.rs b/helix-term/src/ui/picker.rs
index 01fea718..f4dd234a 100644
--- a/helix-term/src/ui/picker.rs
+++ b/helix-term/src/ui/picker.rs
@@ -607,7 +607,16 @@ impl<T: Item + 'static> Component for Picker<T> {
for (i, (_index, option)) in files.take(rows as usize).enumerate() {
let is_active = i == (self.cursor - offset);
if is_active {
- surface.set_string(inner.x.saturating_sub(2), inner.y + i as u16, ">", selected);
+ surface.set_string(
+ inner.x.saturating_sub(3),
+ inner.y + i as u16,
+ " > ",
+ selected,
+ );
+ surface.set_style(
+ Rect::new(inner.x, inner.y + i as u16, inner.width, 1),
+ selected,
+ );
}
let spans = option.label(&self.editor_data);