+ JPanel byValuePanel = new JPanel();
+ byValuePanel.setLayout(new BoxLayout(byValuePanel, BoxLayout.Y_AXIS));
+ JvSwingUtils.createItalicTitledBorder(byValuePanel,
+ MessageManager.getString("label.colour_by_value"), true);
+ byValuePanel.setBackground(Color.white);
+
+ /*
+ * first row - choose colour by score or by attribute, choose attribute
+ */
+ JPanel byWhatPanel = new JPanel(new FlowLayout(FlowLayout.LEFT));
+ byWhatPanel.setBackground(Color.white);
+ byValuePanel.add(byWhatPanel);
+
+ byScore.setText(MessageManager.getString("label.score"));
+ byWhatPanel.add(byScore);
+ byScore.addActionListener(changeMinMaxAction);
+
+ byAttributeValue.setText(MessageManager.getString("label.attribute"));
+ byAttributeValue.addActionListener(changeMinMaxAction);
+ byWhatPanel.add(byAttributeValue);
+
+ List<String[]> attNames = FeatureAttributes.getInstance()
+ .getAttributes(type);
+ valueAttributeCombo = populateAttributesDropdown(type, attNames, true);
+
+ /*
+ * if no numeric atttibutes found, disable colour by attribute value
+ */
+ if (valueAttributeCombo.getItemCount() == 0)
+ {
+ byAttributeValue.setEnabled(false);
+ }
+
+ byWhatPanel.add(valueAttributeCombo);
+
+ /*
+ * second row - min/max/no colours
+ */
+ JPanel colourRangePanel = new JPanel(new FlowLayout(FlowLayout.LEFT));
+ colourRangePanel.setBackground(Color.white);
+ byValuePanel.add(colourRangePanel);