javafx.scene.web.HTMLEditor
This node takes the attributes from the javafx.scene.web.HTMLEditor class. see javafx.scene.web.HTMLEditor
This node takes the common node content, effects, transforms, and input.
Creates a HTMLEditor JavaFX node.
import groovyx.javafx.GroovyFX
import groovyx.javafx.SceneGraphBuilder
def url = "http://www.yahoo.com";
GroovyFX.start({
def sg = new SceneGraphBuilder();
def webEngine = sg.webEngine(location: url);
def goAction = { webEngine.load(urlBox.getText()) };
def stage = sg.stage(
title: "HTML Editor (Groovy)",
visible: true,
) {
scene(fill: hsb(128, 0.5, 0.5, 0.5), width: 400, height:400 ) {
borderPane() {
html = htmlEditor()
bottom(align: "center", margin: [10,0]) {
button(text: "Print HTML", onAction: { println html.htmlText})
}
}
}
}
});
|