⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 reportelement.java

📁 iReport-0.4.1-src是iReport的源代码,iReport是一个开源的报表项目,可以生成PDF等格式报表
💻 JAVA
📖 第 1 页 / 共 3 页
字号:
        }
        else if (pen.equals("3Point")) {
            return (Stroke)new BasicStroke((float)(3f*zoom_factor));
        }
        else if (pen.equals("4Point")) {
            return (Stroke)new BasicStroke((float)(4f*zoom_factor));
        }
        else if (pen.equals("Thin")) {
            
            return (Stroke)new BasicStroke( (float)(1f*zoom_factor));
        }
        else //if (pen.equals("1Point"))
        {
            return (Stroke)new BasicStroke((float)(1f*zoom_factor));
        }
    }
    
    
    
    
    /** Getter for property width.
     * @return Value of property width.
     *
     */
    public int getWidth() {
        return width;
    }
    
    /** Setter for property width.
     * @param width New value of property width.
     *
     */
    public void setWidth(int width) {
        this.width = width;
        updateBounds();
    }
    
    /** Getter for property height.
     * @return Value of property height.
     *
     */
    public int getHeight() {
        return height;
    }
    
    /** Setter for property height.
     * @param height New value of property height.
     *
     */
    public void setHeight(int height) {
        this.height = height;
        updateBounds();
    }
    
    /** Getter for property position.
     * @return Value of property position.
     *
     */
    public java.awt.Point getPosition() {
        return position;
    }
    
    /** Getter for property band.
     * @return Value of property band.
     *
     */
    public it.businesslogic.ireport.Band getBand() {
        return band;
    }
    
    /** Setter for property band.
     * @param band New value of property band.
     *
     */
    public void setBand(it.businesslogic.ireport.Band band) {
        this.band = band;
    }
    
    /** Getter for property transparent.
     * @return Value of property transparent.
     *
     */
    public java.lang.String getTransparent() {
        return transparent;
    }
    
    /** Setter for property transparent.
     * @param transparent New value of property transparent.
     *
     */
    public void setTransparent(java.lang.String transparent) {
        this.transparent = transparent;
    }
    
    /** Getter for property positionType.
     * @return Value of property positionType.
     *
     */
    public java.lang.String getPositionType() {
        return positionType;
    }
    
    /** Setter for property positionType.
     * @param positionType New value of property positionType.
     *
     */
    public void setPositionType(java.lang.String positionType) {
        this.positionType = positionType;
    }
    
    /** Getter for property isPrintInFirstWholeBand.
     * @return Value of property isPrintInFirstWholeBand.
     *
     */
    public boolean isIsPrintInFirstWholeBand() {
        return isPrintInFirstWholeBand;
    }
    
    /** Setter for property isPrintInFirstWholeBand.
     * @param isPrintInFirstWholeBand New value of property isPrintInFirstWholeBand.
     *
     */
    public void setIsPrintInFirstWholeBand(boolean isPrintInFirstWholeBand) {
        this.isPrintInFirstWholeBand = isPrintInFirstWholeBand;
    }
    
    /** Getter for property printWhenExpression.
     * @return Value of property printWhenExpression.
     *
     */
    public java.lang.String getPrintWhenExpression() {
        return printWhenExpression;
    }
    
    /** Setter for property printWhenExpression.
     * @param printWhenExpression New value of property printWhenExpression.
     *
     */
    public void setPrintWhenExpression(java.lang.String printWhenExpression) {
        this.printWhenExpression = printWhenExpression;
    }
    
    /** Getter for property isPrintRepeatedValues.
     * @return Value of property isPrintRepeatedValues.
     *
     */
    public boolean isIsPrintRepeatedValues() {
        return isPrintRepeatedValues;
    }
    
    /** Setter for property isPrintRepeatedValues.
     * @param isPrintRepeatedValues New value of property isPrintRepeatedValues.
     *
     */
    public void setIsPrintRepeatedValues(boolean isPrintRepeatedValues) {
        this.isPrintRepeatedValues = isPrintRepeatedValues;
    }
    
    /** Getter for property fgcolor.
     * @return Value of property fgcolor.
     *
     */
    public java.awt.Color getFgcolor() {
        return fgcolor;
    }
    
    /** Setter for property fgcolor.
     * @param fgcolor New value of property fgcolor.
     *
     */
    public void setFgcolor(java.awt.Color fgcolor) {
        this.fgcolor = fgcolor;
    }
    
    /** Getter for property bgcolor.
     * @return Value of property bgcolor.
     *
     */
    public java.awt.Color getBgcolor() {
        return bgcolor;
    }
    
    /** Setter for property bgcolor.
     * @param bgcolor New value of property bgcolor.
     *
     */
    public void setBgcolor(java.awt.Color bgcolor) {
        this.bgcolor = bgcolor;
    }
    
    /** Getter for property isRemoveLineWhenBlank.
     * @return Value of property isRemoveLineWhenBlank.
     *
     */
    public boolean isIsRemoveLineWhenBlank() {
        return isRemoveLineWhenBlank;
    }
    
    /** Setter for property isRemoveLineWhenBlank.
     * @param isRemoveLineWhenBlank New value of property isRemoveLineWhenBlank.
     *
     */
    public void setIsRemoveLineWhenBlank(boolean isRemoveLineWhenBlank) {
        this.isRemoveLineWhenBlank = isRemoveLineWhenBlank;
    }
    
    /** Getter for property printWhenGroupChanges.
     * @return Value of property printWhenGroupChanges.
     *
     */
    public java.lang.String getPrintWhenGroupChanges() {
        return printWhenGroupChanges;
    }
    
    /** Setter for property printWhenGroupChanges.
     * @param printWhenGroupChanges New value of property printWhenGroupChanges.
     *
     */
    public void setPrintWhenGroupChanges(java.lang.String printWhenGroupChanges) {
        this.printWhenGroupChanges = printWhenGroupChanges;
    }
    
    /** Getter for property name.
     * @return Value of property name.
     *
     */
    public java.lang.String getName() {
        return name;
    }
    
    /** Setter for property name.
     * @param name New value of property name.
     *
     */
    public void setName(java.lang.String name) {
        this.name = name;
    }
    
    /** Getter for property isPrintWhenDetailOverflows.
     * @return Value of property isPrintWhenDetailOverflows.
     *
     */
    public boolean isIsPrintWhenDetailOverflows() {
        return isPrintWhenDetailOverflows;
    }
    
    /** Setter for property isPrintWhenDetailOverflows.
     * @param isPrintWhenDetailOverflows New value of property isPrintWhenDetailOverflows.
     *
     */
    public void setIsPrintWhenDetailOverflows(boolean isPrintWhenDetailOverflows) {
        this.isPrintWhenDetailOverflows = isPrintWhenDetailOverflows;
    }
    
    public void  copyBaseReportElement(ReportElement destination, ReportElement source) {
        // Canonical report elements....
        destination.setName( new String(source.getName()) );
        destination.setBgcolor( source.getBgcolor());
        destination.setFgcolor( source.getFgcolor() );
        destination.setBand( source.getBand() );
        destination.setPositionType(new String(source.getPositionType()));
        destination.setIsPrintRepeatedValues( source.isIsPrintRepeatedValues());
        destination.setIsPrintWhenDetailOverflows( source.isIsPrintWhenDetailOverflows());
        destination.setIsRemoveLineWhenBlank(source.isIsRemoveLineWhenBlank());
        destination.setPrintWhenExpression(new String( source.getPrintWhenExpression()));
        destination.setPrintWhenGroupChanges(new String(source.getPrintWhenGroupChanges()));
        destination.setTransparent(new String(source.getTransparent()));
        destination.setIsPrintInFirstWholeBand(source.isIsPrintInFirstWholeBand());
    }
    
    
    
    
    /** Getter for property key.
     * @return Value of property key.
     *
     */
    public java.lang.String getKey() {
        return name;
    }
    
    /** Setter for property key.
     * @param key New value of property key.
     *
     */
    public void setKey(java.lang.String key) {
        this.name = key;
    }
    
    
    
    /** Getter for property stretchType.
     * @return Value of property stretchType.
     *
     */
    public java.lang.String getStretchType() {
        return stretchType;
    }
    
    /** Setter for property stretchType.
     * @param stretchType New value of property stretchType.
     *
     */
    public void setStretchType(java.lang.String stretchType) {
        this.stretchType = stretchType;
    }
    
    /**
     * Getter for property bounds.
     * @return Value of property bounds.
     */
    public java.awt.Rectangle getBounds() {
        return bounds;
    }    
    
    /**
     * Setter for property bounds.
     * @param bounds New value of property bounds.
     */
     public void setBounds(java.awt.Rectangle bounds) {
         this.position.x = bounds.x;
         this.position.y = bounds.y;
         this.width = bounds.width;
         this.height = bounds.height;
         this.updateBounds();
    }    
    
    public void addToGroup(String groupname)
    {
    	if (elementGroup == null || elementGroup.equals("")) elementGroup += groupname;
    	else elementGroup = groupname + "." + elementGroup;
    }
    
    public void removeFromGroup(String groupname)
    {
    	if (elementGroup == null || elementGroup.equals("")) return;
    	if (elementGroup.startsWith(groupname))
    	{
    		elementGroup = elementGroup.substring(groupname.length());
    		if (elementGroup.startsWith(".")) elementGroup = elementGroup.substring(1);
    	}
    }
    
    public void removeFromAllGroups()
    {
    	elementGroup="";
    }
} 

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -