Prince (software)

Last updated
Prince
Original author(s) Michael Day [1]
Developer(s) YesLogic Pty Ltd
Initial releaseApril 2003
Stable release
15.2 [2] / October 2023;17 days ago (October 2023)
Preview release
20191023 / 23 October 2019;3 years ago (2019-10-23) [3]
Written in Mercury, Rust [4]
Operating system Windows, macOS, Linux, Solaris, FreeBSD
Type File format converter
License Freemium
Website www.princexml.com

Prince (formerly Prince XML) is a computer program that converts XML and HTML documents into PDF files by applying Cascading Style Sheets (CSS). Prince is a commercial product, which is free to download and use for non-commercial purposes. [5]

Contents

Prince supports all common web standards, including HTML, CSS and JavaScript, through its own code. That is, Prince is not based on a browser engine, but implements its own engine.

Prince can generate accessible PDFs conforming to the PDF/UA profile (ISO 14289, the International Standard for accessible PDF technology) that can be used by people with assistive technologies. [6]

Prince supports many languages, including Thai, Indic scripts (Hindi, Bengali, Tamil, etc.) [7] and right-to-left scripts like Arabic and Hebrew.

Prince is developed by YesLogic, a small company based in Melbourne, Australia. Since 2004, Håkon Wium Lie, the co-creator of CSS, has been chairman of the board.

History

In April 2003, Prince 1.0 was released, with basic support for XHTML, Cascading Style Sheets (CSS), Scalable Vector Graphics (SVG), and arbitrary XML. This first version was a command-line program that supported Microsoft Windows and Linux; there was no graphical user interface for Windows yet.

In December 2005, Prince 5.1 passed the Acid2 test from the Web Standards Project. [8] It was the third user agent to pass the test, after Safari and Konqueror.

In June 2012, Prince 8.1 added support for HTML5.

In subsequent releases, CSS support has steadily been extended, both to have comparable support with web browsers (such as Opera and Firefox), and to add support for print-specific features, like page breaks and footnotes.

Prince is available for several platforms, including Windows, Linux, macOS, FreeBSD, and Solaris. Wrappers are available for Java SE, .NET Framework, ActiveX, PHP, Ruby on Rails and Node.js to help integrate Prince into websites and apps.

Technical summary

Prince was developed primarily using the Mercury functional logic programming language.

The main driving force behind Prince is the standard CSS3-paged [9] that integrates paged media (including PDF) layout specification with any other W3C technologies: HTML4, HTML5, XHTML, and "free XML", working or not with JavaScript.

More experimental facilities for print needs (for example, footnote policies, specifying the size of the bleed area of the page when crop marks are enabled, creating running page headers and footers and similar) are being standardized in the Generated Content for Paged Media (css-gcpm-3) CSS module.

Prince has good support for CSS, with a print focus: better than web browsers for print-specific CSS modules such as the aforementioned css-page-3 and css-gcpm-3; while support other modules is good relative to other user agents not using a web browser engine but not always as well as web browsers: [10] for example, CSS Flexible Box Model was added in Prince 12 (2018), whereas CSS Grid Layout (css-grid-1) is not yet present in Prince 14.

Prince supports most of ECMAScript 5th edition, but not strict mode. Later editions of ECMAScript are largely not supported. [10]

Related Research Articles

<span class="mw-page-title-main">Document Object Model</span> Convention for representing and interacting with objects in HTML, XHTML, and XML documents

The Document Object Model (DOM) is a cross-platform and language-independent interface that treats an HTML or XML document as a tree structure wherein each node is an object representing a part of the document. The DOM represents a document with a logical tree. Each branch of the tree ends in a node, and each node contains objects. DOM methods allow programmatic access to the tree; with them one can change the structure, style or content of a document. Nodes can have event handlers attached to them. Once an event is triggered, the event handlers get executed.

<span class="mw-page-title-main">HTML</span> HyperText Markup Language

The HyperText Markup Language or HTML is the standard markup language for documents designed to be displayed in a web browser. It defines the meaning and structure of web content. It is often assisted by technologies such as Cascading Style Sheets (CSS) and scripting languages such as JavaScript.

Scalable Vector Graphics (SVG) is an XML-based vector image format for defining two-dimensional graphics, having support for interactivity and animation. The SVG specification is an open standard developed by the World Wide Web Consortium since 1999.

Mathematical Markup Language (MathML) is a mathematical markup language, an application of XML for describing mathematical notations and capturing both its structure and content, and is one of a number of mathematical markup languages. Its aim is to natively integrate mathematical formulae into World Wide Web pages and other documents. It is part of HTML5 and standardised by ISO/IEC since 2015.

A HTML editor is a program used for editing HTML, the markup of a web page. Although the HTML markup in a web page can be controlled with any text editor, specialized HTML editors can offer convenience, added functionality, and organisation. For example, many HTML editors handle not only HTML, but also related technologies such as CSS, XML and JavaScript or ECMAScript. In some cases they also manage communication with remote web servers via FTP and WebDAV, and version control systems such as Subversion or Git. Many word processing, graphic design and page layout programs that are not dedicated to web design, such as Microsoft Word or Quark XPress, also have the ability to function as HTML editors.

An HTML element is a type of HTML document component, one of several types of HTML nodes. The first used version of HTML was written by Tim Berners-Lee in 1993 and there have since been many versions of HTML. The most commonly used version is HTML 4.01, which became official standard in December 1999. An HTML document is composed of a tree of simple HTML nodes, such as text nodes, and HTML elements, which add semantics and formatting to parts of document. Each element can have HTML attributes specified. Elements can also have content, including other elements and text.

XForms is an XML format used for collecting inputs from web forms. XForms was designed to be the next generation of HTML / XHTML forms, but is generic enough that it can also be used in a standalone manner or with presentation languages other than XHTML to describe a user interface and a set of common data manipulation tasks.

Web standards are the formal, non-proprietary standards and other technical specifications that define and describe aspects of the World Wide Web. In recent years, the term has been more frequently associated with the trend of endorsing a set of standardized best practices for building web sites, and a philosophy of web design and development that includes those methods.

<span class="mw-page-title-main">W3C Markup Validation Service</span> Validator service by the World Wide Web Consortium

The Markup Validation Service is a validator by the World Wide Web Consortium (W3C) that allows Internet users to check pre-HTML5 HTML and XHTML documents for well-formed markup against a document type definition. Markup validation is an important step towards ensuring the technical quality of web pages. However, it is not a complete measure of web standards conformance. Though W3C validation is important for browser compatibility and site usability, it has not been confirmed what effect it has on search engine optimization.

Cross-browser compatibility is the ability of a website or web application to function across different browsers and degrade gracefully when browser features are absent or lacking.

The Web Standards Project (WaSP) was a group of professional web developers dedicated to disseminating and encouraging the use of the web standards recommended by the World Wide Web Consortium, along with other groups and standards bodies.

In HTML, div and span tags are elements used to define parts of a document, so that they are identifiable when a unique classification is necessary. Where other HTML elements such as p (paragraph), em (emphasis), and so on, accurately represent the semantics of the content, the additional use of span and div tags leads to better accessibility for readers and easier maintainability for authors. Where no existing HTML element is applicable, span and div can valuably represent parts of a document so that HTML attributes such as class, id, lang, or dir can be applied.

RDFa or Resource Description Framework in Attributes is a W3C Recommendation that adds a set of attribute-level extensions to HTML, XHTML and various XML-based document types for embedding rich metadata within Web documents. The Resource Description Framework (RDF) data-model mapping enables its use for embedding RDF subject-predicate-object expressions within XHTML documents. It also enables the extraction of RDF model triples by compliant user agents.

SCXML stands for State Chart XML: State Machine Notation for Control Abstraction. It is an XML-based markup language that provides a generic state-machine-based execution environment based on Harel statecharts.

In computer science and web development, XML Events is a W3C standard for handling events that occur in an XML document. These events are typically caused by users interacting with the web page using a device, such as a web browser on a personal computer or mobile phone.

<span class="mw-page-title-main">HTML5</span> Fifth and current version of hypertext markup language

HTML5 is a markup language used for structuring and presenting content on the World Wide Web. It is the fifth and final major HTML version that is a World Wide Web Consortium (W3C) recommendation. The current specification is known as the HTML Living Standard. It is maintained by the Web Hypertext Application Technology Working Group (WHATWG), a consortium of the major browser vendors.

<span class="mw-page-title-main">Acid3</span> Online HTML rendering test

The Acid3 test is a web test page from the Web Standards Project that checks a web browser's compliance with elements of various web standards, particularly the Document Object Model (DOM) and JavaScript.

Extensible HyperText Markup Language (XHTML) is part of the family of XML markup languages. It mirrors or extends versions of the widely used HyperText Markup Language (HTML), the language in which Web pages are formulated.

<span class="mw-page-title-main">CSS</span> Style sheet language

Cascading Style Sheets (CSS) is a style sheet language used for describing the presentation of a document written in a markup language such as HTML or XML. CSS is a cornerstone technology of the World Wide Web, alongside HTML and JavaScript.

<span class="mw-page-title-main">CSS HTML Validator</span>

CSS HTML Validator is an HTML editor and CSS editor for Windows that helps web developers create syntactically correct and accessible HTML/HTML5, XHTML, and CSS documents by locating errors, potential problems like browser compatibility issues, and common mistakes. It is also able to check links, check spelling, suggest improvements, alert developers to deprecated, obsolete, or proprietary tags, attributes, and CSS properties, and find issues that can affect search engine optimization.

References

  1. Michael Day: I am the founder of YesLogic and the designer of Prince, software for getting web content onto paper.
  2. "Prince - Release Notes for Prince 15".
  3. "Prince - Latest builds". www.princexml.com.
  4. "Announcing the Allsorts Font Shaping Engine". yeslogic.com.
  5. "Prince - End User License Agreement". www.princexml.com.
  6. "Prince 12 released! - Prince forum". www.princexml.com.
  7. "Devanagari vowel sign support - Prince forum". www.princexml.com.
  8. Prince 5.1 Passes Acid2 Web Standards Project announcement, December 10, 2005
  9. CSS Paged Media Module Level 3, W3C
  10. 1 2 "doc-refs · Prince Documentation". www.princexml.com.

Further reading