[][src]Module imgui_ext::display

display(...) docs.

display(...) is used to display a field.

Optional fields

  • label
  • display formatted text (followed by the parameters).

Example

#[derive(imgui_ext::Gui)]
struct Labels {
    #[imgui(display)]
    foo: f32,

    // Use inner fields to format the text.
    #[imgui(display(label = "Tuple", display = "({}, {}, {})", 0, 1, 2))]
    bar: (f32, bool, usize),

    // when display() is the only annotation, it can be abbreviated:
    #[imgui(label = "String param")]
    baz: String,
}

]result