retro_core_option_v2_definition

Struct retro_core_option_v2_definition 

Source
#[repr(C)]
pub struct retro_core_option_v2_definition { pub key: *const i8, pub desc: *const i8, pub desc_categorized: *const i8, pub info: *const i8, pub info_categorized: *const i8, pub category_key: *const i8, pub values: [retro_core_option_value; 128], pub default_value: *const i8, }

Fields§

§key: *const i8

Variable to query in RETRO_ENVIRONMENT_GET_VARIABLE. Valid key characters are [a-z, A-Z, 0-9, _, -]

§desc: *const i8

Human-readable core option description

Used as menu label when frontend does not have core option category support e.g. “Video > Aspect Ratio”

§desc_categorized: *const i8

Human-readable core option description

Used as menu label when frontend has core option category support e.g. “Aspect Ratio”, where associated retro_core_option_v2_category::desc is “Video” If empty or NULL, the string specified by desc will be used as the menu label Will be ignored (and may be set to NULL) if category_key is empty or NULL

§info: *const i8

Human-readable core option information

Used as menu sublabel

§info_categorized: *const i8

Human-readable core option information

Used as menu sublabel when frontend has core option category support (e.g. may be required when info text references an option by name/desc, and the desc/desc_categorized text for that option differ) If empty or NULL, the string specified by info will be used as the menu sublabel Will be ignored (and may be set to NULL) if category_key is empty or NULL

§category_key: *const i8

Variable specifying category (e.g. “video”, “audio”) that will be assigned to the option if frontend has core option category support.

Categorized options will be displayed in a subsection/submenu of the frontend core option interface Specified string must match one of the retro_core_option_v2_category::key values in the associated retro_core_option_v2_category array; If no match is not found, specified string will be considered as NULL If specified string is empty or NULL, option will have no category and will be shown at the top level of the frontend core option interface

§values: [retro_core_option_value; 128]

Array of retro_core_option_value structs, terminated by NULL

§default_value: *const i8

Default core option value. Must match one of the values in the retro_core_option_value array, otherwise will be ignored

Trait Implementations§

Source§

impl Clone for retro_core_option_v2_definition

Source§

fn clone(&self) -> retro_core_option_v2_definition

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for retro_core_option_v2_definition

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

Formats the value using the given formatter. Read more
Source§

impl Copy for retro_core_option_v2_definition

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.