09.04.2018 Views

tornadofx-guide

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

4. Basic Controls<br />

Keep in mind that many controls like TableView and TreeTableView already have scroll<br />

bars on them, so wrapping them in a ScrollPane is not necessary (Figure 4.22).<br />

Hyperlink<br />

You can create a Hyperlink control to mimic the behavior of a typical hyperlink to a file, a<br />

website, or simply perform an action.<br />

hyperlink("Open File").action { println("Opening file...") }<br />

Figure 4.22<br />

Text<br />

You can add a simple piece of Text with formatted properties. This control is simpler and<br />

rawer than a Label , and paragraphs can be separated using \n characters (Figure 4.23).<br />

47

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!