public final class Picture
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
static byte[] |
BMP
Deprecated.
|
static byte[] |
COMPRESSED1 |
static byte[] |
COMPRESSED2 |
static byte[] |
EMF
Deprecated.
|
static byte[] |
GIF
Deprecated.
|
static byte[] |
IHDR |
static byte[] |
JPG
Deprecated.
|
static byte[] |
PNG
Deprecated.
|
static byte[] |
TIFF
Deprecated.
|
static byte[] |
TIFF1
Deprecated.
|
static byte[] |
WMF1
Deprecated.
|
static byte[] |
WMF2
Deprecated.
|
Constructor and Description |
---|
Picture(EscherBlipRecord blipRecord)
Builds a Picture object for a Picture stored as
Escher.
|
Picture(int dataBlockStartOfsset,
byte[] _dataStream,
boolean fillBytes)
Builds a Picture object for a Picture stored in the
DataStream
|
Modifier and Type | Method and Description |
---|---|
int |
getAspectRatioX()
Deprecated.
use more precise
getHorizontalScalingFactor() |
int |
getAspectRatioY()
Deprecated.
use more precise
getVerticalScalingFactor() |
byte[] |
getContent() |
java.lang.String |
getDescription()
returns the description stored in the alternative text
|
int |
getDxaCropLeft()
Deprecated.
|
int |
getDxaCropRight()
Deprecated.
|
int |
getDxaGoal()
Gets the initial width of the picture, in twips, prior to cropping or
scaling.
|
int |
getDyaCropBottom()
Deprecated.
|
int |
getDyaCropTop()
Deprecated.
|
int |
getDyaGoal()
Gets the initial height of the picture, in twips, prior to cropping or
scaling.
|
int |
getHeight()
returns pixel height of the picture or -1 if dimensions determining was
failed
|
int |
getHorizontalScalingFactor() |
java.lang.String |
getMimeType()
Returns the MIME type for the image
|
byte[] |
getRawContent()
Returns picture's content as it stored in Word file, i.e. possibly in
compressed form.
|
int |
getSize() |
int |
getStartOffset() |
int |
getVerticalScalingFactor() |
int |
getWidth()
returns pixel width of the picture or -1 if dimensions determining was
failed
|
java.lang.String |
suggestFileExtension()
tries to suggest extension for picture's file by matching signatures of
popular image formats to first bytes of picture's contents
|
java.lang.String |
suggestFullFileName()
Tries to suggest a filename: hex representation of picture structure
offset in "Data" stream plus extension that is tried to determine from
first byte of picture's content.
|
PictureType |
suggestPictureType() |
void |
writeImageContent(java.io.OutputStream out)
Writes Picture's content bytes to specified OutputStream.
|
@Deprecated public static final byte[] BMP
public static final byte[] COMPRESSED1
public static final byte[] COMPRESSED2
@Deprecated public static final byte[] EMF
@Deprecated public static final byte[] GIF
public static final byte[] IHDR
@Deprecated public static final byte[] JPG
@Deprecated public static final byte[] PNG
@Deprecated public static final byte[] TIFF
@Deprecated public static final byte[] TIFF1
@Deprecated public static final byte[] WMF1
@Deprecated public static final byte[] WMF2
public Picture(EscherBlipRecord blipRecord)
public Picture(int dataBlockStartOfsset, byte[] _dataStream, boolean fillBytes)
@Deprecated public int getAspectRatioX()
getHorizontalScalingFactor()
@Deprecated public int getAspectRatioY()
getVerticalScalingFactor()
public byte[] getContent()
@Deprecated public int getDxaCropLeft()
@Deprecated public int getDxaCropRight()
public int getDxaGoal()
@Deprecated public int getDyaCropBottom()
@Deprecated public int getDyaCropTop()
public int getDyaGoal()
public int getHeight()
public int getHorizontalScalingFactor()
public java.lang.String getMimeType()
public byte[] getRawContent()
public int getSize()
public int getStartOffset()
CharacterRun.getPicOffset()
public int getVerticalScalingFactor()
public int getWidth()
public java.lang.String getDescription()
public java.lang.String suggestFileExtension()
public java.lang.String suggestFullFileName()
public PictureType suggestPictureType()
public void writeImageContent(java.io.OutputStream out) throws java.io.IOException
out
- a stream to write tojava.io.IOException
- if some exception is occured while writing to specified outCopyright © 2005-2010 Potix Corporation. All Rights Reserved.