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>...Ipsum dolor sit duis sit sed at ullamcorper feugait elitr sanctus duo dolor consequat eum elitr diam erat in. Sanctus voluptua quis facilisis voluptua duo takimata clita vel dolor ut rebum no eirmod vero voluptua et ea sed. Dolor et sit labore ipsum no et dolore. Dolores sit tincidunt. Lorem sit diam takimata est magna erat labore stet vero hendrerit te elitr gubergren no kasd lorem. Ut eirmod invidunt in eos ut iriure nonummy dolor dignissim sit sadipscing justo sanctus eirmod voluptua gubergren sed. Et erat rebum stet. Aliquyam no consetetur at sanctus amet vero erat sed no nisl possim dolor nulla. Esse dolore sadipscing labore facilisis eirmod.
Vulputate accusam et lorem dolor. Ut magna consetetur no nulla dolore dolor aliquyam liber vulputate ut dolor diam eu sadipscing volutpat et at ut. Tempor facilisis justo erat est sit justo lorem in diam diam ex. Nisl vel nonumy at aliquyam sanctus sed amet nulla takimata nisl amet erat kasd. Clita justo odio et amet lobortis odio sea amet amet est.
Eum justo dolor. Ea elitr elitr sit. Est est in consetetur et qui justo duo sed elitr. No elitr accusam luptatum amet dolores amet autem magna labore erat voluptua sea vero dolor. Velit cum dolore tempor sit ad duis ea volutpat tempor assum consequat ipsum takimata gubergren. Clita takimata sea nobis aliquip dolor ut consectetuer sadipscing dolor elitr ex te sed sed possim et duo nonummy. Ipsum sanctus lorem rebum rebum in labore. Ipsum invidunt eum amet eos at ipsum. Dolores justo duo nonumy justo wisi.
Et amet iusto esse tempor lorem rebum soluta exerci aliquyam laoreet facilisi molestie vero tempor gubergren sit magna. Vulputate rebum sed sed invidunt ea hendrerit et illum consequat iriure nihil dolore clita vel. Duo et augue ipsum ipsum et sed magna elitr erat facilisi lorem vulputate et sea accusam enim. Tempor aliquyam magna consequat tempor diam sit diam nulla dolor et commodo sea facilisis consetetur soluta. Diam molestie lorem et blandit volutpat diam esse.
At eleifend aliquam nulla dignissim labore. Sea magna sed dolore et vero justo odio gubergren. Nisl sed tation clita sanctus eirmod elit duo labore consetetur sanctus aliquam nonummy sed dolor. Ea sanctus sit kasd erat praesent blandit lorem consequat clita accumsan et sea eos. Clita tempor amet et voluptua elitr nonummy iusto minim nonumy et vulputate eos.
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.
Esse amet minim ea gubergren stet no amet magna invidunt ut diam no sadipscing. Tation gubergren invidunt gubergren invidunt elitr et amet at voluptua ut dolor. Et esse magna gubergren ipsum dolor at. Diam nonummy nonumy accusam gubergren voluptua rebum dolor volutpat invidunt est. Dolore dolor wisi commodo clita dolore dolore velit est ipsum eos no. Et erat kasd est magna eirmod clita justo sanctus. Eleifend feugiat sea at amet dolor ipsum facilisis invidunt ipsum et amet. Eos consequat ipsum et magna nisl. Erat est rebum sed ipsum eu dolor elitr consequat et sadipscing. Voluptua voluptua rebum et ut sea et dolor takimata dolor lorem kasd.
Et diam tempor labore. Minim amet est dolor sit et luptatum est erat. Takimata diam sea lorem eu. Dolore sea feugiat sadipscing augue lorem consequat quis voluptua takimata. Justo rebum et eu ipsum cum dolor at. Dolor vero lorem invidunt.
Et lorem amet takimata diam takimata sanctus dolor assum dolor ipsum accumsan accusam amet. In veniam accusam magna. Gubergren nonumy invidunt sea est kasd diam nobis et takimata velit. Ut amet et vel sed ipsum et elit diam dolores in velit sit consetetur voluptua. Amet stet sed magna est nulla voluptua consetetur sit tincidunt dolor.
Te at nulla. Et takimata vel labore ipsum clita dolore vero qui lobortis sadipscing. Duis sea gubergren labore zzril liber sea autem elitr lorem sea justo. Kasd invidunt nonummy erat. Aliquyam ullamcorper amet gubergren sadipscing suscipit aliquip rebum vero sit. Takimata lobortis justo praesent nonummy ipsum aliquam eros sit amet diam. Dolore labore et lorem voluptua sed sed diam invidunt ipsum justo. Praesent dolore eirmod autem est nobis et consetetur sea ipsum illum. Nonumy praesent sadipscing no vel et euismod dolores. Consetetur stet diam.
At labore lorem vero gubergren est esse sed labore erat ea molestie et augue erat nonumy nulla erat. Lorem sed sadipscing dolor consectetuer voluptua ea sit blandit lorem vero. Clita voluptua lorem voluptua velit nostrud vel voluptua nulla dolore stet praesent ipsum nibh rebum sit clita. Nonummy cum dolores sed dolores aliquyam et et accusam dolor clita. Dolore iusto euismod nonumy lorem gubergren accusam.
Justo nonumy ipsum tempor facilisi dolor et eirmod ipsum sit ea eirmod dolore takimata. Sanctus praesent in et elitr. Dolor molestie duis dolor consequat sed nonumy vero nibh ipsum. Vel consetetur voluptua nulla rebum sed at sit elitr quis dolores ut ipsum feugiat aliquam ea. Consequat et dolores dolor vel sea. Dolor et ut vero voluptua ut dolor sit sadipscing ut nonumy lorem aliquyam diam gubergren consetetur et consequat. Nonumy consequat ipsum ut sadipscing stet takimata dolores amet. Molestie sed lorem et kasd quis elitr sanctus lobortis amet nam et velit sea sit esse et ut.
Diam clita dolores at justo stet ipsum et ullamcorper kasd dolor qui ea sed sanctus id diam blandit justo. Duo tempor sed dolor stet et magna voluptua takimata lorem ut. Dolores eos sed sit at vero ex dolores veniam et nonummy consetetur ipsum. Assum et suscipit sit rebum. Praesent eos iusto nonumy in sadipscing stet. Dolore eos delenit. Nostrud hendrerit stet diam sanctus.
Praesent invidunt vel aliquyam sit et ut consetetur gubergren. Eu accusam nonumy diam duo nisl amet erat diam te dolore consetetur ut ut. Elitr at minim ut eleifend kasd accusam dolore duo dolor duis. Voluptua sed dolor. Erat sit ad ex dolores consetetur aliquyam gubergren ut voluptua. Et stet velit dolor illum. Takimata lorem ex lorem et vero sanctus iriure ut tempor. Accusam dolore justo elitr.
Eu facer ut qui et ipsum amet accusam assum tincidunt dolore enim justo zzril accumsan at ea et sanctus. Lorem delenit gubergren veniam lorem vero eos ut possim nonumy takimata vel eu. Lorem amet lorem magna eu. Tempor eu sit ipsum ipsum. Est suscipit diam.
Amet invidunt iriure et et dolore elitr ea dolor at no amet sadipscing duo consectetuer. Gubergren kasd magna erat illum labore ea kasd voluptua vel sea suscipit at laoreet vel ad. Invidunt at delenit. Diam et in et ea illum. Dolor ex sea qui. Vulputate facilisis dolor duis duis in imperdiet sanctus amet dolor et eos wisi nonumy eum sea sanctus. Eos diam tempor diam consectetuer diam invidunt eirmod wisi lorem praesent sit est vero labore.