Example style and count

Questions about XML that are not covered by the other forums should go here.
anna_craneo
Posts: 33
Joined: Tue Feb 20, 2018 2:51 pm

Example style and count

Post by anna_craneo »

Hi,

I use PDF Chemistry and CSS styling to format my PDFs.
I would like to change my border look for example element, but it doesn't work if I use common CSS border style.
Code looks like this:

Code: Select all


*[class~="topic/example"] {
/*See -colors.css*/
display: block;
margin:10px 0;
padding:0.2em;
border: 1px;
border-color: #4B4646;
border-radius: 0 10px;
background-color: #DCF0F7;
}
I also want to add Example (examplecount) and tried to do like this:

Code: Select all

/* Reset the counters */
*[class ~= "map/map"] {
counter-reset: page 1 part 0 chapter 0 figcount 0 tablecount 0 examplecount 0;
}
....
@media print {
/*
Put a number before the figure title.
The counter is reset in p-page-titles-and-numbers.css
*/

*[class~="topic/example"] {
counter-increment: examplecount;
}
*[class~="topic/example"] > *[class~="topic/title"]:before {
content: "Example " counter(examplecount) ".";
}
}
But it doesn't affect the output at all.

I would really appreciate any help!
Costin
Posts: 833
Joined: Mon Dec 05, 2011 6:04 pm

Re: Example style and count

Post by Costin »

Hello,

In order to help us investigate and find a solution, could you please send us some sample files (a minimal DITA Map containing the topic(s) you need to style in the PDF output) and the CSS you are using?
You should zip the files and send the archive to support@oxygenxml.com

Regards,
Costin
Costin Sandoi
oXygen XML Editor and Author Support
Post Reply