+ String tooltip = null;
+ if (bundle.getDescriptionBundle() != null) {
+ tooltip = bundle.getDescriptionBundle().getString(id);
+ if (tooltip.trim().isEmpty()) {
+ tooltip = null;
+ }
+ }
+
+ String name = id.toString();
+ if (name.length() > 1) {
+ name = name.substring(0, 1) + name.substring(1).toLowerCase();
+ name = name.replace("_", " ");
+ }
+
+ JLabel nameLabel = new JLabel(name);
+ nameLabel.setToolTipText(tooltip);