@ -38,6 +38,7 @@ import com.fr.report.cell.CellElement;
import com.fr.report.elementcase.TemplateElementCase ;
import com.fr.report.elementcase.TemplateElementCase ;
import com.fr.report.worksheet.FormElementCase ;
import com.fr.report.worksheet.FormElementCase ;
import com.fr.report.worksheet.WorkSheet ;
import com.fr.report.worksheet.WorkSheet ;
import com.fr.stable.Constants ;
import javax.swing.JComponent ;
import javax.swing.JComponent ;
import javax.swing.JPanel ;
import javax.swing.JPanel ;
@ -151,6 +152,7 @@ public class FormElementCaseDesigner
Grid grid = this . elementCasePane ! = null ? this . elementCasePane . getGrid ( ) : null ;
Grid grid = this . elementCasePane ! = null ? this . elementCasePane . getGrid ( ) : null ;
if ( grid ! = null ) {
if ( grid ! = null ) {
resetGrid ( grid ) ;
boolean oldTranslucent = grid . isTranslucent ( ) ;
boolean oldTranslucent = grid . isTranslucent ( ) ;
boolean oldShowExtraGridLine = grid . isShowExtraGridLine ( ) ;
boolean oldShowExtraGridLine = grid . isShowExtraGridLine ( ) ;
// 截缩图图时grid需支持半透明,不能用默认白色填充画布,否则会遮挡组件样式背景
// 截缩图图时grid需支持半透明,不能用默认白色填充画布,否则会遮挡组件样式背景
@ -168,6 +170,15 @@ public class FormElementCaseDesigner
return image ;
return image ;
}
}
private void resetGrid ( Grid grid ) {
grid . setResolution ( Constants . DEFAULT_WEBWRITE_AND_SCREEN_RESOLUTION ) ;
grid . updateUI ( ) ;
grid . setAdsorbHeight ( 0 ) ;
grid . setAdsorbWidth ( 0 ) ;
grid . setVerticalValue ( 0 ) ;
grid . setHorizontalValue ( 0 ) ;
}
/ * *
/ * *
* 刷新右侧属性面板
* 刷新右侧属性面板
* /
* /