From ffcc3f066c181132956a5938683361be34d14f9a Mon Sep 17 00:00:00 2001 From: Emil Ernerfeldt Date: Fri, 22 Dec 2023 17:33:01 +0100 Subject: [PATCH] Typos and doc improvements --- crates/ecolor/src/color32.rs | 2 +- crates/eframe/src/epi.rs | 2 +- crates/egui/src/context.rs | 8 ++++++-- 3 files changed, 8 insertions(+), 4 deletions(-) diff --git a/crates/ecolor/src/color32.rs b/crates/ecolor/src/color32.rs index 32e1487b..f3cf3fe6 100644 --- a/crates/ecolor/src/color32.rs +++ b/crates/ecolor/src/color32.rs @@ -71,7 +71,7 @@ impl Color32 { /// i.e. often taken to mean "no color". pub const PLACEHOLDER: Color32 = Color32::from_rgba_premultiplied(64, 254, 0, 128); - #[deprecated = "Renmaed to PLACEHOLDER"] + #[deprecated = "Renamed to PLACEHOLDER"] pub const TEMPORARY_COLOR: Color32 = Self::PLACEHOLDER; #[inline] diff --git a/crates/eframe/src/epi.rs b/crates/eframe/src/epi.rs index 115235cd..8f96b796 100644 --- a/crates/eframe/src/epi.rs +++ b/crates/eframe/src/epi.rs @@ -581,7 +581,7 @@ impl std::str::FromStr for Renderer { /// Represents the surroundings of your app. /// /// It provides methods to inspect the surroundings (are we on the web?), -/// allocate textures, and change settings (e.g. window size). +/// access to persistent storage, and access to the rendering backend. pub struct Frame { /// Information about the integration. pub(crate) info: IntegrationInfo, diff --git a/crates/egui/src/context.rs b/crates/egui/src/context.rs index c24a9d02..02d58390 100644 --- a/crates/egui/src/context.rs +++ b/crates/egui/src/context.rs @@ -1191,11 +1191,13 @@ impl Context { /// If this is called at least once in a frame, then there will be another frame right after this. /// Call as many times as you wish, only one repaint will be issued. /// + /// To request repaint with a delay, use [`Self::request_repaint_after`]. + /// /// If called from outside the UI thread, the UI thread will wake up and run, /// provided the egui integration has set that up via [`Self::set_request_repaint_callback`] /// (this will work on `eframe`). /// - /// This will repaint the current viewport + /// This will repaint the current viewport. pub fn request_repaint(&self) { self.request_repaint_of(self.viewport_id()); } @@ -1205,11 +1207,13 @@ impl Context { /// If this is called at least once in a frame, then there will be another frame right after this. /// Call as many times as you wish, only one repaint will be issued. /// + /// To request repaint with a delay, use [`Self::request_repaint_after_for`]. + /// /// If called from outside the UI thread, the UI thread will wake up and run, /// provided the egui integration has set that up via [`Self::set_request_repaint_callback`] /// (this will work on `eframe`). /// - /// This will repaint the specified viewport + /// This will repaint the specified viewport. pub fn request_repaint_of(&self, id: ViewportId) { self.write(|ctx| ctx.request_repaint(id)); }