SlideShare una empresa de Scribd logo
1 de 31
Descargar para leer sin conexión
Andreas Jung • info@zopyx.com • print-css.rocks
State of PrintCSS in 2023
MarkupUK 2023, London
Agenda
(this is not a PrintCSS tutorial)
• Brief introduction to PrintCSS and its standards
• The problems with comparing tools
• Free PrintCSS tools
• Commercial CSS tools
• Role of Javascript in PrintCSS
• The pain points with PrintCSS
• Decision criteria
• Q & A
Publishing developer & consultant
since mid-90s
https://print-css.rocks
https://andreas-jung.com
✉ info@zopyx.com
Funder of print-css.rocks project
Independent PrintCSS consulting
- Software developer & software architect
- Requirements engineering
- Python developer & Python expert
- NGOs, EDU
- medical & pharmaceutical
- energy
- research & development quantum mechanics
- CMS Solutions
- Publishing Solutions
- Individual software solutions
About me
Introduction
The PrintCSS process
• Input: HTML (or XML)
• Styling: CSS
• Formatting: a free or commercial PrintCSS renderer
• Output: PDF
Definition of „PrintCSS“
„PrintCSS“ synonym for „W3C CSS Paged Media“
W3C CSS Paged Media Level 3 (2018)
• the official standard for generated paginated content aka
PDF from HTML using cascading stylesheets (CSS)
Related standards:
• CSS Generated Content for Paged Media Module (2014, GCPM)
Comparing tools, metrics and their problems
How to compare tools in a reasonable way?
Problems
• we have many PrintCSS tools
• we have hundreds of CSS properties + PrintCSS specific CSS properties
• we can not test all tools against all CSS properties
(not manually, not automatically)
• W3C standards do not cover everything, leaving room for interpretations
Metrics and approach of print-css.rocks
• testing the core PrintCSS features (W3C Paged Media, GCPM)
• focus on high-level topics (e.g. footnotes, CSS grid, RTL)
How we do in print-css.rocks?
How we do in print-css.rocks?
How we do in print-css.rocks?
Standards, non-standards and extensions
Example: variations on footnotes
…not even talking of
• endnotes 😈
• sidenotes 😈
Standard
no standard
Free PrintCSS renderers
Free PrintCSS renderers
(Feature selection is highly opinionated)
WeasyPrint Vivliostyle PagedJS
Python
Javascript/
Chromium
Javascript/
Chromium
✅ solid core
✅ Flexbox
✅ Hyphenation
✅ simple footnote support
✅ solid core
✅ Javascript support
✅ MathML
✅ simple footnote support
❌ Grid
❌ Javascript
❌ XML
❌ Hyphentation
❌ XML
❌ many unfixed issues and bugs
good community support good community support community support 🤷
👍
actively maintained
👍
actively maintained
👎👎
badly maintained
Commercial PrintCSS renderers
Commercial PrintCSS renderers
(Feature selection is highly opinionated)
Typeset.sh Prince PDFreactor BFO Publisher
Antennahouse
Formatter
PHP Java Java
✅ solid core
✅ Grid & Flexbox
✅ very mature
✅ Javascript
✅ Flexbox
✅ excellent docs/examples
(https://css4.pub/)
✅ XML
✅ very mature
✅ Javascript
✅ Grid & Flexbox
✅ XML
✅ solid core ✅ very mature
✅ most advanced
typography features
✅ most complete
✅ XML
• young project
• has some rough edges
here and there
❌ Grid • young product
• has some rough edges
• not much experience
❌ Grid
❌ Flexbox
❌ Javascript
✅ excellent support ✅ excellent support ✅ excellent support ✅ excellent support
👍
actively maintained
👍👍
actively maintained
👍
actively maintained
👍
actively maintained
👍👍
actively maintained
89 € (annual)
or 499 € (perpetual licence)
3800 USD (4 CPUs) 2.950 € (4 CPUs) n/a 5000 USD (1st CPU)
* check pricing for educational license or „personal“ usage licenses
Role of Javascript?
Why Javascript?
Javascript is the „Franca Lingua“ of the web (besides HTML)
Javascript on the web:
• no modern web solutions without Javascript
• omnipresent
Javascript in Print/PrintCSS
• provide enhanced visualizations (graphs, charts etc) from the web in print
• for content: ideally Javascript visualization that work on the web, should work in PrintCSS
• for internal usage: influencing the rendering process of the PrintCSS renderer
• generating TOC, listings, indices
Situation of Javascript support in renderers
well…
Renderer PagedJS Prince PDFreactor Vivliostyle
Implementation Chromium/native custom JS engine custom JS engine Chromium/native
JS compatibility for
PDF generation
unknown selected JS packages selected JS packages
best compatibility for JS
modules (where they
make sense)
JS for internal usage unknown
• adaptive rendering
• adaptive image scaling
• table of contents
• adaptive rendering
• adaptive image scaling
• table of contents
unknown
The pain points with PrintCSS
The dark side of PrintCSS and its renderers
Problems and pain points
• inconsistent implementations and behavior of renderers
(due to incomplete or inconsistent Paged Media specifications)
• different defaults (page size, borders, page area dimensions etc.)
• easy things often work differently across tools
• complex topics
• floats
• adaptive rendering of images
• handling of long or wide tables
Decision criteria
Is your publishing use case suitable for PrintCSS?
Automatic typesetting
means automatic!!!
No manual interaction!!!
Know your typographic and layout requirements
…an opinionated selection of criteria
• Is your publication text-oriented or layout-oriented?
• Do you need a grid system or flex box?
• Do you need a baseline grid?
• Support for multiple columns needed?
• Footnotes required?
• Floating objects needed?
Do I need Javascript?
• Do you have to interact with external Javascript modules
(charts etc.)?
• Do you need Javascript support inside the renderer or can you
prepare Javascript-based assets in a pre-processing step?
Do I have XML or HTML as input?
• only some renderers speak XML natively
• but all renderers handle HTML
• raw XML often not directly suitable unless transformed
to publishable XML or HTML
• PrintCSS is not a transformation framework
• flat or nested HTML?
• personal preference: nested HTML but YMMV
Do I have special PDF requirements?
• PDF metadata
• PDF variants
• PDF/UA (accessibility)
• PDF/X (print)
• PDF/A (archiving)
• supported by most commercial renderers
• PDF security (encryption, signing)
• supported by most commercial renderers
Other features needed?
• Scientific context? (formulas, MathML, MathJax)
• integration of renderers in workflows:
• all tools run on the command line
• some tools provide a server mode
• some tools provide APIs for integration with PHP, Python etc.
• Produce & Publish server (abstraction of renderers)
Recommendations
Recommendation and hints
• be aware of your special requirements
(regarding more complex features)
• build prototypes and evaluate against different renderers
• use CSS variables (not widely supported)
• consider using CSS preprocessors (e.g. Less, Sass)
for complex workloads
• start with free tools, use commercial tools if needed
Q & A
Thank you for listening
Andreas Jung • info@zopyx.com • print-css.rocks

Más contenido relacionado

La actualidad más candente

La actualidad más candente (20)

BrightonSEO Deck - April 2023.pdf
BrightonSEO Deck - April 2023.pdfBrightonSEO Deck - April 2023.pdf
BrightonSEO Deck - April 2023.pdf
 
Influencing Discovery, Indexing Strategies For Complex Websites
Influencing Discovery, Indexing Strategies For Complex WebsitesInfluencing Discovery, Indexing Strategies For Complex Websites
Influencing Discovery, Indexing Strategies For Complex Websites
 
Creating An Inclusive Web
Creating An Inclusive WebCreating An Inclusive Web
Creating An Inclusive Web
 
Diginius - DuckDuckGo, Privacy and the Future of Search
Diginius - DuckDuckGo, Privacy and the Future of Search Diginius - DuckDuckGo, Privacy and the Future of Search
Diginius - DuckDuckGo, Privacy and the Future of Search
 
Twitter taitekohdassa
Twitter taitekohdassaTwitter taitekohdassa
Twitter taitekohdassa
 
How to convince even the pickiest editors to take SEO more seriously :: brigh...
How to convince even the pickiest editors to take SEO more seriously :: brigh...How to convince even the pickiest editors to take SEO more seriously :: brigh...
How to convince even the pickiest editors to take SEO more seriously :: brigh...
 
Creating interest based content for google discover
Creating interest based content for google discoverCreating interest based content for google discover
Creating interest based content for google discover
 
Giulia Panozzo | BrightonSEO Measurefest | October 2022
Giulia Panozzo | BrightonSEO Measurefest | October 2022Giulia Panozzo | BrightonSEO Measurefest | October 2022
Giulia Panozzo | BrightonSEO Measurefest | October 2022
 
How to rethink the traditional SEO workspace to promote team wellbeing and pr...
How to rethink the traditional SEO workspace to promote team wellbeing and pr...How to rethink the traditional SEO workspace to promote team wellbeing and pr...
How to rethink the traditional SEO workspace to promote team wellbeing and pr...
 
Not Just Pride Month: Crafting LGBTQ+-Inclusive Campaigns Year Round - bright...
Not Just Pride Month: Crafting LGBTQ+-Inclusive Campaigns Year Round - bright...Not Just Pride Month: Crafting LGBTQ+-Inclusive Campaigns Year Round - bright...
Not Just Pride Month: Crafting LGBTQ+-Inclusive Campaigns Year Round - bright...
 
How to do keyword research in a language you don’t speak, by Lidia Infante
How to do keyword research in a language you don’t speak, by Lidia InfanteHow to do keyword research in a language you don’t speak, by Lidia Infante
How to do keyword research in a language you don’t speak, by Lidia Infante
 
WTSFest 2023 - Data Storytelling, Lazarina Stoy. (3).pdf
WTSFest 2023 - Data Storytelling, Lazarina Stoy. (3).pdfWTSFest 2023 - Data Storytelling, Lazarina Stoy. (3).pdf
WTSFest 2023 - Data Storytelling, Lazarina Stoy. (3).pdf
 
[TurnDigi 2020] Getting Tech SEO Implemented
[TurnDigi 2020] Getting Tech SEO Implemented[TurnDigi 2020] Getting Tech SEO Implemented
[TurnDigi 2020] Getting Tech SEO Implemented
 
Kathryn Bevan - How To Ace Your Website Migration - Brighton SEO Slides
Kathryn Bevan - How To Ace Your Website Migration - Brighton SEO Slides Kathryn Bevan - How To Ace Your Website Migration - Brighton SEO Slides
Kathryn Bevan - How To Ace Your Website Migration - Brighton SEO Slides
 
Issie Hannah - Brighton SEO Slides 2023.pptx
Issie Hannah - Brighton SEO Slides 2023.pptxIssie Hannah - Brighton SEO Slides 2023.pptx
Issie Hannah - Brighton SEO Slides 2023.pptx
 
How to overcome the fear of taking time off.pptx
How to overcome the fear of taking time off.pptxHow to overcome the fear of taking time off.pptx
How to overcome the fear of taking time off.pptx
 
Information Architecture & Findability
Information Architecture & FindabilityInformation Architecture & Findability
Information Architecture & Findability
 
Google Discover Optimisation with Google Web Stories
Google Discover Optimisation with Google Web StoriesGoogle Discover Optimisation with Google Web Stories
Google Discover Optimisation with Google Web Stories
 
Brighton Y U No Reply_Bibi the Link Builder.pdf
Brighton Y U No Reply_Bibi the Link Builder.pdfBrighton Y U No Reply_Bibi the Link Builder.pdf
Brighton Y U No Reply_Bibi the Link Builder.pdf
 
What is Information Design?
What is Information Design?What is Information Design?
What is Information Design?
 

Similar a State of PrintCSS - MarkupUK 2023.pdf

Web design-workflow
Web design-workflowWeb design-workflow
Web design-workflow
Peter Kaizer
 
Custom Development for SharePoint
Custom Development for SharePointCustom Development for SharePoint
Custom Development for SharePoint
Talbott Crowell
 
FITC - 2012-04-23 - Responsive Web Design
FITC - 2012-04-23 - Responsive Web DesignFITC - 2012-04-23 - Responsive Web Design
FITC - 2012-04-23 - Responsive Web Design
Frédéric Harper
 

Similar a State of PrintCSS - MarkupUK 2023.pdf (20)

Web design-workflow
Web design-workflowWeb design-workflow
Web design-workflow
 
SPS Monaco 2017 - The Lay of the Land of Client-Side Development circa 2017
SPS Monaco 2017 - The Lay of the Land of Client-Side Development circa 2017SPS Monaco 2017 - The Lay of the Land of Client-Side Development circa 2017
SPS Monaco 2017 - The Lay of the Land of Client-Side Development circa 2017
 
Web design training , Web Design Training In Kolkata
Web design training , Web Design Training In KolkataWeb design training , Web Design Training In Kolkata
Web design training , Web Design Training In Kolkata
 
Approaches to Responsive Wen Design & Development
Approaches to Responsive Wen Design & DevelopmentApproaches to Responsive Wen Design & Development
Approaches to Responsive Wen Design & Development
 
IWMW 1997: Web tools
IWMW 1997: Web toolsIWMW 1997: Web tools
IWMW 1997: Web tools
 
SEF 2014 - Responsive Design in SharePoint 2013
SEF 2014 - Responsive Design in SharePoint 2013SEF 2014 - Responsive Design in SharePoint 2013
SEF 2014 - Responsive Design in SharePoint 2013
 
PrintCSS W3C workshop at XMLPrague 2020
PrintCSS W3C workshop at XMLPrague 2020PrintCSS W3C workshop at XMLPrague 2020
PrintCSS W3C workshop at XMLPrague 2020
 
Javascript Template Engine - Getting Started
Javascript Template Engine - Getting StartedJavascript Template Engine - Getting Started
Javascript Template Engine - Getting Started
 
Building Responsive Intranet using Sharepoint Framework solutions - Asish Pad...
Building Responsive Intranet using Sharepoint Framework solutions - Asish Pad...Building Responsive Intranet using Sharepoint Framework solutions - Asish Pad...
Building Responsive Intranet using Sharepoint Framework solutions - Asish Pad...
 
Converting and Transforming Technical Graphics
Converting and Transforming Technical GraphicsConverting and Transforming Technical Graphics
Converting and Transforming Technical Graphics
 
The Great Consolidation - Entertainment Weekly Migration Case Study - SANDcam...
The Great Consolidation - Entertainment Weekly Migration Case Study - SANDcam...The Great Consolidation - Entertainment Weekly Migration Case Study - SANDcam...
The Great Consolidation - Entertainment Weekly Migration Case Study - SANDcam...
 
Custom Development for SharePoint
Custom Development for SharePointCustom Development for SharePoint
Custom Development for SharePoint
 
Responsive Web Design - Web & PHP Conference - 2013-09-18
Responsive Web Design - Web & PHP Conference - 2013-09-18Responsive Web Design - Web & PHP Conference - 2013-09-18
Responsive Web Design - Web & PHP Conference - 2013-09-18
 
The Characteristics of a Successful SPA
The Characteristics of a Successful SPAThe Characteristics of a Successful SPA
The Characteristics of a Successful SPA
 
Cool Tools for Technical Writers
Cool Tools for Technical WritersCool Tools for Technical Writers
Cool Tools for Technical Writers
 
Metadata & Interoperability: Free Tools
Metadata & Interoperability: Free ToolsMetadata & Interoperability: Free Tools
Metadata & Interoperability: Free Tools
 
FITC - 2012-04-23 - Responsive Web Design
FITC - 2012-04-23 - Responsive Web DesignFITC - 2012-04-23 - Responsive Web Design
FITC - 2012-04-23 - Responsive Web Design
 
Webinar - Transforming Graphical Data
Webinar - Transforming Graphical DataWebinar - Transforming Graphical Data
Webinar - Transforming Graphical Data
 
Incremental DOM and Recent Trend of Frontend Development
Incremental DOM and Recent Trend of Frontend DevelopmentIncremental DOM and Recent Trend of Frontend Development
Incremental DOM and Recent Trend of Frontend Development
 
Your Intranet, Your Way
Your Intranet, Your WayYour Intranet, Your Way
Your Intranet, Your Way
 

Más de Andreas Jung

Más de Andreas Jung (20)

Typesense Plone Integration Plone Conference 2022 Namur
Typesense Plone Integration Plone Conference 2022 NamurTypesense Plone Integration Plone Conference 2022 Namur
Typesense Plone Integration Plone Conference 2022 Namur
 
Onkopedia - Plone Tagung 2020 Dresden
Onkopedia - Plone Tagung 2020 DresdenOnkopedia - Plone Tagung 2020 Dresden
Onkopedia - Plone Tagung 2020 Dresden
 
PrintCSS workshop XMLPrague 2020
PrintCSS workshop XMLPrague 2020PrintCSS workshop XMLPrague 2020
PrintCSS workshop XMLPrague 2020
 
Plone 5.2 migration at University Ghent, Belgium
Plone 5.2 migration at University Ghent, BelgiumPlone 5.2 migration at University Ghent, Belgium
Plone 5.2 migration at University Ghent, Belgium
 
Back to the future - Plone 5.2 und Python 3 Migration am Beispiel Onkopedia
Back to the future - Plone 5.2 und Python 3 Migration am Beispiel OnkopediaBack to the future - Plone 5.2 und Python 3 Migration am Beispiel Onkopedia
Back to the future - Plone 5.2 und Python 3 Migration am Beispiel Onkopedia
 
Plone migrations using plone.restapi
Plone migrations using plone.restapiPlone migrations using plone.restapi
Plone migrations using plone.restapi
 
Plone Migrationen mit Plone REST API
Plone Migrationen mit Plone REST APIPlone Migrationen mit Plone REST API
Plone Migrationen mit Plone REST API
 
Plone im Einsatz bei der Universität des Saarländes als Shop-System und Gefah...
Plone im Einsatz bei der Universität des Saarländes als Shop-System und Gefah...Plone im Einsatz bei der Universität des Saarländes als Shop-System und Gefah...
Plone im Einsatz bei der Universität des Saarländes als Shop-System und Gefah...
 
Generierung von PDF aus XML/HTML mit PrintCSS
Generierung von PDF aus XML/HTML mit PrintCSSGenerierung von PDF aus XML/HTML mit PrintCSS
Generierung von PDF aus XML/HTML mit PrintCSS
 
Creating Content Together - Plone Integration with SMASHDOCs
Creating Content Together - Plone Integration with SMASHDOCsCreating Content Together - Plone Integration with SMASHDOCs
Creating Content Together - Plone Integration with SMASHDOCs
 
Creating Content Together - Plone Integration with SMASHDOCs
Creating Content Together - Plone Integration with SMASHDOCsCreating Content Together - Plone Integration with SMASHDOCs
Creating Content Together - Plone Integration with SMASHDOCs
 
The Plone and The Blockchain
The Plone and The BlockchainThe Plone and The Blockchain
The Plone and The Blockchain
 
Content Gemeinsam Erstellen: Integration Plone mit SMASHDOCs
Content Gemeinsam Erstellen: Integration Plone mit SMASHDOCsContent Gemeinsam Erstellen: Integration Plone mit SMASHDOCs
Content Gemeinsam Erstellen: Integration Plone mit SMASHDOCs
 
PDF Generierung mit XML/HTML und CSS - was die Tools können und was nicht.
PDF Generierung mit XML/HTML und CSS - was die Tools können und was nicht.PDF Generierung mit XML/HTML und CSS - was die Tools können und was nicht.
PDF Generierung mit XML/HTML und CSS - was die Tools können und was nicht.
 
Why we love ArangoDB. The hunt for the right NosQL Database
Why we love ArangoDB. The hunt for the right NosQL DatabaseWhy we love ArangoDB. The hunt for the right NosQL Database
Why we love ArangoDB. The hunt for the right NosQL Database
 
XML Director - the technical foundation of onkopedia.com
XML Director - the technical foundation of onkopedia.comXML Director - the technical foundation of onkopedia.com
XML Director - the technical foundation of onkopedia.com
 
PyFilesystem
PyFilesystemPyFilesystem
PyFilesystem
 
Building bridges - Plone Conference 2015 Bucharest
Building bridges   - Plone Conference 2015 BucharestBuilding bridges   - Plone Conference 2015 Bucharest
Building bridges - Plone Conference 2015 Bucharest
 
CSS Paged Media - A review of tools and techniques
CSS Paged Media - A review of tools and techniquesCSS Paged Media - A review of tools and techniques
CSS Paged Media - A review of tools and techniques
 
Integration of Plone with eXist-db
Integration of Plone with eXist-dbIntegration of Plone with eXist-db
Integration of Plone with eXist-db
 

Último

EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
Earley Information Science
 

Último (20)

Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 

State of PrintCSS - MarkupUK 2023.pdf

  • 1. Andreas Jung • info@zopyx.com • print-css.rocks State of PrintCSS in 2023 MarkupUK 2023, London
  • 2. Agenda (this is not a PrintCSS tutorial) • Brief introduction to PrintCSS and its standards • The problems with comparing tools • Free PrintCSS tools • Commercial CSS tools • Role of Javascript in PrintCSS • The pain points with PrintCSS • Decision criteria • Q & A
  • 3. Publishing developer & consultant since mid-90s https://print-css.rocks https://andreas-jung.com ✉ info@zopyx.com Funder of print-css.rocks project Independent PrintCSS consulting - Software developer & software architect - Requirements engineering - Python developer & Python expert - NGOs, EDU - medical & pharmaceutical - energy - research & development quantum mechanics - CMS Solutions - Publishing Solutions - Individual software solutions About me
  • 5. The PrintCSS process • Input: HTML (or XML) • Styling: CSS • Formatting: a free or commercial PrintCSS renderer • Output: PDF
  • 6. Definition of „PrintCSS“ „PrintCSS“ synonym for „W3C CSS Paged Media“ W3C CSS Paged Media Level 3 (2018) • the official standard for generated paginated content aka PDF from HTML using cascading stylesheets (CSS) Related standards: • CSS Generated Content for Paged Media Module (2014, GCPM)
  • 7. Comparing tools, metrics and their problems How to compare tools in a reasonable way? Problems • we have many PrintCSS tools • we have hundreds of CSS properties + PrintCSS specific CSS properties • we can not test all tools against all CSS properties (not manually, not automatically) • W3C standards do not cover everything, leaving room for interpretations Metrics and approach of print-css.rocks • testing the core PrintCSS features (W3C Paged Media, GCPM) • focus on high-level topics (e.g. footnotes, CSS grid, RTL)
  • 8. How we do in print-css.rocks?
  • 9. How we do in print-css.rocks?
  • 10. How we do in print-css.rocks?
  • 11. Standards, non-standards and extensions Example: variations on footnotes …not even talking of • endnotes 😈 • sidenotes 😈 Standard no standard
  • 13. Free PrintCSS renderers (Feature selection is highly opinionated) WeasyPrint Vivliostyle PagedJS Python Javascript/ Chromium Javascript/ Chromium ✅ solid core ✅ Flexbox ✅ Hyphenation ✅ simple footnote support ✅ solid core ✅ Javascript support ✅ MathML ✅ simple footnote support ❌ Grid ❌ Javascript ❌ XML ❌ Hyphentation ❌ XML ❌ many unfixed issues and bugs good community support good community support community support 🤷 👍 actively maintained 👍 actively maintained 👎👎 badly maintained
  • 15. Commercial PrintCSS renderers (Feature selection is highly opinionated) Typeset.sh Prince PDFreactor BFO Publisher Antennahouse Formatter PHP Java Java ✅ solid core ✅ Grid & Flexbox ✅ very mature ✅ Javascript ✅ Flexbox ✅ excellent docs/examples (https://css4.pub/) ✅ XML ✅ very mature ✅ Javascript ✅ Grid & Flexbox ✅ XML ✅ solid core ✅ very mature ✅ most advanced typography features ✅ most complete ✅ XML • young project • has some rough edges here and there ❌ Grid • young product • has some rough edges • not much experience ❌ Grid ❌ Flexbox ❌ Javascript ✅ excellent support ✅ excellent support ✅ excellent support ✅ excellent support 👍 actively maintained 👍👍 actively maintained 👍 actively maintained 👍 actively maintained 👍👍 actively maintained 89 € (annual) or 499 € (perpetual licence) 3800 USD (4 CPUs) 2.950 € (4 CPUs) n/a 5000 USD (1st CPU) * check pricing for educational license or „personal“ usage licenses
  • 17. Why Javascript? Javascript is the „Franca Lingua“ of the web (besides HTML) Javascript on the web: • no modern web solutions without Javascript • omnipresent Javascript in Print/PrintCSS • provide enhanced visualizations (graphs, charts etc) from the web in print • for content: ideally Javascript visualization that work on the web, should work in PrintCSS • for internal usage: influencing the rendering process of the PrintCSS renderer • generating TOC, listings, indices
  • 18. Situation of Javascript support in renderers well… Renderer PagedJS Prince PDFreactor Vivliostyle Implementation Chromium/native custom JS engine custom JS engine Chromium/native JS compatibility for PDF generation unknown selected JS packages selected JS packages best compatibility for JS modules (where they make sense) JS for internal usage unknown • adaptive rendering • adaptive image scaling • table of contents • adaptive rendering • adaptive image scaling • table of contents unknown
  • 19. The pain points with PrintCSS
  • 20. The dark side of PrintCSS and its renderers Problems and pain points • inconsistent implementations and behavior of renderers (due to incomplete or inconsistent Paged Media specifications) • different defaults (page size, borders, page area dimensions etc.) • easy things often work differently across tools • complex topics • floats • adaptive rendering of images • handling of long or wide tables
  • 22. Is your publishing use case suitable for PrintCSS? Automatic typesetting means automatic!!! No manual interaction!!!
  • 23. Know your typographic and layout requirements …an opinionated selection of criteria • Is your publication text-oriented or layout-oriented? • Do you need a grid system or flex box? • Do you need a baseline grid? • Support for multiple columns needed? • Footnotes required? • Floating objects needed?
  • 24. Do I need Javascript? • Do you have to interact with external Javascript modules (charts etc.)? • Do you need Javascript support inside the renderer or can you prepare Javascript-based assets in a pre-processing step?
  • 25. Do I have XML or HTML as input? • only some renderers speak XML natively • but all renderers handle HTML • raw XML often not directly suitable unless transformed to publishable XML or HTML • PrintCSS is not a transformation framework • flat or nested HTML? • personal preference: nested HTML but YMMV
  • 26. Do I have special PDF requirements? • PDF metadata • PDF variants • PDF/UA (accessibility) • PDF/X (print) • PDF/A (archiving) • supported by most commercial renderers • PDF security (encryption, signing) • supported by most commercial renderers
  • 27. Other features needed? • Scientific context? (formulas, MathML, MathJax) • integration of renderers in workflows: • all tools run on the command line • some tools provide a server mode • some tools provide APIs for integration with PHP, Python etc. • Produce & Publish server (abstraction of renderers)
  • 29. Recommendation and hints • be aware of your special requirements (regarding more complex features) • build prototypes and evaluate against different renderers • use CSS variables (not widely supported) • consider using CSS preprocessors (e.g. Less, Sass) for complex workloads • start with free tools, use commercial tools if needed
  • 30. Q & A
  • 31. Thank you for listening Andreas Jung • info@zopyx.com • print-css.rocks