Sign In  Sign Up Live-Chat

pdf.kit + pdf

Last post 05-13-2008, 8:03 PM by forever. 3 replies.
Sort Posts: Previous Next
  •  05-13-2008, 10:58 AM 126723

    pdf.kit + pdf

    Is it possible to use the features from both the pdf.kit & pdf components to create a single pdf?

    I currently have an existing 2 page PDF that I would like to modify by adding text, images & solid color shapes (such as a black rectangle) to. In pdf.kit I can just open the source pdf and drop in the text & images, but I don't see a way to create tables, rows & cells so I can drop the text into a cell and align it however I wish like I can in aspose.pdf.

    In aspose.pdf I have to create jpeg's from my source pdf and place those into the aspose pdf as background images which increases the size of the pdf and reduces the overall quality, in my opinion.

    Is there a way to open the source pdf in pdf.kit and pass that to aspose.pdf for the real modifications? Can pdf.kit do what I want and I'm just not seeing it (adding a table then adding text that's centered horizontally and vertically in that table)?

    If I'm not clear or you need more details please let me know. Thank you.

    ~Brian

     
  •  05-13-2008, 2:07 PM 126761 in reply to 126723

    Re: pdf.kit + pdf

    Hi,

    Thanks for considering Aspose.Pdf.Kit and Aspose.Pdf

    With reference to your question that "Is it possible to add a table then adding text that's centered horizontally and vertically in that table using Aspose.Pdf?

    Yes, Aspose.Pdf allows developers to create tables in PDF documents. Moreover, other effects like setting its border style, margins and Cell paddings can also be applied on the tables. For more details kindly visit

    http://www.aspose.com/documentation/file-format-components/aspose.pdf-for-.net-and-java/working-with-tables.html

     


    Nayyer Shahbaz
    Support Developer
    Aspose Changsha Team
    About Us
     
  •  05-13-2008, 5:57 PM 126787 in reply to 126761

    Re: pdf.kit + pdf

    Is it possible to do this in aspose.kit though?

    Here's my issue, I have a two page existing pdf document that I need to add a multitude of images & text areas to.

    I currently do this in aspose.pdf by creating .jpg files from my source pdf pages and then importing them into a new aspose.pdf document and setting them as background images. From that point I can add tables, rows & cells with text and images to finish the job. All of this happens great on the screen, but when it comes time to print, the background images don't have the same printed quality as my original pdfs. I understand that this is most likely because I'm taking a vector based object, rendering it in photoshop and then generating a .jpg file from it, but whatever the reason it's something I can give to the client.

    I'd like to use Aspose.pdf.kit for my needs since I can just modify the source pdf and retain the inherent quality in it. My question is if apose.pdf.kit has the same capability when it comes to adding text and images. From what I've seen so far it doesn't, for instance I don't see a way to duplicate this code from aspose.pdf to aspose.pdf.kit:

    Dim tblName As New Table
    Section.Paragraphs.Add(tblName)

    tblName.PositioningType = PositioningType.PageRelative
    tblName.Left = Left
    tblName.Top = Top
    tblName.ColumnWidths = ColumnWidth

    Dim rowName As Row = tblName.Rows.Add()
    rowName.FixedRowHeight = RowHeight

    Dim cellName As Cell = rowName.Cells.Add()
    cellName.VerticalAlignment = Aspose.Pdf.VerticalAlignmentType.Center

    Dim NameInfo As TextInfo = New TextInfo
    NameInfo.Alignment = Aspose.Pdf.AlignmentType.Center
    NameInfo.FontName =
    "Avenir LT 65 Medium"
    NameInfo.IsTrueTypeFontBold = True
    NameInfo.IsFontEmbedded = True
    NameInfo.FontSize = 9

    cellName.Paragraphs.Add(New Text("My Name")

    I could as a possible workaround use aspose.pdf to generate a pdf containing the modifications that I need to make, and then use aspose.pdf.kit to merge the two seperate documents together, but that doesn't seem all that efficient resource wise.

    Any suggestions?

    Thanks.

    ~Brian

     
  •  05-13-2008, 8:03 PM 126798 in reply to 126787

    Re: pdf.kit + pdf

    Dear Brian,

    Aspose.Pdf can only be used to create PDF from scratch. It is not possible to pass objects between Aspose.Pdf and Aspose.Pdf.Kit. Currently we support some basic editing features in Aspose.Pdf.Kit. In Aspose.Pdf.Kit, it is very difficult to support most of the features of Aspose.Pdf.


    Tommy Wang
    Lead Developer
    Aspose Changsha Team
    About Us
    Contact Us
     
View as RSS news feed in XML