RE: Alternate flows on odd and even pages
-Original Message- From: Roxana Constandes [mailto:[EMAIL PROTECTED] Sent: April 24, 2003 11:37 AM To: [EMAIL PROTECTED] Subject: Alternate flows on odd and even pages Hi All! I need to to alternate two different flows on odd and even pages. I know that is possible to alternate the static-content regions. But can I do it for region-body? I have to create two flows, one for odd pages and another one for even pages. Is it possible? Thanks in advance, Roxana No, you cannot do this directly with XSL-FO. What is your scenario? It may be possible to accomplish the task with a few extra steps. AHS - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Logging
-Original Message- From: Roland Neilands [mailto:[EMAIL PROTECTED] Sent: June 16, 2002 8:02 PM To: [EMAIL PROTECTED] Subject: RE: Logging check the website/docs, there is a logging available, also there is an example Again, great for embedding, but would be useful to have from the command line. Especially for debugging in Windows as anything more than ~20 lines output is lost. Depends on your version of Windows, and maybe even not so much at that, unless you've got something ancient. On Win2K I either set my console to 500 or 1000 lines, and/or redirect with stuff like C:\runsomecommand logfile.txt 21 On all versions of Windows going back to Win95, plus plain DOS, you've got the MODE command that you can set your columns and lines with. Check out http://www.computerhope.com/modehlp.htm. Just some thoughts. AHS
RE: Logging
-Original Message- From: Roland Neilands [mailto:[EMAIL PROTECTED] Sent: June 16, 2002 9:07 PM To: [EMAIL PROTECTED] Subject: RE: Logging [ SNIP ] The MODE command helps some, but won't go higher than 80 odd lines (no scrollback). I've tried redirection to file without success before but not 21 : this just threw up the FOP usage screen Don't know what to do with 2. I'll just keep debugging on UNIX if I need to. Yes, I mentioned the standard error redirection (or just redirection period) in case you had at least NT. I recall having had problems with just simple redirection with Win98. Another option is to run FOP from a decent text editor, like UltraEdit, where you can run DOS commands and executables, and capture the output. Yet another option is to get a better shell, like 4DOS/4NT. In the final analysis, though, if you've got UNIX handy, use that. :-) Arved Sandstrom
RE: Adding Fonts to userconfig...
-Original Message- From: Andrius Sabanas [mailto:[EMAIL PROTECTED] Sent: April 29, 2002 5:32 AM To: [EMAIL PROTECTED] Subject: Re: Adding Fonts to userconfig... J.Pietschmann wrote: [EMAIL PROTECTED] wrote: ... Any down side to changing the baseDire? Yes, it's global. You may run into problems with multithreaded servers. J.Pietschmann Hello, I would like to install 2 webapps with servlets using FOP on the same servlet engine. Both of them specify their own userconfig.xml files, but I do not use baseDir, rather get the absolute paths hardcoded. Now I wonder if I am going to get a conflict between those two. This design with static (magic) Options passing seems bizzare to me :-) But as I understand, separate webapps get loaded by separate classloaders, so is there any problem? Can anybody comment on this? The Servlet 2.3 specification is the first servlet spec to really have much to say about classloaders; sections 3.7 and 9.7 in particular. Most of the items are recommendations, not definite requirements. (I consider musts and shoulds to be definite requirements). In any case, there is nothing in the spec that says that each web application gets its own classloader. In fact even if all musts, shoulds and recommendations are satisfied you could still have one classloader for the servlet container and all web-apps; it's just that that single classloader has certain rules. The situation is akin to that of loading application classes when invoking Java on the command line. You might have class A in each of 2 separate JARs, and also loose in yet another location, all three of which are in your classpath. Do you expect each location to be serviced by its own classloader? No, likely not. It may be that the Tomcat reference implementation has separate classloaders for each webapp. If so, this would be a signal to other servlet container authors that even if that is not required (or suggested) by the spec, that it's a good idea. But in the interests of portability I wouldn't rely on this. I think we are trying to fix things up in terms of use of statics. I want to point out that when Fop was begun that there was no idea that people would want to run the thing inside a servlet; it was meant to be a command-line processor that ran in its own JVM and produced PDF files. Regards, AHS
RE: block question in multi columns area
Hi, Xavier Part of this I can speak about...when I put in an algorithm for column rebalancing (the equilibration you refer to, on other words) it was very crude, really nothing more than a placeholder. I meant to go back to it but never did, and as far as I know no one else has ever put in a better one. Your blocks have very little content, so it may not look like they break across columns. But that they already do. It's just that the break is not quite in the right place. I'll take a quick look and see if we can't do somewhat better than what we have at the moment. Regards, Arved Sandstrom -Original Message- From: Xavier DAMAY [mailto:[EMAIL PROTECTED] Sent: April 25, 2002 11:05 AM To: [EMAIL PROTECTED] Subject: block question in multi columns area Hello, I've got a presentation problem, when i use the block below in a two column body region. * I would like to equilibrate the two columns : Is it possible to force fop to cut a block to do that ? * I use blocks to simulate carriage return : Is there another solution ? * In the first sub-block (Le temps), I would like to place this piece of text lower than it does. It's placed in the top of the blue box, and I would like to place it in the middle. *I would like to have an italic and bold piece of text : what's the corresponding font-style ? fo:block font-size=10pt font-family=Times Roman line-height=14pt space-after.optimum=3pt text-align=justify background-color=white span=none fo:block background-color=darkblue text-align=center color=white font-size=20 LE TEMPS /fo:block fo:block font-style=italic text-align=left Bla bla bla bla /fo:block fo:block Bla bla bla bla /fo:block fo:block Bla bla bla bla /fo:block fo:block Bla bla bla bla /fo:block /fo:block I thank you for your help ! Xavier DAMAY
RE: Spaces and precedence
Joerg, it's the diagrams that accompany Section 4.2.5 that make things halfway understandable. They have an diagrammed example of each clause. There are also some key statements in the first paragraph of 4.2.5 - namely, that the definitions are recursive, and, that the entire point of the definitions is to identify areas that have only spaces between them. So actually I was also half-incorrect, because I spoke too hastily; with respect to the situation with _siblings_ and their space-after/space-before, the borders padding do _not_ have to have zero width. Even where borders and padding have non-zero width they may have a conditionality of discard, in which case under certain conditions they look like they have zero width for space-resolution purposes. Arved -Original Message- From: J.Pietschmann [mailto:[EMAIL PROTECTED] Sent: April 24, 2002 9:10 PM To: [EMAIL PROTECTED] Subject: Re: Spaces and precedence Arved Sandstrom wrote: Assuming Western reference-orienattion and writing mode, clause 3a of Section 4.2.5 indicates that if the border-after-width and padding-after of the first block are zero, and the border-before-width and padding-before of the second block are zero, that we have a block-stacking constraint. In which case the precedence on the space-fater of the one and the space-before of the other can be used precisely to achieve this collapsing effect. Thanks for the correction. I'll reread the spec again. J.Pietschmann
RE: Spaces and precedence
-Original Message- From: J.Pietschmann [mailto:[EMAIL PROTECTED] Sent: April 24, 2002 5:17 PM To: [EMAIL PROTECTED] Subject: Re: Spaces and precedence Ralf Steppacher wrote: I have a short question about spaces and precedences: What I want is to suppress additional space if one headline directly follows another. To achieve this I wrote the template with FOs below but it does not work (I played a bit with attributes and values and could not find any other working solution using precendences). Could anybody please tell me whether my FO is wrong or this is a limitation of FOP? After having read the spec several times, i got the impression that space-*.precedence is for prioritizing space reservations coming from stuff from the same area. Roughly: fo:block space-before=10pt precedence=1 fo:block space-before=5pt precedence=2 stuff ... will put stuff 5pt after preceding content. This means, precedence can't be used to collapse space-after and space-before of consecutive blocks. Assuming Western reference-orienattion and writing mode, clause 3a of Section 4.2.5 indicates that if the border-after-width and padding-after of the first block are zero, and the border-before-width and padding-before of the second block are zero, that we have a block-stacking constraint. In which case the precedence on the space-fater of the one and the space-before of the other can be used precisely to achieve this collapsing effect. Regards, Arved Sandstrom
RE: Spaces and precedence
-Original Message- From: Arved Sandstrom [mailto:[EMAIL PROTECTED] Sent: April 24, 2002 6:38 PM To: [EMAIL PROTECTED] Subject: RE: Spaces and precedence -Original Message- From: J.Pietschmann [mailto:[EMAIL PROTECTED] Sent: April 24, 2002 5:17 PM To: [EMAIL PROTECTED] Subject: Re: Spaces and precedence Ralf Steppacher wrote: I have a short question about spaces and precedences: What I want is to suppress additional space if one headline directly follows another. To achieve this I wrote the template with FOs below but it does not work (I played a bit with attributes and values and could not find any other working solution using precendences). Could anybody please tell me whether my FO is wrong or this is a limitation of FOP? After having read the spec several times, i got the impression that space-*.precedence is for prioritizing space reservations coming from stuff from the same area. Roughly: fo:block space-before=10pt precedence=1 fo:block space-before=5pt precedence=2 stuff ... will put stuff 5pt after preceding content. This means, precedence can't be used to collapse space-after and space-before of consecutive blocks. Assuming Western reference-orienattion and writing mode, clause 3a of Section 4.2.5 indicates that if the border-after-width and padding-after of the first block are zero, and the border-before-width and padding-before of the second block are zero, that we have a block-stacking constraint. In which case the precedence on the space-fater of the one and the space-before of the other can be used precisely to achieve this collapsing effect. Regards, Arved Sandstrom Read orientation and space-after :-) orienattion is one of my top mistyping words (like retrun), but fater is new. :-) Normally I don't have 2 in one post. Drives me nuts. AHS
RE: Omitting content length
Well, the alternative is chunked transfer-coding (which can be used on either the request or response payloads). This is completely defined by HTTP 1.1, and _must_ be accepted in both directions by HTTP 1.1 compliant apps, so if you send it to a recent IE browser it should know what to do with it. I assume. :-) In the context of servlet engines it doesn't make sense for a servlet to be aware that a _request_ was transfer-coded, whether chunked or anything else. The HTTP layer should handle this transparently. If it doesn't then it will probably choke before your servlet ever gets a chance at it (this is what should happen anyway). Going in the other direction one can only that the servlet engine/HTTP server combo will pick up on the fact that, at the instant that it must commit the response, it doesn't have a content-length, and will therefore switch over to chunked transfer coding, thereby keeping the connection open _and_ allowing you not to worry about calculating an overall content-length. I see from mailing lists that the Tomcat people were talking about chunked transfer coding for Tomcat 3.2/3.3 a year or more ago - do they have it properly implemented in 4.0 - I don't know. Worth checking out. If all else fails I'd suggest that your servlet do all the work itself, but my gut feeling is that if the servlet engine doesn't do chunked transfer coding anyway, it's hardly going to properly react to the fact that your servlet is doing it itself - it'll probably close the connection on you anyway after committing the first buffer. Hope that helps. Regards, AHS -Original Message- From: Brian O'Kelley [mailto:[EMAIL PROTECTED] Sent: April 15, 2002 7:25 PM To: [EMAIL PROTECTED] Subject: Omitting content length Ignore the question below - it works (if anyone needs SAX example, this is decent). It looks like what is happening is that I was writing this directly to a servlet's outputstream, so I never set the content length header. This made IE puke, although Lynx caught it ok. I've read through the threads about how IE handles content length header and requests the document twice. Is there any alternative to writing to a byte array to calculate the length before rewriting to the servlet's output stream? I'd like to avoid the memory consequences. Thanks, Brian -Original Message- From: Brian O'Kelley [mailto:[EMAIL PROTECTED] Sent: Monday, April 15, 2002 5:28 PM To: [EMAIL PROTECTED] Subject: FOP and SAX I'm trying to take an XML document, combine it with an XSL stylesheet, and spit it to PDF using SAX events, and I'm having trouble finding an example that works. Here's my code (using Fop 0.20.3): TransformerHandler tHandler = XSLTranslateFactory. getHandler(FopInput.xsl) ; // gets TransformerHandler from this file Driver fopDriver = new Driver() ; fopDriver.setRenderer(Driver.RENDER_PDF) ; fopDriver.setOutputStream(out) ; ContentHandler cHandler = driver.getContentHandler() ; XMLReader reader = XMLReaderFactory.createXMLReader() ; reader.setContentHandler(tHandler) ; reader.setProperty(http://xml.org/sax/properties/lexical-handler;, tHandler) ; tHandler.setResult(new SAXResult(cHandler)) ; reader.parse(source) ; Any ideas? Thanks, Brian
RE: table error
IPD is the handy abbreviation for inline-progression-dimension (well, it could also be for inline-progression-direction, but in this case it's the dimension. :-)) It's not mandatory to specify this on tables, as there is a default, so I don't know _why_ you are getting this message. Can you post the start tag for your offending table, complete with properties? Regards, Arved Sandstrom -Original Message- From: Norr, Peter [mailto:[EMAIL PROTECTED] Sent: April 5, 2002 11:47 AM To: '[EMAIL PROTECTED]' Subject: table error Doe anybody know what this means? ERROR 10180 [fop ] (): At least one of minimum, optimum, or maximum IPD must be specified on table. -- This message is intended only for the personal and confidential use of the designated recipient(s) named above. If you are not the intended recipient of this message you are hereby notified that any review, dissemination, distribution or copying of this message is strictly prohibited. This communication is for information purposes only and should not be regarded as an offer to sell or as a solicitation of an offer to buy any financial product, an official confirmation of any transaction, or as an official statement of Lehman Brothers. Email transmission cannot be guaranteed to be secure or error-free. Therefore, we do not represent that this information is complete or accurate and it should not be relied upon as such. All information is subject to change without notice.
RE: When a page is not a page
Here is the thing. XSLT and XSL-FO are independent. XSL-FO has no more special meaning to XSLT than does MathML or DocBook or SVG. XSLT understands its own elements (including extensions of course). It understands no others. fo:page-number/ (or as Ken Holman points out, page-number/ in the http://www.w3.org/1999/XSL/Format namespace, since we may assign any prefix we like, or none) is not acted on by the XSL-FO formatter to produce a number until after XSLT is done. Period. And note that fo:page-number/ never actually _is_ a number, and in fact the formatter is not required to even generate a stringified page-number. This is what the XSL Recommendation allows or does not allow you to do. If you feel that there is a compelling use case for being able to do what you want to do, I'd suggest writing it up and submitting it to the [EMAIL PROTECTED] list. Hope this clears things up. Regards, Arved Sandstrom -Original Message- From: Wayne Elliott [mailto:[EMAIL PROTECTED] Sent: March 29, 2002 10:15 PM To: [EMAIL PROTECTED] Subject: Re: When a page is not a page Thanks for the tips guys. However fo:page-number/ does not like being treated like a number, as it does not assign to a variable numerically. This was surprising. The following snippet fo:block space-after=5mm text-align=justify - fo:page-number/ - xsl:variable name=curpagefo:page-number//xsl:variable xsl:value-of select=$curpage/ - xsl:value-of select=$curpage * 2/ - xsl:value-of select=floor($curpage) * 2/ - xsl:value-of select=column-number/ - xsl:value-of select=(2 * $curpage) + 1/ - xsl:number/ /fo:block produces the following output On page (sheet) 1. - 1 - - NaN - NaN - - NaN - 1 On sheet 2. - 2 - - NaN - NaN - - NaN - 1 i.e On sheet n. - n - - NaN - NaN - - NaN - 1 Expected for sheet n was - n - n - 2n - 2n - 2n? - 2n+1- 1? Not sure why page-number behaves non-numerically. Perhaps it is something to do with the number formatting, e.g 1 = i = a etc. Perhaps there is a low level function that can extract the number part from fo:page-number? What I really need is a way of determining the number of the current column, based on column count and page number,but this also eludes me. WPE - Original Message - From: Matthew L. Avizinis [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Saturday, March 30, 2002 9:42 AM Subject: RE: When a page is not a page I believe this will not work as Wayne intends. Page numbers will be generated sequentially starting with the initial-page-number. So, this might work better: fo:page-sequence initial-page-number=0 then xsl:variable name=currentpagefo:page-number//xsl:variable then Then xsl:value-of select=(2 * $currentpage) + 1/ for the left page number and xsl:value-of select=(2 * $currentpage) + 2/ for the right page number hth, Matthew L. Avizinis mailto:[EMAIL PROTECTED] Gleim Publications, Inc. 4201 NW 95th Blvd. Gainesville, FL 32606 (352)-375-0772 ext. 101 www.gleim.com http://www.gleim.com -Original Message- From: David Wood [mailto:[EMAIL PROTECTED] Sent: Friday, March 29, 2002 8:03 PM To: [EMAIL PROTECTED]; [EMAIL PROTECTED] Subject: Re: When a page is not a page Just speculating, but have you tried putting the page-number element inside a variable? i.e.: xsl:variable name=currentpagefo:page-number//xsl:variable Then xsl:value-of select=$currentpage * 2/, etc... I haven't tried this, but it's just what pops into my head... -David At 08:44 AM 3/30/2002 +0800, Wayne Elliott wrote: A picture paints a thousand words... --- | ... : .. | | ... : .. | | ... : .. | | ... : .. | | ... : .. | | ... : .. | | ... : .. | | ... : .. | | ... : .. | | ... : .. | | ... : .. | | ... : .. | |1:2| --- The picture above represents a single sheet of A4 (Letter) paper. However it also represents two pages in a book, and if the page is folded down the dotted line it even starts to look like a book. My problem is this; I need the page number sequence as displayed in the picture - ie. 2 pages per page (sheet) I have no trouble laying out the text flow correctly using stuff like fo:simple-page-master master-name=content page-height={$pageheight}mm page-width={$pagewidth}mm margin-left={$marginleft}mm margin-right
RE: page intentionnally left blank
I am 95% certain that this did work once, and maybe it still does. I assume that you set up a simple-page-master for the express purpose of handling blank pages, and then used a page-sequence-master with a conditional-page-master-reference using blank-or-not-blank=true, that points at that simple-page-master? I can investigate this, this weekend, if it appears not to be working. Also, I believe it is not against the rules, or the spirit of the spec,in this case, to use a static-content that targets the region-body. The main thing about blank pages is that they are assigned no content from the fo:flow; in fact they may still make heavy use of static-contents. And we are used to using static-contents for the outside regions, which is their primary purpose, but this is not strictly speaking an absolute rule. So I may investigate this, too. Regards, AHS -Original Message-From: Rodolphe VAGNER [mailto:[EMAIL PROTECTED]Sent: March 28, 2002 7:31 AMTo: [EMAIL PROTECTED]Subject: page intentionnally left blank I would like to put the mention "page intentionnally left Blank" in every blank page forced bythe force-page-count="end-on-even" ; I tried to use a static-content but without any success ; Does someone know if it's possible with FOP, and how to do that ?
RE: Error
Apache mailing lists are populated by pretty friendly people. Like Ken said, not all of our mailboxes can easily absorb the hit of monster files and the download time for dialup folks is significant; that being said, you're reacting pretty well to the outcry and that'll stand you in good stead. :-) Small snippets of source (FO and/or XML + XSLT, up to complete files as long as they're not more than a few K in size) are cool. We welcome those because they help us reproduce problems. As far as the rest of the net etiquette goes, you may get pointed to various sources. All of them boil down to this - most of us are volunteers with real jobs doing other things, typically in software development. We have FAQs (Frequently Asked Questions) available, there are mailing list archives, there is the XSL specification, and there is the rest of the Web with lots of resources, so what we really like to see are well-posed questions that say: OK, I've tried this, and this, and this, already...here's where I'm at now, and here's the output showing what actually happened, and this is how it is different from what I expected...can you help? You do that and by and large, maybe not right away, we'll address your question. Cheerfully. Regards, Arved Sandstrom -Original Message- From: Woods, John T. [mailto:[EMAIL PROTECTED] Sent: March 20, 2002 8:08 PM To: '[EMAIL PROTECTED]' Subject: RE: Error To all the fop-users. I want to apologize for sending the large files over the internet. I am new to the whole user group thing and am learning how this net ettiquete works. Please accept my apologies and I look forward to working more profesionally with you guys in the future. :-) John Woods -Original Message- From: Arved Sandstrom [mailto:[EMAIL PROTECTED] Sent: Wednesday, March 20, 2002 2:12 PM To: [EMAIL PROTECTED] Subject: RE: Error Hey, Ken, those of us on _cable_ connections aren't exactly impressed by giant emails either. :-) Arved -Original Message- From: G. Ken Holman [mailto:[EMAIL PROTECTED] Sent: March 20, 2002 12:37 PM To: [EMAIL PROTECTED] Subject: Re: Error Would you please *stop* sending 1Mb files over email? Those of us on dial-up connections and small ISP mail boxes can really get burned and it isn't netiquette to almost wipe us out with repeated mailings of this size. Thanks. . Ken
RE: Error
Hey, Ken, those of us on _cable_ connections aren't exactly impressed by giant emails either. :-) Arved -Original Message- From: G. Ken Holman [mailto:[EMAIL PROTECTED] Sent: March 20, 2002 12:37 PM To: [EMAIL PROTECTED] Subject: Re: Error Would you please *stop* sending 1Mb files over email? Those of us on dial-up connections and small ISP mail boxes can really get burned and it isn't netiquette to almost wipe us out with repeated mailings of this size. Thanks. . Ken
RE: Different footers for one fo:page-sequence/
Yes, absolutely. Different headers, footers, sidebars, it doesn't matter. Same fo:flow, it doesn't matter. As long as the use of a page-sequence-master ensures that a given page is pointed at a specific page-master, the regions in _that_ page-master are used. It is the mapping between the region-names (which can be arbitrary, with certain loose constraints) in that selected page-master, and the flow-names in various static-contents in the page-sequence that contains your flow, that allow you to have different content. Regards, AHS -Original Message- From: Peter Velichko [mailto:[EMAIL PROTECTED] Sent: March 12, 2002 6:21 AM To: [EMAIL PROTECTED] Subject: RE: Different footers for one fo:page-sequence/ Is it possible to give different content to headers for different simple-page-masters of one fo:flow/? -Original Message- From: Arved Sandstrom [mailto:[EMAIL PROTECTED] Sent: Tuesday, March 12, 2002 1:36 AM To: [EMAIL PROTECTED] Subject: RE: Different footers for one fo:page-sequence/ Provided that different simple-page-masters are being used for the pages that are intended to have different footers, prepare the various static-contents that you'll need, and give them different names that map to corresponding region-after's in your various page-masters. Regards, AHS -Original Message- From: Peter Velichko [mailto:[EMAIL PROTECTED] Sent: March 11, 2002 10:44 AM To: [EMAIL PROTECTED] Subject: Different footers for one fo:page-sequence/ Hi! Please advise how can I use footers of different size and content for one fo:page-sequence/? Many thanks in advance Peter Velichko
RE: page sequence of different last page and rest pages
Right now (unless someone snuck it in) last as a value for page-position is not implemented. The reason is, it's not so easy to do for the general case. For example, you can fairly easily imagine simple-page-masters for rest and last that put the processor into an infinite loop if the strategy is to redo the last page of content with last when the end of flow is detected when laying out with rest. So the algorithm needs be more sophisticated. Keiron and Karen's rewrite may give us more options to look ahead and make it easier to handle this situation. Hope this explains what's going on. Sorry I couldn't tell you that the feature exists. Regards, Arved Sandstrom -Original Message- From: Peter Velichko [mailto:[EMAIL PROTECTED] Sent: March 11, 2002 3:07 PM To: [EMAIL PROTECTED] Subject: page sequence of different last page and rest pages Hi! Please suggest how can I create page sequence of different last page and rest pages with FOP 0.20.3. The following code ship is not work correctly unfortunately :( fo:page-sequence-master master-name=my-sequence fo:repeatable-page-master-alternatives fo:conditional-page-master-reference page-position=first master-reference=common_page/ fo:conditional-page-master-reference page-position=rest master-reference=common_page/ fo:conditional-page-master-reference page-position=last master-reference=last_page/ /fo:repeatable-page-master-alternatives /fo:page-sequence-master Thank you in advance Peter Velichko
RE: Different footers for one fo:page-sequence/
Provided that different simple-page-masters are being used for the pages that are intended to have different footers, prepare the various static-contents that you'll need, and give them different names that map to corresponding region-after's in your various page-masters. Regards, AHS -Original Message- From: Peter Velichko [mailto:[EMAIL PROTECTED] Sent: March 11, 2002 10:44 AM To: [EMAIL PROTECTED] Subject: Different footers for one fo:page-sequence/ Hi! Please advise how can I use footers of different size and content for one fo:page-sequence/? Many thanks in advance Peter Velichko
RE: XMLSpy - FOP
-Original Message- From: Savino, Matt C [mailto:[EMAIL PROTECTED] Sent: February 28, 2002 3:20 PM To: '[EMAIL PROTECTED]' Subject: RE: XMLSpy - FOP Arved, I'd love to help out with the Perl prototyping if you have any pieces that make sense to break off. I hear you about the UML. I think on some projects it's more about control than functional necessity. [ SNIP ] -End Of Original Message- Anyone who has interest should track the mailing list for that project, which is available off the project page: https://sourceforge.net/projects/xslfo-proc/. I can think of some stuff already, which is best discussed there. If you need a break from Java and just want to get back into Perl or C, you're welcome. Also, this is an opportunity to come up to speed with XSL implementation while waiting for the FOP redesign to reach a less critical stage. If it's an either/or situation please stick with FOP and try to help out with the maintenance branch. Regards, AHS
RE: XMLSpy - FOP
-Original Message- From: Savino, Matt C [mailto:[EMAIL PROTECTED] Sent: February 27, 2002 9:15 PM To: '[EMAIL PROTECTED]' Subject: RE: XMLSpy - FOP Thanks Peter. I'm really glad to hear some positive news about the redesign! I'll try to get on that list and check out the code. I like reading Perl, it's therapeutic when you have to deal with Java all day long. I'm sure FOP is a very tough problem. I regretted the tone of that last email as soon as I spit it out. I'm just not having a very great day. I know from watching the fop-dev list for the last year or so that all the active players on FOP are very concientious, hard-working and know what they're doing. Maybe you can look at my little outburst as a rare window into the frustrations that some of the end users are feeling but have the tact to withhold. [ SNIP ] -End Of Original Message- Hi, Matt Let me clarify. The redesign is what Keiron Karen (primarily) are working on. It is a redesign for FOP. What I started last fall is another project, which is intended to produce a C/C++ XSL-FO formatter. This is called xslfo-proc, and is on Sourceforge. I had a number of reasons for diverting my energies from FOP, and they had to do with limited free time last summer (due to intense real work) and a general burnout with how complicated FOP had gotten. xslfo-proc got off to a slow start, mainly because the company I was working for in real life went bust in October, and it's only this month that I got back into it. I did enough UML design last fall to realise that that was a waste of time. So a month ago I started working on a Perl prototype. I uploaded the first code yesterday but please don't expect this to actually be doing any layout yet. There is a lot there already, though, and at my current pace I expect to have some pretty good layout happening within a month. I have no intentions of abandoning FOP, but the redesign for FOP was and is critical, and only so many people can usefully do that - two max, IMO. When the redesign started I was out of the loop, so now I am waiting like everyone else. In the meantime I am devoting most of my efforts to xslfo-proc - it has a different approach and I hope it complements FOP rather than competes with it. My intention further down the road is to fold it back into Apache when the codebase is mature, there is a community built up around it, and the time is right. I'll second one specific comment of Peter's very strongly. I also believe that an XSL formatter project that is going to succeed has to tackle the whole problem. Formatting is not very modular, in other words. Not everything needs to be implemented right away but it sure needs to be considered, and a place for everything needs to be built in. The existing FOP shows us that retrofitting doesn't work. I'll welcome your interest in the xslfo-proc project if you feel like a break from Java. I don't mind admitting that since I work with Java every day in real life that the opportunity to get back to Perl (and C down the road) was not an unpleasant thought. :-) Regards, Arved
RE: region boundaries
Comments below. -Original Message- From: Alexandre Denes dos Santos [mailto:[EMAIL PROTECTED] Sent: February 27, 2002 11:02 AM To: [EMAIL PROTECTED] Subject: region boundaries Hi all, I'm having a problem with regions. In the simplecol4 example, I changed the page layout as showed above: fo:layout-master-set !-- layout for the first page -- fo:simple-page-master master-name=only page-height=29.7cm page-width=21cm margin-top=3cm margin-bottom=2cm margin-left=2.5cm margin-right=2.5cm fo:region-body margin-top=1cm margin-bottom=1cm column-count=3 column-gap=0.15in/ fo:region-before extent=4cm/ fo:region-after extent=4cm/ /fo:simple-page-master /fo:layout-master-set The remaining of the example is the same. When I print the page using acroread, all the margins are ok, but the body overlapped the before and after regions (the init of the body is at 1.5cm from the top margin and 1cm from the bottom margin). The text of the after region was printed four lines before the end of the body region, like a watermark. In my understanding, the extent of the region-after and region-before is the length of the region, and the region-body should use all the remaining space in the center (something like the BorderLayout in Java). Is this correct? Can someone tell me how the extent works and how can I define a static length for the before and after regions? Thanks in advance Denes * Because of the margings on the page-master, you effectively have a working area of height (29.7cm - 3cm - 2cm) = 24.7cm, and a width of (21cm - 2.5cm - 2.5cm) = 16cm. There are no changes made to reference-orientation, so the margin directions on the *region-body* correspond to the page-master directions. As a result, the region-body (which does _not_ use all the remaining space in the centre) is inset 1cm from the top, 1cm from the bottom, and 0cm from both left and right, ending up with a height (also block-progression-dimension in this case, with the default 'paginate' 'overflow' settings) of (24.7cm - 1cm - 1cm) = 22.7cm, and a width (also inline-progression-dimension) of 16cm. The before after regions will overlap by 3cm because the extents on the outside regions, AND the margins on the region-body, are both measured from the edges of the content-rectangle of the page: the 24.7cm x 16cm rectangle. If you set the margin-top and margin-bottom on the region-body to 5cm you would have 1cm clearance. In which case the region-body height would be 14.7cm. AHS
RE: markers
Interesting...I didn't realise that that much was still functional. :-) I will have to revisit and see what the scope of potential fixes is. AHS -Original Message- From: Chuck Paussa [mailto:[EMAIL PROTECTED] Sent: February 27, 2002 12:48 PM To: [EMAIL PROTECTED] Subject: Re: markers Hi Bart, I've done some playing with markers also and gotten them to work pretty well. One of the things I've noticed is that FOP complains mightily about both fo:marker must be an initial child and marker-class-name' must be unique for same parent.but, they are recoverable errors and can be ignored. Here's an XML and XSL to demonstrate the capabilities. Notice that I place a marker at the beginning and end of each marked block (That's strictly illegal! But it works) I also have placed an x in the illegal marker contents so you can see the illegal retrieval. I do that so that the functions first-including-carryover and last-ending-within-page will work. Arved did a great job of implementing markers, you just have to break the rules for now (and be prepared to unbreak the rules when FOP has a correct implementation) fop -xsl dictionary.xsl -xml dictionary.xml -pdf dictionary.pdf Chuck
RE: region boundaries
The margins on the region-body define only the insets of the edges of the region-body from the edges of the page content rectangle. The dimensions of the outside regions, perpendicular to the edges, are defined by the extent value. If we have this SPM: fo:simple-page-master master-name=only page-height=29.7cm page-width=21cm margin-top=3cm margin-bottom=2cm margin-left=2.5cm margin-right=2.5cm fo:region-body margin-top=5cm margin-bottom=5cm column-count=3 column-gap=0.15in/ fo:region-before extent=4cm/ fo:region-after extent=4cm/ /fo:simple-page-master then we end up with a layout like I picture in the attached figure. Regards, AHS -Original Message- From: Alexandre Denes dos Santos [mailto:[EMAIL PROTECTED] Sent: February 27, 2002 1:39 PM To: [EMAIL PROTECTED] Subject: Re: region boundaries Thanks to Arved Sandstrom for the explanation. I have only one more question: if the extention of the region-before is defined by the magin-top extention of the region body, what is the use of the parameter extent in the declaration of the region-before? It´s just for clipping? Denes - Original Message - From: Arved Sandstrom [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Wednesday, February 27, 2002 12:27 PM Subject: RE: region boundaries Comments below. -Original Message- From: Alexandre Denes dos Santos [mailto:[EMAIL PROTECTED] Sent: February 27, 2002 11:02 AM To: [EMAIL PROTECTED] Subject: region boundaries Hi all, I'm having a problem with regions. In the simplecol4 example, I changed the page layout as showed above: fo:layout-master-set !-- layout for the first page -- fo:simple-page-master master-name=only page-height=29.7cm page-width=21cm margin-top=3cm margin-bottom=2cm margin-left=2.5cm margin-right=2.5cm fo:region-body margin-top=1cm margin-bottom=1cm column-count=3 column-gap=0.15in/ fo:region-before extent=4cm/ fo:region-after extent=4cm/ /fo:simple-page-master /fo:layout-master-set The remaining of the example is the same. When I print the page using acroread, all the margins are ok, but the body overlapped the before and after regions (the init of the body is at 1.5cm from the top margin and 1cm from the bottom margin). The text of the after region was printed four lines before the end of the body region, like a watermark. In my understanding, the extent of the region-after and region-before is the length of the region, and the region-body should use all the remaining space in the center (something like the BorderLayout in Java). Is this correct? Can someone tell me how the extent works and how can I define a static length for the before and after regions? Thanks in advance Denes * Because of the margings on the page-master, you effectively have a working area of height (29.7cm - 3cm - 2cm) = 24.7cm, and a width of (21cm - 2.5cm - 2.5cm) = 16cm. There are no changes made to reference-orientation, so the margin directions on the *region-body* correspond to the page-master directions. As a result, the region-body (which does _not_ use all the remaining space in the centre) is inset 1cm from the top, 1cm from the bottom, and 0cm from both left and right, ending up with a height (also block-progression-dimension in this case, with the default 'paginate' 'overflow' settings) of (24.7cm - 1cm - 1cm) = 22.7cm, and a width (also inline-progression-dimension) of 16cm. The before after regions will overlap by 3cm because the extents on the outside regions, AND the margins on the region-body, are both measured from the edges of the content-rectangle of the page: the 24.7cm x 16cm rectangle. If you set the margin-top and margin-bottom on the region-body to 5cm you would have 1cm clearance. In which case the region-body height would be 14.7cm. AHS attachment: spm1.jpg
RE: Classpath in jar
-Original Message- From: Magnus Rydin [mailto:[EMAIL PROTECTED] Sent: February 26, 2002 7:30 AM To: [EMAIL PROTECTED] Subject: Classpath in jar Dear group, Could someone please tell me why the FOP helper jar:s are hardcoded to reside in a lib/ directory under the fop.jar ? This makes it extremely icky to use FOP in a J2EE container without manually fixing the classpath entries. WR *** FOP started as a standalone. The original directory structure was pretty spare, and original numbers of helper JARs were low (things like xp.jar and xt.jar). At some point we decided to package as extra JARs showed up. So lib/ appeared. CVS tells me that the addition of the Ant manifest task was about 11 months ago, and I think this is where your issue started. I guess you are referring to the dependency declarations in the fop.jar MANIFEST.MF. There is nothing else hardcoded that I am aware of, not in your sense of hardcode. This has not come up as a problem much elsewhere, but I can see where this would be causing Orion problems (or other J2EE servers for that matter). Any suggestions? Our requirements are that FOP works as a standalone, which it clearly can without resorting to the extension mechanism, and also can be used as a servlet. I don't think a huge amount of thought went into using this mechanism in FOP, across all possible deployment scenarios, so I'll be happy to listen to change requests. As I say, however it is being used, either standalone or as a servlet, this extension mechanism problem has not cropped up much, but that's not to say it's not a problem the way we have it set up. Regards, Arved Sandstrom
RE: markers
Hi, Bart I took markers up to a certain point last summer. I didn't have the property re-parenting happening yet, but in terms of retrieving the right marker probably about half the retrieve-position/retrieve-boundary combos were already functional. The example file glossary.xml stems from that period. We had an injection of code just about that time that was generally held to be higher priority, including by me, and this broke the partial marker support. I don't think anything has happened since, and so you are probably seeing the effects of this, not doing anything wrong in your FO. I am loathe to invest any effort in marker support in the maintenance branch, unless Karen and/or Keiron were to indicate that they do not expect functional markers in the rewrite for at least another 3 months (by which I mean I'd be happy to actually write that code if they indicate that I could reasonably expect to be doing so within 3 months). If it looks like there won't be any markers in the rewrite for quite a while then I'd be happy to look at getting them back into the maintenance branch because it wouldn't be wasted effort. Regards, Arved Sandstrom -Original Message- From: Bart Locanthi [mailto:[EMAIL PROTECTED] Sent: February 26, 2002 7:26 PM To: [EMAIL PROTECTED] Subject: markers does fop support markers? i'm having trouble getting them to work. my input looks like ... fo:flow fo:block fo:block fo:marker marker-class-name=chapchapter one/fo:marker ... /fo:block /fo:block fo:block fo:block fo:marker marker-class-name=chapchapter two/fo:marker ... note that the markers share a common great-grandparent. the error message i get from any fop-0.20.[23] is: [ERROR]: fo:marker must be an initial child,and 'marker-class-name' must be unique for same parent. i'm following all the rules, i think, but no joy. sounds like a simple misconception on my part but i'm stumped.
RE: individual character in symbol font?
Youd would have one template that picks up element, as in xsl:template match=element fo:block xsl:apply-templates/ /fo:block /xsl:template and then if you supply another for greek it will get picked up as necessary: xsl:template match=greek fo:character character={.}/ /xsl:template Regards, AHS -Original Message- From: Stephen Clarke [mailto:[EMAIL PROTECTED] Sent: February 22, 2002 1:37 AM To: [EMAIL PROTECTED] Subject: Re: individual character in symbol font? - Original Message - From: Arved Sandstrom [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Friday, February 22, 2002 3:15 AM Subject: RE: individual character in symbol font? Ideally, and I don't think FOP does this yet, this is what font-selection-strategy (and other font properties) are for. In practical terms this really comes down to specifying your font-family property in such a way that when the processor sees that character (the Greek character), it makes its first glyph match using the Symbol font. Hi Arved, Thanks for the reply. Failing that you have to do a workaround at the moment of the kind you suggest. Doing the greekS/greek kind of thing is probably easiest; your XSLT template can turn that into an fo:character. OK. Good. But you wouldn't believe how stoopid I am. I don't even know the xsl to turn elementNon equidem insector delendave carmina Livi esse reor, memini quae plagosum mihi parvo Orbilium dictare; greekS/greeksed emendata videri pulchraque et exactis minimum distantia miror. Inter quae verbum emicuit si forte decorum, et si versus paulo concinnior unus et alter, venditque poema./element into fo:blockNon equidem insector delendave carmina Livi esse reor, memini quae plagosum mihi parvo Orbilium dictare; fo:character character=S font-family=Symbol/sed emendata videri pulchraque et exactis minimum distantia miror. Inter quae verbum emicuit si forte decorum, et si versus paulo concinnior unus et alter, venditque poema./element Do you happen to know what would be the xsl:fo to do that? There must be a way but i can't think what it is. {:-( let's see... fo:blockxsl:value-of select=elementxsl:apply-templates select=greek//xsl:value-of/fo:block .. would that be it. But I don't think it would even parse. Can see where I'm at with this? {:-( Grateful for any further assistance. -- Best, Stephen
Re: Columns
At 01:41 PM 10/4/01 +0200, Sam Prokop wrote: Hi folks, I´ve got the following Problem, i want to create a page, that has a different number of columns, for example it starts with 2 columns than only one and than 4. But i can only define columns in region-body and there can be only one region-body in a simple-page-master. I don´t want to give an absolute value for the height of the multicolumn-block. So is there another way to do multicolumns? If you are relying on 'column-count' on 'region-body', no, you are stuck with that one figure, as you surmised. This is an XSL limitation. So on one page you can have areas with one column and 'column-count' columns, depending on how you set 'span', but that is it - 2 choices. You might be able to do something clever if you also introduce tables. Regards, Arved Sandstrom Fairly Senior Software Type e-plicity (http://www.e-plicity.com) Wireless * B2B * J2EE * XML --- Halifax, Nova Scotia
Test #0
Do I need to moderate these damned things? Fairly Senior Software Type e-plicity (http://www.e-plicity.com) Wireless * B2B * J2EE * XML --- Halifax, Nova Scotia