You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
You can download a complete working sample from GitHub.
5195
+
You can download a complete working sample from [GitHub](https://github.com/SyncfusionExamples/PDF-Examples/tree/260329/Annotation/Setting-Annotation-Intent/.NET).
5196
5196
5197
5197
## Adding comments and review status to the PDF annotation
Copy file name to clipboardExpand all lines: Document-Processing/PDF/PDF-Library/NET/Working-with-Images.md
+154Lines changed: 154 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -723,6 +723,160 @@ doc.Close(True)
723
723
724
724
You can download a complete working sample from [GitHub](https://github.com/SyncfusionExamples/PDF-Examples/tree/master/Images/Add-transparancy-and-rotation-to-the-image/).
725
725
726
+
## Unit conversion in image position
727
+
728
+
The [PdfUnitConverter](https://help.syncfusion.com/cr/document-processing/Syncfusion.Pdf.Graphics.PdfUnitConvertor.html) class provides precise measurement conversion capabilities for PDF layouts. When positioning images in a PDF document, the converter translates pixel dimensions to PDF points, enabling millimeter-perfect placement and sizing. This ensures images maintain their aspect ratio while rendering at exact locations and filling designated spaces like rectangles.
729
+
730
+
The code snippet to illustrate the same is given below.
731
+
732
+
{% tabs %}
733
+
734
+
{% highlight c# tabtitle="C# [Cross-platform]" %}
735
+
736
+
using Syncfusion.Drawing;
737
+
using Syncfusion.Pdf;
738
+
using Syncfusion.Pdf.Graphics;
739
+
740
+
//Create a new PDF document
741
+
using (PdfDocument document = new PdfDocument())
742
+
{
743
+
using (FileStream stream = new FileStream("Image.png", FileMode.Open, FileAccess.Read))
744
+
{
745
+
//Load the image from the disk
746
+
PdfBitmap image = new PdfBitmap(stream);
747
+
748
+
//Add the first section to the PDF document
749
+
PdfSection section = document.Sections.Add();
750
+
751
+
//Initialize unit converter
752
+
PdfUnitConverter converter = new PdfUnitConverter();
You can download a complete working sample from GitHub.
879
+
726
880
## Converting multi page TIFF to PDF
727
881
728
882
Multi frame TIFF image can be converted to PDF document. This can be done by accessing each frame of the multi frame TIFF image and rendering it in each page of the PDF document using [PdfBitmap](https://help.syncfusion.com/cr/document-processing/Syncfusion.Pdf.Graphics.PdfBitmap.html) class.
0 commit comments