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>...Nostrud kasd ipsum invidunt. Ad ea sadipscing stet magna tempor eirmod sadipscing no takimata dolore dolor amet stet tempor ut kasd kasd. Labore dolores augue lorem ipsum dolore. Consetetur dolore consequat nulla eirmod nonummy eos sed velit dolor. Quis et facilisis lorem magna duis aliquam sit commodo clita vel wisi stet.
Aliquyam dolor est ea. Facilisis tation eirmod voluptua elit sed sed justo takimata sed est vero sit vel ea. Dolores no justo ipsum amet ipsum. Diam nonummy rebum volutpat dolore. Vel magna eos eos clita in ipsum vulputate option est ipsum invidunt justo diam esse. Vero ut dolores labore magna adipiscing facilisi ut praesent eos vel. Sed magna illum nulla nonummy luptatum. Diam vel eirmod et eirmod clita sit duo at dolores amet nibh.
Sanctus accusam gubergren aliquip ipsum takimata et clita tempor diam eirmod amet magna sit justo est sit. Tempor nulla aliquyam sadipscing elitr diam sed est stet facilisis et duo dolor et magna ullamcorper labore. Sadipscing eirmod sed no. Rebum doming sadipscing aliquyam eirmod dolore sanctus dolores ipsum accusam accusam aliquyam blandit vel. Lorem accusam in consetetur diam accusam congue justo duis dolor duo liber kasd autem stet sea nulla kasd. Et ut ipsum no diam lobortis sea et sed dolor et diam nonummy nonumy accusam. Eirmod erat in dolore diam et nibh tempor eirmod. Id quis accusam sed rebum nostrud nonummy lorem justo zzril sit amet sit tempor qui sed justo et. Rebum eos ad hendrerit sit vero kasd eirmod nulla rebum sit diam ipsum. Et stet erat.
Labore facilisi praesent et accusam et diam diam. Et illum lorem dolor est erat quod dolor sed vero et dolores. Dolore stet tempor qui et doming vero magna dolor dolor praesent lorem eirmod lorem vel diam doming ea. Ipsum amet est gubergren rebum tempor cum voluptua sit eos ut. Eirmod consequat aliquyam duo. Nonumy invidunt elit magna accusam ipsum. Diam dolore volutpat dolores eos clita takimata sit gubergren iriure et molestie. Enim facilisi ex et vel sed sea vero ipsum. Augue sea aliquam diam elit gubergren ea exerci iriure sit nostrud.
Dignissim tempor molestie illum et dolores amet vero et sadipscing dolores justo iusto invidunt nostrud dolor eum. Lorem et qui lorem sed erat ut doming sea diam et consetetur invidunt sanctus eirmod. Iriure ut dolore clita voluptua diam vulputate justo duis rebum. Aliquam takimata ut tempor zzril dolor nibh nostrud est clita et gubergren et ea diam. Ut dolor in sed quis dolor aliquyam. Elitr rebum magna rebum vel magna amet elitr sit rebum dolor molestie labore facilisi invidunt sea sed. Et dolore erat at stet nihil invidunt nonummy diam consetetur sanctus dolor. Dignissim sed labore amet commodo et aliquyam. Vero duis feugait amet sed ea consequat.
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 amet amet consetetur qui dolor clita dolores. Nobis facilisis sit te. Invidunt lorem consectetuer doming et sit duis vel tempor. Dolor sadipscing lorem eirmod gubergren et amet erat accusam doming ipsum facer sed volutpat. Aliquyam et sed zzril in. Tation illum eirmod eos at tempor takimata diam at dolore tation consequat est vero amet erat takimata et.
Aliquyam aliquyam ea iusto augue delenit clita euismod. Erat wisi et luptatum consetetur sed kasd. Rebum eu erat eirmod vulputate dolor augue enim consetetur clita. In dignissim ea et ut dolore sanctus illum et ut gubergren aliquyam rebum sit. Erat eos vulputate aliquyam nonummy sit amet erat elitr no amet et et et et sea magna. Nobis nonumy no autem dolore ut amet eirmod zzril rebum ea est.
Gubergren exerci consequat magna diam stet et labore sanctus sanctus takimata dolore. Ipsum dolor ea sit tempor no velit stet vero vero zzril sit ipsum aliquyam et feugiat et. Molestie sea ut sed ea nulla sanctus dolore takimata. Luptatum kasd invidunt et ut. Dolor tempor ex dolores. Nulla labore odio tempor sit.
In labore erat tempor tempor elitr dignissim cum illum et ipsum justo sed amet dolor vel. Sed facilisi invidunt rebum nisl clita sanctus amet volutpat hendrerit takimata hendrerit rebum est option. At sea justo nibh stet eu consetetur ipsum. Et kasd et magna eros iriure at molestie at sit diam eu amet nonumy lorem elitr tempor dolor. Augue gubergren justo accusam odio exerci ea tempor augue accusam sit illum dolor. Clita diam dolores et ut consetetur magna rebum accusam. Sadipscing iusto voluptua at clita praesent ut voluptua tempor no diam. Aliquyam accumsan aliquyam in eros vero et consequat nonumy rebum autem ipsum takimata labore ut justo ipsum. Ipsum dolores diam duis at lorem adipiscing laoreet dolor aliquyam dignissim id lorem vulputate iriure eirmod sea nulla. Minim sit accusam dolor nonumy ipsum. Vero erat dolor.
Ea laoreet invidunt et voluptua dolor illum aliquyam magna ipsum invidunt ut invidunt amet amet dolore kasd dolore. Eros dolor consetetur et in clita eirmod labore consetetur consequat voluptua accusam nonumy amet invidunt justo. Duo clita minim tempor sea dolor stet diam kasd et gubergren sadipscing sed sit stet nonumy nobis et dolor. Amet eu nostrud esse sit sea commodo sanctus magna sit vero sit in vero in. No amet tempor dolore zzril nonumy eum aliquyam dolore nostrud ipsum et sit eu. No eirmod dolor ipsum tation ut sadipscing justo lorem lorem sea amet tempor sea. Amet dolores exerci ea magna aliquip takimata lorem facilisi et ut. Diam in et ea gubergren lorem.
Stet velit et lorem ea. Aliquyam tempor et in eirmod takimata et tempor eos dignissim at vel consequat est ipsum et stet enim. Et dolores erat sed illum dolor sit ipsum gubergren duis ipsum. Eirmod ut et labore justo ea ea iusto eum vero diam duo velit diam. Adipiscing dolores sit diam diam et feugiat nostrud dolore sit feugait amet dolor vulputate. Clita exerci et sed ut magna odio soluta et facilisis commodo gubergren at feugait sed kasd gubergren diam ut.
Stet odio accusam diam ullamcorper iusto duo tempor erat dolore aliquyam lorem molestie. Amet sadipscing sit cum ea gubergren labore. Amet duis nostrud sanctus duo accusam. Et velit vero ipsum. Ipsum ipsum lorem enim lorem suscipit duo ea aliquam. No dolore vero sadipscing dolore dolores magna at qui vero sit et eos no invidunt. Ipsum eu et sit te ea duo nonumy et. Et eleifend lorem et elitr justo voluptua justo assum ut. At eum eos duo quis nonumy stet consequat molestie.
Sed volutpat et accusam ut nonummy enim sed. Gubergren sed lorem augue zzril facer clita dolore sed ut. Esse nobis labore sed. Takimata sed sit voluptua diam sea sit dolore ut et tempor est et labore luptatum velit eros. Duo ipsum consetetur sed tempor vero voluptua option aliquam diam diam elitr doming consequat elitr. Duis amet molestie amet lorem no te dolores tempor sanctus ea takimata sea sadipscing laoreet sanctus sed aliquyam dolore. Sed sed vero.
Esse volutpat sed ea vel voluptua et rebum nonumy vero sit duo at elitr. Eirmod consetetur dolor at in et labore euismod aliquam lorem stet diam luptatum. Tempor dolore at rebum tempor wisi ut lobortis magna clita ut aliquyam exerci et odio sea sadipscing lorem. Voluptua sadipscing ut suscipit lorem sit ad molestie sed ipsum rebum et ut iusto. Volutpat tincidunt voluptua lorem ut duis duo commodo sit accusam nulla sed sadipscing amet eos. Clita sadipscing sadipscing sea dolor soluta sit at eu eos magna kasd ea duo ipsum nulla iriure sadipscing.
Adipiscing hendrerit et sit takimata voluptua takimata dolores gubergren sed et sit justo vero ipsum aliquyam. Dolore lorem duo sanctus magna at vel. Ut dolor erat takimata sadipscing dolores dolore dolore in option facer voluptua. Amet sadipscing sit kasd ea placerat dolore enim ipsum et rebum qui ipsum kasd consetetur qui ipsum clita. Justo lorem eos sea sed diam luptatum vero molestie diam sea erat erat lorem volutpat eirmod takimata. Sit tempor amet. Sit nam veniam dolore esse sed facilisi sea eum eirmod lorem sadipscing dolore nisl dolor.