|
|
|
@ -1,5 +1,7 @@
|
|
|
|
|
package com.fr.design.mainframe.theme.edit.cell; |
|
|
|
|
|
|
|
|
|
import com.fr.base.CellBorderStyle; |
|
|
|
|
import com.fr.base.Style; |
|
|
|
|
import com.fr.base.theme.settings.ThemedCellStyle; |
|
|
|
|
import com.fr.design.cell.CellRectangleStylePreviewPane; |
|
|
|
|
import com.fr.design.constants.UIConstants; |
|
|
|
@ -87,12 +89,35 @@ public class CellStyleEditPane extends MultiTabPane<ThemedCellStyle> {
|
|
|
|
|
@Override |
|
|
|
|
public ThemedCellStyle updateBean() { |
|
|
|
|
AbstractBasicStylePane basicStylePane = (AbstractBasicStylePane) paneList.get(tabPane.getSelectedIndex()); |
|
|
|
|
this.cellStyle.setStyle(basicStylePane.update(this.cellStyle.getStyle())); |
|
|
|
|
Style style = basicStylePane.update(this.cellStyle.getStyle()); |
|
|
|
|
CellBorderStyle borderStyle = createDefaultBorderStyleFromStyle(style); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (ThemedFeatureController.isCellStyleSupportInnerBorder() && basicStylePane instanceof BorderPane) { |
|
|
|
|
this.cellStyle.setCellBorderStyle(((BorderPane) basicStylePane).update()); |
|
|
|
|
borderStyle = ((BorderPane) basicStylePane).update(); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
this.cellStyle.setStyle(style); |
|
|
|
|
this.cellStyle.setCellBorderStyle(borderStyle); |
|
|
|
|
|
|
|
|
|
return this.cellStyle; |
|
|
|
|
} |
|
|
|
|
private CellBorderStyle createDefaultBorderStyleFromStyle(Style style) { |
|
|
|
|
CellBorderStyle cellBorderStyle = new CellBorderStyle(); |
|
|
|
|
cellBorderStyle.setTopStyle(style.getBorderTop()); |
|
|
|
|
cellBorderStyle.setTopColor(style.getBorderTopColor()); |
|
|
|
|
|
|
|
|
|
cellBorderStyle.setBottomStyle(style.getBorderBottom()); |
|
|
|
|
cellBorderStyle.setBottomColor(style.getBorderBottomColor()); |
|
|
|
|
|
|
|
|
|
cellBorderStyle.setLeftStyle(style.getBorderLeft()); |
|
|
|
|
cellBorderStyle.setLeftColor(style.getBorderLeftColor()); |
|
|
|
|
|
|
|
|
|
cellBorderStyle.setRightStyle(style.getBorderRight()); |
|
|
|
|
cellBorderStyle.setRightColor(style.getBorderRightColor()); |
|
|
|
|
|
|
|
|
|
return cellBorderStyle; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
@Override |
|
|
|
|
public boolean accept(Object ob) { |
|
|
|
|