当前位置: 首页>>代码示例>>Java>>正文


Java RunDirectionEnum类代码示例

本文整理汇总了Java中net.sf.jasperreports.engine.type.RunDirectionEnum的典型用法代码示例。如果您正苦于以下问题:Java RunDirectionEnum类的具体用法?Java RunDirectionEnum怎么用?Java RunDirectionEnum使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


RunDirectionEnum类属于net.sf.jasperreports.engine.type包,在下文中一共展示了RunDirectionEnum类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: setPropertyValue

import net.sf.jasperreports.engine.type.RunDirectionEnum; //导入依赖的package包/类
@Override
public void setPropertyValue(Object id, Object value) {
	JRDesignCrosstab jrElement = (JRDesignCrosstab) getValue();

	if (id.equals(JRDesignCrosstab.PROPERTY_REPEAT_COLUMN_HEADERS))
		jrElement.setRepeatColumnHeaders((Boolean) value);
	else if (id.equals(JRDesignCrosstab.PROPERTY_REPEAT_ROW_HEADERS))
		jrElement.setRepeatRowHeaders((Boolean) value);
	else if (id.equals(JRBaseCrosstab.PROPERTY_HORIZONTAL_POSITION))
		jrElement.setHorizontalPosition(HorizontalPositionUtil.getTextPosition4Pos((Integer) value));
	else if (id.equals(JRDesignCrosstab.PROPERTY_IGNORE_WIDTH))
		jrElement.setIgnoreWidth((Boolean) value);
	else if (id.equals(JRDesignCrosstab.PROPERTY_COLUMN_BREAK_OFFSET))
		jrElement.setColumnBreakOffset((Integer) value);
	if (id.equals(JRBaseCrosstab.PROPERTY_RUN_DIRECTION)) {
		jrElement.setRunDirection((RunDirectionEnum) runDirectionD.getEnumValue(value));

		getCrosstabManager().refresh();
		getPropertyChangeSupport().firePropertyChange(new PropertyChangeEvent(this, JRBaseCrosstab.PROPERTY_RUN_DIRECTION, null, value));
	} else if (id.equals(JRDesignCrosstab.PROPERTY_PARAMETERS_MAP_EXPRESSION))
		jrElement.setParametersMapExpression(ExprUtil.setValues(jrElement.getParametersMapExpression(), value));
	else
		super.setPropertyValue(id, value);
}
 
开发者ID:OpenSoftwareSolutions,项目名称:PDFReporter-Studio,代码行数:25,代码来源:MCrosstab.java

示例2: addBand

import net.sf.jasperreports.engine.type.RunDirectionEnum; //导入依赖的package包/类
/**
 *
 */
private void addBand(JRBand band, boolean isColumnBand)
{
	if (band != null)
	{
		JRBasePrintFrame frame = new JRBasePrintFrame(null);
		frame.setX(
			isColumnBand && report.getColumnDirection() == RunDirectionEnum.RTL 
				? report.getPageWidth() - report.getRightMargin() - report.getColumnWidth() 
				: report.getLeftMargin()
			);
		frame.setY(offsetY);
		frame.setWidth(
			isColumnBand
			? report.getColumnWidth()
			: report.getPageWidth() - report.getLeftMargin() - report.getRightMargin()
			);
		frame.setHeight(band.getHeight());
		
		band.visit(new ConvertVisitor(this, frame));
		
		pageElements.add(frame);
		
		offsetY += band.getHeight();
		addBandSeparator(offsetY);
	}
}
 
开发者ID:TIBCOSoftware,项目名称:jasperreports,代码行数:30,代码来源:ReportConverter.java

示例3: setColumnDirection

import net.sf.jasperreports.engine.type.RunDirectionEnum; //导入依赖的package包/类
/**
 * Sets the column direction.
 */
public void setColumnDirection(RunDirectionEnum columnDirection)
{
	Object old = this.columnDirection;
	this.columnDirection = columnDirection;
	getEventSupport().firePropertyChange(PROPERTY_COLUMN_DIRECTION, old, this.columnDirection);
}
 
开发者ID:TIBCOSoftware,项目名称:jasperreports,代码行数:10,代码来源:JasperDesign.java

示例4: render

import net.sf.jasperreports.engine.type.RunDirectionEnum; //导入依赖的package包/类
@Override
public void render()
{
	ColumnText colText = new ColumnText(pdfContentByte);
	colText.setSimpleColumn(
		getPhrase(styledText, text),
		x + leftPadding,
		pdfExporter.getCurrentPageFormat().getPageHeight()
			- y
			- topPadding
			- verticalAlignOffset
			- text.getLeadingOffset(),
			//+ text.getLineSpacingFactor() * text.getFont().getSize(),
		x + width - rightPadding,
		pdfExporter.getCurrentPageFormat().getPageHeight()
			- y
			- height
			+ bottomPadding,
		0,//text.getLineSpacingFactor(),// * text.getFont().getSize(),
		horizontalAlignment == Element.ALIGN_JUSTIFIED_ALL ? Element.ALIGN_JUSTIFIED : horizontalAlignment
		);

	colText.setLeading(0, text.getLineSpacingFactor());// * text.getFont().getSize());
	colText.setRunDirection(
		text.getRunDirectionValue() == RunDirectionEnum.LTR
		? PdfWriter.RUN_DIRECTION_LTR : PdfWriter.RUN_DIRECTION_RTL
		);

	try
	{
		colText.go();
	}
	catch (DocumentException e)
	{
		throw new JRRuntimeException(e);
	}
}
 
开发者ID:TIBCOSoftware,项目名称:jasperreports,代码行数:38,代码来源:SimplePdfTextRenderer.java

示例5: concreteHorizontalPosition

import net.sf.jasperreports.engine.type.RunDirectionEnum; //导入依赖的package包/类
protected HorizontalPosition concreteHorizontalPosition()
{
	HorizontalPosition position = getHorizontalPosition();
	if (position == null)
	{
		position = getRunDirectionValue() == RunDirectionEnum.RTL 
				? HorizontalPosition.RIGHT : HorizontalPosition.LEFT;
	}
	return position;
}
 
开发者ID:TIBCOSoftware,项目名称:jasperreports,代码行数:11,代码来源:JRFillCrosstab.java

示例6: setOffsetX

import net.sf.jasperreports.engine.type.RunDirectionEnum; //导入依赖的package包/类
/**
 *
 */
private void setOffsetX()
{
	if (columnDirection == RunDirectionEnum.RTL)
	{
		offsetX = pageWidth - rightMargin - columnWidth - columnIndex * (columnSpacing + columnWidth);
	}
	else
	{
		offsetX = leftMargin + columnIndex * (columnSpacing + columnWidth);
	}
}
 
开发者ID:TIBCOSoftware,项目名称:jasperreports,代码行数:15,代码来源:JRHorizontalFiller.java

示例7: readObject

import net.sf.jasperreports.engine.type.RunDirectionEnum; //导入依赖的package包/类
@SuppressWarnings("deprecation")
private void readObject(ObjectInputStream in) throws IOException, ClassNotFoundException
{
	in.defaultReadObject();

	if (PSEUDO_SERIAL_VERSION_UID < JRConstants.PSEUDO_SERIAL_VERSION_UID_3_7_2)
	{
		runDirectionValue = RunDirectionEnum.getByValue(runDirection);
	}
}
 
开发者ID:TIBCOSoftware,项目名称:jasperreports,代码行数:11,代码来源:JRTemplatePrintText.java

示例8: setRunDirection

import net.sf.jasperreports.engine.type.RunDirectionEnum; //导入依赖的package包/类
@Override
public void setRunDirection(RunDirectionEnum runDirectionValue)
{
	RunDirectionEnum old = this.runDirectionValue;
	this.runDirectionValue = runDirectionValue;
	getEventSupport().firePropertyChange(PROPERTY_RUN_DIRECTION, old, this.runDirectionValue);
}
 
开发者ID:TIBCOSoftware,项目名称:jasperreports,代码行数:8,代码来源:JRBaseCrosstab.java

示例9: setRunDirection

import net.sf.jasperreports.engine.type.RunDirectionEnum; //导入依赖的package包/类
@Override
public void setRunDirection(RunDirectionEnum runDirectionValue)
{
	RunDirectionEnum old = this.runDirectionValue;
	this.runDirectionValue = runDirectionValue;
	getEventSupport().firePropertyChange(JRBaseCrosstab.PROPERTY_RUN_DIRECTION, old, this.runDirectionValue);
}
 
开发者ID:TIBCOSoftware,项目名称:jasperreports,代码行数:8,代码来源:JRDesignCrosstab.java

示例10: ColumnDirectionProperty

import net.sf.jasperreports.engine.type.RunDirectionEnum; //导入依赖的package包/类
@SuppressWarnings("unchecked")
public ColumnDirectionProperty(JasperDesign jd)
{
    super(RunDirectionEnum.class,jd);
    this.jd = jd;
    setValue("suppressCustomEditor", Boolean.TRUE);
}
 
开发者ID:JockiHendry,项目名称:ireport-fork,代码行数:8,代码来源:ReportNode.java

示例11: getTagList

import net.sf.jasperreports.engine.type.RunDirectionEnum; //导入依赖的package包/类
public List getTagList()
{
    List tags = new java.util.ArrayList();
    tags.add(new Tag(RunDirectionEnum.LTR, I18n.getString("Global.Property.ColumnDirection.LTR")));
    tags.add(new Tag(RunDirectionEnum.RTL, I18n.getString("Global.Property.ColumnDirection.RTL")));

    return tags;
}
 
开发者ID:JockiHendry,项目名称:ireport-fork,代码行数:9,代码来源:ReportNode.java

示例12: setPropertyValue

import net.sf.jasperreports.engine.type.RunDirectionEnum; //导入依赖的package包/类
@Override
public void setPropertyValue(Object value) {
    if (value != null && value instanceof RunDirectionEnum)
    {
        jd.setColumnDirection( (RunDirectionEnum)value);
    }
}
 
开发者ID:JockiHendry,项目名称:ireport-fork,代码行数:8,代码来源:ReportNode.java

示例13: RunDirectionProperty

import net.sf.jasperreports.engine.type.RunDirectionEnum; //导入依赖的package包/类
@SuppressWarnings("unchecked")
public RunDirectionProperty(JRDesignCrosstab crosstab)
{
    super(RunDirectionEnum.class, crosstab);
    this.crosstab = crosstab;
    setValue("suppressCustomEditor", Boolean.TRUE);
}
 
开发者ID:JockiHendry,项目名称:ireport-fork,代码行数:8,代码来源:CrosstabNode.java

示例14: getTagList

import net.sf.jasperreports.engine.type.RunDirectionEnum; //导入依赖的package包/类
public List getTagList() {
    List list = new ArrayList();
    list.add(new Tag(RunDirectionEnum.LTR, "Left to Right"));
    list.add(new Tag(RunDirectionEnum.RTL, "Right to Left"));
    return list;

}
 
开发者ID:JockiHendry,项目名称:ireport-fork,代码行数:8,代码来源:CrosstabNode.java

示例15: test

import net.sf.jasperreports.engine.type.RunDirectionEnum; //导入依赖的package包/类
@Override
public void test() {
	super.test();

	JRBaseCrosstab crosstab = (JRBaseCrosstab) getJasperReport().getSummary().getElementByKey("summary.crosstab1");
	Assert.assertFalse("Crosstab repeatColumnHeaders", crosstab.isRepeatColumnHeaders());
	Assert.assertFalse("Crosstab repeatRowHeaders", crosstab.isRepeatRowHeaders());
	Assert.assertEquals("Crosstab columnBreakOffset", 100, crosstab.getColumnBreakOffset());
	Assert.assertTrue("Crosstab ignoreWidth", crosstab.getIgnoreWidth());
	Assert.assertEquals("Crosstab runDirection", RunDirectionEnum.RTL, crosstab.getRunDirectionValue());
	Assert.assertEquals("Crosstab row group position", CrosstabRowPositionEnum.STRETCH, crosstab.getRowGroups()[0].getPositionValue());
	Assert.assertEquals("Crosstab column group position", CrosstabColumnPositionEnum.STRETCH, crosstab.getColumnGroups()[0].getPositionValue());
}
 
开发者ID:svn2github,项目名称:dynamicreports-jasper,代码行数:14,代码来源:CrosstabTest.java


注:本文中的net.sf.jasperreports.engine.type.RunDirectionEnum类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。