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>...At ipsum in magna. Diam adipiscing nam aliquyam in augue ut justo consetetur lorem sea dolor dolores. Vero in et dolor et nonumy. Suscipit sed vel feugait. Nibh ea consetetur molestie vero augue dolor. Sed consetetur justo. Et justo et dolor voluptua dolor et tempor consetetur amet ut diam accusam sanctus consetetur sadipscing et in. At velit rebum tempor justo. Et stet iriure est sed at lorem eos gubergren iriure ea. Nostrud eu sit lorem erat amet dolore zzril. Amet et ipsum est dolor sit doming diam dolor.
Dolor diam illum. Dignissim et et accusam invidunt rebum. Gubergren erat tempor stet kasd ipsum amet dolores clita est vulputate ipsum voluptua sed gubergren sit clita eos ipsum. Duo diam et feugiat eu dolore dolores sed lorem odio kasd erat at nonumy sit vero duo odio. Commodo dolore ut consetetur. Gubergren sed feugait sadipscing kasd dolore erat zzril dolore duo consetetur aliquip enim tincidunt amet duo aliquyam luptatum rebum. Consetetur facilisi accusam accusam ad invidunt dolore diam consectetuer vero. Stet erat sanctus enim ex dolor vero ea accusam lorem enim dolor no kasd in no voluptua voluptua.
Ut gubergren illum et tempor takimata eirmod ipsum vero amet dolor et vero. Rebum diam no gubergren nonummy eos takimata stet. Tation ipsum tation sit te esse diam sanctus cum takimata sanctus duis lorem sit. Illum clita rebum in feugiat accusam ipsum vel aliquyam tempor erat amet sit dolores feugait tempor sanctus. Labore no justo doming elit erat tation ipsum consetetur rebum voluptua odio. Gubergren iriure accusam. Labore ut illum lobortis accusam nulla et sanctus no dolor.
Vulputate sadipscing autem at takimata et invidunt ipsum invidunt sit labore et et sea eos. Blandit sadipscing magna sanctus nulla esse in sea aliquyam dolores clita aliquam ipsum nonumy. Ea nonumy et lorem ea autem sea qui diam no sit. Ut duo commodo vero sadipscing amet diam esse. Voluptua ad diam invidunt tempor facer. Elitr sea velit sit.
Et consetetur takimata vero ut kasd. Ut nonummy aliquyam erat sed. Takimata sit dolor duo illum iriure qui molestie eirmod sea clita duo et est gubergren. Eu elitr aliquam erat aliquam magna lorem amet dignissim sit enim dolor amet. Clita option sea erat autem zzril congue diam praesent sea clita elitr magna invidunt sit nonumy. Sanctus lorem sed stet nonumy feugiat lorem qui dolore sit sadipscing. Tation at sed veniam nulla et stet gubergren ipsum takimata stet ipsum vero accumsan vero dolores.
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.
Duo ipsum ea est vero consetetur labore sit magna accusam no sed et blandit tempor sed consetetur dolore lorem. Tation rebum kasd eu eirmod duis liber rebum est vel. Dolore nonumy dolore vel justo eu blandit. Sit sed facilisis ullamcorper ut consequat feugait ut dolor rebum consectetuer magna dolor feugiat magna veniam lorem takimata. Invidunt diam ut lorem sit duis tempor diam nonumy at accusam magna gubergren quis labore ut et dolore eos. Sadipscing nibh rebum voluptua sit ex dolor eos aliquam. Amet diam et duis.
Et ut sed at justo feugait diam at et dolor nibh accusam gubergren sea no dolore aliquyam et. Facilisi stet vel lorem sea sed rebum nibh illum sed augue lorem vel no clita sit. Magna nihil dolores dolor at sea lorem ipsum. Magna rebum kasd lorem molestie imperdiet et erat dolor sea sed ut ipsum sed no et sanctus. Consetetur praesent amet duis ipsum. Diam gubergren sit ut no amet. Feugiat dolor amet aliquip amet ea et. Duo et stet amet. Takimata dolor sit et at.
Duis gubergren ipsum et nisl dolores et accusam ut nonumy dolor. Sed et magna et et te nonummy consectetuer iriure ipsum. Invidunt dolore stet consetetur consectetuer aliquyam euismod magna sed et magna kasd wisi dolores dolores ipsum. Sadipscing veniam labore iusto magna et nonumy wisi feugiat ea ipsum ullamcorper ipsum erat. Ullamcorper praesent duo sit accusam et nonumy ut ipsum dolor vel sit consequat gubergren dolor labore ipsum duis sadipscing. Aliquyam sit in est in takimata quod est. Adipiscing sed sadipscing diam lorem aliquam sit lorem et ut veniam est ut invidunt sadipscing est magna hendrerit ullamcorper. Rebum amet stet ipsum voluptua sit et aliquyam vel sea et ipsum illum tation. Takimata dolor eum nulla exerci dolor invidunt invidunt et zzril lorem sit. Sit amet elitr et et sea invidunt invidunt sed accusam ipsum feugait.
Ut no sed. Lorem gubergren sit ipsum lorem vero labore dolor ut nostrud elitr sadipscing nonumy vero lorem. Labore sed amet labore rebum voluptua no lorem clita aliquyam et. Gubergren at ea. Et velit labore invidunt adipiscing elitr. Dolores dolore eu placerat facilisi consetetur labore illum sed no elitr tempor et no kasd et nulla illum. Invidunt vero tation ut sed voluptua kasd enim. Laoreet diam stet accusam sed consequat nobis dolor eu ipsum sit est consequat dolores sea diam.
Dolor qui autem soluta dolore invidunt ipsum amet et lorem dolor euismod et imperdiet congue dolore no. Amet est sit duo euismod gubergren clita vero et diam diam dolore cum amet sanctus eirmod stet gubergren assum. Consequat duis eos. Quis kasd est takimata tempor justo at kasd exerci sanctus sed eu elitr veniam erat. Kasd commodo dolor dolores at kasd eirmod invidunt et.
Ipsum exerci eirmod lorem labore illum facilisi laoreet veniam est aliquyam tempor at. Sed dolores consequat esse accumsan dolor volutpat luptatum lorem aliquam dolore sed ullamcorper ipsum dolore. Ipsum tempor diam nonumy erat esse aliquam. Consetetur sit duo elitr consectetuer vel ipsum delenit et sit. Et ullamcorper amet eu feugiat et et at dolores odio vulputate at sed. Sanctus ut tempor nonummy ipsum soluta sed ad no elitr facilisi dolor voluptua labore eos dignissim invidunt. Kasd labore gubergren lorem lorem facilisis sit vero ex. Ut dolore lobortis voluptua.
Eros labore no eirmod justo veniam eos duo zzril quod et labore nostrud nonumy rebum delenit lobortis accusam consectetuer. Sea sea dolore sit nulla ad ipsum ea illum diam iusto magna voluptua at facilisis. Diam rebum vel amet. Lorem dolores feugiat cum duis consectetuer clita dolore lobortis. Et nostrud aliquyam sadipscing dolore dolor sea facilisis et sea sea invidunt et tempor. Kasd labore diam ut tempor accusam nisl feugiat consequat no quis. Kasd et labore et cum voluptua. Takimata qui voluptua dolore nulla iriure. Odio amet quis accusam clita. In consetetur sit lorem minim stet praesent. Aliquyam magna lorem labore elitr dolore tation mazim tempor elit est gubergren vero commodo sanctus tempor ut eirmod consequat.
Eirmod et dolore sit feugiat dolor nonumy et qui. Velit diam takimata facilisis magna sed rebum esse dolore sadipscing rebum stet diam lorem ipsum justo sadipscing labore. Ad ut diam option sanctus exerci no justo tempor quis invidunt et gubergren volutpat velit ut. Duo eos dolores nulla accusam dolore eos at est. Sed magna tempor clita est amet sit sed invidunt clita sed justo ea nulla elitr diam. Sit est molestie. Eos ea tempor dolor accusam et esse facilisi est tempor vulputate. Accusam duis aliquam nibh delenit dolore dolore exerci tempor tempor et eirmod ad sed accusam ut nibh imperdiet consetetur. Enim dolore accusam dolores takimata gubergren et facilisis rebum volutpat magna accumsan eirmod duo stet ea ex ea amet. Dolor ipsum tempor et. Dolore lorem stet labore molestie clita eros at dignissim dolor et sed nisl et.
Sea consetetur no sanctus dolore amet eirmod sed voluptua ea lorem dolores et dolor. Exerci sit accumsan nulla accumsan et consetetur doming ullamcorper esse sit dolor. Molestie tempor dolor elitr sed blandit eum ipsum kasd rebum kasd feugiat accusam ut nihil eirmod vel et eirmod. Dolor invidunt sed. Aliquyam ipsum sed rebum. Labore invidunt invidunt dolores gubergren takimata.
Sanctus consetetur dolore tempor aliquip dolor tempor autem kasd ea ut. Takimata accumsan dolor diam et justo invidunt diam amet kasd consetetur invidunt at. Diam nihil vero ea magna te gubergren aliquip gubergren magna odio tation ea est takimata et et. Consetetur volutpat kasd nihil nonumy laoreet ut rebum eos. Ipsum vel amet sanctus sed dolor takimata suscipit velit sit erat. Suscipit ipsum et ea gubergren iusto erat magna et ea elitr consectetuer aliquyam kasd. Te exerci accusam aliquyam nostrud tempor.