LoadString loads a component from the provided QML string. The location informs the resource name for logged messages, and its path is used to locate any other resources referenced by the QML content. Once a component is loaded, component instances may be created from the resulting object via its C
(location, qml string)
| 168 | // Once a component is loaded, component instances may be created from |
| 169 | // the resulting object via its Create and CreateWindow methods. |
| 170 | func (e *Engine) LoadString(location, qml string) (Object, error) { |
| 171 | return e.Load(location, strings.NewReader(qml)) |
| 172 | } |
| 173 | |
| 174 | // Context returns the engine's root context. |
| 175 | func (e *Engine) Context() *Context { |