mirror of
https://github.com/emilk/egui.git
synced 2026-06-28 07:23:13 -04:00
Shape refactor (#705)
* More introspection stats about vertices/indices etc * more serde derive * #[inline] to Shape constructors * Introduce RectShape * Introduce CircleShape * Introduce PathShape * More serde derive * impl Copy for RectShape and CircleShape * Simplify some code * More serde derive * Add helpers for appending more input or output * Serde derives for RawInput * Rename Fonts::from_definitions to Fonts::new * Add Output::take * refactor EguiGlium slightly * Derive PartialEq for RawInput * Improve egui::util::History interface * tweaks * Improve History filter: add minimum length * Calculate galley bounding rect * tessellator: cull line segments and paths * tessellator: cull meshes * Fix bug in History bandwidth estimator
This commit is contained in:
@@ -52,12 +52,11 @@ impl Shadow {
|
||||
let Self { extrusion, color } = *self;
|
||||
|
||||
use crate::tessellator::*;
|
||||
let rect = PaintRect {
|
||||
rect: rect.expand(0.5 * extrusion),
|
||||
corner_radius: corner_radius + 0.5 * extrusion,
|
||||
fill: color,
|
||||
stroke: Default::default(),
|
||||
};
|
||||
let rect = RectShape::filled(
|
||||
rect.expand(0.5 * extrusion),
|
||||
corner_radius + 0.5 * extrusion,
|
||||
color,
|
||||
);
|
||||
let mut tessellator = Tessellator::from_options(TessellationOptions {
|
||||
aa_size: extrusion,
|
||||
anti_alias: true,
|
||||
|
||||
Reference in New Issue
Block a user