@Beta public interface PicturesManager
Modifier and Type | Method and Description |
---|---|
java.lang.String |
savePicture(byte[] content, PictureType pictureType, java.lang.String suggestedName, float widthInches, float heightInches)
Stores image (probably on disk).
(存储图像(可能在磁盘上)。)
|
java.lang.String savePicture(byte[] content, PictureType pictureType, java.lang.String suggestedName, float widthInches, float heightInches)
PictureType.GIF
,
PictureType.JPEG
,
PictureType.PNG
,
PictureType.TIFF
, but rarely
PictureType.EMF
or
PictureType.WMF
. FO (Apache FOP) supports at least PNG and SVG types.
(存储图像(可能在磁盘上)。请注意,不同的输出格式支持不同的文件类型,因此可能需要进行图像转换。例如,HTML 浏览器通常支持 PictureType.GIF、PictureType.JPEG、PictureType.PNG、PictureType.TIFF,但很少支持 PictureType.EMF 或 PictureType.WMF。 FO (Apache FOP) 至少支持 PNG 和 SVG 类型。)
content
- picture content
(内容——图片内容)
pictureType
- detected picture type (may be
PictureType.UNKNOWN
(pictureType - 检测到的图片类型(可能是 PictureType.UNKNOWN)
suggestedName
- suggested picture name (based on picture offset in file), supposed to be unique
(建议名称 - 建议的图片名称(基于文件中的图片偏移),应该是唯一的)
widthInches
- display width in inches (scaled). May be useful for rendering vector images (such as EMF or WMF)
(widthInches - 以英寸为单位的显示宽度(按比例缩放)。可用于渲染矢量图像(例如 EMF 或 WMF))
heightInches
- display height in inches (scaled). May be useful for rendering vector images (such as EMF or WMF)
(heightInches - 以英寸为单位显示高度(按比例缩放)。可用于渲染矢量图像(例如 EMF 或 WMF))
Copyright 2021 The Apache Software Foundation or its licensors, as applicable.