mirror of
https://github.com/JFormDesigner/FlatLaf.git
synced 2026-02-13 07:17:13 -06:00
Demo: added multi-line tooltip
This commit is contained in:
@@ -74,6 +74,7 @@ class MoreComponentsPanel
|
|||||||
indeterminateCheckBox = new JCheckBox();
|
indeterminateCheckBox = new JCheckBox();
|
||||||
JLabel toolTipLabel = new JLabel();
|
JLabel toolTipLabel = new JLabel();
|
||||||
JToolTip toolTip1 = new JToolTip();
|
JToolTip toolTip1 = new JToolTip();
|
||||||
|
JToolTip toolTip2 = new JToolTip();
|
||||||
JLabel toolBarLabel = new JLabel();
|
JLabel toolBarLabel = new JLabel();
|
||||||
JToolBar toolBar1 = new JToolBar();
|
JToolBar toolBar1 = new JToolBar();
|
||||||
JButton button4 = new JButton();
|
JButton button4 = new JButton();
|
||||||
@@ -260,6 +261,10 @@ class MoreComponentsPanel
|
|||||||
toolTip1.setTipText("Some text in tool tip.");
|
toolTip1.setTipText("Some text in tool tip.");
|
||||||
add(toolTip1, "cell 1 7 3 1");
|
add(toolTip1, "cell 1 7 3 1");
|
||||||
|
|
||||||
|
//---- toolTip2 ----
|
||||||
|
toolTip2.setTipText("Tool tip with\nmultiple\nlines.");
|
||||||
|
add(toolTip2, "cell 1 7 3 1");
|
||||||
|
|
||||||
//---- toolBarLabel ----
|
//---- toolBarLabel ----
|
||||||
toolBarLabel.setText("JToolBar:");
|
toolBarLabel.setText("JToolBar:");
|
||||||
add(toolBarLabel, "cell 0 8");
|
add(toolBarLabel, "cell 0 8");
|
||||||
|
|||||||
@@ -238,6 +238,12 @@ new FormModel {
|
|||||||
}, new FormLayoutConstraints( class net.miginfocom.layout.CC ) {
|
}, new FormLayoutConstraints( class net.miginfocom.layout.CC ) {
|
||||||
"value": "cell 1 7 3 1"
|
"value": "cell 1 7 3 1"
|
||||||
} )
|
} )
|
||||||
|
add( new FormComponent( "javax.swing.JToolTip" ) {
|
||||||
|
name: "toolTip2"
|
||||||
|
"tipText": "Tool tip with\nmultiple\nlines."
|
||||||
|
}, new FormLayoutConstraints( class net.miginfocom.layout.CC ) {
|
||||||
|
"value": "cell 1 7 3 1"
|
||||||
|
} )
|
||||||
add( new FormComponent( "javax.swing.JLabel" ) {
|
add( new FormComponent( "javax.swing.JLabel" ) {
|
||||||
name: "toolBarLabel"
|
name: "toolBarLabel"
|
||||||
"text": "JToolBar:"
|
"text": "JToolBar:"
|
||||||
|
|||||||
Reference in New Issue
Block a user