Domain: princexml.com
Stories and comments across the archive that link to princexml.com.
Comments · 23
-
Re:Long live TeX and LaTeX
While I'd concede it's not "just HTML", I've had pretty good success producing attractive documents with HTML and CSS using Prince. Sadly it's pretty expensive and I've only ever managed to persuade one company to spring for a licence, which we predominantly used to produce PDF versions of HTML documents.
This article prompted me to look again for open source alternatives and this time I turned up WeasyPrint. I've not had a chance to give it a try yet, but it feels to me like one could build a pretty compelling document preparation stack with a nice semantic, WYSIWYG, stylesheet-enabled HTML editor coupled with either Prince or WeasyPrint for final output. As with most typesetting, the final printed product won't exactly match what's on-screen, but it could do a pretty good job as well as producing a document that's pleasant for on-screen viewing to boot.
-
Printing from HTML/CSS
Anyone needing to produce good-looking print-form documents from content that "lives" on the web should check out http://www.princexml.com/.
Prince supports most CSS3 and has a number of CSS extensions that help you control formatting. So getting well-formed and styled HTML to print beautifully is a relatively painless step forward. -
Re:LaTeX?
Very few people can actually use LaTeX. It's an exceptionally user-hostile approach to writing text. Yes, I know some people still use vi, but that doesn't make vi a good word processor. Similarly, LaTeX has exceptional strengths for creating particular sorts of highly technical documents, but for the sorts of documents most people write it is overcomplicated and just gets in the way.
Most people don't want to learn a new language before they can write a simple document. Even if they do want to learn a new language, Markdown is good enough for most people's uses - you can produce damn nice looking documents and, yes, books with it (my toolchain is text piped through a sed script which renders the markdown into rough HTML, through JTidy which cleans that up, through Prince which translates the HTML into nicely rendered PDF, and thence to print. I could use LaTeX - I have used LaTeX - but except for very complicated technical documents it just isn't worth it.
-
CSS is fine for print - pages aren't good for web
One of the major advantages of electronic viewing is that you aren't limited by physical constraints like page size.
If paged media styles were introduced as part of the "web browsing experience" then either there would be the extra overhead of calculating the screen size then setting the optimal page size or your pages would look like crap on the devices they weren't explicitly built for and would need scrollbars anyway. The you run into the epub awkwardness of using physical page numbers for electronic documents. So you scroll 3 or 4 screens and you are still on page 2 because that is what matches the physical document.
There is no need for things like indices in electronic media because you have the far superior search function for anything that might interest you. TOCs work better due to hyperlinking. You don't need traditional running headers or footers or footnotes in electronic media, all of that can be more elegantly handled by the reading application.
That isn't to say there isn't a place for styling physical documents with CSS. The best business case I can think of is if you want to have a good looking, informative web page and also print out the content into a well formatted physical document. With CSS formatting you only have to maintain a single set of stylesheets along with the paged media pseudoclasses describing the page information.
A quick search shows a couple of products that support CSS paged media formatting:
antenna house and princeI'm sure there are more if anyone cares to look.
-
Re:Stop using the browser for print
Export your data to XML or PDF on the fly and have something sensible print it.
-
Re:CSS3 is the solution
I don't think he needs a browser, just a CSS3-compliant client that will print out his documents correctly, such as Prince, which creates perfect PDFs from HTML+CSS3. See "Printing a Book with CSS: Boom!". That should be enough, for the time being, until browsers catch up.
-
Re:Have you looked at PrinceXML?
Thirded. PrinceXML is precisely what you ask for. See the sample output and judge for yourself.
-
Re:Have you looked at PrinceXML?
Thirded. PrinceXML is precisely what you ask for. See the sample output and judge for yourself.
-
Re:Learn the tools first, then worry about changin
As the previous poster said: in the context of HTML + CSS have a look at 'Prince XML' (http://www.princexml.com/overview//). From the website ('why type if you can copy & paste'
;-) ): "Prince is a computer program that converts XML and HTML into PDF documents. Prince can read many XML formats, including XHTML and SVG. Prince formats documents according to style sheets written in CSS. Prince is available for several platforms and is easy to download and install. We offer a free Personal license for interactive use on a single computer." I have used it successfully for some personal projects and if you're already somewhat familiar with HTML & CSS it's real easy to get into. Don't forget to check out the examples on the site. -
Learn the tools first, then worry about changing
See, as someone has already pointed out, there's at least one such tool that's in wide use already: TeX and LaTeX. If you don't like that one, it turns out that HTML, with CSS and a little bit of Javascript, is perfectly capable of doing all the things you want, too. You just have to learn how. Have a look at Lie's Cascading Style Sheets: Designing for the Web (written and typeset in HTML/CSS) and at Prince XML for detailed examples.
-
Prince XML
I think writing papers using XHTML and CSS 2.1 or 3 is a good idea. Then you can use Prince XML to convert it to PDF. Their site has a nice sample or two of journal articles / conference papers. The quality of the renderer is great. It was even used to create a professional book, Cascading Style Sheets: Designing for the Web.
-
Word < LaTeX < Print CSS
the ability to separate content from presentation. A closer example would be if HTML + CSS could handle all these things.
It can. CSS supports print media as well as screen media, and speech media. It's fully possible to write a document in HTML with modern features like unicode, mathml, etc., and run it through a program to get nice printed output. Unfortunately it's not quite a click-to-convert process, and it's not one many people know about. The most well-known example of it is a tool called Prince, which produces high-quality stuff like this Wikipedia page rendered to PDF via CSS. See the Prince Samples page for more.
I think Prince is proprietary, but it's freely downloadable with packages for many distros already made, and I think if people realised what a nice solution it is, we could replace TeX etc. fairly quickly, and have a modern HTMLpublication system which works well with long documents, modern vector graphics and math and languages etc., and also works well with standard software version control tools like Git.
-
Word < LaTeX < Print CSS
the ability to separate content from presentation. A closer example would be if HTML + CSS could handle all these things.
It can. CSS supports print media as well as screen media, and speech media. It's fully possible to write a document in HTML with modern features like unicode, mathml, etc., and run it through a program to get nice printed output. Unfortunately it's not quite a click-to-convert process, and it's not one many people know about. The most well-known example of it is a tool called Prince, which produces high-quality stuff like this Wikipedia page rendered to PDF via CSS. See the Prince Samples page for more.
I think Prince is proprietary, but it's freely downloadable with packages for many distros already made, and I think if people realised what a nice solution it is, we could replace TeX etc. fairly quickly, and have a modern HTMLpublication system which works well with long documents, modern vector graphics and math and languages etc., and also works well with standard software version control tools like Git.
-
Word < LaTeX < Print CSS
the ability to separate content from presentation. A closer example would be if HTML + CSS could handle all these things.
It can. CSS supports print media as well as screen media, and speech media. It's fully possible to write a document in HTML with modern features like unicode, mathml, etc., and run it through a program to get nice printed output. Unfortunately it's not quite a click-to-convert process, and it's not one many people know about. The most well-known example of it is a tool called Prince, which produces high-quality stuff like this Wikipedia page rendered to PDF via CSS. See the Prince Samples page for more.
I think Prince is proprietary, but it's freely downloadable with packages for many distros already made, and I think if people realised what a nice solution it is, we could replace TeX etc. fairly quickly, and have a modern HTMLpublication system which works well with long documents, modern vector graphics and math and languages etc., and also works well with standard software version control tools like Git.
-
Re:XHTML and CSS
Check out PrinceXML. It actually adds footnotes, page number, and all that stuff to standard XHTML+CSS. It has already been used to typeset a book, and it looks quite nice. The authors of the one book have talked about their experiences with it
Their tool renders into PDF, but the same based XHTML will work in a web browser, giving the option of having the same document look good on paper and on the web.There is also a Google Tech Talk on PrinceXML
-
Prince XML Used?
I was looking at converting HTML into PDF and found Prince XML . Some authors of a professional book on CSS wrote it in HTML and used Price XML to generate the master PDF document they sent to the printing press. This page has what a PDF version of wikipedia would look like. You can change the look by just changing the CSS.
-
Prince XML Used?
I was looking at converting HTML into PDF and found Prince XML . Some authors of a professional book on CSS wrote it in HTML and used Price XML to generate the master PDF document they sent to the printing press. This page has what a PDF version of wikipedia would look like. You can change the look by just changing the CSS.
-
Re:The best tools stay out of the way...Amen, brother. That's why I like to use sed and shell echos, pipes, and redirects to do my word processing.
Many a true word spoken in jest. My 'word processor' now consists of shell script which uses sed to convert my own very idiosyncratic markup into HTML, pipes that through tidy and then through an XSL transform which adds standard boilerplate headers as required and then through Prince to generate print-ready PDF.
Why?
- First, it means I can use any text editor I like to edit my text (currently I use kate);
- Second, it plays nice with CVS;
- Third, I can define my own markup at any time;
- Fourth, it saves distractions;
- Fifth, it separated content from presentation, so that I can produce an editor's galley proof or a print-ready paperback from the same text.
OK, I accept this wouldn't suit everyone but it works for me.
-
Re:PDF
Others recommended a few good ones. If you're in the research arena and you print to PDF and are crazy about getting your layout precisely correct, I suggest you check out PrinceXML. Full XML+CSS to PDF printing. For printing random web pages you may get away with running the HTML SGML through Tidy to produce valid XHTML which you can pipe through PrinceXML, but something like cups-pdf will probably work easier for you.
-
X(HT)ML+CSS?
I had been thinking that ODF was "obviously" a good thing until I read the rant by Opera's CTO about how shit both standards are (a memory dump between angle brackets), and how the correct way would be to go for XHTML with CSS formatting.
Like, seriously, why not? Have we not been here before, going "so we need to separate content from display" and was not the eventual solution actually rather good. It took ten years or so to get adopted, but nobody is denying that css has made the web a less obnoxious place. There are no technical reasons why it can't be extended to all aspects of "office" publishing/collaboration, and indeed a book has been published using XML+CSS.
I know that ODF is "here now", and it must be an improvement over Office's internal format ... but I'm concerned that standardising on ODF will come to bite us, the IT industry, in our collective butts sooner rather than later. We need something clear. Obvious. Simple. And from this some genuine innovation will come - remember that?
Dave -
Re:PDF?
Seems to me that if you are wanting to make a point about using HTML and CSS to distrubute data, you would distribute your paper arguring this case in the same format.
The HTML and CSS source files are available from that page. The PDF file is also there to show, in a frozen format fit for a printer, what can be generated directly from HTML/CSS. -
Re:Some leaks fixedWell, if you follow the link in my signature, you'll get a good idea of which language I'd recommend. And yes, it's impure functional.
What you say about Java is right -- but just because one garbage collected language sucks badly does not imply that all GCs are bad.
Interestingly, rendering engines as powerful and complete as Gecko have been written in functional, garbage collected languages. The most advanced is PrinceXML which is written in Mercury, which is not just "uber-functional", but a logic programming language too - a bit like Prolog
:-) Check out some of the amazing rendering examples on their website. And yes, it even passes ACID2.Rich.
-
Re:Some leaks fixedWell, if you follow the link in my signature, you'll get a good idea of which language I'd recommend. And yes, it's impure functional.
What you say about Java is right -- but just because one garbage collected language sucks badly does not imply that all GCs are bad.
Interestingly, rendering engines as powerful and complete as Gecko have been written in functional, garbage collected languages. The most advanced is PrinceXML which is written in Mercury, which is not just "uber-functional", but a logic programming language too - a bit like Prolog
:-) Check out some of the amazing rendering examples on their website. And yes, it even passes ACID2.Rich.