1
0
mirror of https://github.com/trezor/trezor-firmware.git synced 2025-03-15 15:46:06 +00:00

chore(core/rust): improve vertical centering in some screens

[no changelog]
This commit is contained in:
grdddj 2023-09-05 11:44:42 +02:00 committed by Jiří Musil
parent d2f67d48fa
commit 623e0ce468

View File

@ -399,8 +399,7 @@ extern "C" fn new_confirm_reset_device(n_args: usize, args: *const Obj, kwargs:
let ops = OpTextLayout::<StrBuffer>::new(theme::TEXT_NORMAL) let ops = OpTextLayout::<StrBuffer>::new(theme::TEXT_NORMAL)
.text_normal("By continuing you agree to Trezor Company's terms and conditions.".into()) .text_normal("By continuing you agree to Trezor Company's terms and conditions.".into())
.newline() .next_page()
.newline()
.text_normal("More info at".into()) .text_normal("More info at".into())
.newline() .newline()
.text_bold("trezor.io/tos".into()); .text_bold("trezor.io/tos".into());
@ -762,7 +761,7 @@ extern "C" fn new_confirm_address(n_args: usize, args: *const Obj, kwargs: *mut
let ops = OpTextLayout::new(theme::TEXT_MONO) let ops = OpTextLayout::new(theme::TEXT_MONO)
.line_breaking(LineBreaking::BreakWordsNoHyphen) .line_breaking(LineBreaking::BreakWordsNoHyphen)
.text_mono(address.clone()); .text_mono(address.clone());
let formatted = FormattedText::new(ops); let formatted = FormattedText::new(ops).vertically_centered();
Page::new(btn_layout, btn_actions, formatted).with_title(title.clone()) Page::new(btn_layout, btn_actions, formatted).with_title(title.clone())
}; };
let pages = FlowPages::new(get_page, 1); let pages = FlowPages::new(get_page, 1);