mirror of
https://github.com/emilk/egui.git
synced 2026-06-26 14:49:06 -04:00
Make all lines and rectangles crisp (#5518)
* Merge this first: https://github.com/emilk/egui/pull/5517 This aligns all rectangles and (horizontal or vertical) line segments to the physical pixel grid in the `epaint::Tessellator`, making these shapes appear crisp everywhere. * Closes https://github.com/emilk/egui/issues/5164 * Closes https://github.com/emilk/egui/issues/3667 This undoes a lot of the explicit, egui-side aligning added in: * https://github.com/emilk/egui/pull/4943 The new approach has several benefits over the old one: * It is done automatically by epaint, so it is applied to everything (no longer opt-in) * It is applied after any layer transforms (so it always works) * It makes line segments crisper on high-DPI screens * All filled rectangles now has sides that end on pixel boundaries
This commit is contained in:
@@ -4,7 +4,7 @@ version = "0.1.0"
|
||||
authors = ["Emil Ernerfeldt <emil.ernerfeldt@gmail.com>"]
|
||||
license = "MIT OR Apache-2.0"
|
||||
edition = "2021"
|
||||
rust-version = "1.76"
|
||||
rust-version = "1.80"
|
||||
publish = false
|
||||
|
||||
# `unsafe_code` is required for `#[no_mangle]`, disable workspace lints to workaround lint error.
|
||||
@@ -16,10 +16,7 @@ crate-type = ["cdylib"]
|
||||
|
||||
|
||||
[dependencies]
|
||||
eframe = { workspace = true, features = [
|
||||
"default",
|
||||
"android-native-activity",
|
||||
] }
|
||||
eframe = { workspace = true, features = ["default", "android-native-activity"] }
|
||||
|
||||
# For image support:
|
||||
egui_extras = { workspace = true, features = ["default", "image"] }
|
||||
@@ -29,4 +26,4 @@ winit = { workspace = true }
|
||||
android_logger = "0.14"
|
||||
|
||||
[package.metadata.android]
|
||||
build_targets = [ "armv7-linux-androideabi", "aarch64-linux-android" ]
|
||||
build_targets = ["armv7-linux-androideabi", "aarch64-linux-android"]
|
||||
|
||||
Reference in New Issue
Block a user