pdf-generation

Creating on-demand, print-quality PDFs (preferably in Ruby if feasible)

霸气de小男生 提交于 2019-12-08 03:36:39
问题 Main-Question What's your fast and reliable (as in "stable") solution to create on-demand, newspaper-like (as in "using advanced layout or typesetting") PDFs out of an application on a Linux server? Therefore: No, HTML2PDF is not the solution I'm looking for. ;-) Bonus-Question And if it's not Ruby-based: Is there a way to steer your solution out of a Rails application? Preferably over a webservice or a something-2-Ruby-bridge-kind-of-thing? Thanks a lot for your suggestions! Update There's a

Convert a image url to pdf using jspdf

心不动则不痛 提交于 2019-12-08 03:26:24
问题 function convertImgToBase64(url) { var canvas = document.createElement('canvas'); var ctx = canvas.getContext('2d'); img = document.createElement('img'), img.src = url; canvas.height = img.height; canvas.width = img.width; var dataURL = canvas.toDataURL('image/jpeg') alert(dataURL); canvas = null; return dataURL; } var imageurl = 'http://qph.is.quoracdn.net/main-qimg-ca033a73e2ea858908c44905d4c25f4b?convert_to_webp=true'; var som =convertImgToBase64(imageurl); doc.addImage(som, 'JPEG', 15, 40

Generating PDF with Quick Reports behind a Delphi Web Server

回眸只為那壹抹淺笑 提交于 2019-12-08 03:17:19
问题 I have a Delphi web server providing some web services*. One of them is supposed to generate and return a PDF report. The PDF creation is done with a QReport that is then exported into a PDF file with the ExportToFilter procedure. The routine works fine when called from within an application, but when called behind a TIdTCPServer, it hangs and never finishes. Debugging it, I got tho the hanging point: (note: I'm home right now and I don't have the source code. I'll try to reproduce quickrpt

Unable to create PDF from HTML in Xamarin Android

故事扮演 提交于 2019-12-08 02:47:40
问题 I am developing an Application in Xamarin for Android. I have already generated HTML file using StringBuilder. Now I have a HTML file in my External storage and the same template is required for PDF. So when I try to convert HTML to PDF using iTextSharp using XML Worker & PDFSharp libraries, I am getting build errors due to missing System.Drawing.dll. Then I found from Xamarin forums & Stackoverflow links that it is not supported for Xamarin.Android. Can anyone please tell me other

css background is not working when convert template into pdf using rendering plugin

ぃ、小莉子 提交于 2019-12-08 02:45:32
问题 I am using rendering plugin to generate pdf in grails. I am using a background color which is prepared by css. code is here. #container #content #mainContent .block .backgroundStyle { background: #ffffff; /* Old browsers */ /* IE9 SVG, needs conditional override of 'filter' to 'none' */ background: url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiA

itext XMLWorkerHelper ignores value attribute of <li> tag

怎甘沉沦 提交于 2019-12-08 01:55:09
问题 I'm using itext 5.4.5 with XMLWorker 5.4.5 to generate pdf from html that cames from ckEditor. Users can also paste some text from word documents and this results sometimes in something like this: <ol> <li value="3">some text1</li> </ol> <div>lorem ipsum dolor</div> <ol> <li value="100">some text2</li> </ol> <div>lorem ipsum dolor</div> <ol> <li value="77">some text3</li> </ol> this results in ckEditor and in html as 3. some text1 lorem ipsum dolor 100. some text2 lorem ipsum dolor 77. some

Insert values from a file in a latex document

这一生的挚爱 提交于 2019-12-08 00:33:40
问题 If a have a latex document, how can I read some key-value pairs from a file an insert them into the document? Something like this: Latex code: customer ID: ${customerID} Text file: customerID=123456 And the resulting .pdf file should contain the customer ID. 回答1: We can always write a perl script to expand them... defs.txt: customerID=123456 customerTel=22530000000 doc.tex: \documentclass{article} \begin{document} latex customer ID: ${customerID} and ${address} costum telphone ID: $

Shrink and merge PDFs in Python

不想你离开。 提交于 2019-12-07 23:13:37
问题 I'm trying to shrink and merge two A4 PDF pages into one A4 page so that if I had; _____ _____ | | | | | p1 | | p2 | | | | | |_____| |_____| I would get; _____ | p1 | |.....| | p2 | |_____| As a new PDF, with two A5 sized pages on that one page. Similar to how you might print two pages per page on paper. I've looked into pyPDF (http://pybrary.net/pyPdf/) ReportLab (http://www.reportlab.com) but I can't seem to find how to shrink and merge like this. Any hints? Thanks! 回答1: pdfnup has this

Free RTF to PDF .NET component or tool? [closed]

删除回忆录丶 提交于 2019-12-07 22:58:19
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed 6 years ago . I am trying to convert a RTF file to a PDF. All tools I found so far cost a lot of money. Is there a tool which I could call or component I could use which converts existing RTF files to PDFs? If its a tool, it should have command line support so I can call it from the code. I am using C#... Thanks 回答1: I wrote

Generate PDF in Android without any 3rd party Library

北城余情 提交于 2019-12-07 20:32:28
I need to generate PDF from my application using PdfDocument class introduced in API 19. I don't want to use any 3rd party library. Here is what I have done PdfDocument document = new PdfDocument(); PdfDocument.PageInfo pageInfo = new PdfDocument.PageInfo.Builder(300, 300, 1).create(); PdfDocument.Page page = document.startPage(pageInfo); View content = findViewById(R.id.testText); content.draw(page.getCanvas()); document.finishPage(page); String fullPath = Environment.getExternalStorageDirectory().getAbsolutePath() + "/AppName"; File dir = new File(fullPath); File file = new File(fullPath,