Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
* #2069 reduce space between team summary labels

* #2069 release_notes.md
  • Loading branch information
wsbrenk committed May 26, 2024
1 parent 2728464 commit f8fe1f0
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 9 deletions.
9 changes: 6 additions & 3 deletions src/main/java/core/gui/comp/panel/DoubleLabelPanel.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
package core.gui.comp.panel;

import core.gui.comp.entry.DoubleLabelEntries;
import core.model.UserParameter;

import javax.swing.*;
import java.awt.*;
Expand All @@ -25,9 +26,11 @@ private void addLabels() {
layout.setVgap(0);
setLayout(layout);
// Fix right label width to avoid components moving when values change.
rightLabel.setMinimumSize(new Dimension(90, 10));
rightLabel.setMaximumSize(new Dimension(90, 10));
rightLabel.setPreferredSize(new Dimension(90, 10));
var width = 60;
var height = UserParameter.instance().fontSize;
rightLabel.setMinimumSize(new Dimension(width, height));
rightLabel.setMaximumSize(new Dimension(width, height));
rightLabel.setPreferredSize(new Dimension(width, height));

add(leftLabel);
add(rightLabel);
Expand Down
7 changes: 2 additions & 5 deletions src/main/java/module/playerOverview/TeamSummaryPanel.java
Original file line number Diff line number Diff line change
Expand Up @@ -50,12 +50,9 @@ private void initComponents() {
}

private void createField(String labelName, JComponent fieldLabel) {
JLabel label;
label = new JLabel(labelName);
this.add(label);
this.add(Box.createHorizontalStrut(10));
this.add(new JLabel(labelName));
// this.add(Box.createHorizontalStrut(2));
this.add(fieldLabel);
this.add(Box.createHorizontalStrut(15));
}

private void setComparisonField(Number val, DoubleLabelPanel label, int numDecimals) {
Expand Down
3 changes: 2 additions & 1 deletion src/main/resources/release_notes.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
* Show stamina sub skill (#383)
* Fix error on player details display after initial download (#2044)
* Update missing world details in database (#2063)
* Reduce space between team summary labels (#2069)

### Team Analyzer
* Restore size of match prediction dialog box (#1898)
Expand Down Expand Up @@ -83,7 +84,7 @@

## Translations

Reports by Contributors - September 24, 2023 - May 05, 2024
Reports by Contributors - September 24, 2023 - May 25, 2024

* wsbrenk 355
* \_KOHb\_ 230
Expand Down

0 comments on commit f8fe1f0

Please sign in to comment.