@ -159,7 +159,7 @@ Please note that this project is released with a [Contributor Code of Conduct][c
We use the [Stack Exchange][stackoverflow] network for free support and [GitHub][github] for code hosting. By using these services, you agree to abide by their terms:
For more advanced use cases, please refer to the [Installation guidelines](https://kb.itextpdf.com/home/it7kb/installation-guidelines).
You can also [build iText Community from source][building].
### Hello PDF!
The following example shows how easy it is to create a simple PDF document:
```csharp
using iText.Kernel.Pdf;
using iText.Layout;
using iText.Layout.Element;
namespace HelloPdf {
class Program {
static void Main(string[] args) {
using var document = new Document(new PdfDocument(new PdfWriter("helloworld-pdf.pdf")));
document.Add(new Paragraph("Hello World!"));
}
}
}
```
### Examples
For more advanced examples, refer to our [Knowledge Base](https://kb.itextpdf.com/home/it7kb/examples) or the main [Examples repo](https://github.com/itext/i7ns-samples). You can find C# equivalents to the Java [Signing examples](https://github.com/itext/i7js-signing-examples) [here](https://github.com/itext/i7ns-samples/tree/develop/itext/itext.publications), though the Java code is very similar since they have the same API.
Some of the output PDF files will be incorrectly displayed by the GitHub previewer, so be sure to download them to see
| Change text properties | [C#](https://github.com/itext/i7ns-samples/blob/master/itext/itext.samples/itext/samples/sandbox/layout/ParagraphTextWithStyle.cs), [PDF](https://github.com/itext/i7ns-samples/blob/master/itext/itext.samples/cmpfiles/sandbox/layout/cmp_paragraphTextWithStyle.pdf) |
| Creating a simple table | [C#](https://github.com/itext/i7ns-samples/blob/master/itext/itext.samples/itext/samples/sandbox/tables/SimpleTable9.cs), [PDF](https://github.com/itext/i7ns-samples/blob/master/itext/itext.samples/cmpfiles/sandbox/tables/cmp_simple_table9.pdf) |
| Add an image to a PDF document | [C#](https://github.com/itext/i7ns-samples/blob/master/itext/itext.samples/itext/samples/sandbox/images/MultipleImages.cs), [PDF](https://github.com/itext/i7ns-samples/blob/master/itext/itext.samples/cmpfiles/sandbox/images/cmp_multiple_images.pdf) |
| Create a list | [C#](https://github.com/itext/i7ns-samples/blob/master/itext/itext.samples/itext/samples/sandbox/objects/NestedLists.cs), [PDF](https://github.com/itext/i7ns-samples/blob/master/itext/itext.samples/cmpfiles/sandbox/objects/cmp_nested_list.pdf) |
| Add a watermark | [C#](https://github.com/itext/i7ns-samples/blob/master/itext/itext.samples/itext/samples/sandbox/events/Watermarking.cs), [PDF](https://github.com/itext/i7ns-samples/blob/master/itext/itext.samples/cmpfiles/sandbox/events/cmp_watermarkings.pdf) |
| Add links to navigate within a document | [C#](https://github.com/itext/i7ns-samples/blob/master/itext/itext.samples/itext/samples/sandbox/annotations/AddLinkAnnotation5.cs), [PDF](https://github.com/itext/i7ns-samples/blob/master/itext/itext.samples/cmpfiles/sandbox/annotations/cmp_add_link_annotation5.pdf) |
| Create a popup annotation | [C#](https://github.com/itext/i7ns-samples/blob/master/itext/itext.samples/itext/samples/sandbox/annotations/MovePopup.cs), [PDF](https://github.com/itext/i7ns-samples/blob/master/itext/itext.samples/cmpfiles/sandbox/annotations/cmp_move_popup.pdf) |
| Change font | [C#](https://github.com/itext/i7ns-samples/blob/master/itext/itext.samples/itext/samples/sandbox/layout/ParagraphTextWithStyle.cs) |
| Add form fields | [C#](https://kb.itextpdf.com/home/it7kb/examples/forms-in-itext-core-8-0-0) |
<br> | |
| **General document settings** | |
| Change page size and margin | [C#](https://github.com/itext/i7ns-samples/blob/master/itext/itext.samples/itext/samples/sandbox/layout/PageSizeAndMargins.cs), [PDF](https://github.com/itext/i7ns-samples/blob/master/itext/itext.samples/cmpfiles/sandbox/layout/cmp_pageSizeAndMargins.pdf) |
| Write PDF to byte array instead of to disk | [C#](https://stackoverflow.com/a/67411657/10015628) |
| Redact based on regex | [C#](https://itextpdf.com/products/pdf-redaction-pdfsweep) |
| <br> | |
| **Support complex writing systems** | [Link to docs](https://itextpdf.com/products/pdfcalligraph) |
| Add Arabic text | [C#](https://github.com/itext/i7ns-samples/blob/master/itext/itext.samples/itext/samples/sandbox/typography/arabic/ArabicWordSpacing.cs) , [PDF](https://github.com/itext/i7ns-samples/blob/master/itext/itext.samples/cmpfiles/sandbox/typography/cmp_ArabicWordSpacing.pdf) |
| <br> | |
| **Optimizing PDFs** | [Link to docs](https://itextpdf.com/products/compress-pdf-pdfoptimizer) |
| Reduce size of PDF | [C#](https://itextpdf.com/products/compress-pdf-pdfoptimizer) |
| <br> | |
| **XFA flattening** | [Link to docs](https://itextpdf.com/products/flatten-pdf-pdfxfa) |
| Flatten an XFA document | [C#](https://itextpdf.com/products/flatten-pdf-pdfxfa) |
| <br> | |
| **RUPS** | [Link to repo](https://github.com/itext/i7j-rups) |
| Debug a PDF | [C#](https://github.com/itext/i7j-rups/releases/latest) |
### FAQs, tutorials, etc. ###
Check out the [iText Knowledge Base](https://kb.itextpdf.com) for the [iText Jump-start tutorial](https://kb.itextpdf.com/home/it7kb/ebooks/itext-jump-start-tutorial-for-net) and other
tutorials, [FAQs](https://kb.itextpdf.com/home/it7kb/faq) and more. For specific information and examples relating to
digital signatures and iText, make sure to check
the [Digital Signatures Hub](https://kb.itextpdf.com/home/it7kb/digital-signatures-hub).
Many common questions have already been answered
on [Stack Overflow](https://stackoverflow.com/questions/tagged/itext+itext7), so make sure to also check there.
### Contributing
Many people have contributed to **iText Core/Community** over the years. If you've found a bug, a mistake in
documentation, or have a hot new feature you want to implement, we welcome your contributions.
Small changes or fixes can be submitted as a [Pull Request](https://github.com/itext/itext7-dotnet/pulls), while for
major changes we request you contact us at community@apryse.com so we can better coordinate our efforts and prevent
duplication of work.
Please read our [Contribution Guidelines][contributing] for details on code submissions, coding rules, and more.
### Licensing
**iText** is dual licensed as [AGPL][agpl]/[Commercial software][sales].