Struct qml::QmlEngine [] [src]

pub struct QmlEngine {
    // some fields omitted
}

Provides an entry point for building QML applications from Rust

Methods

impl QmlEngine
[src]

fn new() -> Self

Creates a QML context of a non-headless application

fn load_file(&self, path: &str)

Loads a file as a qml file

fn load_data(&self, data: &str)

Loads a string as a qml file

fn exec(&self)

Launches the application

fn quit(&self)

Closes the application

fn set_and_store_property<T: Into<QVariant>>(&mut self, name: &str, value: T)

Sets a property for this QML context

This variant stores qvariant, so it is removed, only when this QmlEngine is removed.

fn set_property(&self, name: &str, value: &QVariant)

Sets a property for this QML context

Trait Implementations

impl Default for QmlEngine
[src]

fn default() -> Self

Returns the "default value" for a type. Read more

impl Drop for QmlEngine
[src]

fn drop(&mut self)

A method called when the value goes out of scope. Read more