From b8b1bfed039adbe3b2817b203c6105511e6208e6 Mon Sep 17 00:00:00 2001 From: bunnie Date: Sat, 22 Feb 2025 01:06:46 +0800 Subject: [PATCH 1/4] fix doc warnings --- libs/ux-api/src/wordwrap.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libs/ux-api/src/wordwrap.rs b/libs/ux-api/src/wordwrap.rs index cfcf067d1..e1368bb07 100644 --- a/libs/ux-api/src/wordwrap.rs +++ b/libs/ux-api/src/wordwrap.rs @@ -42,7 +42,7 @@ pub struct TypesetWord { /// overall height for the word pub height: isize, /// set if this `word` is not drawable, e.g. a newline placeholder. - /// *however* the Vec should still be checked for an insertion point, so that + /// *however* the `Vec` should still be checked for an insertion point, so that /// successive newlines properly get their insertion point drawn pub non_drawable: bool, /// the position in the originating abstract string of the first character in the word @@ -277,7 +277,7 @@ impl Typesetter { /// the caller must reset the cursor to the desired resume position, otherwise it will pick /// up again at the overflow position. /// - /// The final Vec:: is snapped to the top left of the Renderable region. This + /// The final `Vec::` is snapped to the top left of the Renderable region. This /// needs to be transformed into the final screen coordinate space before blitting. pub fn typeset(&mut self, strat: OverflowStrategy) -> ComposedType { // a composition only lasts as long as the lifetime of this call, and is passed back to the caller From 56123fea8d2199221f2bb816500f3c2c9328d344 Mon Sep 17 00:00:00 2001 From: bunnie Date: Sat, 22 Feb 2025 01:07:01 +0800 Subject: [PATCH 2/4] fix doc warnings --- libs/ux-api/src/minigfx/mod.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libs/ux-api/src/minigfx/mod.rs b/libs/ux-api/src/minigfx/mod.rs index dd4d08aed..0dfaf7bf3 100644 --- a/libs/ux-api/src/minigfx/mod.rs +++ b/libs/ux-api/src/minigfx/mod.rs @@ -67,7 +67,7 @@ pub struct TypesetWord { /// overall height for the word pub height: isize, /// set if this `word` is not drawable, e.g. a newline placeholder. - /// *however* the Vec should still be checked for an insertion point, so that + /// *however* the `Vec` should still be checked for an insertion point, so that /// successive newlines properly get their insertion point drawn pub non_drawable: bool, /// the position in the originating abstract string of the first character in the word From 7e57af5841625f9bc6347e9c4b54556e18ae9d0e Mon Sep 17 00:00:00 2001 From: bunnie Date: Sat, 22 Feb 2025 01:07:12 +0800 Subject: [PATCH 3/4] add documentation target for library this helps cargo doc to run --- libs/ux-api/Cargo.toml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/libs/ux-api/Cargo.toml b/libs/ux-api/Cargo.toml index 1f124e30d..d0896cb06 100644 --- a/libs/ux-api/Cargo.toml +++ b/libs/ux-api/Cargo.toml @@ -65,6 +65,8 @@ cramium-soc = [] precursor = ["blitstr2/precursor"] derive-rkyv = ["rkyv"] +doc-deps = ["hosted", "blitstr2/hosted"] + std = [ "derive-rkyv", "locales", From fabb3174c71e7ea2d08352d055ca589121fdf56f Mon Sep 17 00:00:00 2001 From: bunnie Date: Sat, 22 Feb 2025 01:07:31 +0800 Subject: [PATCH 4/4] specify the doc-deps feature in ux-api so that cargo doc builds correctly --- services/modals/Cargo.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/services/modals/Cargo.toml b/services/modals/Cargo.toml index cce7acf99..31c3fe5f9 100644 --- a/services/modals/Cargo.toml +++ b/services/modals/Cargo.toml @@ -42,7 +42,7 @@ renode = ["utralib/renode", "trng", "gam", "tts-frontend"] cramium-soc = ["utralib/cramium-soc", "cram-hal-service"] hosted-baosec = ["ux-api/hosted-baosec", "cramium-emu"] board-baosec = ["ux-api/board-baosec"] -doc-deps = ["gam"] +doc-deps = ["gam", "ux-api/doc-deps"] tts = [] ditherpunk = []