QuickGUIHostView
Reverse-hosts one ordinary QuickGUI subtree inside a SwiftUI hierarchy.
#Import
Import ui from github.com/egoist/quickgui/go/ui.
import (
"github.com/egoist/quickgui/go/ui"
)#Usage
func SwiftUiQuickguiHostViewExample() *native.Node {
return ui.SwiftUI.Host(
ui.SwiftUIHostProps{MatchContents: true},
func() *native.Node {
return ui.SwiftUI.QuickGUIHostView(
ui.SwiftUIQuickGUIHostViewProps{Width: 320, Height: 180},
func() *ui.Element {
return ui.View().Child(
"QuickGUI inside SwiftUI",
).Width("100%").Height("100%").Padding(16)
},
)
},
)
}#API reference
Expand an entry for its description and complete signature. A dash means no declaration default is documented.
SwiftUI.QuickGUIHostView
View sourceui.SwiftUI.QuickGUIHostView(props SwiftUIQuickGUIHostViewProps, children ...any) *native.NodeQuickGUIHostView is an independently owned QuickGUI renderer inside a SwiftUI hierarchy.
TestIDany—
Modifiersany—
Reffunc(*native.Node)—
Receives the retained native node after construction. Keep imperative work in event or lifecycle callbacks.
func(*native.Node)View sourceChildrenComponent—
Content mounted inside the component. Compound child callbacks run after the parent context exists.
ComponentView source