()
| 75 | |
| 76 | |
| 77 | public void rebuild() { |
| 78 | removeAll(); // remove previous components, if any |
| 79 | List<EditorButton> buttons = createButtons(); |
| 80 | |
| 81 | box = Box.createHorizontalBox(); |
| 82 | box.add(Box.createHorizontalStrut(Editor.LEFT_GUTTER)); |
| 83 | |
| 84 | rolloverLabel = new JLabel(); |
| 85 | |
| 86 | for (EditorButton button : buttons) { |
| 87 | box.add(button); |
| 88 | box.add(Box.createHorizontalStrut(GAP)); |
| 89 | } |
| 90 | |
| 91 | box.add(rolloverLabel); |
| 92 | |
| 93 | box.add(Box.createHorizontalGlue()); |
| 94 | addModeButtons(box, rolloverLabel); |
| 95 | |
| 96 | box.add(modeSelector = new ModeSelector(editor)); |
| 97 | box.add(Box.createHorizontalStrut(Editor.RIGHT_GUTTER)); |
| 98 | |
| 99 | setLayout(new BorderLayout()); |
| 100 | add(box, BorderLayout.CENTER); |
| 101 | |
| 102 | updateTheme(); |
| 103 | } |
| 104 | |
| 105 | |
| 106 | public void updateTheme() { |
no test coverage detected