├── .gitignore ├── .nuspec └── PdfSharp.Xamarin.Forms.nuspec ├── PdfSharp.Xamarin.Forms.Droid ├── AndroidImageSource.cs ├── AndroidImageSourceImpl.cs ├── Orientation.cs ├── PdfSharp.Xamarin.Forms.Droid.csproj ├── Platform.cs ├── Properties │ └── AssemblyInfo.cs └── Resources │ ├── AboutResources.txt │ ├── Resource.Designer.cs │ └── values │ └── Strings.xml ├── PdfSharp.Xamarin.Forms.UWP ├── PdfSharp.Xamarin.Forms.UWP.csproj ├── Platform.cs ├── Properties │ ├── AssemblyInfo.cs │ └── PdfSharp.Xamarin.Forms.UWP.rd.xml ├── UWPImagesource.cs └── UwpImageSourceImpl.cs ├── PdfSharp.Xamarin.Forms.iOS ├── IOSImageSourceImpl.cs ├── IOSImagesource.cs ├── Orientation.cs ├── PdfSharp.Xamarin.Forms.iOS.csproj ├── Platform.cs ├── Properties │ └── AssemblyInfo.cs └── packages.config ├── PdfSharp.Xamarin.Forms.sln ├── PdfSharp.Xamarin.Forms ├── Attributes │ └── PdfRendererAttribute.cs ├── Contracts │ ├── ICustomFontProvider.cs │ └── IPdfHandler.cs ├── DefaultFonts │ ├── OpenSans-Bold.ttf │ ├── OpenSans-BoldItalic.ttf │ ├── OpenSans-Italic.ttf │ └── OpenSans-Regular.ttf ├── Delegates │ └── PDFListViewRendererDelegate.cs ├── Extensions │ ├── ColorExtension.cs │ ├── LayoutOptionsExtension.cs │ ├── PointExtension.cs │ └── RectangleExtensions.cs ├── Icons │ └── search.png ├── PDFGenerator.cs ├── PdfManager.cs ├── PdfRendererAttributes.cs ├── PdfSharp.Xamarin.Forms.csproj ├── Renderers │ ├── PDFLabelRender.cs │ ├── PDFListViewRenderer.cs │ ├── PdfBoxViewRenderer.cs │ ├── PdfButtonRenderer.cs │ ├── PdfContentViewRenderer.cs │ ├── PdfDatePickerRenderer.cs │ ├── PdfEditorRenderer.cs │ ├── PdfEntryRenderer.cs │ ├── PdfImageRenderer.cs │ ├── PdfPickerRenderer.cs │ ├── PdfProgressBarRenderer.cs │ ├── PdfRendererBase.cs │ └── PdfSearchBarRenderer.cs └── Utils │ ├── FontProvider.cs │ └── SizeUtils.cs ├── PdfSharp.Xamarin.Sample ├── PdfSharp.Xamarin.Sample.Android │ ├── Assets │ │ └── AboutAssets.txt │ ├── MainActivity.cs │ ├── PdfSave.cs │ ├── PdfSharp.Xamarin.Sample.Android.csproj │ ├── Properties │ │ ├── AndroidManifest.xml │ │ └── AssemblyInfo.cs │ ├── Resources │ │ ├── AboutResources.txt │ │ ├── Resource.Designer.cs │ │ ├── drawable-hdpi │ │ │ └── icon.png │ │ ├── drawable-xhdpi │ │ │ └── icon.png │ │ ├── drawable-xxhdpi │ │ │ └── icon.png │ │ ├── drawable │ │ │ ├── icon.png │ │ │ └── test.jpg │ │ ├── layout │ │ │ ├── Tabbar.axml │ │ │ └── Toolbar.axml │ │ └── values │ │ │ └── styles.xml │ └── packages.config ├── PdfSharp.Xamarin.Sample.UWP │ ├── App.xaml │ ├── App.xaml.cs │ ├── Assets │ │ ├── LockScreenLogo.scale-100.png │ │ ├── LockScreenLogo.scale-125.png │ │ ├── LockScreenLogo.scale-150.png │ │ ├── LockScreenLogo.scale-200.png │ │ ├── LockScreenLogo.scale-400.png │ │ ├── SplashScreen.scale-100.png │ │ ├── SplashScreen.scale-125.png │ │ ├── SplashScreen.scale-150.png │ │ ├── SplashScreen.scale-200.png │ │ ├── SplashScreen.scale-400.png │ │ ├── Square150x150Logo.scale-100.png │ │ ├── Square150x150Logo.scale-125.png │ │ ├── Square150x150Logo.scale-150.png │ │ ├── Square150x150Logo.scale-200.png │ │ ├── Square150x150Logo.scale-400.png │ │ ├── Square44x44Logo.scale-100.png │ │ ├── Square44x44Logo.scale-125.png │ │ ├── Square44x44Logo.scale-150.png │ │ ├── Square44x44Logo.scale-200.png │ │ ├── Square44x44Logo.scale-400.png │ │ ├── Square44x44Logo.targetsize-16_altform-unplated.png │ │ ├── Square44x44Logo.targetsize-24_altform-unplated.png │ │ ├── Square44x44Logo.targetsize-256_altform-unplated.png │ │ ├── Square44x44Logo.targetsize-32_altform-unplated.png │ │ ├── Square44x44Logo.targetsize-48_altform-unplated.png │ │ ├── StoreLogo.png │ │ ├── Wide310x150Logo.scale-100.png │ │ ├── Wide310x150Logo.scale-125.png │ │ ├── Wide310x150Logo.scale-150.png │ │ ├── Wide310x150Logo.scale-200.png │ │ └── Wide310x150Logo.scale-400.png │ ├── MainPage.xaml │ ├── MainPage.xaml.cs │ ├── Package.appxmanifest │ ├── PdfSave.cs │ ├── PdfSharp.Xamarin.Sample.UWP.csproj │ ├── PdfSharp.Xamarin.Sample.UWP.nuget.props │ ├── PdfSharp.Xamarin.Sample.UWP.nuget.targets │ ├── PdfSharp.Xamarin.Sample.UWP_TemporaryKey.pfx │ ├── Properties │ │ ├── AssemblyInfo.cs │ │ └── Default.rd.xml │ ├── project.json │ ├── project.lock.json │ └── test.jpg ├── PdfSharp.Xamarin.Sample.iOS │ ├── AppDelegate.cs │ ├── Entitlements.plist │ ├── Info.plist │ ├── Main.cs │ ├── PdfSave.cs │ ├── PdfSharp.Xamarin.Sample.iOS.csproj │ ├── Properties │ │ └── AssemblyInfo.cs │ ├── Resources │ │ ├── Default-568h@2x.png │ │ ├── Default-Portrait.png │ │ ├── Default-Portrait@2x.png │ │ ├── Default.png │ │ ├── Default@2x.png │ │ ├── Icon-60@2x.png │ │ ├── Icon-60@3x.png │ │ ├── Icon-76.png │ │ ├── Icon-76@2x.png │ │ ├── Icon-Small-40.png │ │ ├── Icon-Small-40@2x.png │ │ ├── Icon-Small-40@3x.png │ │ ├── Icon-Small.png │ │ ├── Icon-Small@2x.png │ │ ├── Icon-Small@3x.png │ │ ├── LaunchScreen.storyboard │ │ └── test.jpg │ ├── iTunesArtwork │ ├── iTunesArtwork@2x │ └── packages.config └── PdfSharp.Xamarin.Sample │ ├── App.xaml │ ├── App.xaml.cs │ ├── IPdfSave.cs │ ├── MainPage.xaml │ ├── MainPage.xaml.cs │ └── PdfSharp.Xamarin.Sample.csproj ├── PdfSharpCore.Charting ├── PdfSharp.Charting.Renderers │ ├── AreaChartRenderer.cs │ ├── AreaPlotAreaRenderer.cs │ ├── AxisRenderer.cs │ ├── AxisTitleRenderer.cs │ ├── BarChartRenderer.cs │ ├── BarClusteredLegendRenderer.cs │ ├── BarClusteredPlotAreaRenderer.cs │ ├── BarDataLabelRenderer.cs │ ├── BarGridlinesRenderer.cs │ ├── BarPlotAreaRenderer.cs │ ├── BarStackedPlotAreaRenderer.cs │ ├── ChartRenderer.cs │ ├── Colors.cs │ ├── ColumnChartRenderer.cs │ ├── ColumnClusteredPlotAreaRenderer.cs │ ├── ColumnDataLabelRenderer.cs │ ├── ColumnLikeChartRenderer.cs │ ├── ColumnLikeGridlinesRenderer.cs │ ├── ColumnLikeLegendRenderer.cs │ ├── ColumnLikePlotAreaRenderer.cs │ ├── ColumnPlotAreaRenderer.cs │ ├── ColumnStackedPlotAreaRenderer.cs │ ├── CombinationChartRenderer.cs │ ├── Converter.cs │ ├── DataLabelRenderer.cs │ ├── GridlinesRenderer.cs │ ├── HorizontalStackedYAxisRenderer.cs │ ├── HorizontalXAxisRenderer.cs │ ├── HorizontalYAxisRenderer.cs │ ├── LegendEntryRenderer.cs │ ├── LegendRenderer.cs │ ├── LineChartRenderer.cs │ ├── LineFormatRenderer.cs │ ├── LinePlotAreaRenderer.cs │ ├── MarkerRenderer.cs │ ├── PieChartRenderer.cs │ ├── PieClosedPlotAreaRenderer.cs │ ├── PieDataLabelRenderer.cs │ ├── PieExplodedPlotAreaRenderer.cs │ ├── PieLegendRenderer.cs │ ├── PiePlotAreaRenderer.cs │ ├── PlotAreaBorderRenderer.cs │ ├── PlotAreaRenderer.cs │ ├── Renderer.cs │ ├── RendererInfo.cs │ ├── RendererParameters.cs │ ├── VerticalStackedYAxisRenderer.cs │ ├── VerticalXAxisRenderer.cs │ ├── VerticalYAxisRenderer.cs │ ├── WallRenderer.cs │ ├── XAxisRenderer.cs │ └── YAxisRenderer.cs ├── PdfSharp.Charting │ ├── Axis.cs │ ├── AxisTitle.cs │ ├── Chart.cs │ ├── ChartFrame.cs │ ├── ChartObject.cs │ ├── DataLabel.cs │ ├── DocumentObject.cs │ ├── DocumentObjectCollection.cs │ ├── FillFormat.cs │ ├── Font.cs │ ├── Gridlines.cs │ ├── Legend.cs │ ├── LineFormat.cs │ ├── PSCSR.cs │ ├── PlotArea.cs │ ├── Point.cs │ ├── Series.cs │ ├── SeriesCollection.cs │ ├── SeriesElements.cs │ ├── TickLabels.cs │ ├── XSeries.cs │ ├── XSeriesElements.cs │ ├── XValue.cs │ ├── XValues.cs │ └── enums │ │ ├── BlankType.cs │ │ ├── ChartType.cs │ │ ├── DataLabelPosition.cs │ │ ├── DataLabelType.cs │ │ ├── DockingType.cs │ │ ├── FontProperties.cs │ │ ├── HorizontalAlignment.cs │ │ ├── LineStyle.cs │ │ ├── MarkerStyle.cs │ │ ├── TickMarkType.cs │ │ ├── Underline.cs │ │ └── VerticalAlignment.cs ├── PdfSharpCore.Charting.csproj ├── PdfSharpCore.Charting.vs2015.csproj ├── PdfSharpCore.Charting.vs2015.nuget.props ├── packages.config ├── project.json └── project.lock.json ├── PdfSharpCore ├── !internal │ ├── Configuration.cs │ └── VS2015.cs ├── Drawing.BarCodes │ ├── BarCode.cs │ ├── BarCodeRenderInfo.cs │ ├── BcgSR.cs │ ├── Code2of5Interleaved.cs │ ├── Code3of9Standard.cs │ ├── CodeBase.cs │ ├── CodeDataMatrix.cs │ ├── CodeOmr.cs │ ├── DataMatrixImage.opensource.cs │ ├── MatrixCode.cs │ ├── OmrData.cs │ ├── ThickThinBarcodeRenderer.cs │ └── enums │ │ ├── AnchorType.cs │ │ ├── CodeDirection.cs │ │ ├── CodeType.cs │ │ ├── DataMatrixEncoding.cs │ │ ├── MarkDistance.cs │ │ └── TextLocation.cs ├── Drawing.Internal │ ├── IImageImporter.cs │ ├── ImageImporter.cs │ ├── ImageImporterBmp.cs │ ├── ImageImporterJpeg.cs │ └── ImageImporterRoot.cs ├── Drawing.Layout │ ├── XTextFormatter.cs │ └── enums │ │ └── XParagraphAlignment.cs ├── Drawing.Pdf │ ├── PdfGraphicsState.cs │ ├── XGraphicsPdfRenderer.cs │ └── enums │ │ ├── DirtyFlags.cs │ │ └── StreamMode.cs ├── Drawing │ ├── CoreGraphicsPath.cs │ ├── FontFamilyCache.cs │ ├── FontFamilyInternal.cs │ ├── FontHelper.cs │ ├── GeometryHelper.cs │ ├── GraphicsStateStack.cs │ ├── IXGraphicsRenderer.cs │ ├── ImageHelper.cs │ ├── ImageSource.cs │ ├── InternalGraphicsState.cs │ ├── PdfFontOptions.cs │ ├── XBitmapDecoder.cs │ ├── XBitmapEncoder.cs │ ├── XBitmapImage.cs │ ├── XBitmapSource.cs │ ├── XBrush.cs │ ├── XBrushes.cs │ ├── XColor.cs │ ├── XColorResourceManager.cs │ ├── XColors.cs │ ├── XConvert.cs │ ├── XFont.cs │ ├── XFontFamily.cs │ ├── XFontMetrics.cs │ ├── XFontSource.cs │ ├── XFontStretch.cs │ ├── XFontWeight.cs │ ├── XFontWeights.cs │ ├── XForm.cs │ ├── XGlyphTypeface.cs │ ├── XGraphics.cs │ ├── XGraphicsContainer.cs │ ├── XGraphicsPath.cs │ ├── XGraphicsPathInternals.cs │ ├── XGraphicsPathItem.cs │ ├── XGraphicsState.cs │ ├── XImage.cs │ ├── XImageFormat.cs │ ├── XKnownColorTable.cs │ ├── XLinearGradientBrush.cs │ ├── XMatrix.cs │ ├── XPdfForm.cs │ ├── XPen.cs │ ├── XPens.cs │ ├── XPoint.cs │ ├── XPrivateFontCollection.cs │ ├── XRect.cs │ ├── XSize.cs │ ├── XSolidBrush.cs │ ├── XStringFormat.cs │ ├── XStringFormats.cs │ ├── XTypeface.cs │ ├── XUnit.cs │ ├── XVector.cs │ └── enums │ │ ├── PathStart.cs │ │ ├── XColorSpace.cs │ │ ├── XCombineMode.cs │ │ ├── XDashStyle.cs │ │ ├── XFillMode.cs │ │ ├── XFontStyle.cs │ │ ├── XGdiFontStyle.cs │ │ ├── XGraphicRenderTarget.cs │ │ ├── XGraphicsPathItemType.cs │ │ ├── XGraphicsPdfPageOptions.cs │ │ ├── XGraphicsUnit.cs │ │ ├── XKnownColor.cs │ │ ├── XLineAlignment.cs │ │ ├── XLineCap.cs │ │ ├── XLineJoin.cs │ │ ├── XLinearGradientMode.cs │ │ ├── XMatrixOrder.cs │ │ ├── XPageDirection.cs │ │ ├── XSmoothingMode.cs │ │ ├── XStringAlignment.cs │ │ ├── XStyleSimulations.cs │ │ └── XSweepDirection.cs ├── Fonts.OpenType │ ├── FontDescriptor.cs │ ├── GenericFontTable.cs │ ├── GlyphDataTable.cs │ ├── GlyphTypefaceCache.cs │ ├── IRefFontTable.cs │ ├── IndexToLocationTable.cs │ ├── OpenTypeDescriptor.cs │ ├── OpenTypeFontTable.cs │ ├── OpenTypeFontTables.cs │ ├── OpenTypeFontWriter.cs │ ├── OpenTypeFontface.cs │ ├── OpenTypeFontfaceCache.cs │ ├── TableDirectoryEntry.cs │ └── enums │ │ ├── FontTechnology.cs │ │ └── TableTagNames.cs ├── Fonts │ ├── AdobeGlyphList20.cs │ ├── CMapInfo.cs │ ├── FontDescriptorCache.cs │ ├── FontFactory.cs │ ├── FontResolverInfo.cs │ ├── FontResolvingOptions.cs │ ├── FontWriter.cs │ ├── GlobalFontSettings.cs │ ├── IFontResolver.cs │ ├── PlatformFontResolver.cs │ └── PlatformFontResolverInfo.cs ├── Internal │ ├── Calc.cs │ ├── ColorHelper.cs │ ├── Diagnostics.cs │ ├── DiagnosticsHelper.cs │ ├── DoubleUtil.cs │ ├── Lock.cs │ ├── NativeMethods.cs │ └── TokenizerHelper.cs ├── Pdf.AcroForms │ ├── PdfAcroField.cs │ ├── PdfAcroForm.cs │ ├── PdfButtonField.cs │ ├── PdfCheckBoxField.cs │ ├── PdfChoiceField.cs │ ├── PdfComboBoxField.cs │ ├── PdfGenericField.cs │ ├── PdfListBoxField.cs │ ├── PdfPushButtonField.cs │ ├── PdfRadioButtonField.cs │ ├── PdfSignatureField.cs │ ├── PdfTextField.cs │ └── enums │ │ └── PdfAcroFieldFlags.cs ├── Pdf.Actions │ ├── PdfAction.cs │ ├── PdfGoToAction.cs │ └── enums │ │ └── PdfNamedActionNames.cs ├── Pdf.Advanced │ ├── IContentStream.cs │ ├── PdfCIDFont.cs │ ├── PdfCatalog.cs │ ├── PdfContent.cs │ ├── PdfContents.cs │ ├── PdfCrossReferenceStream.cs │ ├── PdfCrossReferenceTable.cs │ ├── PdfDictionaryWithContentStream.cs │ ├── PdfExtGState.cs │ ├── PdfExtGStateTable.cs │ ├── PdfFont.cs │ ├── PdfFontDescriptor.cs │ ├── PdfFontTable.cs │ ├── PdfFormXObject.cs │ ├── PdfFormXObjectTable.cs │ ├── PdfGroupAttributes.cs │ ├── PdfImage.FaxEncode.cs │ ├── PdfImage.cs │ ├── PdfImageTable.cs │ ├── PdfImportedObjectTable.cs │ ├── PdfInternals.cs │ ├── PdfObjectInternals.cs │ ├── PdfObjectStream.cs │ ├── PdfPageInheritableObjects.cs │ ├── PdfPageInterals.cs │ ├── PdfReference.cs │ ├── PdfResourceMap.cs │ ├── PdfResourceTable.cs │ ├── PdfResources.cs │ ├── PdfShading.cs │ ├── PdfShadingPattern.cs │ ├── PdfSoftMask.cs │ ├── PdfTilingPattern.cs │ ├── PdfToUnicodeMap.cs │ ├── PdfTrailer.cs │ ├── PdfTransparencyGroupAttributes.cs │ ├── PdfTrueTypeFont.cs │ ├── PdfType0Font.cs │ ├── PdfType1Font.cs │ └── PdfXObject.cs ├── Pdf.Annotations │ ├── PdfAnnotation.cs │ ├── PdfAnnotations.cs │ ├── PdfGenericAnnotation.cs │ ├── PdfLinkAnnotation.cs │ ├── PdfRubberStampAnnotation.cs │ ├── PdfTextAnnotation.cs │ ├── PdfWidgetAnnotation.cs │ └── enums │ │ ├── PdfAnnotationFlags.cs │ │ ├── PdfRubberStampAnnotationIcon.cs │ │ └── PdfTextAnnotationIcon.cs ├── Pdf.Content.Objects │ ├── CObjects.cs │ ├── Operators.cs │ └── enum │ │ ├── OpCodeFlags.cs │ │ └── OpCodeName.cs ├── Pdf.Content │ ├── CLexer.cs │ ├── CParser.cs │ ├── Chars.cs │ ├── ContentReader.cs │ ├── ContentReaderException.cs │ ├── ContentWriter.cs │ └── enums │ │ └── Symbol.cs ├── Pdf.Filters │ ├── Ascii85Decode.cs │ ├── AsciiHexDecode.cs │ ├── Filter.cs │ ├── Filtering.cs │ ├── FlateDecode.cs │ └── LzwDecode.cs ├── Pdf.IO │ ├── Chars.cs │ ├── Lexer.cs │ ├── Parser.cs │ ├── PdfReader.cs │ ├── PdfReaderException.cs │ ├── PdfWriter.cs │ ├── ShiftStack.cs │ └── enums │ │ ├── PasswordValidity.cs │ │ ├── PdfDocumentOpenMode.cs │ │ ├── PdfWriterLayout.cs │ │ ├── PdfWriterOptions.cs │ │ └── Symbol.cs ├── Pdf.Internal │ ├── AnsiEncoding.cs │ ├── ColorSpaceHelper.cs │ ├── DocEncoding.cs │ ├── GlobalObjectTable.cs │ ├── PdfDiagnostics.cs │ ├── PdfEncoders.cs │ ├── RawEncoding.cs │ ├── RawUnicodeEncoding.cs │ └── ThreadLocalStorage.cs ├── Pdf.Printing │ └── PdfFilePrinter.cs ├── Pdf.Security │ ├── MD5Managed.cs │ ├── PdfSecurityHandler.cs │ ├── PdfSecuritySettings.cs │ ├── PdfStandardSecurityHandler.cs │ └── enums │ │ ├── PdfDocumentSecurity.cs │ │ └── PdfUserAccessPermission.cs ├── Pdf │ ├── EntryInfoAttribute.cs │ ├── KeysBase.cs │ ├── KeysMeta.cs │ ├── PdfArray.cs │ ├── PdfBoolean.cs │ ├── PdfBooleanObject.cs │ ├── PdfCustomValue.cs │ ├── PdfCustomValues.cs │ ├── PdfDate.cs │ ├── PdfDictionary.cs │ ├── PdfDocument.cs │ ├── PdfDocumentInformation.cs │ ├── PdfDocumentOptions.cs │ ├── PdfDocumentSettings.cs │ ├── PdfInteger.cs │ ├── PdfIntegerObject.cs │ ├── PdfItem.cs │ ├── PdfLiteral.cs │ ├── PdfName.cs │ ├── PdfNameObject.cs │ ├── PdfNull.cs │ ├── PdfNullObject.cs │ ├── PdfNumber.cs │ ├── PdfNumberObject.cs │ ├── PdfObject.cs │ ├── PdfObjectID.cs │ ├── PdfOutline.cs │ ├── PdfOutlineCollection.cs │ ├── PdfPage.cs │ ├── PdfPages.cs │ ├── PdfReal.cs │ ├── PdfRealObject.cs │ ├── PdfRectangle.cs │ ├── PdfReferenceTable.cs │ ├── PdfString.cs │ ├── PdfStringObject.cs │ ├── PdfUInteger.cs │ ├── PdfUIntegerObject.cs │ ├── PdfViewerPreferences.cs │ ├── TrimMargins.cs │ └── enums │ │ ├── DocumentState.cs │ │ ├── PdfColorMode.cs │ │ ├── PdfCustomValueCompression.cs │ │ ├── PdfFlateEncodeMode.cs │ │ ├── PdfFontEncoding.cs │ │ ├── PdfOutlineStyle.cs │ │ ├── PdfPageDestinationType.cs │ │ ├── PdfPageLayout.cs │ │ ├── PdfPageMode.cs │ │ ├── PdfReadingDirection.cs │ │ ├── PdfTextStringEncoding.cs │ │ └── PdfUseFlateDecoderForJpegImages.cs ├── PdfSharpCore.csproj ├── PdfSharpCore.vs2015.csproj ├── PdfSharpCore.vs2015.nuget.props ├── SharpZipLib │ ├── Checksums │ │ ├── Adler32.cs │ │ ├── CRC32.cs │ │ └── IChecksum.cs │ ├── ReadMe.txt │ ├── SharpZipBaseException.cs │ └── Zip │ │ ├── Compression │ │ ├── Deflater.cs │ │ ├── DeflaterConstants.cs │ │ ├── DeflaterEngine.cs │ │ ├── DeflaterHuffman.cs │ │ ├── DeflaterPending.cs │ │ ├── Inflater.cs │ │ ├── InflaterDynHeader.cs │ │ ├── InflaterHuffmanTree.cs │ │ ├── PendingBuffer.cs │ │ └── Streams │ │ │ ├── DeflaterOutputStream.cs │ │ │ ├── InflaterInputStream.cs │ │ │ ├── OutputWindow.cs │ │ │ └── StreamManipulator.cs │ │ ├── ZipConstants.cs │ │ └── ZipException.cs ├── SilverlightInternals │ └── AgHacks.cs ├── packages.config ├── project.json ├── project.lock.json └── root │ ├── PSSR.cs │ ├── PageSizeConverter.cs │ ├── PdfSharpException.cs │ ├── ProductVersionInfo.cs │ ├── VersionInfo.cs │ └── enums │ ├── PSMsgID.cs │ ├── PageOrientation.cs │ └── PageSize.cs ├── README.md └── Screenshots ├── app.PNG ├── pdf.PNG └── table.PNG /.gitignore: -------------------------------------------------------------------------------- 1 | .vs/ 2 | packages/ 3 | Debug/ 4 | ipch/ 5 | obj/ 6 | bin/ 7 | Output/ 8 | *.sdf 9 | UpgradeLog.htm 10 | buildlog.log 11 | *.opendb 12 | *.user -------------------------------------------------------------------------------- /PdfSharp.Xamarin.Forms.Droid/AndroidImageSource.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.IO; 3 | using System.Linq; 4 | using Android.Graphics.Drawables; 5 | using MigraDocCore.DocumentObjectModel.MigraDoc.DocumentObjectModel.Shapes; 6 | using static Android.Graphics.Bitmap; 7 | namespace PdfSharp.Xamarin.Forms.Droid 8 | { 9 | public class AndroidImageSource : ImageSource 10 | { 11 | protected override IImageSource FromBinaryImpl(string name, Func imageSource, int? quality = 75) 12 | { 13 | return new AndroidImageSourceImpl(name, () => { return new MemoryStream(imageSource.Invoke()); }, (int)quality); 14 | } 15 | 16 | protected override IImageSource FromFileImpl(string path, int? quality = 75) 17 | { 18 | if (path.Contains(".")) 19 | { 20 | string[] tokens = path.Split('.'); 21 | tokens = tokens.Take(tokens.Length - 1).ToArray(); 22 | path = String.Join(".", tokens); 23 | } 24 | 25 | var res = global::Xamarin.Forms.Forms.Context.Resources; 26 | var resId = res.GetIdentifier(path, "drawable", res.GetResourcePackageName(Android.Resource.Id.Home)); 27 | Stream stream = new MemoryStream(); 28 | BitmapDrawable drawable = null; 29 | if (resId > 0) 30 | { 31 | drawable = res.GetDrawable(resId) as BitmapDrawable; 32 | if (drawable != null) 33 | { 34 | drawable.Bitmap.Compress(CompressFormat.Jpeg, quality ?? 75, stream); 35 | } 36 | } 37 | 38 | return new AndroidImageSourceImpl(path, () => stream, quality ?? 75) { Bitmap = drawable?.Bitmap }; 39 | } 40 | 41 | protected override IImageSource FromStreamImpl(string name, Func imageStream, int? quality = 75) 42 | { 43 | return new AndroidImageSourceImpl(name, imageStream, (int)quality); 44 | } 45 | } 46 | } -------------------------------------------------------------------------------- /PdfSharp.Xamarin.Forms.Droid/Orientation.cs: -------------------------------------------------------------------------------- 1 | namespace PdfSharp.Xamarin.Forms.Droid 2 | { 3 | internal enum Orientation 4 | { 5 | Normal = 1, 6 | Rotate90 = 6, 7 | Rotate180 = 3, 8 | Rotate270 = 8 9 | } 10 | } -------------------------------------------------------------------------------- /PdfSharp.Xamarin.Forms.Droid/Platform.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using System.Reflection; 3 | using PdfSharp.Xamarin.Forms.Contracts; 4 | 5 | namespace PdfSharp.Xamarin.Forms.Droid 6 | { 7 | public class Platform 8 | { 9 | public static void Init(ICustomFontProvider customFontProvider = null, IList rendererAssemblies = null) 10 | { 11 | PDFManager.Init(new AndroidImageSource(), customFontProvider, rendererAssemblies); 12 | } 13 | } 14 | } -------------------------------------------------------------------------------- /PdfSharp.Xamarin.Forms.Droid/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | using Android.App; 5 | 6 | // General Information about an assembly is controlled through the following 7 | // set of attributes. Change these attribute values to modify the information 8 | // associated with an assembly. 9 | [assembly: AssemblyTitle("PdfSharp.Xamarin.Forms.Droid")] 10 | [assembly: AssemblyDescription("")] 11 | [assembly: AssemblyConfiguration("")] 12 | [assembly: AssemblyCompany("")] 13 | [assembly: AssemblyProduct("PdfSharp.Xamarin.Forms.Droid")] 14 | [assembly: AssemblyCopyright("Copyright © 2018")] 15 | [assembly: AssemblyTrademark("")] 16 | [assembly: AssemblyCulture("")] 17 | [assembly: ComVisible(false)] 18 | 19 | // Version information for an assembly consists of the following four values: 20 | // 21 | // Major Version 22 | // Minor Version 23 | // Build Number 24 | // Revision 25 | // 26 | // You can specify all the values or you can default the Build and Revision Numbers 27 | // by using the '*' as shown below: 28 | // [assembly: AssemblyVersion("1.0.*")] 29 | [assembly: AssemblyVersion("1.0.0.0")] 30 | [assembly: AssemblyFileVersion("1.0.0.0")] 31 | -------------------------------------------------------------------------------- /PdfSharp.Xamarin.Forms.Droid/Resources/AboutResources.txt: -------------------------------------------------------------------------------- 1 | Images, layout descriptions, binary blobs and string dictionaries can be included 2 | in your application as resource files. Various Android APIs are designed to 3 | operate on the resource IDs instead of dealing with images, strings or binary blobs 4 | directly. 5 | 6 | For example, a sample Android app that contains a user interface layout (main.axml), 7 | an internationalization string table (strings.xml) and some icons (drawable-XXX/icon.png) 8 | would keep its resources in the "Resources" directory of the application: 9 | 10 | Resources/ 11 | drawable/ 12 | icon.png 13 | 14 | layout/ 15 | main.axml 16 | 17 | values/ 18 | strings.xml 19 | 20 | In order to get the build system to recognize Android resources, set the build action to 21 | "AndroidResource". The native Android APIs do not operate directly with filenames, but 22 | instead operate on resource IDs. When you compile an Android application that uses resources, 23 | the build system will package the resources for distribution and generate a class called "R" 24 | (this is an Android convention) that contains the tokens for each one of the resources 25 | included. For example, for the above Resources layout, this is what the R class would expose: 26 | 27 | public class R { 28 | public class drawable { 29 | public const int icon = 0x123; 30 | } 31 | 32 | public class layout { 33 | public const int main = 0x456; 34 | } 35 | 36 | public class strings { 37 | public const int first_string = 0xabc; 38 | public const int second_string = 0xbcd; 39 | } 40 | } 41 | 42 | You would then use R.drawable.icon to reference the drawable/icon.png file, or R.layout.main 43 | to reference the layout/main.axml file, or R.strings.first_string to reference the first 44 | string in the dictionary file values/strings.xml. -------------------------------------------------------------------------------- /PdfSharp.Xamarin.Forms.Droid/Resources/values/Strings.xml: -------------------------------------------------------------------------------- 1 | 2 | Hello World, Click Me! 3 | PdfSharp.Xamarin.Forms.Droid 4 | 5 | -------------------------------------------------------------------------------- /PdfSharp.Xamarin.Forms.UWP/Platform.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using System.Reflection; 3 | using PdfSharp.Xamarin.Forms.Contracts; 4 | 5 | namespace PdfSharp.Xamarin.Forms.UWP 6 | { 7 | public class Platform 8 | { 9 | public static void Init(ICustomFontProvider customFontProvider = null, IList rendererAssemblies = null) 10 | { 11 | PDFManager.Init(new UwpImageSource(), customFontProvider, rendererAssemblies); 12 | } 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /PdfSharp.Xamarin.Forms.UWP/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | [assembly: AssemblyTitle("PdfSharp.Xamarin.Forms.UWP")] 9 | [assembly: AssemblyDescription("")] 10 | [assembly: AssemblyConfiguration("")] 11 | [assembly: AssemblyCompany("")] 12 | [assembly: AssemblyProduct("PdfSharp.Xamarin.Forms.UWP")] 13 | [assembly: AssemblyCopyright("Copyright © 2018")] 14 | [assembly: AssemblyTrademark("")] 15 | [assembly: AssemblyCulture("")] 16 | 17 | // Version information for an assembly consists of the following four values: 18 | // 19 | // Major Version 20 | // Minor Version 21 | // Build Number 22 | // Revision 23 | // 24 | // You can specify all the values or you can default the Build and Revision Numbers 25 | // by using the '*' as shown below: 26 | // [assembly: AssemblyVersion("1.0.*")] 27 | [assembly: AssemblyVersion("1.0.0.0")] 28 | [assembly: AssemblyFileVersion("1.0.0.0")] 29 | [assembly: ComVisible(false)] -------------------------------------------------------------------------------- /PdfSharp.Xamarin.Forms.UWP/Properties/PdfSharp.Xamarin.Forms.UWP.rd.xml: -------------------------------------------------------------------------------- 1 | 2 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | -------------------------------------------------------------------------------- /PdfSharp.Xamarin.Forms.UWP/UWPImagesource.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.IO; 3 | using MigraDocCore.DocumentObjectModel.MigraDoc.DocumentObjectModel.Shapes; 4 | 5 | namespace PdfSharp.Xamarin.Forms.UWP 6 | { 7 | public class UwpImageSource : ImageSource 8 | { 9 | protected override IImageSource FromBinaryImpl(string name, Func imageSource, int? quality = 75) 10 | { 11 | return new UwpImageSourceImpl(name, 12 | () => { 13 | return new MemoryStream(imageSource.Invoke()).AsRandomAccessStream(); 14 | }, (int)quality); 15 | } 16 | 17 | protected override IImageSource FromFileImpl(string path, int? quality = 75) 18 | { 19 | return new UwpImageSourceImpl(Path.GetFileName(path), 20 | () => { 21 | var stream = new FileStream(path, FileMode.Open, FileAccess.Read, FileShare.Read); 22 | return stream.AsRandomAccessStream(); 23 | }, (int)quality); 24 | } 25 | 26 | protected override IImageSource FromStreamImpl(string name, Func imageStream, int? quality = 75) 27 | { 28 | return new UwpImageSourceImpl(name, 29 | () => { 30 | return imageStream.Invoke().AsRandomAccessStream(); 31 | }, (int)quality); 32 | } 33 | 34 | } 35 | } 36 | -------------------------------------------------------------------------------- /PdfSharp.Xamarin.Forms.iOS/IOSImageSourceImpl.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.IO; 3 | using System.Threading; 4 | using Foundation; 5 | using static MigraDocCore.DocumentObjectModel.MigraDoc.DocumentObjectModel.Shapes.ImageSource; 6 | 7 | namespace PdfSharp.Xamarin.Forms.iOS 8 | { 9 | 10 | internal class IosImageSourceImpl : IImageSource 11 | { 12 | internal UIKit.UIImage image; 13 | 14 | private Orientation Orientation { get; } 15 | 16 | private readonly Func _streamSource; 17 | private readonly int _quality; 18 | 19 | public int Width { get; } 20 | public int Height { get; } 21 | public string Name { get; } 22 | 23 | 24 | public IosImageSourceImpl(string name, Func streamSource, int quality) 25 | { 26 | Name = name; 27 | _streamSource = streamSource; 28 | _quality = quality; 29 | using (var stream = streamSource.Invoke()) 30 | { 31 | image = UIKit.UIImage.LoadFromData(NSData.FromStream(stream)); 32 | var size = image?.Size ?? new CoreGraphics.CGSize(0, 0); 33 | 34 | Width = (int)size.Width; 35 | Height = (int)size.Height; 36 | Orientation = Orientation.Normal; 37 | } 38 | } 39 | 40 | public void SaveAsJpeg(MemoryStream ms, CancellationToken ct) 41 | { 42 | var jpg = image.AsJPEG(); 43 | ms.Write(jpg.ToArray(), 0, (int)jpg.Length); 44 | ms.Seek(0, SeekOrigin.Begin); 45 | } 46 | } 47 | } -------------------------------------------------------------------------------- /PdfSharp.Xamarin.Forms.iOS/IOSImagesource.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.IO; 3 | using System.Threading; 4 | using Foundation; 5 | using MigraDocCore.DocumentObjectModel.MigraDoc.DocumentObjectModel.Shapes; 6 | 7 | namespace PdfSharp.Xamarin.Forms.iOS 8 | { 9 | public class IosImageSource : ImageSource 10 | { 11 | protected override IImageSource FromBinaryImpl(string name, Func imageSource, int? quality = 75) 12 | { 13 | return new IosImageSourceImpl(name, () => { return new MemoryStream(imageSource.Invoke()); }, (int)quality); 14 | } 15 | 16 | protected override IImageSource FromFileImpl(string path, int? quality = 75) 17 | { 18 | return new IosImageSourceImpl(path, () => { return File.OpenRead(path); }, (int)quality); 19 | } 20 | 21 | protected override IImageSource FromStreamImpl(string name, Func imageStream, int? quality = 75) 22 | { 23 | return new IosImageSourceImpl(name, imageStream, (int)quality); 24 | } 25 | 26 | private class IosImageSourceImpl : IImageSource 27 | { 28 | internal UIKit.UIImage image; 29 | 30 | private Orientation Orientation { get; } 31 | 32 | private readonly Func _streamSource; 33 | private readonly int _quality; 34 | 35 | public int Width { get; } 36 | public int Height { get; } 37 | public string Name { get; } 38 | 39 | 40 | public IosImageSourceImpl(string name, Func streamSource, int quality) 41 | { 42 | Name = name; 43 | _streamSource = streamSource; 44 | _quality = quality; 45 | using (var stream = streamSource.Invoke()) 46 | { 47 | image = UIKit.UIImage.LoadFromData(NSData.FromStream(stream)); 48 | var size = image?.Size ?? new CoreGraphics.CGSize(0, 0); 49 | 50 | Width = (int)size.Width; 51 | Height = (int)size.Height; 52 | Orientation = Orientation.Normal; 53 | } 54 | } 55 | 56 | public void SaveAsJpeg(MemoryStream ms, CancellationToken ct) 57 | { 58 | var jpg = image.AsJPEG(); 59 | ms.Write(jpg.ToArray(), 0, (int)jpg.Length); 60 | ms.Seek(0, SeekOrigin.Begin); 61 | } 62 | } 63 | } 64 | } -------------------------------------------------------------------------------- /PdfSharp.Xamarin.Forms.iOS/Orientation.cs: -------------------------------------------------------------------------------- 1 | namespace PdfSharp.Xamarin.Forms.iOS 2 | { 3 | internal enum Orientation 4 | { 5 | Normal = 1, 6 | Rotate90 = 6, 7 | Rotate180 = 3, 8 | Rotate270 = 8 9 | } 10 | } -------------------------------------------------------------------------------- /PdfSharp.Xamarin.Forms.iOS/Platform.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using System.Reflection; 3 | using PdfSharp.Xamarin.Forms.Contracts; 4 | 5 | namespace PdfSharp.Xamarin.Forms.iOS 6 | { 7 | public class Platform 8 | { 9 | public static void Init(ICustomFontProvider customFontProvider = null, IList rendererAssemblies = null) 10 | { 11 | PDFManager.Init(new IosImageSource(), customFontProvider); 12 | } 13 | } 14 | } -------------------------------------------------------------------------------- /PdfSharp.Xamarin.Forms.iOS/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | [assembly: AssemblyTitle("NewApp")] 9 | [assembly: AssemblyDescription("")] 10 | [assembly: AssemblyConfiguration("")] 11 | [assembly: AssemblyCompany("")] 12 | [assembly: AssemblyProduct("NewApp")] 13 | [assembly: AssemblyCopyright("Copyright © 2017")] 14 | [assembly: AssemblyTrademark("")] 15 | [assembly: AssemblyCulture("")] 16 | 17 | // Setting ComVisible to false makes the types in this assembly not visible 18 | // to COM components. If you need to access a type in this assembly from 19 | // COM, set the ComVisible attribute to true on that type. 20 | [assembly: ComVisible(false)] 21 | 22 | // The following GUID is for the ID of the typelib if this project is exposed to COM 23 | [assembly: Guid("50c7b8c9-e664-45af-b88e-0c9b8b9c1be1")] 24 | 25 | // Version information for an assembly consists of the following four values: 26 | // 27 | // Major Version 28 | // Minor Version 29 | // Build Number 30 | // Revision 31 | // 32 | // You can specify all the values or you can default the Build and Revision Numbers 33 | // by using the '*' as shown below: 34 | // [assembly: AssemblyVersion("1.0.*")] 35 | [assembly: AssemblyVersion("1.0.0.0")] 36 | [assembly: AssemblyFileVersion("1.0.0.0")] 37 | -------------------------------------------------------------------------------- /PdfSharp.Xamarin.Forms.iOS/packages.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | -------------------------------------------------------------------------------- /PdfSharp.Xamarin.Forms/Attributes/PdfRendererAttribute.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace PdfSharp.Xamarin.Forms.Attributes 4 | { 5 | internal class PdfRendererAttribute : Attribute 6 | { 7 | public Type ViewType { get; set; } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /PdfSharp.Xamarin.Forms/Contracts/ICustomFontProvider.cs: -------------------------------------------------------------------------------- 1 | namespace PdfSharp.Xamarin.Forms.Contracts 2 | { 3 | public interface ICustomFontProvider 4 | { 5 | byte[] GetFont(string faceName); 6 | 7 | string ProvideFont(string fontName, bool isItalic, bool isBold); 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /PdfSharp.Xamarin.Forms/Contracts/IPdfHandler.cs: -------------------------------------------------------------------------------- 1 | using MigraDocCore.DocumentObjectModel.MigraDoc.DocumentObjectModel.Shapes; 2 | 3 | namespace PdfSharp.Xamarin.Forms.Contracts 4 | { 5 | public interface IPDFHandler 6 | { 7 | ImageSource GetImageSource(); 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /PdfSharp.Xamarin.Forms/DefaultFonts/OpenSans-Bold.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/groege/PdfSharpCore/81691250eab00f12a517fb6f9a42e0d8aeea820c/PdfSharp.Xamarin.Forms/DefaultFonts/OpenSans-Bold.ttf -------------------------------------------------------------------------------- /PdfSharp.Xamarin.Forms/DefaultFonts/OpenSans-BoldItalic.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/groege/PdfSharpCore/81691250eab00f12a517fb6f9a42e0d8aeea820c/PdfSharp.Xamarin.Forms/DefaultFonts/OpenSans-BoldItalic.ttf -------------------------------------------------------------------------------- /PdfSharp.Xamarin.Forms/DefaultFonts/OpenSans-Italic.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/groege/PdfSharpCore/81691250eab00f12a517fb6f9a42e0d8aeea820c/PdfSharp.Xamarin.Forms/DefaultFonts/OpenSans-Italic.ttf -------------------------------------------------------------------------------- /PdfSharp.Xamarin.Forms/DefaultFonts/OpenSans-Regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/groege/PdfSharpCore/81691250eab00f12a517fb6f9a42e0d8aeea820c/PdfSharp.Xamarin.Forms/DefaultFonts/OpenSans-Regular.ttf -------------------------------------------------------------------------------- /PdfSharp.Xamarin.Forms/Extensions/ColorExtension.cs: -------------------------------------------------------------------------------- 1 | using PdfSharpCore.Drawing; 2 | using Xamarin.Forms; 3 | 4 | namespace PdfSharp.Xamarin.Forms 5 | { 6 | public static class ColorExtension 7 | { 8 | public static XColor ToXColor(this Color color) 9 | { 10 | if (color == default(Color)) 11 | return XColors.Transparent; 12 | 13 | return XColor.FromArgb((int)(color.A * 255), (int)(color.R * 255), (int)(color.G * 255), (int)(color.B * 255)); 14 | } 15 | 16 | public static XBrush ToXBrush(this Color color) 17 | { 18 | return new XSolidBrush(color.ToXColor()); 19 | } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /PdfSharp.Xamarin.Forms/Extensions/LayoutOptionsExtension.cs: -------------------------------------------------------------------------------- 1 | using PdfSharpCore.Drawing; 2 | using Xamarin.Forms; 3 | 4 | namespace PdfSharp.Xamarin.Forms 5 | { 6 | public static class LayoutOptionsExtension 7 | { 8 | public static XStringAlignment ToXStringAlignment(this TextAlignment alignment) 9 | { 10 | switch (alignment) 11 | { 12 | case TextAlignment.Start: 13 | return XStringAlignment.Near; 14 | case TextAlignment.Center: 15 | return XStringAlignment.Center; 16 | case TextAlignment.End: 17 | return XStringAlignment.Far; 18 | default: 19 | return XStringAlignment.Near; 20 | } 21 | } 22 | 23 | public static XLineAlignment ToXLineAlignment(this TextAlignment alignment) 24 | { 25 | switch (alignment) 26 | { 27 | case TextAlignment.Start: 28 | return XLineAlignment.Near; 29 | case TextAlignment.Center: 30 | return XLineAlignment.Center; 31 | case TextAlignment.End: 32 | return XLineAlignment.Far; 33 | default: 34 | return XLineAlignment.BaseLine; 35 | } 36 | } 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /PdfSharp.Xamarin.Forms/Extensions/PointExtension.cs: -------------------------------------------------------------------------------- 1 | using PdfSharpCore.Drawing; 2 | using Xamarin.Forms; 3 | 4 | namespace PdfSharp.Xamarin.Forms 5 | { 6 | public static class PointExtension 7 | { 8 | public static XPoint ToXPoint(this Point point) 9 | { 10 | return new XPoint(point.X, point.Y); 11 | } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /PdfSharp.Xamarin.Forms/Extensions/RectangleExtensions.cs: -------------------------------------------------------------------------------- 1 | using PdfSharpCore.Drawing; 2 | using Xamarin.Forms; 3 | 4 | namespace PdfSharp.Xamarin.Forms 5 | { 6 | public static class RectangleExtensions 7 | { 8 | public static XRect ToXRect(this Rectangle rect) 9 | { 10 | return new XRect(rect.X, rect.Y, rect.Width, rect.Height); 11 | } 12 | 13 | public static XRect AddMargin(this XRect rect, Thickness thickness) 14 | { 15 | return new XRect(rect.X + thickness.Left, rect.Y + thickness.Top, rect.Width - thickness.HorizontalThickness, rect.Height - thickness.VerticalThickness); 16 | } 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /PdfSharp.Xamarin.Forms/Icons/search.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/groege/PdfSharpCore/81691250eab00f12a517fb6f9a42e0d8aeea820c/PdfSharp.Xamarin.Forms/Icons/search.png -------------------------------------------------------------------------------- /PdfSharp.Xamarin.Forms/PdfRendererAttributes.cs: -------------------------------------------------------------------------------- 1 | using PdfSharp.Xamarin.Forms.Delegates; 2 | using Xamarin.Forms; 3 | 4 | namespace PdfSharp.Xamarin.Forms 5 | { 6 | public class PdfRendererAttributes : BindableObject 7 | { 8 | 9 | public bool ShouldRender 10 | { 11 | get { return (bool)GetValue(ShouldRenderProperty); } 12 | set { SetValue(ShouldRenderProperty, value); } 13 | } 14 | 15 | public PdfListViewRendererDelegate ListRendererDelegate 16 | { 17 | get { return (PdfListViewRendererDelegate)GetValue(ListRendererDelegateProperty); } 18 | set { SetValue(ListRendererDelegateProperty, value); } 19 | } 20 | 21 | public static readonly BindableProperty ShouldRenderProperty = 22 | BindableProperty.CreateAttached(nameof(ShouldRender), typeof(bool), typeof(PdfRendererAttributes), true); 23 | 24 | public static readonly BindableProperty ListRendererDelegateProperty = 25 | BindableProperty.CreateAttached(nameof(ListRendererDelegate), typeof(PdfListViewRendererDelegate), typeof(PdfRendererAttributes), new PdfListViewRendererDelegate()); 26 | 27 | public static bool ShouldRenderView(BindableObject bindable) 28 | { 29 | return (bool)bindable.GetValue(ShouldRenderProperty); 30 | } 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /PdfSharp.Xamarin.Forms/PdfSharp.Xamarin.Forms.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | netstandard1.4 5 | akgulebubekir 6 | 7 | 8 | 9 | full 10 | true 11 | false 12 | 13 | 14 | 15 | pdbonly 16 | true 17 | 18 | true 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | -------------------------------------------------------------------------------- /PdfSharp.Xamarin.Forms/Renderers/PDFLabelRender.cs: -------------------------------------------------------------------------------- 1 | using PdfSharp.Xamarin.Forms.Attributes; 2 | using PdfSharpCore.Drawing; 3 | using PdfSharpCore.Fonts; 4 | using Xamarin.Forms; 5 | 6 | namespace PdfSharp.Xamarin.Forms.Renderers 7 | { 8 | [PdfRenderer(ViewType = typeof(Label))] 9 | public class PDFLabelRenderer : PdfRendererBase