• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

C# pdf.PdfPatternPainter类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

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



PdfPatternPainter类属于iTextSharp.text.pdf命名空间,在下文中一共展示了PdfPatternPainter类的9个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C#代码示例。

示例1: PatternColor

 /** Creates a color representing a pattern.
                            * @param painter the actual pattern
                            */    
 public PatternColor(PdfPatternPainter painter) : base(TYPE_PATTERN, .5f, .5f, .5f) {
     this.painter = painter;
 }
开发者ID:Niladri24dutta,项目名称:itextsharp,代码行数:6,代码来源:PatternColor.cs


示例2: SetPatternStroke

 /** Sets the stroke color to a pattern. The pattern can be
  * colored or uncolored.
  * @param p the pattern
  */
 public virtual void SetPatternStroke(PdfPatternPainter p)
 {
     if (p.IsStencil()) {
         SetPatternStroke(p, p.DefaultColor);
         return;
     }
     CheckWriter();
     PageResources prs = PageResources;
     PdfName name = writer.AddSimplePattern(p);
     name = prs.AddPattern(name, p.IndirectReference);
     content.Append(PdfName.PATTERN.GetBytes()).Append(" CS ").Append(name.GetBytes()).Append(" SCN").Append_i(separator);
 }
开发者ID:HardcoreSoftware,项目名称:iSecretary,代码行数:16,代码来源:PdfContentByte.cs


示例3: CreatePattern

 /**
  * Create a new uncolored tiling pattern.
  *
  * @param width the width of the pattern
  * @param height the height of the pattern
  * @param xstep the desired horizontal spacing between pattern cells.
  * May be either positive or negative, but not zero.
  * @param ystep the desired vertical spacing between pattern cells.
  * May be either positive or negative, but not zero.
  * @param color the default color. Can be <CODE>null</CODE>
  * @return the <CODE>PdfPatternPainter</CODE> where the pattern will be created
  */
 public PdfPatternPainter CreatePattern(float width, float height, float xstep, float ystep, BaseColor color)
 {
     CheckWriter();
     if ( xstep == 0.0f || ystep == 0.0f )
         throw new Exception(MessageLocalization.GetComposedMessage("xstep.or.ystep.can.not.be.zero"));
     PdfPatternPainter painter = new PdfPatternPainter(writer, color);
     painter.Width = width;
     painter.Height = height;
     painter.XStep = xstep;
     painter.YStep = ystep;
     writer.AddSimplePattern(painter);
     return painter;
 }
开发者ID:HardcoreSoftware,项目名称:iSecretary,代码行数:25,代码来源:PdfContentByte.cs


示例4: AddSimplePattern

 internal PdfName AddSimplePattern(PdfPatternPainter painter)
 {
     PdfName name = (PdfName)documentPatterns[painter];
     if ( name == null ) {
         name = new PdfName("P" + patternNumber);
         ++patternNumber;
         documentPatterns[painter] = name;
     }
     return name;
 }
开发者ID:bmictech,项目名称:iTextSharp,代码行数:10,代码来源:PdfWriter.cs


示例5: UncoloredPattern

 protected internal UncoloredPattern(PdfPatternPainter p, BaseColor color, float tint) : base(p) {
     this.color = color;
     this.tint = tint;
 }
开发者ID:NelsonSantos,项目名称:fyiReporting-Android,代码行数:4,代码来源:PdfContentByte.cs


示例6: SetPatternStroke

 /**
 * @see com.lowagie.text.pdf.PdfContentByte#setPatternStroke(com.lowagie.text.pdf.PdfPatternPainter)
 */
 public override void SetPatternStroke(PdfPatternPainter p) {
     CheckNoColor();
     base.SetPatternStroke(p);
 }
开发者ID:nicecai,项目名称:iTextSharp-4.1.6,代码行数:7,代码来源:PdfPatternPainter.cs


示例7: SetPatternFill

 /**
 * @see com.lowagie.text.pdf.PdfContentByte#setPatternFill(com.lowagie.text.pdf.PdfPatternPainter, java.awt.Color, float)
 */
 public override void SetPatternFill(PdfPatternPainter p, BaseColor color, float tint)
 {
     CheckNoColor();
     base.SetPatternFill(p, color, tint);
 }
开发者ID:mapo80,项目名称:iTextSharp-Monotouch,代码行数:8,代码来源:PdfPatternPainter.cs


示例8: CreatePattern

 /**
  * Create a new uncolored tiling pattern.
  *
  * @param width the width of the pattern
  * @param height the height of the pattern
  * @param xstep the desired horizontal spacing between pattern cells.
  * May be either positive or negative, but not zero.
  * @param ystep the desired vertical spacing between pattern cells.
  * May be either positive or negative, but not zero.
  * @param color the default color. Can be <CODE>null</CODE>
  * @return the <CODE>PdfPatternPainter</CODE> where the pattern will be created
  */
 public PdfPatternPainter CreatePattern(float width, float height, float xstep, float ystep, Color color)
 {
     CheckWriter();
     if ( xstep == 0.0f || ystep == 0.0f )
         throw new Exception("XStep or YStep can not be ZERO.");
     PdfPatternPainter painter = new PdfPatternPainter(writer, color);
     painter.Width = width;
     painter.Height = height;
     painter.XStep = xstep;
     painter.YStep = ystep;
     writer.AddSimplePattern(painter);
     return painter;
 }
开发者ID:JamieMellway,项目名称:iTextSharpLGPL-Monotouch,代码行数:25,代码来源:PdfContentByte.cs


示例9: SetPatternFill

 /** Sets the fill color to an uncolored pattern.
  * @param p the pattern
  * @param color the color of the pattern
  * @param tint the tint if the color is a spot color, ignored otherwise
  */
 public virtual void SetPatternFill(PdfPatternPainter p, Color color, float tint)
 {
     CheckWriter();
     if (!p.IsStencil())
         throw new Exception("An uncolored pattern was expected.");
     PageResources prs = PageResources;
     PdfName name = writer.AddSimplePattern(p);
     name = prs.AddPattern(name, p.IndirectReference);
     ColorDetails csDetail = writer.AddSimplePatternColorspace(color);
     PdfName cName = prs.AddColor(csDetail.ColorName, csDetail.IndirectReference);
     content.Append(cName.GetBytes()).Append(" cs").Append_i(separator);
     OutputColorNumbers(color, tint);
     content.Append(' ').Append(name.GetBytes()).Append(" scn").Append_i(separator);
 }
开发者ID:JamieMellway,项目名称:iTextSharpLGPL-Monotouch,代码行数:19,代码来源:PdfContentByte.cs



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


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C# pdf.PdfReader类代码示例发布时间:2022-05-26
下一篇:
C# pdf.PdfPTable类代码示例发布时间:2022-05-26
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap