Re: RE: Does FOP support non-breaking hyphens?
May be post a fo snippet showing what you give to fop and then describe your expected and the actual output. Thank you for your answer! I am using FOP 0.95 (latest stable at the time of writing). I am trying the following fo snippet. fo:block This is the example with 2011 (as char) non breaking hyphen: This#8209;is#8209;a#8209;line#8209;with#8209;8209#8209;characters /fo:block fo:block This is the example with 2011 (as hex) non breaking hyphen: This#x2011;is#x2011;a#x2011;line#x2011;with#x2011;8209#x2011;characters /fo:block fo:block This is the example with 2011 (as number) non breaking hyphen: This#8209;is#8209;a#8209;line#8209;with#8209;8209#8209;characters /fo:block fo:block This is the example ZZ with an HTML shy hyphen: Bigandlongwordthatshouldbreakinalogicalplaceandnotgotothenextline /fo:block fo:block This is the example Z with non breaking space : Big#160;and#160;long#160;word#160;that#160;should#160;break#160;in#160;a#160;logical#160;place#160;and#160;not#160;go#160;to#160;the#160;next#160;line /fo:block Comments: - The hyphens in the first block are hex 2011 chars inserted directly into the FO file from the VIM editor - The hyphens in second block are entities with number 8209 - The hyphens in the third block are entities with hex 2011 - There are hyphens in 4th block with hex AD inserted directly by VIM - The non-breaking-space in the 5th block are entities with number 160 I run this snippet with FOP using fop -fo hyphens.xml hyphens.pdf Expected output First Block: This-is-a-line-with-8209-characters sentence appearing with hyphens but it should not break at any point. Second block: The same as first Third block: The same as first Fourth block: The sentence Bigandlong... with no visible hyphens. Only one visible hyphen when it breaks Fifth block: The sentence Big and long... with spaces but no break at all Actual output First block:The sentence appearing with # characters instead of hyphens Second block: Same as first Third block same as first Fourth block: As expected (so this works OK) Fifth block: As expeected (so this works OK) Thus the problem is that I get the # (sharp symbol) instead of a non-breaking-hyphen in the PDF output. I hope this is more clear. - To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org
Using keep-together.within-column and break-after results in missing text
Hello I am using FOP 0.95 (latest stable at the time of writing) and trying the following FO file. ?xml version=1.0 encoding=utf-8? fo:root xmlns:fo=http://www.w3.org/1999/XSL/Format; fo:layout-master-set fo:simple-page-master page-width=210mm page-height=297mm font-family=LiberationSerif master-name=pim-page fo:region-body margin-left=2.5cm margin-bottom=2cm margin-right=2.5cm margin-top=2cm/ /fo:simple-page-master /fo:layout-master-set fo:page-sequence master-reference=pim-page fo:flow flow-name=xsl-region-body fo:table border=1px fo:table-body fo:table-row keep-together.within-column=always fo:table-cell fo:block fo:block break-after=page Text on the first page. A page break should follow. /fo:block fo:blockText on the next page after the break/fo:block /fo:block /fo:table-cell /fo:table-row /fo:table-body /fo:table /fo:flow /fo:page-sequence /fo:root I then convert it to PDF with fop -fo minimal.xml minimal.PDF Expected output Either (option 1): A PDF file with two pages with Text on the first .. shown in the first page and Text on the next... shown in the second (this means that break-after prevails) Or (option 2): A PDF file with only one page that contains both of the above sentences (the keep-together prevails) Actual Output A PDF file with two pages. Only the Text on the first.. appears on the document. The rest of Text on the next... is completely missing (not shown at all). What am I missing? Is this an issue or my mistake? Thank you. - To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org
Does FOP support non-breaking hyphens?
Hello I was really glad when I saw that FOP supports soft hyphens (HEX AD) I noticed however that non-breaking hyphens (HEX 2011) do not work as expected. Is this a known issue? Should I report it in Bugzilla? Do you plan to support this on the next FOP version? Thank you. - To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org
Re: Re: Is it possible to create PDFs in 96 DPI?
Hi, Like you noticed the resolution only applies to images. I am slightly puzzled by the way you compare both outputs: are you putting the sheet of paper next to the screen and looking for differences? I have a table with fixed-size width and a large chunk of text inside (so that is wraps). When I test the HTML file all major browsers (Safari,Chrome,Firefox,Opera,Explorer) wrap at a specific word (i.e. the third) and the output is the same on-screen for all of them. The resulting PDF file however wraps at a different word (i.e. the second) even though everything else is the same (text contents, font size,font, e.t.c.). When I print the HTML and PDF files the text is printed with exactly the same font size and the only difference is the text wrapping. All of this in the same physical machine (winXP 32bit and FOP 0.95), so screen resolution and OS are also the same. It seems to me that fixed-width in tables are 96/72 dpi wider in PDF than in the HTML browser. Is there a reason why the calculations for fixed-width in tables produce a different result than ALL the other browsers? Is is possible to configure how these fixed-width calculations are performed? - To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org
Is it possible to create PDFs in 96 DPI?
Hello list! I have an XML file which is either converted to PDF (via FOP) or to XHTML (via another XSL stylesheet) I have noticed however that things look different in (printed) PDF and (on-screen) HTML formats. The sizes are different for the text elements. After searching for a cause it came to my attention that PDF files from FOP are rendered at 72DPI (correct me if I am wrong) while the browser/screen/OS works at 96DPI. I found the configuration for dpi at http://xmlgraphics.apache.org/fop/0.95/configuration.html, but this applies only to images and not text. So is there a workaround to make things appear on print the same as they are on screen? I am thinking of manully changing the sizes in one stylesheet (either for FO or HTML) to bring it to the same size with the other. But I wonder if there is a more elegant solution. Thank you - To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org