[][src]Struct i3status_rs::blocks::sound::SoundConfig

pub struct SoundConfig {
    pub driver: SoundDriver,
    pub name: Option<String>,
    pub device: Option<String>,
    pub device_kind: DeviceKind,
    pub natural_mapping: bool,
    pub step_width: u32,
    pub format: String,
    pub show_volume_when_muted: bool,
    pub mappings: Option<BTreeMap<String, String>>,
    pub max_vol: Option<u32>,
}

Fields

driver: SoundDriver

ALSA / PulseAudio sound device name

name: Option<String>

PulseAudio device name, or ALSA control name as listed in the output of amixer -D yourdevice scontrols (default is "Master")

device: Option<String>

ALSA device name, usually in the form "hw:#" where # is the number of the card desired (default is "default")

device_kind: DeviceKind

Type of device: sink or source (default is "sink")

natural_mapping: bool

Use the mapped volume for evaluating the percentage representation like alsamixer, to be more natural for human ear

step_width: u32

The steps volume is in/decreased for the selected audio device (When greater than 50 it gets limited to 50)

format: String

Format string for displaying sound information. placeholders: {volume}

show_volume_when_muted: boolmappings: Option<BTreeMap<String, String>>max_vol: Option<u32>

Trait Implementations

impl Clone for SoundConfig[src]

impl Debug for SoundConfig[src]

impl Default for SoundConfig[src]

impl<'de> Deserialize<'de> for SoundConfig where
    SoundConfig: Default
[src]

Auto Trait Implementations

impl RefUnwindSafe for SoundConfig[src]

impl Send for SoundConfig[src]

impl Sync for SoundConfig[src]

impl Unpin for SoundConfig[src]

impl UnwindSafe for SoundConfig[src]

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> DeserializeOwned for T where
    T: for<'de> Deserialize<'de>, 
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

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

The type returned in the event of a conversion error.