pdf-generation

(DOORS/DXL) Export to pdf or print with a given template

百般思念 提交于 2019-12-10 15:16:20
问题 We are interested in export/print one view from formal module. As we want it can be an ofcial document we want to add our corporative template that have it own front page, and its own headers and footers pages with a given text font, size, and color, and inserted images (company symbol, clients ones). As far as I can see, DOORS let us print adding header&footer but without images. On the other side it is possible export to Word adding a template, but I can't do it directly to pdf format or to

How to determine which part of an nsstring fits into a rect?

人走茶凉 提交于 2019-12-10 13:41:40
问题 This is about PDF formatting using core graphics. But it could be about any type of paging when it comes to printing a string on two pages. I need to spread a string over several pages. For smaller strings this is no real problem. For those I use the NSString UIKit extensions sizeWithFont to determine, whether the full text fits on the current page or not. If it does, then I print it with drawInRect and if it does not then I move it to the next page. Works fine but is not suitable for longer

convert excel to pdf in python

二次信任 提交于 2019-12-10 13:34:06
问题 Is there a good python module to convert .xls file to PDF? 回答1: Try xtopdf. Note that there are some limitations: Only simple spreadsheets that have plain text content, such as strings, numbers and dates, are supported. Spreadsheets with formatted cells (bold, italic, right-justified, etc.) or embedded images are not supported, or the formatting and images may be lost in the PDF output. Support for this input format means that you can publish your spreadsheets as PDF. 回答2: I know this is

Primefaces DataExporter Set Table Columns Width

末鹿安然 提交于 2019-12-10 13:08:05
问题 I have a Primefaces DataGrid that I export whith Primefaces DataExporter but I can't figure out how to resize the columns. I added a preporcessor <p:dataExporter type="pdf" target="tbl" fileName="cars" preProcessor="#{customizedDocumentsView.preProcessPDF}" /> And this is the code in my bean public void preProcessPDF(Object document) { Document pdf = (Document) document; pdf.open(); pdf.setPageSize(PageSize.A4); //I need to do something like that //PdfPTable table = new PdfPTable(4); //float[

Does a library exist to remove passwords from PDFs programmatically? [closed]

泪湿孤枕 提交于 2019-12-10 12:48:53
问题 As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance. Closed 6 years ago . Does a library exist that will remove "owner" passwords from PDF documents so that the text can then be programmatically extracted

Generating a PDF document based on a Microsoft Word Template [closed]

99封情书 提交于 2019-12-10 12:48:31
问题 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 3 years ago . I need to take a Word document that is a template of sorts...collect user input to populate specific fields in that template..then generate a PDF file that includes the completed template as well as a few other document types. Does anyone have a good suggestion on a component to achieve this? Preferably one that

IOS Swift sharing PDF documents with images

大憨熊 提交于 2019-12-10 12:23:06
问题 I'm getting a weird behaviour when sharing a simple PDF document using Swift on IOS. Basicaly if I create it and share it to be printed the image it should contain is not included. If I first display it using a UIViewController and then share it it's fine. I just don't get why ! Here are the interresting parts of my code : func getHtml() -> String { // Create a HTML document to be printed // Save data to file let fileName = "noteImage.jpeg" let pathToInvoiceHTMLTemplate = Bundle.main.path

from reportlab.platypus import ListFlowable, ListItem not working

牧云@^-^@ 提交于 2019-12-10 12:18:26
问题 I am a newbie to python. I have to create an ordered list in my pdf document using Reportlab . I found these two classes ListFlowable(), ListItem() in the user-guide of Reportlab to do the same. But the very first import statement for these classes is not working. from reportlab.platypus import ListFlowable, ListItem This statement gives me the following error: ImportError: cannot import name ListFlowable How can I use these classes? I am using python 2.6, reportlab 2.5. 回答1: In my install of

iText 7 return Pdf from Asp.Net WebApi

不羁的心 提交于 2019-12-10 12:06:11
问题 So I am alreay searching about this the entire day and I just don't know how to get it working. Basically I want to create a PDF server side with iText 7 in my ASP.Net WebApi. Very straightforward and easy Pdf creation: [HttpGet] public HttpResponseMessage CreateLieferschein() { MemoryStream stream = new MemoryStream(); PdfWriter writer = new PdfWriter(stream); var pdf = new PdfDocument(writer); var document = new Document(pdf); document.Add(new Paragraph("Hello World!")); } From here on I

Set cell borders as dashed in tcpdf WriteHTML

元气小坏坏 提交于 2019-12-10 11:58:26
问题 Hi i want to make the border of table cells as dashed lines in TCPDF writehtml()... I have tried using border=1 for tables but only a thick border comes .. also i have tried using css like style="border-style: dashed;border-width: 1px; " however the border remains the same... Can anyone point me in the right direction? 回答1: According to the docs, if you’d use writeHTMLCell() , the 6th argument represents the border style. A dashed border would look like: TCPDF::writeHTMLCell( …, array( 'LRTB'