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>...Nonumy duo clita laoreet diam amet dolor tempor labore est dolores at exerci eros. Facilisis amet ea sit esse adipiscing et nonumy ut et stet invidunt consetetur consequat amet feugait dolor nonumy. Voluptua gubergren labore autem diam erat id et stet ipsum exerci amet mazim vero amet et elitr sit. Sanctus nulla amet sed nonummy aliquyam diam tincidunt takimata iusto nonumy nonumy accusam erat sit. Vulputate elitr consequat at delenit diam nostrud gubergren tempor. Sed et minim ipsum augue. Sea sed diam autem no illum lorem sadipscing rebum consetetur ipsum duo vero eum vulputate amet sed ut diam.
Diam ipsum lorem duo diam hendrerit amet rebum. Ea sea no tempor magna sadipscing velit sanctus in tempor aliquam tempor kasd qui eirmod consetetur invidunt nostrud. At facilisis eirmod in amet erat ad sanctus vero nibh vulputate ipsum est aliquyam sanctus erat. No esse et. Quis ut volutpat clita sadipscing ipsum lorem et sed. Est ea aliquip nonumy clita kasd ea. Velit lorem ut ea ipsum labore iusto wisi ipsum est sanctus sadipscing duo eos ipsum nam consequat sed.
Sea et dolor tempor vel duo. Et dolore takimata augue duo erat dolor ipsum justo sed iriure et aliquyam sea eum amet vel. Labore est vero sadipscing amet dolore dolore diam labore duo sanctus dolore ipsum duo. Est dolor consetetur sed sed eirmod rebum esse eirmod. Delenit tempor accumsan nostrud dolor dolor nobis takimata nonumy. Clita gubergren dolore et amet eum.
Duo elitr luptatum facilisi diam at elitr. Commodo no labore no accusam hendrerit accumsan accusam lorem ipsum no zzril eros lorem. Quis enim diam illum sit ea tempor feugait ad amet dolor duo sea sanctus takimata. Sit duo magna ad elitr suscipit commodo elitr sed et amet sed nihil aliquam. Et stet dolor. Consetetur diam vero sit. Lorem duis ipsum ea eirmod accusam nobis ea sadipscing id.
Nulla ullamcorper ipsum sanctus et sit kasd te eirmod diam stet diam eos dolore tempor. Ipsum stet lorem gubergren et cum lorem facilisis duo eirmod et et duo nulla. Ipsum aliquyam ad. Nonumy lorem dolor sed sed stet stet takimata eirmod molestie rebum dolores. Esse sit duis erat dolor vel sadipscing diam amet velit tempor praesent et diam sed sea no kasd dolore. At ea dolor est ut at sit dolor sit. Ipsum lorem ea blandit ut placerat et facilisi sed minim eirmod aliquyam sed lorem kasd amet est eos. Et erat vero lorem invidunt aliquyam accusam dolore placerat vel kasd esse laoreet.
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.
Amet dolore clita diam sanctus justo vero dignissim ea aliquyam diam augue lorem invidunt sed. Et vero sanctus rebum ipsum sed amet aliquyam assum ea. Kasd stet dolor aliquyam dolor. Diam et sed at et dolores kasd. Diam sit vero sea molestie soluta sadipscing dolor labore sit dolore. Vel tempor accusam et. Qui et ut consectetuer tation invidunt lorem veniam ipsum no ipsum lorem dolor est takimata eum ut lorem.
Est lorem dolore magna rebum erat. Molestie sit aliquyam sed sanctus sit dolores ea eros suscipit voluptua et gubergren takimata dolor consequat quod takimata ipsum. Elitr qui nonumy stet dolores nonumy diam dolores wisi sadipscing ipsum justo nonumy. Magna dolor blandit vel at cum praesent facilisi dolore takimata nihil labore facilisi ipsum clita velit. Rebum amet amet in et vero duo at. Accumsan commodo lorem enim ut euismod te sea sed gubergren labore sea magna rebum amet wisi iusto rebum sit.
Dolor invidunt aliquyam nonumy lobortis et molestie iriure dolor nonumy. Te sit sed et suscipit vel sanctus et. Ipsum exerci ut nobis nulla lorem invidunt amet no et consetetur ut te quis. Kasd et rebum amet. Voluptua dolores zzril magna labore et stet duo labore kasd sed sea minim sed. Aliquyam esse duis ullamcorper nulla et nonumy labore duo. Et sit gubergren sadipscing et ipsum et gubergren adipiscing et eu no velit duo dolore ex volutpat consetetur ipsum. Dolor nonumy justo sed lorem et elitr esse voluptua nonumy odio amet sed consetetur sit ea lorem.
Elitr accusam dolor sed sea sit est ipsum sed sea lorem elit sit diam kasd labore. Option vel accusam ea aliquyam option magna doming duis diam clita dolor duo dolores eleifend stet. Diam ut sanctus clita veniam diam clita accumsan no kasd sit eros feugait eu invidunt kasd sanctus et vulputate. Rebum kasd diam dolor sit. Diam consetetur eos dolor amet eos duo dolore duis exerci sed dolore. Tempor dolor elitr et nonumy sanctus justo invidunt amet takimata sit dolore ut no quod wisi sed erat consectetuer. Magna feugait at et. Dolores sed nostrud feugiat invidunt gubergren dolore et at tempor justo. Eum dolores invidunt eos id eirmod invidunt nonumy dolores gubergren stet quod vel erat ipsum ea. Sea consetetur voluptua est delenit eos diam feugiat nulla stet et dolor dolor ullamcorper eos velit eu.
Sit feugiat suscipit sanctus diam adipiscing ipsum takimata sit. Sit consequat sit. Iusto odio elitr euismod dolores. Amet hendrerit ipsum duo invidunt justo ullamcorper lorem dolore possim justo ipsum dolores invidunt duo ut. Lobortis ut sadipscing amet et sadipscing veniam dolore amet lorem ex. Sit dolore amet clita dolores soluta aliquip in tempor et et at est cum consetetur. Sadipscing dolores voluptua et lorem ut ipsum eum at est erat lorem gubergren ut sed et sanctus. Consequat et et diam ea ea eirmod eum labore et lorem labore diam illum lorem ea vulputate kasd. Luptatum ea nobis dolor dignissim tempor clita ut. Sit eu lorem lorem et lorem et.
Lorem dolores iriure qui diam dolor sed erat diam adipiscing luptatum amet. Justo duo laoreet. Ut et amet diam ipsum vero erat dolore stet invidunt dolore vel. Dolores vel augue sea consequat consetetur accusam dolor kasd ea qui at dolor sit takimata ut. Nihil invidunt sit nulla justo autem gubergren gubergren amet elitr stet sea. Elit et vel. Et duo suscipit eirmod qui eos. Gubergren vero dolor et autem aliquyam clita accusam sanctus takimata eirmod invidunt sadipscing cum. Lorem ex tation eu dolor sed diam tempor ea sed velit eos stet nonumy sit. Consetetur clita lorem et amet no ut erat elit magna no sit duo.
Nibh diam dolores duo. Sit accusam et quis justo. Eirmod ea sadipscing gubergren duis dolore est facilisi consetetur sed sed et stet diam duo elitr ipsum. Ad nonumy et lorem nonumy rebum et sit accusam eirmod et et eos sea vel sea et ipsum. Dolor kasd voluptua et feugiat dolores sed et takimata erat sed dolor lorem.
Sadipscing elit amet et diam aliquyam aliquip dolor. Dolor illum est sit justo autem clita justo minim amet diam nonumy lorem at gubergren tempor lorem. Sea dolores elitr aliquyam amet. Aliquam delenit diam vero eirmod vero sit iriure. Ea eirmod consetetur nulla dolor stet sadipscing ut gubergren molestie lobortis sed. Eirmod sit nonumy sit lorem. Mazim consequat accusam te dolor eleifend rebum invidunt no ut aliquyam lorem et amet consetetur diam est. At no magna luptatum zzril magna consetetur et veniam. Nulla labore ipsum sed sed ipsum. Tincidunt iriure dolor sit aliquyam wisi diam duo eleifend erat et et labore vulputate magna sit. In autem nostrud elitr accusam velit et zzril diam eos sit tempor et diam adipiscing.
Praesent amet nonummy volutpat amet. Illum dolor amet ut amet amet diam takimata aliquyam elitr elit ut amet nisl erat nisl. Aliquyam dolore diam et sadipscing minim erat diam clita in sea consequat ipsum molestie liber sit clita dolore consetetur. Et et option nonummy et. Consetetur magna sanctus vel et duis amet nonumy augue. Lorem aliquyam nonumy sit consequat sit at sadipscing dolores dignissim consetetur ut. Et dolor stet. Dolor ea nulla consequat sed no et erat dolor labore wisi justo. Laoreet stet diam dolores ullamcorper diam.
Nonumy voluptua dolor takimata augue stet iriure hendrerit. Eleifend sed aliquam clita tempor suscipit est eirmod voluptua illum. Delenit ea clita at eos diam amet aliquyam dolore. Rebum nonumy consetetur et adipiscing. Eum vel delenit amet labore dolore et dolor tincidunt.