Issue with docbook listitem/para

Having trouble installing Oxygen PDF Chemistry? Got a bug to report? Post it all here.
fsteimke
Posts: 80
Joined: Tue Jan 01, 2013 3:19 pm

Issue with docbook listitem/para

Post by fsteimke »

Hi,
i am trying my first steps with PDF Chemistry bundled with XML Editor. I started with a simple DocBook document and a CSS file which imports the docbook.css from the DocBook Framework in the Oxygen installation folder. My CSS has only one rule which applies to the para element as well as the simpara element. The whole CSS file has this content:

Code: Select all

@import "/opt/Oxygen XML Editor 24/frameworks/docbook/css/docbook.css";
para,
simpara {
    border: 1px solid black;
    text-align: justify
}
The XML source file references the CSS file via an xml-stylesheet PI.

I create and apply a new transformation scenario for PDF Chemistry. The DocBook source file consists of two simple parts:
  • a simpara and a para as immediate childs of the article (top-level paragraphs);
  • same simpara and para as childs of itemizedlist/listitem (paragraphs in itemized list)
I would expect all four paragraphs in the generated PDF as justified with a border. I checked with the chrome browser, the result is as expected.

However, the generated PDF file shows the expected result for both simpara elements an the top-level para element. The para element in the itemizedlist is not justified but left-aligned, and has no real border (see attachement).
chembug.png
chembug.png (149.17 KiB) Viewed 1233 times
I have tried with an !important directive to exclude obscure precedence rules bit without success. I am using XML Editor 24.0, build 2021101506 on Linux.

Sincerely, Frank
fsteimke
Posts: 80
Joined: Tue Jan 01, 2013 3:19 pm

Re: Issue with docbook listitem/para

Post by fsteimke »

You will find the dumped styled xml and fo file within the attached archive
chembug.tar
(210 KiB) Downloaded 197 times
F. Steimke
julien_lacour
Posts: 481
Joined: Wed Oct 16, 2019 3:47 pm

Re: Issue with docbook listitem/para

Post by julien_lacour »

Hello Franck,

There's a default rule for print that override the default display for para (in frameworks\docbook\css\print.css):

Code: Select all

listitem > para {
  display:inline;
}
I added an issue on our side to see if this rule is still necessary. Until then you can override it in your custom CSS.

Regards,
Julien
fsteimke
Posts: 80
Joined: Tue Jan 01, 2013 3:19 pm

Re: Issue with docbook listitem/para

Post by fsteimke »

I can confirm that overriding that rule is a solution in my test-case.
I wonder what reasons may be to declare a paragraph as an inline element ...
Thanks,
Frank Steimke
julien_lacour
Posts: 481
Joined: Wed Oct 16, 2019 3:47 pm

Re: Issue with docbook listitem/para

Post by julien_lacour »

Hello,

It was an old workaround that fixed a display problem: list items bullets and text were not aligned perfectly but this has been fixed since.

Regards,
Julien
Post Reply