mirror of
https://github.com/nushell/nushell.git
synced 2025-08-15 15:33:21 +02:00
Bump ratatui
to 0.29.0
(#15187)
This is the most recent version Deduplicates the `crossterm` dependency, brings `itertools` in line with the majority of dependencies. In the fight against compile times this sadly introduces a proc-macro-crate for writing proc-macros (`darling`) as a transitive dependency. So may not lead to a compile time improvement (or could make it even slightly worse) Observation: Cargo changed the `Cargo.lock` file version when running this. (this should still be the specified toolchain, so don't expect a risk of locking out the expected `cargo` versions)
This commit is contained in:
committed by
GitHub
parent
1ab09256d7
commit
6f6ad23072
@ -344,7 +344,7 @@ fn draw_frame(
|
||||
layout: &mut Layout,
|
||||
info: ViewInfo,
|
||||
) {
|
||||
let area = f.size();
|
||||
let area = f.area();
|
||||
let available_area = Rect::new(area.x, area.y, area.width, area.height.saturating_sub(2));
|
||||
|
||||
if let Some(page) = view {
|
||||
@ -359,7 +359,7 @@ fn draw_frame(
|
||||
}
|
||||
|
||||
fn draw_info(f: &mut Frame, pager: &mut Pager<'_>, info: ViewInfo) {
|
||||
let area = f.size();
|
||||
let area = f.area();
|
||||
|
||||
if let Some(report) = info.status {
|
||||
let last_2nd_line = area.bottom().saturating_sub(2);
|
||||
@ -453,14 +453,14 @@ fn set_cursor_cmd_bar(f: &mut Frame, area: Rect, pager: &Pager) {
|
||||
let next_pos = (pager.cmd_buf.buf_cmd2.len() + 1) as u16;
|
||||
// 1 skips a ':' char
|
||||
if next_pos < area.width {
|
||||
f.set_cursor(next_pos, area.height - 1);
|
||||
f.set_cursor_position((next_pos, area.height - 1));
|
||||
}
|
||||
} else if pager.search_buf.is_search_input {
|
||||
// todo: deal with a situation where we exceed the bar width
|
||||
let next_pos = (pager.search_buf.buf_cmd_input.len() + 1) as u16;
|
||||
// 1 skips a ':' char
|
||||
if next_pos < area.width {
|
||||
f.set_cursor(next_pos, area.height - 1);
|
||||
f.set_cursor_position((next_pos, area.height - 1));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -109,7 +109,7 @@ impl View for TryView {
|
||||
let cur_w = area.x + 1 + 1 + 1 + max_cmd_len;
|
||||
let cur_w_max = area.x + 1 + 1 + 1 + area.width - 2 - 1 - 1 - 1 - 1;
|
||||
if cur_w < cur_w_max {
|
||||
f.set_cursor(area.x + 1 + 1 + 1 + max_cmd_len, area.y + 1);
|
||||
f.set_cursor_position((area.x + 1 + 1 + 1 + max_cmd_len, area.y + 1));
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user