[][src]Struct alacritty::config::font::Font

pub struct Font {
    pub offset: Delta<i8>,
    pub glyph_offset: Delta<i8>,
    pub use_thin_strokes: bool,
    normal: FontDescription,
    bold: SecondaryFontDescription,
    italic: SecondaryFontDescription,
    bold_italic: SecondaryFontDescription,
    size: Size,
}

Font config.

Defaults are provided at the level of this struct per platform, but not per field in this struct. It might be nice in the future to have defaults for each value independently. Alternatively, maybe erroring when the user doesn't provide complete config is Ok.

Fields

offset: Delta<i8>

Extra spacing per character.

glyph_offset: Delta<i8>

Glyph offset within character cell.

use_thin_strokes: boolnormal: FontDescription

Normal font face.

bold: SecondaryFontDescription

Bold font face.

italic: SecondaryFontDescription

Italic font face.

bold_italic: SecondaryFontDescription

Bold italic font face.

size: Size

Font size in points.

Implementations

impl Font[src]

pub fn with_size(self, size: FontSize) -> Font[src]

Get a font clone with a size modification.

pub fn size(&self) -> FontSize[src]

pub fn normal(&self) -> &FontDescription[src]

Get normal font description.

pub fn bold(&self) -> FontDescription[src]

Get bold font description.

pub fn italic(&self) -> FontDescription[src]

Get italic font description.

pub fn bold_italic(&self) -> FontDescription[src]

Get bold italic font description.

Trait Implementations

impl Clone for Font[src]

impl Debug for Font[src]

impl Default for Font[src]

impl<'de> Deserialize<'de> for Font[src]

impl Eq for Font[src]

impl PartialEq<Font> for Font[src]

impl StructuralEq for Font[src]

impl StructuralPartialEq for Font[src]

Auto Trait Implementations

impl RefUnwindSafe for Font

impl Send for Font

impl Sync for Font

impl Unpin for Font

impl UnwindSafe for Font

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.