Merge pull request #730 from teyrana/fix/727/config-spacing

[fixes #727][gui][cosmetic] Adjusted layout in RocketComponentConfig layout
This commit is contained in:
Daniel Williams 2020-08-01 14:55:33 -04:00 committed by GitHub
commit ed409204d0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -71,7 +71,8 @@ public class RocketComponentConfig extends JPanel {
public RocketComponentConfig(OpenRocketDocument document, RocketComponent component) { public RocketComponentConfig(OpenRocketDocument document, RocketComponent component) {
setLayout(new MigLayout("fill, gap 5!, ins panel", "[]:5[]", "[growprio 10]10![fill, grow, growprio 500]10![growprio 10]")); setLayout(new MigLayout("fill, gap 4!, ins panel", "[]:5[]", "[growprio 5]5![fill, grow, growprio 500]5![growprio 5]"));
this.document = document; this.document = document;
this.component = component; this.component = component;
@ -79,7 +80,7 @@ public class RocketComponentConfig extends JPanel {
JLabel label = new JLabel(trans.get("RocketCompCfg.lbl.Componentname")); JLabel label = new JLabel(trans.get("RocketCompCfg.lbl.Componentname"));
//// The component name. //// The component name.
label.setToolTipText(trans.get("RocketCompCfg.ttip.Thecomponentname")); label.setToolTipText(trans.get("RocketCompCfg.ttip.Thecomponentname"));
this.add(label, "spanx, height 50!, split"); this.add(label, "spanx, height 32!, split");
componentNameField = new JTextField(15); componentNameField = new JTextField(15);
textFieldListener = new TextFieldListener(); textFieldListener = new TextFieldListener();
@ -126,8 +127,8 @@ public class RocketComponentConfig extends JPanel {
this.remove(buttonPanel); this.remove(buttonPanel);
} }
buttonPanel = new JPanel(new MigLayout("fillx, ins 0")); buttonPanel = new JPanel(new MigLayout("fillx, ins 5"));
//// Mass: //// Mass:
infoLabel = new StyledLabel(" ", -1); infoLabel = new StyledLabel(" ", -1);
buttonPanel.add(infoLabel, "growx"); buttonPanel.add(infoLabel, "growx");
@ -148,7 +149,7 @@ public class RocketComponentConfig extends JPanel {
updateFields(); updateFields();
this.add(buttonPanel, "newline, spanx, growx, height 50!"); this.add(buttonPanel, "newline, spanx, growx, height 32!");
} }