Implemented Expander
- Updated example to show behavior - Created styles for Expander and ExpanderRow - Simpler implementation of `ExpanderRow` - Deleted `ExpanderData` and replaced it with `ExpanderRow` - Every row can now have child rows. - Ran cargo fmt. - Deleted settings example - Added expander to cosmic example - Expander icons now render ListBox partially implemented
This commit is contained in:
parent
a50294676d
commit
7743d0d084
22 changed files with 1222 additions and 738 deletions
|
|
@ -29,9 +29,7 @@ impl<'a> FontLayoutLine<'a> {
|
|||
let y = bb.min.y as i32;
|
||||
outline.draw(|off_x, off_y, v| {
|
||||
//TODO: ensure v * 255.0 does not overflow!
|
||||
let color =
|
||||
((v * 255.0) as u32) << 24 |
|
||||
base & 0xFFFFFF;
|
||||
let color = ((v * 255.0) as u32) << 24 | base & 0xFFFFFF;
|
||||
f(x + off_x as i32, y + off_y as i32, color);
|
||||
});
|
||||
}
|
||||
|
|
@ -42,9 +40,7 @@ impl<'a> FontLayoutLine<'a> {
|
|||
let y = bb.min.y;
|
||||
glyph.inner.draw(|off_x, off_y, v| {
|
||||
//TODO: ensure v * 255.0 does not overflow!
|
||||
let color =
|
||||
((v * 255.0) as u32) << 24 |
|
||||
base & 0xFFFFFF;
|
||||
let color = ((v * 255.0) as u32) << 24 | base & 0xFFFFFF;
|
||||
f(x + off_x as i32, y + off_y as i32, color);
|
||||
});
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue