pub struct ChromeString {
pub key: &'static str,
pub en: &'static str,
pub args: usize,
pub slot: usize,
}Expand description
One compiler-authored player-visible string.
Fields§
§key: &'static strThe stable delvewright.ui.… translation key.
en: &'static strThe canonical English text, %s for each argument.
args: usizeHow many with arguments the component supplies.
slot: usizeThis string’s index in ALL — the slot a language table fills.
Implementations§
Source§impl ChromeString
impl ChromeString
Sourcepub fn tagged(&self) -> String
pub fn tagged(&self) -> String
This string as a translation tag over its canonical English, under the bare chrome key.
The plan-time form, for a default the compiler bakes before it knows the
build’s language or the delve’s key namespace. It is not emittable as it
stands: Chrome::rebind is what turns it into the delve’s own pack key,
and crates/delvec/tests/i18n_v2.rs fails the build of any tree that emits
a bare key, so a site that forgets to rebind is a red rather than a string
another delve’s pack can answer.
Trait Implementations§
Source§impl Clone for ChromeString
impl Clone for ChromeString
impl Copy for ChromeString
Source§impl Debug for ChromeString
impl Debug for ChromeString
impl Eq for ChromeString
Source§impl PartialEq for ChromeString
impl PartialEq for ChromeString
impl StructuralPartialEq for ChromeString
Auto Trait Implementations§
impl Freeze for ChromeString
impl RefUnwindSafe for ChromeString
impl Send for ChromeString
impl Sync for ChromeString
impl Unpin for ChromeString
impl UnsafeUnpin for ChromeString
impl UnwindSafe for ChromeString
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more