forked from fanruan/design
Browse Source
* commit 'e628896a90d5b43b8b88bb0d15ad189483b9e099': REPORT-58577【回归测试】map公式合法性检测错误 && REPORT-58124 公式编辑器优化:不支持实时计算的功能提示处理 1.map的参数类型调整; 2.对内置参数不支持提示。 CHART-20515 渐变风格关闭 REPORT-58579【回归测试】rank的带参模拟计算值不正确 1.数字类型转换 REPORT-56134 js提交事件报错中添加定位信息 REPORT-58124 公式编辑器优化:不支持实时计算的功能提示处理 1.添加ds1.select类型的识别 REPORT-55048 websocket使用代理的情况处理下 KERNEL-8776 绝对布局下拖动组件,会生成新的XCreator REPORT-58398 【主题切换】新单元格的默认样式确定 REPORT-58536 【主题切换】新建cpt,增加sheet页,设计器里主题配置的背景只在第一个sheet生效 REPORT-58403 【主题切换】组件右侧边框标题部分,间距有点大 REPORT-58411 【FR11二轮回归】主题样式-body右侧设置面板按交互文档预期是提示“背景设置”,现在是“样式设置” REPORT-55748 处理下import 问题 REPORT-58535 【稳定共创】附件模板概率出现2个编辑按钮 KERNEL-8879 自适应预览下 给报表块增加自适应逻辑接口research/11.0
superman
3 years ago
49 changed files with 445 additions and 278 deletions
@ -0,0 +1,19 @@ |
|||||||
|
package com.fr.design.fun; |
||||||
|
|
||||||
|
import com.fr.stable.fun.mark.Mutable; |
||||||
|
|
||||||
|
|
||||||
|
public interface PcFitProvider extends Mutable { |
||||||
|
String XML_TAG = "PcFitProvider"; |
||||||
|
int CURRENT_LEVEL = 1; |
||||||
|
|
||||||
|
//设计器上看到的选项
|
||||||
|
String getContentDisplayValue(); |
||||||
|
|
||||||
|
//返回给前端的值
|
||||||
|
int getContentDisplayKey(); |
||||||
|
|
||||||
|
//设计器上的提示信息
|
||||||
|
String getContentDisplayTip(); |
||||||
|
|
||||||
|
} |
@ -0,0 +1,19 @@ |
|||||||
|
package com.fr.design.fun.impl; |
||||||
|
|
||||||
|
import com.fr.design.fun.PcFitProvider; |
||||||
|
import com.fr.stable.fun.mark.API; |
||||||
|
|
||||||
|
|
||||||
|
@API(level = PcFitProvider.CURRENT_LEVEL) |
||||||
|
public abstract class AbstractPcFitProvider implements PcFitProvider { |
||||||
|
|
||||||
|
@Override |
||||||
|
public int currentAPILevel() { |
||||||
|
return CURRENT_LEVEL; |
||||||
|
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public String mark4Provider() { |
||||||
|
return getClass().getName(); |
||||||
|
} |
||||||
|
} |
@ -0,0 +1,45 @@ |
|||||||
|
package com.fr.design.mainframe.theme.utils; |
||||||
|
|
||||||
|
import com.fr.base.NameStyle; |
||||||
|
import com.fr.base.theme.TemplateTheme; |
||||||
|
import com.fr.base.theme.settings.ThemedCellStyle; |
||||||
|
import com.fr.design.file.HistoryTemplateListCache; |
||||||
|
import com.fr.design.mainframe.JTemplate; |
||||||
|
import com.fr.report.cell.DefaultTemplateCellElement; |
||||||
|
|
||||||
|
/** |
||||||
|
* @author Starryi |
||||||
|
* @version 1.0 |
||||||
|
* Created by Starryi on 2021/8/31 |
||||||
|
*/ |
||||||
|
public class DefaultThemedTemplateCellElementCase { |
||||||
|
|
||||||
|
public static DefaultTemplateCellElement createInstance() { |
||||||
|
return themingCellElement(new DefaultTemplateCellElement()); |
||||||
|
} |
||||||
|
|
||||||
|
public static DefaultTemplateCellElement createInstance(int column, int row) { |
||||||
|
return themingCellElement(new DefaultTemplateCellElement(column, row)); |
||||||
|
} |
||||||
|
|
||||||
|
public static DefaultTemplateCellElement createInstance(int column, int row, Object value) { |
||||||
|
return themingCellElement(new DefaultTemplateCellElement(column, row, value)); |
||||||
|
} |
||||||
|
|
||||||
|
public static DefaultTemplateCellElement createInstance(int column, int row, int columnSpan, int rowSpan, Object value) { |
||||||
|
return themingCellElement(new DefaultTemplateCellElement(column, row, columnSpan, rowSpan, value)); |
||||||
|
} |
||||||
|
|
||||||
|
private static DefaultTemplateCellElement themingCellElement(DefaultTemplateCellElement cellElement) { |
||||||
|
JTemplate<?,?> template = HistoryTemplateListCache.getInstance().getCurrentEditingTemplate(); |
||||||
|
if (template != null) { |
||||||
|
TemplateTheme theme = template.getTemplateTheme(); |
||||||
|
ThemedCellStyle themedCellStyle = theme.getCellStyleList().getDefaultCellStyle4New(); |
||||||
|
if (themedCellStyle != null) { |
||||||
|
NameStyle nameStyle = NameStyle.getPassiveInstance(themedCellStyle.getName(), themedCellStyle.getStyle()); |
||||||
|
cellElement.setStyle(nameStyle); |
||||||
|
} |
||||||
|
} |
||||||
|
return cellElement; |
||||||
|
} |
||||||
|
} |
Loading…
Reference in new issue