Browse Source

REPORT-138690 fix: 富文本编辑器工具条缺失元素补充

fbp/master
Levy.Xie-解安森 1 month ago
parent
commit
6ef55ce571
  1. 11
      designer-realize/src/main/java/com/fr/design/cell/editor/RichTextToolBar.java

11
designer-realize/src/main/java/com/fr/design/cell/editor/RichTextToolBar.java

@ -108,7 +108,7 @@ public class RichTextToolBar extends BasicPane {
fontNameComboBox = new UIComboBox(DesignUtils.getAvailableFontFamilyNames4Report()); fontNameComboBox = new UIComboBox(DesignUtils.getAvailableFontFamilyNames4Report());
fontSizeComboBox = new UIComboBox(FRFontPane.getFontSizes()); fontSizeComboBox = new UIComboBox(FRFontPane.getFontSizes());
colorSelectPane = new UIToolbarColorButton(new LazyIcon("foreground")); colorSelectPane = new UIToolbarColorButton(new LazyIcon("foreground"));
colorSelectPane.set4Toolbar(); setColorSelectPaneStyle();
bold = new UIToggleButton(new LazyIcon("bold")); bold = new UIToggleButton(new LazyIcon("bold"));
italic = new UIToggleButton(new LazyIcon("italic")); italic = new UIToggleButton(new LazyIcon("italic"));
@ -127,10 +127,19 @@ public class RichTextToolBar extends BasicPane {
bindListener(); bindListener();
} }
private void setColorSelectPaneStyle() {
colorSelectPane.set4Toolbar();
if (colorSelectPane.getLeftButton() != null && colorSelectPane.getRightButton() != null) {
colorSelectPane.getLeftButton().setBackground(null);
colorSelectPane.getRightButton().setBackground(null);
}
}
private void addIntoToolBar() { private void addIntoToolBar() {
toolbar.add(bold); toolbar.add(bold);
toolbar.add(italic); toolbar.add(italic);
toolbar.add(underline); toolbar.add(underline);
toolbar.add(colorSelectPane);
toolbar.add(subPane); toolbar.add(subPane);
toolbar.add(superPane); toolbar.add(superPane);
toolbar.add(formulaPane); toolbar.add(formulaPane);

Loading…
Cancel
Save