Pdf锋利的字体样式大胆,斜体和下划线在一起

Sha*_*dat 8 .net c# pdf-generation pdfsharp migradoc

有什么办法设置字体样式ItalicUnderline或BoldItalicUnderline? 在此输入图像描述

谢谢

Hen*_*man 12

XFontStyle是一种enum类型.您可以使用按位逻辑来组合值.

const XFontStyle ItalicUnderline = XFontStyle.Italic | XFontStyle.Underline ;

const XFontStyle BoldItalicUnderline = XFontStyle.Bold | XFontStyle.Italic | XFontStyle.Underline ;
Run Code Online (Sandbox Code Playgroud)

  • @Koen - 抱歉回复晚了,但“[Flags]”无关紧要。它只影响“ToString()”。基本部分是 1、2、4、8、16 编号。 (2认同)