[][src]Struct qt_gui::q_font::StyleStrategy

#[repr(transparent)]
pub struct StyleStrategy(_);

The style strategy tells the font matching algorithm what type of fonts should be used to find an appropriate default family.

C++ enum: QFont::StyleStrategy.

C++ documentation:

The style strategy tells the font matching algorithm what type of fonts should be used to find an appropriate default family.

The following strategies are available:

Any of these may be OR-ed with one of these flags:

Methods

impl StyleStrategy[src]

pub fn to_int(&self) -> c_int[src]

impl StyleStrategy[src]

pub const PreferDefault: StyleStrategy[src]

the default style strategy. It does not prefer any type of font. (C++ enum variant: PreferDefault = 1)

pub const PreferBitmap: StyleStrategy[src]

prefers bitmap fonts (as opposed to outline fonts). (C++ enum variant: PreferBitmap = 2)

pub const PreferDevice: StyleStrategy[src]

prefers device fonts. (C++ enum variant: PreferDevice = 4)

pub const PreferOutline: StyleStrategy[src]

prefers outline fonts (as opposed to bitmap fonts). (C++ enum variant: PreferOutline = 8)

pub const ForceOutline: StyleStrategy[src]

forces the use of outline fonts. (C++ enum variant: ForceOutline = 16)

pub const PreferMatch: StyleStrategy[src]

prefer an exact match. The font matcher will try to use the exact font size that has been specified. (C++ enum variant: PreferMatch = 32)

pub const PreferQuality: StyleStrategy[src]

prefer the best quality font. The font matcher will use the nearest standard point size that the font supports. (C++ enum variant: PreferQuality = 64)

pub const PreferAntialias: StyleStrategy[src]

antialias if possible. (C++ enum variant: PreferAntialias = 128)

pub const NoAntialias: StyleStrategy[src]

don't antialias the fonts. (C++ enum variant: NoAntialias = 256)

pub const OpenGLCompatible: StyleStrategy[src]

forces the use of OpenGL compatible fonts. (C++ enum variant: OpenGLCompatible = 512)

pub const ForceIntegerMetrics: StyleStrategy[src]

forces the use of integer values in font engines that support fractional font metrics. (C++ enum variant: ForceIntegerMetrics = 1024)

pub const NoSubpixelAntialias: StyleStrategy[src]

avoid subpixel antialiasing on the fonts if possible. (C++ enum variant: NoSubpixelAntialias = 2048)

pub const NoFontMerging: StyleStrategy[src]

If the font selected for a certain writing system does not contain a character requested to draw, then Qt automatically chooses a similar looking font that contains the character. The NoFontMerging flag disables this feature. Please note that enabling this flag will not prevent Qt from automatically picking a suitable font when the selected font does not support the writing system of the text. (C++ enum variant: NoFontMerging = 32768)

pub const PreferNoShaping: StyleStrategy[src]

Sometimes, a font will apply complex rules to a set of characters in order to display them correctly. In some writing systems, such as Brahmic scripts, this is required in order for the text to be legible, but in e.g. Latin script, it is merely a cosmetic feature. The PreferNoShaping flag will disable all such features when they are not required, which will improve performance in most cases (since Qt 5.10). (C++ enum variant: PreferNoShaping = 4096)

Trait Implementations

impl Clone for StyleStrategy[src]

impl Copy for StyleStrategy[src]

impl Debug for StyleStrategy[src]

impl Eq for StyleStrategy[src]

impl From<StyleStrategy> for c_int[src]

impl From<i32> for StyleStrategy[src]

impl PartialEq<StyleStrategy> for StyleStrategy[src]

impl StructuralEq for StyleStrategy[src]

impl StructuralPartialEq for StyleStrategy[src]

Auto Trait Implementations

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, U> CastInto<U> for T where
    U: CastFrom<T>, 
[src]

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

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

impl<T> StaticUpcast<T> for 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.