summaryrefslogtreecommitdiffstats
path: root/src/ui
diff options
context:
space:
mode:
authorJeff Zhao <jeff.no.zhao@gmail.com>2021-02-02 10:39:00 -0500
committerJeff Zhao <jeff.no.zhao@gmail.com>2021-02-02 10:39:00 -0500
commit0f1c106b611632704618b44b3e8dd05678e5e4bb (patch)
treeafb07cfa681c79271c76119d19ac734ce6da4fc9 /src/ui
parent6268cbbeca71e77ca2c0999f41c313926cb98531 (diff)
remove clipboard dependencies and utilize commands instead
- fix some printing issues
Diffstat (limited to 'src/ui')
-rw-r--r--src/ui/widgets/tui_dirlist.rs2
-rw-r--r--src/ui/widgets/tui_dirlist_detailed.rs2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/ui/widgets/tui_dirlist.rs b/src/ui/widgets/tui_dirlist.rs
index a296283..15ceabb 100644
--- a/src/ui/widgets/tui_dirlist.rs
+++ b/src/ui/widgets/tui_dirlist.rs
@@ -104,7 +104,7 @@ fn print_entry(
let stem_width = stem.width();
buf.set_stringn(x, y, stem, file_drawing_width, style);
if stem_width > file_drawing_width {
- buf.set_string(x + stem_width as u16, y, ELLIPSIS, style);
+ buf.set_string(x + file_drawing_width as u16 - 1, y, ELLIPSIS, style);
}
} else {
let stem_width = stem.width();
diff --git a/src/ui/widgets/tui_dirlist_detailed.rs b/src/ui/widgets/tui_dirlist_detailed.rs
index f06946f..c6cd9ba 100644
--- a/src/ui/widgets/tui_dirlist_detailed.rs
+++ b/src/ui/widgets/tui_dirlist_detailed.rs
@@ -117,7 +117,7 @@ fn print_entry(
let stem_width = stem.width();
buf.set_stringn(x, y, stem, file_drawing_width, style);
if stem_width > file_drawing_width {
- buf.set_string(x + stem_width as u16, y, ELLIPSIS, style);
+ buf.set_string(x + drawing_width as u16 - 1, y, ELLIPSIS, style);
}
} else {
let stem_width = stem.width();