Java 类net.sf.jasperreports.engine.base.JRBaseLine 实例源码

项目:PDFReporter-Studio    文件:MLine.java   
/**
 * Creates the property descriptors.
 * 
 * @param desc
 *          the desc
 */
@Override
public void createPropertyDescriptors(List<IPropertyDescriptor> desc, Map<String, Object> defaultsMap) {
    super.createPropertyDescriptors(desc, defaultsMap);

    directionD = new JSSEnumPropertyDescriptor(JRBaseLine.PROPERTY_DIRECTION, Messages.MLine_direction,
            LineDirectionEnum.class, NullEnum.NULL);
    directionD.setDescription(Messages.MLine_direction_description);
    directionD.setCategory(Messages.MLine_line_category);
    desc.add(directionD);

    /*
     * fillD = new JSSEnumPropertyDescriptor(JRBaseStyle.PROPERTY_FILL, Messages.common_fill, FillEnum.class,
     * NullEnum.INHERITED); fillD.setDescription(Messages.MLine_fill_description); desc.add(fillD);
     */

    defaultsMap.put(JRBaseLine.PROPERTY_DIRECTION, EnumHelper.getValue(LineDirectionEnum.TOP_DOWN, 1, true));
    defaultsMap.put(JRBaseStyle.PROPERTY_FILL, null);

    setHelpPrefix(desc, "net.sf.jasperreports.doc/docs/schema.reference.html?cp=0_1#line");
}
项目:jasperreports    文件:JRDesignLine.java   
@Override
public void setDirection(LineDirectionEnum directionValue)
{
    LineDirectionEnum old = this.directionValue;
    this.directionValue = directionValue;
    getEventSupport().firePropertyChange(JRBaseLine.PROPERTY_DIRECTION, old, this.directionValue);
}
项目:PDFReporter-Studio    文件:LineSection.java   
public void createControls(Composite parent, TabbedPropertySheetPage tabbedPropertySheetPage) {
    super.createControls(parent, tabbedPropertySheetPage);

    parent.setLayout(new GridLayout(2, false));

    createWidget4Property(parent, JRBaseStyle.PROPERTY_FILL);
    createWidget4Property(parent, JRBaseLine.PROPERTY_DIRECTION);
}
项目:PDFReporter-Studio    文件:MLine.java   
@Override
public Object getPropertyValue(Object id) {
    JRDesignLine jrElement = (JRDesignLine) getValue();
    if (id.equals(JRBaseLine.PROPERTY_DIRECTION))
        return directionD.getEnumValue(jrElement.getDirectionValue());
    if (id.equals(JRBaseStyle.PROPERTY_FILL))
        return fillD.getEnumValue(jrElement.getOwnFillValue());
    return super.getPropertyValue(id);
}
项目:PDFReporter-Studio    文件:MLine.java   
@Override
public void setPropertyValue(Object id, Object value) {
    JRDesignLine jrElement = (JRDesignLine) getValue();
    if (id.equals(JRBaseLine.PROPERTY_DIRECTION))
        jrElement.setDirection((LineDirectionEnum) directionD.getEnumValue(value));
    if (id.equals(JRBaseStyle.PROPERTY_FILL))
        jrElement.setFill((FillEnum) fillD.getEnumValue(value));
    else
        super.setPropertyValue(id, value);
}
项目:PDFReporter-Studio    文件:LineSection.java   
@Override
protected void initializeProvidedProperties() {
    super.initializeProvidedProperties();
    addProvidedProperties(JRBaseStyle.PROPERTY_FILL, Messages.common_fill);
    addProvidedProperties(JRBaseLine.PROPERTY_DIRECTION, Messages.MLine_direction);
}
项目:PDFReporter-Studio    文件:MLine.java   
public HashSet<String> generateGraphicalProperties(){
    HashSet<String> result = super.generateGraphicalProperties();
    result.add(JRBaseLine.PROPERTY_DIRECTION);
    result.add(JRBaseStyle.PROPERTY_FILL);
    return result;
}
项目:ireport-fork    文件:LineDirectionProperty.java   
@Override
public String getName()
{
    return JRBaseLine.PROPERTY_DIRECTION;
}