Browse Source

REPORT-115175 模板主题按钮显示不全

final/11.0
obo 9 months ago
parent
commit
ea8a502dc7
  1. 25
      designer-base/src/main/java/com/fr/design/gui/style/TranslucentBorderSpecialPane.java

25
designer-base/src/main/java/com/fr/design/gui/style/TranslucentBorderSpecialPane.java

@ -46,10 +46,10 @@ import javax.swing.event.ChangeListener;
import javax.swing.plaf.basic.BasicButtonUI; import javax.swing.plaf.basic.BasicButtonUI;
import java.awt.BorderLayout; import java.awt.BorderLayout;
import java.awt.Color; import java.awt.Color;
import java.awt.Component;
import java.awt.Cursor; import java.awt.Cursor;
import java.awt.Desktop; import java.awt.Desktop;
import java.awt.Dimension; import java.awt.Dimension;
import java.awt.FlowLayout;
import java.awt.FontMetrics; import java.awt.FontMetrics;
import java.awt.Graphics; import java.awt.Graphics;
import java.awt.Graphics2D; import java.awt.Graphics2D;
@ -137,7 +137,9 @@ public class TranslucentBorderSpecialPane extends AbstractBorderPackerPane imple
} }
}); });
tweakNinePointButton = new UIButton(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Form_Widget_Style_Border_Image_Config_Nine_Point_Fill")); String buttonText = com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Form_Widget_Style_Border_Image_Config_Nine_Point_Fill");
tweakNinePointButton = new UIButton(buttonText);
tweakNinePointButton.setToolTipText(buttonText);
borderImageOpacityPane = new UIPercentDragPane(); borderImageOpacityPane = new UIPercentDragPane();
} }
@ -174,23 +176,28 @@ public class TranslucentBorderSpecialPane extends AbstractBorderPackerPane imple
borderedImagePreviewPane.setPreferredSize(new Dimension(145, 145)); borderedImagePreviewPane.setPreferredSize(new Dimension(145, 145));
borderedImagePreviewPane.add(imagePreviewPane, BorderLayout.CENTER); borderedImagePreviewPane.add(imagePreviewPane, BorderLayout.CENTER);
JPanel tweakNinePointComposedPane = new JPanel();
tweakNinePointComposedPane.setLayout(new FlowLayout(FlowLayout.RIGHT, 0, 0));
tweakNinePointButton.setPreferredSize(new Dimension(145, 16));
tweakNinePointComposedPane.add(tweakNinePointHelpButton);
tweakNinePointComposedPane.add(tweakNinePointButton);
return TableLayoutHelper.createGapTableLayoutPane( return TableLayoutHelper.createGapTableLayoutPane(
new JComponent[][]{ new JComponent[][]{
{null, borderedImagePreviewPane}, {null, borderedImagePreviewPane},
{null, chooseImageButton}, {null, chooseImageButton},
{tweakNinePointComposedPane, null}, {null, createTweakNinePointComposedPane()},
{null, new UILabel(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Form_Widget-Style_Alpha"))}, {null, new UILabel(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Form_Widget-Style_Alpha"))},
{null, this.borderImageOpacityPane} {null, this.borderImageOpacityPane}
}, },
rowSize, columnSize, IntervalConstants.INTERVAL_L1, IntervalConstants.INTERVAL_L1); rowSize, columnSize, IntervalConstants.INTERVAL_L1, IntervalConstants.INTERVAL_L1);
} }
private JPanel createTweakNinePointComposedPane() {
double p = TableLayout.PREFERRED;
double f = TableLayout.FILL;
return TableLayoutHelper.createGapTableLayoutPane(
new Component[][]{
{tweakNinePointHelpButton, tweakNinePointButton}
},
new double[]{p},
new double[]{p, f},
new int[][]{{1, 1}}, 0, 0);
}
private void initImageFileChooserIfNotExist() { private void initImageFileChooserIfNotExist() {
if (imageFileChooser == null) { if (imageFileChooser == null) {
imageFileChooser = new ImageFileChooser(); imageFileChooser = new ImageFileChooser();

Loading…
Cancel
Save