1
0
Fork 0
forked from wry/wry

Merge pull request #597 from mahkoh/jorth/float-title-always

float: don't shortcut title rendering when rect is empty
This commit is contained in:
mahkoh 2025-09-08 13:01:22 +02:00 committed by GitHub
commit c402dd0153
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -205,13 +205,8 @@ impl FloatNode {
true => theme.colors.focused_title_text.get(),
false => theme.colors.unfocused_title_text.get(),
};
let bw = theme.sizes.border_width.get();
let font = theme.font.get();
let title = self.title.borrow_mut();
let pos = self.position.get();
if pos.width() <= 2 * bw {
return on_completed.event();
}
let ctx = match self.state.render_ctx.get() {
Some(c) => c,
_ => return on_completed.event(),
@ -234,9 +229,6 @@ impl FloatNode {
width = (width as f64 * scale).round() as _;
scalef = Some(scale);
}
if th == 0 || width == 0 {
continue;
}
tex.schedule_render(
on_completed.clone(),
1,