pdf-generation

PDF generation with DocRaptor in AngularJS

て烟熏妆下的殇ゞ 提交于 2019-12-11 05:01:58
问题 I am trying to incorporate DocRaptor in my AngularJS project for PDF generation and exporting some pages as PDFs. I am fairly new to Angular and can't seem to find any supporting documentation. Could someone point me to the right resources. The only resource I have found is this StackOverflow question: Using DocRaptor web service with AngularJS?. 回答1: I'm a DocRaptor developer. We fully support Angular sites. The example given in the existing question you linked to is pretty good. You can

jsPDF: justify text with custom font

空扰寡人 提交于 2019-12-11 04:52:08
问题 With jsPDF and a custom font, the option to justify text doesn't seem to work. Once you remove the custom font, the options works just fine. document.getElementById("get-pdf").addEventListener("click",getPDF); function getPDF(){ var doc = new jsPDF(); const helveticaNeueNormalBase64 = 'AAE...twC3/70='; const helveticaNeueMediumBase64 = 'AAEAAAAPADAAA...CgAAAGAAuQACAAE='; const helveticaNeueBoldBase64 = 'AAEAAAAPADAAAwDAT1...AAIAAQ=='; const fontShort = 'HelveticaNeue'; const fontStyleNormal =

Grails rendering-plugin fails when app is deployed

孤人 提交于 2019-12-11 04:31:48
问题 I've been using the plugin for a while and it has worked both in development environment and in the deploying system. But with the latest version it fails in the deployed version but works in the development system. I think it has something to do with using images. The call in the controller: def createPDF() { def file = assetResourceLocator.findAssetForURI( 'Checkout16x16.png' ) def OfferHeader offerHeader = OfferHeader.get(params.id) def millId = offerHeader.offerDetails.millOfferID def

How to show an image with large dimensions across multiple pages in a PDF using iText5?

空扰寡人 提交于 2019-12-11 03:16:33
问题 I have a graph image with large dimensions which I need to display in a PDF file. I can't scale to fit the image as this would make text on the node illegible. How could I split the image into multiple pages while retaining its original dimensions? 回答1: Please take a look at the TiledImage example. It takes an image at its original size and it tiles it over 4 pages: tiled_image.pdf To make this work, I first asked the image for its size: Image image = Image.getInstance(IMAGE); float width =

TCPDF do not display Chinese on Linux client

余生长醉 提交于 2019-12-11 02:26:06
问题 I cannot get TCPDF display any chinese character no matter what font I am using. I crawled and searched everywhere I could, including these interesting posts tcpdf-utf-8-problem tcpdf-encode-chinese-character but still without success. The sample #7 from TCPDF works well with a lot of different characters sets but if I add some Chinese to the text it will display as squares and the strangest thing is if I change the font to stsongstdlight as suggested in one message the text won't display at

Is there a way to display postscript (.ps) files on iOS?

十年热恋 提交于 2019-12-11 02:25:30
问题 I need to display .ps files in an iOS app. Native support for .ps to .pdf conversion appears to be switched off -- CGPSConverter, https://developer.apple.com/documentation/coregraphics/cgpsconverter?language=occ are not available on iOS: https://developer.apple.com/library/archive/documentation/GraphicsImaging/Conceptual/drawingwithquartz2d/dq_ps_convert/dq_ps_convert.html Does anyone know of another way? Is there any 3rd party library that could help me here? Please note that a Ghostscript

ruby prawn how to wrap text around an aligned right image?

こ雲淡風輕ζ 提交于 2019-12-11 02:12:30
问题 s it posible to align an image to the right and wrap text around the image like it is in html and css using the float:right property ? If so how do you do this ? I can align an image but dont't know how to wrap the text around it. The text is dynamic text therefore varies alot in length. Thanks alot Rick 回答1: One suggestion is to try nested bounding boxes. The main bounding box would have the text inside it. with at some point another bounding box for the image. Something along the lines of

PDF document is modified by another revision?

南楼画角 提交于 2019-12-11 01:52:11
问题 I use PDFbox in order to sign PDF. It works very well. I can add several signature to one document, and everything works well. Now, someone sign me a document(she sign by another software), this signature was working too. but when I add another revision (by pdfbox) to his document now Adobe reader tells me that PDF was modified. that is original document: this this is signed document which was done by another software: link when I add another revision to the signed pdf, I get this document,

Fill in PDF Forms from VB.NET application

孤人 提交于 2019-12-11 01:19:28
问题 I am being tasked with creating a Windows application in VB.Net, and one of the requirements is to read data from an MSSQL database, and put in certain values into a PDF form. How can I achieve putting data into a pre-existing PDF file using VB.Net? Also, is it possible to put the PDF file in as a resource instead of calling it externally? 回答1: You may be able to take advantage of a 3rd party component like iTextSharp which is a PDF library. It's written in C#, but could be added to your

iTextSharp - very large table memory leak

ε祈祈猫儿з 提交于 2019-12-11 00:56:19
问题 I have a SqlDataReader reading a large record set (1M records approx.) and I'm trying to export it to a PDF document using iTextSharp. This is my code: if (reader.HasRows) { int rowNum = 0; while (reader.Read()) { if (rowNum % 2 == 1) datatable.DefaultCell.GrayFill = 0.8f; else datatable.DefaultCell.GrayFill = 0.95f; if (meRes.Trans(Lang, "Dir", CompanyID).ToUpper() == "RTL") for (int i = reader.FieldCount - 1; i >= 0; i--) { object o = reader[i]; datatable.AddCell(new Phrase(o.ToString(),