Browse Source

Merge pull request #784 in DESIGN/design from release/10.0 to final/10.0

* commit '4b88605e8dfc6a367dd0c6f12e654d1cd8f6efdd':
  CHART-3956 数据配置界面显示'数据集'
  CHART-3954 改善设计器的自定义区间值使用公式时,其邻值背景颜色显示逻辑
final/10.0
Kara 6 years ago
parent
commit
c2f74f6918
  1. 5
      designer-chart/src/main/java/com/fr/design/mainframe/chart/gui/data/TableDataPane.java
  2. 6
      designer-chart/src/main/java/com/fr/design/mainframe/chart/gui/style/series/UIColorPickerPane.java

5
designer-chart/src/main/java/com/fr/design/mainframe/chart/gui/data/TableDataPane.java

@ -11,6 +11,7 @@ import com.fr.design.beans.FurtherBasicBeanPane;
import com.fr.design.data.tabledata.wrapper.TableDataWrapper; import com.fr.design.data.tabledata.wrapper.TableDataWrapper;
import com.fr.design.gui.ilable.BoldFontTextLabel; import com.fr.design.gui.ilable.BoldFontTextLabel;
import com.fr.design.gui.ilable.UILabel; import com.fr.design.gui.ilable.UILabel;
import com.fr.design.i18n.Toolkit;
import com.fr.design.mainframe.chart.gui.ChartDataPane; import com.fr.design.mainframe.chart.gui.ChartDataPane;
import com.fr.design.mainframe.chart.gui.data.table.AbstractTableDataContentPane; import com.fr.design.mainframe.chart.gui.data.table.AbstractTableDataContentPane;
import com.fr.design.utils.gui.UIComponentUtils; import com.fr.design.utils.gui.UIComponentUtils;
@ -39,7 +40,7 @@ public class TableDataPane extends FurtherBasicBeanPane<ChartCollection>{
} }
private void initDataPane() { private void initDataPane() {
UILabel label = new BoldFontTextLabel(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Chart_TableData")); UILabel label = new BoldFontTextLabel(Toolkit.i18nText("Fine-Design_Chart_Table_Data"));
UIComponentUtils.setLineWrap(label, TABLE_DATA_LABEL_LINE_WRAP_WIDTH); UIComponentUtils.setLineWrap(label, TABLE_DATA_LABEL_LINE_WRAP_WIDTH);
tableDataPane = new DatabaseTableDataPane(label) { tableDataPane = new DatabaseTableDataPane(label) {
@ -85,7 +86,7 @@ public class TableDataPane extends FurtherBasicBeanPane<ChartCollection>{
* @return 返回标题. * @return 返回标题.
*/ */
public String title4PopupWindow() { public String title4PopupWindow() {
return com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Chart_TableData"); return Toolkit.i18nText("Fine-Design_Chart_TableData");
} }

6
designer-chart/src/main/java/com/fr/design/mainframe/chart/gui/style/series/UIColorPickerPane.java

@ -531,12 +531,16 @@ public class UIColorPickerPane extends BasicPane implements UIObserver {
double forValue = Double.MAX_VALUE; double forValue = Double.MAX_VALUE;
double backValue = -Double.MAX_VALUE; double backValue = -Double.MAX_VALUE;
for(int i = 0, size = textFieldList.size(); i < size; i++) {// check 是否合格, 然后检查 是否改变颜色, for(int i = 0, size = textFieldList.size(); i < size; i++) {// check 是否合格, 然后检查 是否改变颜色,
//backNumber是否是公式形式
boolean formulaBackNumber = false;
if(i == size - 1) { if(i == size - 1) {
backValue = -Double.MAX_VALUE; backValue = -Double.MAX_VALUE;
} else { } else {
Number backNumber = ChartBaseUtils.formula2Number(BaseFormula.createFormulaBuilder().build(getValue4Index(i+1))); Number backNumber = ChartBaseUtils.formula2Number(BaseFormula.createFormulaBuilder().build(getValue4Index(i+1)));
if(backNumber != null){ if(backNumber != null){
backValue = backNumber.doubleValue(); backValue = backNumber.doubleValue();
} else {
formulaBackNumber = true;
} }
} }
@ -544,7 +548,7 @@ public class UIColorPickerPane extends BasicPane implements UIObserver {
if(number != null) { if(number != null) {
double value = number.doubleValue(); double value = number.doubleValue();
if(value < forValue && value > backValue) { if ((value < forValue && value > backValue) || formulaBackNumber) {
setBackgroundUIColor(i,Color.WHITE); setBackgroundUIColor(i,Color.WHITE);
} else { } else {
setBackgroundUIColor(i, Color.red); setBackgroundUIColor(i, Color.red);

Loading…
Cancel
Save