Package org.pentaho.reporting.libraries.pixie.wmf

Examples of org.pentaho.reporting.libraries.pixie.wmf.MfRecord


   * @return the created record.
   */
  public MfRecord getRecord()
      throws RecordCreationException
  {
    final MfRecord record = new MfRecord(RECORD_SIZE);
    record.setType(getFunction());
    record.setParam(POS_NEW_PALETTE_SIZE, getPaletteSize());
    return record;
  }
View Full Code Here


   *
   * @return the created record.
   */
  public MfRecord getRecord()
  {
    final MfRecord record = new MfRecord(4);
    final Dimension dim = getDimension();
    record.setParam(0, dim.height);
    record.setParam(1, dim.width);
    record.setParam(2, getRegion());
    record.setParam(3, getBrush());
    return record;
  }
View Full Code Here

   * @return the created record.
   */
  public MfRecord getRecord()
      throws RecordCreationException
  {
    final MfRecord record = new MfRecord(1);
    record.setParam(0, getNSavedDC());
    return record;
  }
View Full Code Here

      throws RecordCreationException
  {
    if (image == null)
    {
      // the simple form, the complex form would need a DIB implementation.
      final MfRecord record = new MfRecord(RECORD_SIZE_SIMPLE);
      record.setLongParam(POS_OPERATION, getOperation());
      final Rectangle source = getSource();
      record.setParam(POS_SRC_Y, (int) source.getY());
      record.setParam(POS_SRC_X, (int) source.getX());

      // Ignore the handle to the device context
      final Rectangle dest = getDestination();
      record.setParam(4, 0); // the handle to the device context ... a stored DIB?.
      record.setParam(SIMPLE_POS_HEIGHT, (int) dest.getHeight());
      record.setParam(SIMPLE_POS_WIDTH, (int) dest.getWidth());
      record.setParam(SIMPLE_POS_DST_Y, (int) dest.getY());
      record.setParam(SIMPLE_POS_DST_X, (int) dest.getX());
      return record;
    }

    // todo implement the complex form
    throw new RecordCreationException("The extended Format of DibBitBlt is not supported");
View Full Code Here

   * @return the created record.
   */
  public MfRecord getRecord()
  {
    final Point dest = getDestination();
    final MfRecord record = new MfRecord(RECORD_SIZE);
    record.setParam(POS_Y, dest.y);
    record.setParam(POS_X, dest.x);
    return record;
  }
View Full Code Here

    String fontFace = getFontFace();
    if (fontFace.length() > FONT_FACE_MAX)
    {
      fontFace = fontFace.substring(0, FONT_FACE_MAX);
    }
    final MfRecord record = new MfRecord(FIXED_RECORD_SIZE + fontFace.length());
    record.setParam(POS_HEIGHT, getHeight());
    record.setParam(POS_WIDTH, getWidth());
    record.setParam(POS_ESCAPEMENT, getEscapement());
    record.setParam(POS_ORIENTATION, getOrientation());
    record.setParam(POS_WEIGHT, getWeight());

    record.setParam(POS_FLAGS1, formFlags(isUnderline(), isItalic()));
    record.setParam(POS_FLAGS2, formFlags(isStrikeout(), false) + getCharset());
    record.setParam(POS_PRECISION, getOutputPrecision() << 8 + getClipPrecision());
    record.setParam(POS_QUALITY, getQuality() << 8 + getPitchAndFamily());
    record.setStringParam(POS_FONTFACE, fontFace);
    return record;
  }
View Full Code Here

   * @return the created record.
   */
  public MfRecord getRecord()
  {
    final Rectangle rc = getBounds();
    final MfRecord record = new MfRecord(RECORD_SIZE);
    record.setParam(POS_BOTTOM, (int) (rc.getY() + rc.getHeight()));
    record.setParam(POS_RIGHT, (int) (rc.getX() + rc.getWidth()));
    record.setParam(POS_TOP, (int) (rc.getY()));
    record.setParam(POS_LEFT, (int) (rc.getX()));
    return record;
  }
View Full Code Here

   * @return the created record.
   */
  public MfRecord getRecord()
      throws RecordCreationException
  {
    final MfRecord record = new MfRecord(RECORD_SIZE);
    final Dimension dim = getDimension();
    record.setParam(POS_HEIGHT, dim.height);
    record.setParam(POS_WIDTH, dim.width);
    return record;
  }
View Full Code Here

   * @return the created record.
   */
  public MfRecord getRecord()
      throws RecordCreationException
  {
    final MfRecord record = new MfRecord(RECORD_SIZE);
    record.setParam(POS_BREAKCOUNT, getBreakCount());
    record.setParam(POS_SPACELENGTH, getExtraSpaceLength());
    return record;
  }
View Full Code Here

   * @return the created record.
   */
  public MfRecord getRecord()
      throws RecordCreationException
  {
    final MfRecord record = new MfRecord(RECORD_SIZE);
    record.setParam(POS_POLYFILLMODE, getFillMode());
    return record;
  }
View Full Code Here

TOP

Related Classes of org.pentaho.reporting.libraries.pixie.wmf.MfRecord

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.