C# uses the cross-platform PdfSharpCore open source library to generate PDF files

1. Description of requirements

        During project development, it is necessary to export some text content of the C# program as a PDF file (which can be automatically divided into rows and pages according to the text), and the program for generating PDF files is required to be cross-platform; to achieve similar effects:

2. Demand analysis

①Export the text content of the program as a PDF file;

②It can automatically divide the text content into lines and pages [and you can add headers, footers, page numbers, watermarks, pictures or encrypt PDF files];

② The C# program that generates PDF needs to be cross-platform (using .netcore);

The open source available PDF library under .netcore is [PdfSharpCore] GitHub - ststeiger/PdfSharpCore: Port of the PdfSharp library to .NET Core - largely removed GDI+ (only missing GetFontData - which can be replaced with freetype2)

Guess you like

Origin blog.csdn.net/xiaochenXIHUA/article/details/131704669