Function gtk4::render_icon[][src]

pub fn render_icon<P: IsA<StyleContext>, Q: IsA<Texture>>(
    context: &P,
    cr: &Context,
    texture: &Q,
    x: f64,
    y: f64
)
Expand description

Renders the icon in texture at the specified x and y coordinates.

This function will render the icon in texture at exactly its size, regardless of scaling factors, which may not be appropriate when drawing on displays with high pixel densities.

context

a StyleContext

cr

a cairo_t

texture

a gdk::Texture containing the icon to draw

x

X position for the texture

y

Y position for the texture