We implemented the spacialized attribute fostyle to carry this information.
Because the browser just ignores this, you must be careful to structure it correctly for processing.
The proper structure is name: value; noting that the ":" after name is followed
by a space and the ";" between items is also followed by a space.
In some instances you may wish to pass through XSL FO attributes that are not
supported in HTML. This is an example, while the text in the HTML has a brown color
applied, we have applied a CMYK color for the PDF generation through the use of the
fostyle attribute. All fostyle attributes are applied
after HTML css and also after direct attributes and override those in the HTML. This
paragraph also has text-align justify in the HTML and font-stretch,
font-size-adjust and hyphenate in the PDF output. The fostyle attribute
is attached right in the HTML, just like style and uses the same
structure internally as style.
The code for the paragraph above looks like this:
<p style="color: brown; text-align:justify;"
fostyle="text-align-last: left;
font-stretch: wider;
font-size-adjust: 0.6;
hyphenate: true;
color: rgb-icc (255, 255, 0, #CMYK, .1, .2, .7, .5);">In some instances ...
Another common use for passing through custom elements is for properties that have specific meaning in a pagination situation like "keeps". There are several forms of keeps that can help you organize content so it is glued together as you like it.
The following are the most commonly used keeps:
keep-together.within-page: set to "always" and used to keep a block
of content always together in a single pagekeep-with-next.within-page: set to "always" and used to keep a
block of content glued to the next one always together in a single pagekeep-with-previous.within-page: set to "always" and used to keep a
block of content glued to the previous one always together in a single pagekeep-together.within-line: set to "always" and used to keep a span
of content glued always together in a single lineThe following shows some demonstrations of these capabilities.
This paragraph, the instructions and the following three para's of LoremIpsum
text are surrounded by a <div> with
keep-together.within-page as always, like
this:
<div fostyle="keep-together.within-page: always;">
<p>This paragraph, the instructions and the following five para's of LoremIpsum text are surrounded
by a <div> with "keep-together.within-page" as "always", like this:</p>...Tempor lorem nonummy ipsum eos et et. Consetetur at et dignissim consetetur dignissim congue accusam sit takimata ut ea et duo elitr amet tempor duo. Sea congue ut iriure veniam amet et dolore veniam dolor sit takimata. Elitr diam aliquam. Duo justo elitr nulla erat justo est autem magna clita vel dolor feugiat diam vel. Volutpat facilisi ut at facilisis et consetetur diam ut tempor vero lorem sit laoreet eos kasd ipsum magna dolore. Elitr sed accumsan nibh erat. Nonummy eirmod qui vero aliquyam.
Sit duis dolor est sed consectetuer rebum voluptua ea sanctus illum rebum. Vel sed nonumy est est nobis clita consequat rebum ut duo consetetur eos ea elitr kasd diam veniam takimata. Ea enim erat nisl sanctus sanctus. Dolor dolore sed nisl nonumy lorem et et facer vel lorem. Ipsum nulla et lorem justo duo gubergren vero ad. Rebum accusam laoreet feugiat facilisis dolores rebum kasd duo ipsum ipsum ut. Et consequat eos erat delenit ipsum amet accusam vel erat elitr elitr voluptua labore.
Nonumy sit dolor lorem lorem duo diam sed sed aliquip clita dolor facilisis. Amet euismod rebum labore rebum et feugiat accusam delenit et dolore sit ipsum tincidunt. Vel eirmod amet labore dolor sed erat illum invidunt. Dolor wisi erat praesent. Diam autem in elitr. Dolor congue elitr et dolor clita. Ad odio et lorem. Imperdiet erat sadipscing sit ipsum duo consetetur ipsum quis sanctus. Diam clita clita invidunt iusto ut ipsum ut sadipscing sanctus aliquyam lorem eirmod amet facilisis ut esse dolor. Stet ipsum delenit dolore justo dolores magna nonummy tation nulla diam consetetur labore dolor lobortis duo nulla sed doming. Clita et magna sanctus consectetuer minim aliquyam est est wisi magna aliquyam dolor suscipit in vero dolor.
Invidunt et sed voluptua nonumy eum clita eum diam soluta sed accusam vero sed. Sadipscing sadipscing et nulla. Labore tempor labore et sed. Voluptua eros vel dolor nonummy elitr consetetur dolore nostrud sed et tempor kasd. Magna labore at labore nulla vel lorem sed et veniam amet accusam invidunt. Erat lorem et sanctus ut. Lorem clita stet diam accusam tempor diam magna sit takimata kasd sit kasd magna ipsum tempor amet elit quis.
Lorem sed aliquyam sit consetetur sanctus magna enim quis erat. Elitr diam vero ut. Tation amet et odio et sea nulla cum labore. Lorem sit ullamcorper esse sit kasd placerat facilisis est sed in invidunt imperdiet et. Et sed sed et. Velit takimata stet lorem esse aliquyam takimata vulputate lorem sed justo amet consectetuer et aliquip zzril sea. Diam dolor sit stet et consetetur elitr. Ipsum suscipit ut lobortis magna nonummy et elitr odio autem accusam accusam sit facilisi cum. Vel rebum et aliquyam dolor augue.
Thus all of this content from the header through this paragraph is together on a single page.
A common practice in print documents is keeping together headings and some of the following lines of a paragraph so no heading is orphaned at bottom of a page and at least a few lines of text from any paragraph stay together.
What follows this are a series of headings and LoremIpsum paragraphs. The headings all have "keep-with-next.within-page" as "always" which will at least glue them to the paragraph. The paragraphs all have widows of "3" and orphans of "3" which will attempt to glue together at least three lines of paragraph at the bottom and top of any page. The LoremIpsum paragraphs are randomly generated on refresh of the page so you can test various layouts just by refresing and printing again.
Elitr vero amet ad et laoreet tempor ipsum eum aliquip sea labore lorem et. Vero vero nulla sit qui amet tempor molestie molestie. Ut sed est. Sit dignissim takimata elitr stet et sanctus sadipscing dolor et aliquyam gubergren enim sadipscing volutpat et. Blandit amet cum dolor sanctus sea sit clita et sanctus sit lorem. Sed commodo et eleifend luptatum vel ipsum sed.
Tempor magna et veniam et no autem diam eirmod. Elit amet nostrud et diam feugait eum takimata aliquyam gubergren kasd lorem consetetur lorem. Eleifend at duo nibh vel sed erat. Dolor eu dolores. Zzril ut ipsum nulla sed consequat in est diam eirmod nonummy gubergren elitr invidunt amet consetetur id. Illum tempor dolores et consequat magna sed et ut rebum dolore sit sea esse takimata.
Eos sed velit lorem velit ipsum lorem justo dolore dolore in ut illum et labore eos diam dolor veniam. Ea ut accusam. Elitr aliquyam at dolor facilisi option elitr ipsum blandit est voluptua ut no voluptua. Labore sit sit diam amet consequat labore duo rebum sit sed feugiat in ut eos amet aliquyam. Eirmod at suscipit no. Magna stet nonumy. Enim elit diam invidunt rebum consectetuer duo. Ea duo stet iusto dolore takimata stet stet et. Duo justo consetetur no nonumy et te et.
In est amet diam gubergren stet dolore takimata tempor ea amet amet. Sit et vel voluptua labore gubergren molestie. Autem doming ipsum amet possim stet eirmod lorem kasd voluptua. Dolore dolor tempor eos duo invidunt nihil ipsum possim vulputate voluptua est sit. Nonummy ipsum eum voluptua sed voluptua diam ipsum sadipscing lorem no dolore dolore esse duo ipsum consequat diam nonumy. Rebum gubergren no tation rebum exerci ut duis consetetur accusam justo diam diam et sea ea amet.
Justo rebum nihil. Nonumy laoreet justo lorem sea ipsum in at eirmod et takimata. Est sanctus ut kasd eleifend dignissim et sea eos stet ex elitr gubergren eum lorem lorem dolores takimata ipsum. Molestie takimata lorem ut dolor est augue rebum labore diam invidunt takimata labore stet dolore. No tempor eirmod delenit ipsum diam magna voluptua duo diam eum clita amet esse eos facilisis stet eu quod. Ut lorem dolore duis sea dolor invidunt no vero duis nulla. Sadipscing consetetur consetetur dolor. Diam gubergren amet vel consetetur dolores ad facilisis dolor et wisi vero. Minim commodo vulputate vero at no dolor sed lorem.
Accusam eirmod takimata aliquam doming dolor ut id at tempor eos diam et lorem laoreet et ex dolores dolor. Velit dolor et labore at eu invidunt. Labore sit imperdiet duo aliquyam at ut amet no ipsum labore eu ut vero ipsum vulputate diam. Nonumy accusam dolores diam et at et dolor ipsum est et eos feugait et praesent. Kasd aliquyam no sanctus diam sed. Eum vero ullamcorper et sea eu clita lorem veniam amet option. Et amet takimata ipsum laoreet ut et est justo facilisis ut et dolores magna justo nonummy. Magna labore ut. Facer erat ipsum no sed vero ea at duo magna erat amet at ipsum. Est duis tempor accusam consetetur tempor aliquyam dolores eirmod ut ea diam ipsum minim blandit et gubergren enim.
Ea est hendrerit eos dolor dolor zzril ut sed. Tempor sadipscing rebum stet gubergren diam sed dolor suscipit voluptua gubergren aliquip ea at no dolor ipsum nonummy. Sed duo duis dolor elitr et amet kasd accumsan diam sadipscing facer sit voluptua magna. Eos eu voluptua aliquyam no dolor sed. Amet molestie sed diam augue.
Molestie eirmod et nonummy eirmod nostrud sit accusam eirmod kasd consetetur dolor invidunt. Aliquip ea euismod et labore ipsum rebum feugait nonumy est voluptua est sea nonumy nulla. Gubergren zzril ea dolor no nisl aliquyam no. Rebum at clita et nonumy tempor eos. Accumsan et et adipiscing facilisi dolore lorem nobis vero ipsum.
Dolores justo amet consetetur option blandit imperdiet tempor at at dolor labore lorem et. Vero molestie sit consetetur duo amet nulla justo dolor sea eirmod blandit invidunt dolore diam ut aliquip ipsum at. Consetetur diam dolores sea. Nulla sit accusam et magna vel clita. Gubergren nulla rebum vero ipsum consetetur consetetur no consectetuer laoreet invidunt te et kasd eirmod.
Wisi eleifend eos doming voluptua sit et euismod ut sed et dolore ut et diam. Consequat te consequat dolor clita luptatum at zzril. Nonummy eos magna luptatum sadipscing ipsum takimata. Kasd labore invidunt sit nulla illum duis minim rebum qui amet kasd ut ea takimata delenit et sit luptatum. Sit sit rebum at et elitr gubergren elitr diam clita at sit consetetur enim vero magna. Takimata in kasd dolor illum ad dolor no labore ipsum at gubergren illum feugait. Et invidunt sanctus duis dignissim euismod eos ea sit voluptua vero dolor. Velit duo sed diam voluptua consetetur et tation vulputate duo dolores delenit dolores et. Iriure assum at vulputate invidunt rebum delenit at no voluptua erat exerci. At in autem duis ipsum ex justo.