FormattedText

FormattedText

ภาพรวม

FormattedText เป็นคลาสใน Aspose.PDF FOSS สําหรับ .NET.

แสดงข้อความที่ใช้ในการประทับและแก้ไข.

หมวดนี้ให้ 26 วิธีในการทํางานกับ FormattedText วัตถุในโปรแกรม .NET. วิธีการที่ใช้ได้แก่: AddNewLineText, FormattedText, IsCjk, SetCjkFontStyle. สมาชิกสาธารณะทุกคนสามารถเข้าถึงการใช้งาน .NET ใดก็ได้หลังจากติดตั้งแพ็คเกจ Aspose.PDF FOSS for .Net. คุณสมบัติ: BackgroundColor, CustomFontFile, FontName, FontSize, ForegroundColor, IsEmbedded,และอีก 3 คน.

คุณสมบัติ

ชื่อประเภทAccessคําอธิบาย
Textstringอ่านเนื้อหาข้อความแถวแรก.
FontSizedoubleอ่าน/เขียนขนาดตัวอักษรในจุด.
FontNamestringอ่าน/เขียนชื่อตัวอักษร (ชื่อตัวหลัก PDF).
ForegroundColorColorอ่าน/เขียนสีพื้นหน้า (ข้อความ).
BackgroundColorColorอ่าน/เขียนสีพื้นหลัง.
IsEmbeddedboolอ่าน/เขียนว่าข้อความถูกนํามาใช้ (สําหรับตัวอักษรที่ไม่เป็นมาตรฐาน) หรือเปล่า.
CustomFontFilestring?อ่าน/เขียนเส้นทางไฟล์ font ที่กําหนดเอง (สําหรับการติดตั้ง Font TrueType).
TextWidthfloatอ่านขนาดของข้อความที่ใช้ในปัจจุบัน และขนาด, ในจุด.
TextHeightfloatอ่านความสูงทั้งหมดของบล็อกข้อความที่ได้รับการจัดรูป (รวมความสูงเส้น).

วิธีการ

Signatureคําอธิบาย
FormattedText()สร้าง FormattedText ใหม่ด้วยข้อความเปล่า.
FormattedText(text: string)สร้าง FormattedText ใหม่ด้วยข้อความที่กําหนด.
FormattedText(text: string, foregroundColor: Color, backgroundColor: Color)สร้าง FormattedText ด้วยข้อความและสีพื้นหลัง / แผนหลัง.
FormattedText(text: string, foregroundColor: FontColor)สร้าง FormattedText ด้วยข้อความและ FontColor แผนหน้า / หลัง.
FormattedText(text: string, foregroundColor: FontColor, backgroundColor: FontColor)สร้าง FormattedText ด้วยข้อความและ FontColor แผนหน้า / หลัง.
FormattedText(text: string, fontColor: FontColor, fontStyle: FontStyle, encodingType: EncodingType, embedded: bool, textSize: float)สร้าง FormattedText ด้วยการจัดรูปแบบเต็ม โดยใช้ FontColor.
FormattedText(text: string, textColor: FontColor, backColor: FontColor, textFont: FontStyle, textEncoding: EncodingType, embedded: bool, textSize: float)สร้าง FormattedText ด้วยการจัดรูปแบบเต็ม โดยใช้ FontColor กับพื้นหน้าและพื้นหลัง.
FormattedText(text: string, fontColor: FontColor, textFont: FontStyle, textEncoding: EncodingType, embedded: bool, textSize: float, lineSpacing: float)สร้าง FormattedText ด้วยการจัดรูปแบบเต็ม โดยใช้ FontColor, พร้อมกับระยะทางเส้น.
FormattedText(text: string, textColor: Color, backColor: Color, fontName: string, textEncoding: EncodingType, embedded: bool, fontSize: float)สร้าง FormattedText ด้วยการตั้งค่าหน้า / แฟนและตัวอักษร System.Drawing.Color.
FormattedText(text: string, textColor: Color, backColor: Color, textFont: FontStyle, encoding: EncodingType, embedded: bool, textSize: float)สร้าง FormattedText ด้วย System.Drawing.Color แผนหน้า/หลัง และ FontStyle.
FormattedText(text: string, textColor: Color, backColor: Color, textFont: FontStyle, textEncoding: EncodingType, embedded: bool, textSize: float, lineSpacing: float)เรียก FormattedText ((text, textColor, backColore, texFont, TextEncoding, embedded, wordSize, lineSpacing) ในตัวอย่างนี้ FormattedText.
FormattedText(text: string, textColor: System.Drawing.Color, backColor: System.Drawing.Color, textFont: FontStyle, textEncoding: EncodingType, embedded: bool, textSize: float, lineSpacing: float)เรียก FormattedText ((text, textColor, backColore, texFont, TextEncoding, embedded, wordSize, lineSpacing) ในตัวอย่างนี้ FormattedText.
FormattedText(text: string, textColor: FontColor, backColor: FontColor, textFont: FontStyle, textEncoding: EncodingType, embedded: bool, textSize: float, lineSpacing: float)เรียก FormattedText ((text, textColor, backColore, texFont, TextEncoding, embedded, wordSize, lineSpacing) ในตัวอย่างนี้ FormattedText.
FormattedText(text: string, textColor: System.Drawing.Color, backColor: System.Drawing.Color)System.Drawing.Color ด้านหน้า + ดําเนินการ / หลังคู่.
FormattedText(text: string, color: System.Drawing.Color, textFont: FontStyle, textEncoding: EncodingType, embedded: bool, textSize: float)System.Drawing.Color แผนหน้า + FontStyle + EncodingType ไม่มีการแช่เส้น.
FormattedText(text: string, textColor: System.Drawing.Color, textFont: FontStyle, textEncoding: EncodingType, embedded: bool, textSize: float, lineSpacing: float)System.Drawing.Color แผนหน้า + FontStyle + EncodingType + lineSpacing.
FormattedText(text: string, textColor: System.Drawing.Color, backColor: System.Drawing.Color, textFont: FontStyle, encoding: EncodingType, embedded: bool, textSize: float)System.Drawing.Color ด้านหน้า/ด้านหลัง + FontStyle.
FormattedText(text: string, textColor: System.Drawing.Color, backColor: System.Drawing.Color, fontName: string, textEncoding: EncodingType, embedded: bool, fontSize: float)System.Drawing.Color แผนหน้า/พื้นหลัง + สายสตรีงชื่อตัวอักษร.
FormattedText(text: string, textColor: System.Drawing.Color, fontName: string, textEncoding: EncodingType, embedded: bool, fontSize: float)สร้าง FormattedText ด้วย System.Drawing.Color ในพื้นหน้า และชื่อตัวอักษรหรือไฟล์ตัวแปล TrueType.
FormattedText(text: string, textColor: Color, fontName: string, textEncoding: EncodingType, embedded: bool, fontSize: float)สร้าง FormattedText ด้วย Aspose.Pdf.Color ในพื้นหน้า และชื่อตัวอักษรหรือไฟล์ตัวแปล TrueType.
FormattedText(text: string, color: Color, textFont: FontStyle, textEncoding: EncodingType, embedded: bool, textSize: float)สร้าง FormattedText ด้วย FontStyle (enum) และ System.Drawing.Color.
FormattedText(text: string, textColor: Color, textFont: FontStyle, textEncoding: EncodingType, embedded: bool, textSize: float, lineSpacing: float)สร้าง FormattedText ด้วย Aspose.Pdf.Color แผนหน้า/หลัง และระยะทางเส้น.
AddNewLineText(newLineText: string)เพิ่มบรรทัดใหม่.
AddNewLineText(newLineText: string, lineSpacing: float)เพิ่มบรรทัดใหม่ของข้อความที่มีระยะทางเส้นที่กําหนดเอง.
IsCjk()ตรวจสอบว่าข้อความมีตัวอักษร CJK ไหม.
SetCjkFontStyle()ตั้งแบบอักษรเป็นแบบอักษรที่รองรับ CJK (เทียบเท่า MS Gothic).

ดูเช่นกัน

 ภาษาไทย