xsl-fo

XSL-FO - how to create static-content for fo:region-body

谁说我不能喝 提交于 2021-02-11 15:16:47
问题 I have to create fo:static-content for header, body and footer. Header and footer are done and it works but I have a problem with body. There is nothing on my output PDF's first page from fo:static-content . Content from fo:flow is generated on next page. I need explanation how to create working fo:static-content for fo:region-body . Below is my fo:layout-master-set , fo:static-content and fo:flow . <fo:layout-master-set> <!-- page master for the first page--> <fo:simple-page-master master

FOP apache - support Hebrew letters

别说谁变了你拦得住时间么 提交于 2021-02-07 13:21:07
问题 I've been investigating in the last few days the support of Hebrew letters in the FOP apache project for generating PDF file. I saw that there was a problem with that in the past and I didn't really understood whether it been solved or not? If there is a support, can somebody show/redirect me to simple sample giving me XSL-FO file with Hebrew letters that when using FOP the PDF is generated properly(clear and not reversed by order letters). I would really appreciate your answer. This thing is

How to do sort(as alphabetical odder) within a for loop as expected below in xslt or xsl-fo?

无人久伴 提交于 2021-01-29 16:23:21
问题 I want to create a table Which contain two columns as product type and number of quantity in XSL-Fo. In the XML input file Type node contain 00 then in the table the product should be come like "Other" if Type element value is 00 then "Other" like wise 51 = Business Loan – General 05 = Personal Loan I want to see all product in alphabetical ascending odder. This is my Input XML <product> <months> <Type>00</Type> <Number>2</Number> </months> <months> <Type>51</Type> <Number>2</Number> </months

XSLT - How to treat inline/escaped XML within a node as nested nodes

只愿长相守 提交于 2021-01-29 13:45:11
问题 New to xslt - not enjoying it so far. Trying to preserve some HTML (table) formatting being received by an application that converts to PDF. Need an xslt way of interpreting escaped HTML/XML data within an XML node as further child nodes? Have tried a v3 parse-xml() on that node. Have tried a v1 search/replace template to convert < into < etc. Have tried disable-output-escaping="yes" - nope. Nothing appears to work for some reason. Source XML: <?xml version="1.0" encoding="windows-1252"?>

XSL:FO Keep the header only for first page

时光毁灭记忆、已成空白 提交于 2021-01-29 07:50:18
问题 I am having a problem to keep "region-before" only for first page. See my code: <fo:layout-master-set> <fo:simple-page-master master-name="first" margin-right="0.5cm" margin-left="0.5cm" margin-bottom="0.5cm" margin-top="0.75cm" page-width="21cm" page-height="29.7cm"> <fo:region-body region-name="xsl-region-body" margin-top="{$extra-body-margin-top+15.6-$header-margin}cm" margin-bottom="3.5cm" /> <fo:region-before region-name="xsl-region-before" extent="17cm" overflow="hidden" /> <fo:region

How can I create a footer on the last page

别说谁变了你拦得住时间么 提交于 2021-01-29 06:42:53
问题 Here the clean code: <fo:root xmlns:fo="http://www.w3.org/1999/XSL/Format"> <fo:layout-master-set> <fo:simple-page-master master-name="pages-normale" page-width="297mm" page-height="210mm" margin-top="0.5cm" margin-bottom="0.5cm" margin-left="0.5cm" margin-right="0.5cm"> <fo:region-body margin-top="1cm" margin-bottom="1cm"/> <fo:region-before margin-top="1cm" margin-bottom="1cm" extent="7cm"/> <fo:region-after margin-top="1cm" margin-bottom="1cm" extent="1cm"/> </fo:simple-page-master> </fo

left and center aligning in same line using XSL FO

☆樱花仙子☆ 提交于 2021-01-28 22:09:15
问题 I saw this in another post, <fo:block text-align-last="justify"> LEFT TEXT <fo:leader leader-pattern="space" /> RIGHT TEXT </fo:block> But i want the RIGHT TEXT to be aligned to center of the same line. I am using Apache FOP to generate PDF from xml. Any help would be appreciated! 回答1: Use a one row, three column table with column widths like 30-40-30 or whatever you need to accommodate the text widths. Put the content in the first two cells only and set the alignment on them to left and

Last block in flow body at the bottom on last page

ぐ巨炮叔叔 提交于 2021-01-27 23:36:32
问题 How can I have the last fo:block in fo:flow body aligned at the bottom of the last page? I do not mean footer section on each page, it is ok, but I want to have the last block in flow body at the bottom on last page. The content of flow body is diverse and I do not know, what will be the height of this last block section. Is it possible to do somehow? 回答1: If you are using AH Formatter, you could make the last block float to the bottom of the page. You may be able to put the last block inside

Need to disable an automatic URL hyperlinking with XSL-FO when generating a PDF document?

落爺英雄遲暮 提交于 2021-01-27 23:30:46
问题 I'm using Apache XSL-FO to generate a PDF document from an XML using XSLT. In my XSL file I have an fo:block where I bring a URL and simply display it like this: xsl:value-of select="company_info/website" My website always contains a valid URL for some company, starting with www.abc.com It seems like that by default anything with a www is being recognized as a URL and becomes linkable. It does not seem like I can force the link of that company to load in a new window, as it always loads the

XSL-FO fo:repeatable-page-master-alternatives not working properly

╄→尐↘猪︶ㄣ 提交于 2021-01-20 06:58:06
问题 I want to add the page number in footer if the number of pages is more than one, but not for if there is only one page. I tried the following code but it shows the page number in all cases : <fo:root xmlns:fo="http://www.w3.org/1999/XSL/Format"> <fo:layout-master-set> <fo:simple-page-master master-name="singlePage" page-height="800pt" page-width="612pt" margin-top="0pt" margin-bottom="46pt" margin-left="26pt" margin-right="26pt"> <fo:region-body margin-top="110pt" margin-bottom="65pt" /> <fo