Default Label Style Demo

This demo shows the most important configuration options for the built-in DefaultLabelStyle class.

Things to Try

  • Observe the various pre-configured label styles that are using different label shapes, different colors, fonts and other settings. Hover over a label to get a tool tip that lists the configured properties.
  • Double-click a label of the orange node to change its text and observe the resize behavior. Note that all other labels are not editable.
  • Take a look at labels showing the text alignment features. This comes into play when the preferred size of the label is larger than the size needed for the text.
  • The three light-blue node labels on the right show the effects of text wrapping and text clipping for labels whose size is smaller than the size needed for displaying the whole text. To learn more about wrapping, please see the Label Text Wrapping Tutorial.

Related Demos

  • HTML Label
  • Markdown Label
  • Rich Text Label
  • Tutorial: Custom Label Style