Aspose.Pdf.Examples.CSharp.AsposePDF.Text.AddText.AddingBorderAroundAddedText C# (CSharp) Method

AddingBorderAroundAddedText() public static method

public static AddingBorderAroundAddedText ( ) : void
return void
        public static void AddingBorderAroundAddedText()
        {
            // ExStart:AddingBorderAroundAddedText
            // The path to the documents directory.
            string dataDir = RunExamples.GetDataDir_AsposePdf_Text();

            PdfContentEditor editor = new PdfContentEditor();
            editor.BindPdf(dataDir + "input.pdf");
            LineInfo lineInfo = new LineInfo();
            lineInfo.LineWidth = 2;
            lineInfo.VerticeCoordinate = new float[] { 0, 0, 100, 100, 50, 100 };
            lineInfo.Visibility = true;
            editor.CreatePolygon(lineInfo, 1, new System.Drawing.Rectangle(0, 0, 0, 0), "");

            dataDir = dataDir + "AddingBorderAroundAddedText_out.pdf";

            // Save resulting PDF document.
            editor.Save(dataDir);
            // ExEnd:AddingBorderAroundAddedText
            Console.WriteLine("\nBorder around text added successfully.\nFile saved at " + dataDir);
        }
        public static void LoadingFontFromStream()