de.sciss.synth.swing.impl
Type members
Classlikes
Renderer that draws a label, which consists of a text string,
an icon, or both. This is based on the prefuse LabelRenderer
class, but changes image for icon. It was converted from Java to Scala,
so the code looks a bit ugly.
Renderer that draws a label, which consists of a text string,
an icon, or both. This is based on the prefuse LabelRenderer
class, but changes image for icon. It was converted from Java to Scala,
so the code looks a bit ugly.
When created using the default constructor, the renderer attempts
to use text from the "label" field. To use a different field, use the
appropriate constructor or use the setTextField
method.
To perform custom String selection, subclass this Renderer and override the
getText
method. When the text field is
null
, no text label will be shown. Labels can span multiple
lines of text, determined by the presence of newline characters ('\n')
within the text string.
By default, no icon is shown. To show an icon, the icon field needs
to be set, either using the appropriate constructor or the
setIconField
method. The value of the icon field should
be an Icon
instance to use.
The position of the icon relative to text can be set using the
setIconPosition
method. Images can be placed to the
left, right, above, or below the text. The horizontal and vertical
alignments of either the text or the icon can be set explicitly
using the appropriate methods of this class (e.g.,
setHorizontalTextAlignment
). By default, both the
text and icon are centered along both the horizontal and
vertical directions.