diff --git a/designer-base/src/main/java/com/fr/design/data/tabledata/tabledatapane/FileTableDataPane.java b/designer-base/src/main/java/com/fr/design/data/tabledata/tabledatapane/FileTableDataPane.java index 5d9d4146d6..3c68cb999f 100644 --- a/designer-base/src/main/java/com/fr/design/data/tabledata/tabledatapane/FileTableDataPane.java +++ b/designer-base/src/main/java/com/fr/design/data/tabledata/tabledatapane/FileTableDataPane.java @@ -4,6 +4,7 @@ import com.fr.base.BaseUtils; import com.fr.base.Parameter; import com.fr.base.ParameterHelper; import com.fr.base.Utils; +import com.fr.base.i18n.BidiUtils; import com.fr.data.core.datasource.FileDataSource; import com.fr.data.core.datasource.URLDataSource; import com.fr.data.core.define.XMLColumnNameType; @@ -137,12 +138,12 @@ public class FileTableDataPane extends AbstractTableDataPane { this.setLayout(new BorderLayout(gap, 0)); JPanel northPanel = new JPanel(new BorderLayout()); JPanel type = new JPanel(); - type.add(new UILabel(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Report_Utils_File_Type") + ":")); + type.add(new UILabel(BidiUtils.reverseConcatenateStrings(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Report_Utils_File_Type"), ":"))); String[] item = {"TXT", "Excel", "XML"}; fileTypeComboBox = new UIComboBox(item); fileTypeComboBox.setPreferredSize(new Dimension(100, 20)); type.add(fileTypeComboBox); - northPanel.add(type, BorderLayout.WEST); + northPanel.add(type, BidiUtils.rtl() ? BorderLayout.EAST : BorderLayout.WEST); // 最上面的pane,文件选择 JPanel centerPanel = new JPanel(); @@ -172,7 +173,8 @@ public class FileTableDataPane extends AbstractTableDataPane { this.add(northPanel, BorderLayout.NORTH); this.add(centerPanel, BorderLayout.CENTER); - this.add(southPanel, BorderLayout.EAST); + this.add(southPanel, BidiUtils.rtl() ? BorderLayout.WEST : BorderLayout.EAST); + BidiUtils.applyOrientationByLocale(this); } private void addToCenterPanel(JPanel centerPanel) { @@ -207,9 +209,9 @@ public class FileTableDataPane extends AbstractTableDataPane { buttonPanel.add(chooseFile); buttonPanel.add(testConnection); filePath = FRGUIPaneFactory.createBorderLayout_S_Pane(); - filePath.add(textPanel, BorderLayout.WEST); + filePath.add(textPanel, BidiUtils.rtl() ? BorderLayout.EAST : BorderLayout.WEST); filePath.add(textFieldPanel, BorderLayout.CENTER); - filePath.add(buttonPanel, BorderLayout.EAST); + filePath.add(buttonPanel, BidiUtils.rtl() ? BorderLayout.WEST : BorderLayout.EAST); centerPanel.add(filePath, BorderLayout.NORTH); // 中间的pane,提示信息 @@ -272,7 +274,8 @@ public class FileTableDataPane extends AbstractTableDataPane { controlPane.setLayout(new BorderLayout(8, 8)); controlPane.setPreferredSize(new Dimension(width, height)); JPanel comboboxPanel = new JPanel(new BorderLayout(8, 8)); - encodeLabel = new UILabel(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Encoding_Type") + ":"); + encodeLabel = new UILabel(BidiUtils.reverseConcatenateStrings(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Encoding_Type"), ":") + ); encodingComboBox = new UIComboBox(EncodeConstants.ALL_ENCODING_ARRAY); encodingComboBox.setSelectedIndex(4); encodingComboBox.setPreferredSize(new Dimension(90, 20)); diff --git a/designer-base/src/main/java/com/fr/design/data/tabledata/tabledatapane/MultiTDTableDataPane.java b/designer-base/src/main/java/com/fr/design/data/tabledata/tabledatapane/MultiTDTableDataPane.java index 66c03ec58c..d30ab005a7 100644 --- a/designer-base/src/main/java/com/fr/design/data/tabledata/tabledatapane/MultiTDTableDataPane.java +++ b/designer-base/src/main/java/com/fr/design/data/tabledata/tabledatapane/MultiTDTableDataPane.java @@ -60,7 +60,7 @@ public class MultiTDTableDataPane extends AbstractTableDataPane