com.lowagie.text.Image.scaleAbsoluteWidth()方法的使用及代码示例

x33g5p2x  于2022-01-21 转载在 其他  
字(2.2k)|赞(0)|评价(0)|浏览(239)

本文整理了Java中com.lowagie.text.Image.scaleAbsoluteWidth()方法的一些代码示例,展示了Image.scaleAbsoluteWidth()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Image.scaleAbsoluteWidth()方法的具体详情如下:
包路径:com.lowagie.text.Image
类名称:Image
方法名:scaleAbsoluteWidth

Image.scaleAbsoluteWidth介绍

[英]Scale the image to an absolute width.
[中]将图像缩放到绝对宽度。

代码示例

代码示例来源:origin: fr.opensagres.xdocreport/org.odftoolkit.odfdom.converter.pdf

public StylableImage( StylableDocument ownerDocument, IStylableContainer parent, Image image, Float x, Float y,
           Float width, Float height )
{
  this.parent = parent;
  this.image = image;
  this.x = x;
  this.y = y;
  if ( width != null )
  {
    image.scaleAbsoluteWidth( width );
  }
  if ( height != null )
  {
    image.scaleAbsoluteHeight( height );
  }
}

代码示例来源:origin: fr.opensagres.xdocreport/fr.opensagres.odfdom.converter.pdf

public StylableImage( StylableDocument ownerDocument, IStylableContainer parent, Image image, Float x, Float y,
           Float width, Float height )
{
  this.parent = parent;
  this.image = image;
  this.x = x;
  this.y = y;
  if ( width != null )
  {
    image.scaleAbsoluteWidth( width );
  }
  if ( height != null )
  {
    image.scaleAbsoluteHeight( height );
  }
}

代码示例来源:origin: es.gob.afirma/afirma-crypto-pdf-itext

image.scaleAbsoluteWidth(Float.parseFloat(value + "f"));

代码示例来源:origin: com.github.librepdf/openpdf

image.scaleAbsoluteWidth(Float.parseFloat(value + "f"));

代码示例来源:origin: fr.opensagres.xdocreport.itext-gae/itext-gae

image.scaleAbsoluteWidth(Float.parseFloat(value + "f"));

代码示例来源:origin: stackoverflow.com

Image logo = Image.getInstance("/image.gif");
logo.setAlignment(Image.MIDDLE);
logo.scaleAbsoluteHeight(20);
logo.scaleAbsoluteWidth(20);
logo.scalePercent(100);
Chunk chunk = new Chunk(logo, 0, -45);
HeaderFooter header = new HeaderFooter(new Phrase(chunk), false);
header.setAlignment(Element.ALIGN_CENTER);
header.setBorder(Rectangle.NO_BORDER);
document.setHeader(header);

代码示例来源:origin: fr.opensagres.xdocreport/org.odftoolkit.odfdom.converter.pdf

if ( width != null )
  image.scaleAbsoluteWidth( width );

代码示例来源:origin: fr.opensagres.xdocreport/fr.opensagres.odfdom.converter.pdf

if ( width != null )
  image.scaleAbsoluteWidth( width );

代码示例来源:origin: fr.opensagres/org.odftoolkit.odfdom.converter

image.scaleAbsoluteWidth(ODFUtils
    .getDimensionAsPoint(width));

相关文章

微信公众号

最新文章

更多

Image类方法