mirror of
https://codeberg.org/unspeaker/tek.git
synced 2025-12-06 19:56:42 +01:00
wip: big flat pt.8: wh -> xy
This commit is contained in:
parent
da25b28ebf
commit
e958b4a2d2
27 changed files with 117 additions and 117 deletions
16
src/pool.rs
16
src/pool.rs
|
|
@ -208,9 +208,9 @@ render!(<Tui>|self: PoolView<'a>|{
|
|||
let upper_right = format!("({})", phrases.len());
|
||||
let color = self.0.phrase().read().unwrap().color;
|
||||
Tui::bg(bg, lay!(move|add|{
|
||||
add(&Fill::wh(Outer(Style::default().fg(color.base.rgb).bg(bg))))?;
|
||||
add(&Fill::xy(Outer(Style::default().fg(color.base.rgb).bg(bg))))?;
|
||||
//add(&Lozenge(Style::default().bg(border_bg).fg(border_color)))?;
|
||||
add(&Padding::xy(0, 1, Fill::wh(col!(move|add|match mode {
|
||||
add(&Padding::xy(0, 1, Fill::xy(col!(move|add|match mode {
|
||||
Some(PoolMode::Import(_, ref file_picker)) => add(file_picker),
|
||||
Some(PoolMode::Export(_, ref file_picker)) => add(file_picker),
|
||||
_ => Ok(for (i, phrase) in phrases.iter().enumerate() {
|
||||
|
|
@ -223,10 +223,10 @@ render!(<Tui>|self: PoolView<'a>|{
|
|||
length.focus = Some(*focus);
|
||||
}
|
||||
}
|
||||
add(&Tui::bg(color.base.rgb, Fill::w(col!([
|
||||
Fill::w(lay!(|add|{
|
||||
add(&Fill::w(Align::w(format!(" {i}"))))?;
|
||||
add(&Fill::w(Align::e(Pull::x(1, length.clone()))))
|
||||
add(&Tui::bg(color.base.rgb, Fill::x(col!([
|
||||
Fill::x(lay!(|add|{
|
||||
add(&Fill::x(Align::w(format!(" {i}"))))?;
|
||||
add(&Fill::x(Align::e(Pull::x(1, length.clone()))))
|
||||
})),
|
||||
Tui::bold(true, {
|
||||
let mut row2 = format!(" {name}");
|
||||
|
|
@ -245,8 +245,8 @@ render!(<Tui>|self: PoolView<'a>|{
|
|||
}))?;
|
||||
})
|
||||
}))))?;
|
||||
add(&Fill::w(Align::nw(Push::x(1, Tui::fg(title_color, upper_left.to_string())))))?;
|
||||
add(&Fill::w(Align::ne(Pull::x(1, Tui::fg(title_color, upper_right.to_string())))))?;
|
||||
add(&Fill::x(Align::nw(Push::x(1, Tui::fg(title_color, upper_left.to_string())))))?;
|
||||
add(&Fill::x(Align::ne(Pull::x(1, Tui::fg(title_color, upper_right.to_string())))))?;
|
||||
add(&self.0.size)
|
||||
}))
|
||||
});
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue