Forum Documentation

Is there any css grid documentation?

vjs
I see the announcement in the "feature requests" section of the Prince forum from 5 July 2024 saying that a build with support for CSS grid is now released. Great! I upgraded to the most recent build and am working with some grid use cases.

I don't, however, see anything about grid support listed in the release notes, and I also don't see grid properties listed in the css properties section of the Prince reference guide.

Beyond the following statement from the feature requests forum...

"currently grids will not be fragmented across multiple pages and some other features remain to be implemented, such as baseline alignment"

...is there anything that more precisely states what aspects of grid aren't yet supported?
howcome
Documentation will follow when Prince 16 is released.

Meanwhile, it would be interesting to see your use cases?
vjs
Thanks so much for your reply.

I asked whether certain grid css properties aren't yet supported because I'm puzzled that a basic use case from Mozilla's grid documentation fails. I've confirmed (by running "prince --version" from the command line) that I'm running Prince 15.4.1. Yet when I define a grid container that contains five child divs, then use the grid-template-columns css property to specify the creation of three columns for the grid, I get the following error:

prince: lab_report.css: warning: unsupported properties: grid-template-columns

No PDF is generated.

This is the command that I run to attempt to generate a PDF that displays the child divs in columns:

prince -s lab_report.css lab_report.html

I can view the lab_report.html file in Chrome, where the child divs appear in columns as expected.

If I remove the "grid-template-columns: 200px 200px 200px" line from the lab-report.css file, Prince generates no error, but of course the child divs fail to appear in columns.

It seems I must be overlooking something basic, because the grid-template-columns property would be supported if grid is supported? I appreciate any light you can shed on this. Files are attached. Thank you!



  1. lab_report.css0.3 kB
  2. lab_report.html2.3 kB
howcome
Try dowload the latest build:

https://www.princexml.com/latest/

I attach the Mozilla example.
  1. foo.html0.9 kB
  2. foo.pdf20.0 kB
vjs
Ah hah! Yes, that solved the problem. Thank you so much.