CSS @Page in Marked
Hi,
I've been using marked for some time, and love it. Up till now, whenever I've needed to print out more complex documents I would need to go through all kinds of steps to get it to look good for print (cut and paste to Pages, redo the styling, add page numbers etc).
It occured to me that the best would be to use custom CSS with all the things that are usually required of printed documents (page numbers, margins dependant on paper size etc). I looked around, and found http://www.w3.org/TR/css3-page/ which outlines the syntax for everything needed.
I tried a few sample css files (eg: http://www.alistapart.com/articles/boom http://www.princexml.com/samples/ ) but the printed pages never contained the properties.
Is there any chance of implementing this is Marked? It would allow us to completely skip other word processors for printing.
Keyboard shortcuts
Generic
? | Show this help |
---|---|
ESC | Blurs the current field |
Comment Form
r | Focus the comment reply box |
---|---|
^ + ↩ | Submit the comment |
You can use Command ⌘
instead of Control ^
on Mac
Support Staff 1 Posted by Brett on 01 Apr, 2012 06:08 PM
I'm afraid webkit doesn't fully support the @page properties, and there's little Marked can do about it. If you set a "limit width in preview" pixel number, that will translate to print for left and right margins, but top/bottom is another story. The next version does include the ability to force page breaks with a special tag, or automatically include them before h1 or h2 headers. I'm working on an external print system that will allow more control, but that's been slow going.
-Brett
2 Posted by Martin on 01 Apr, 2012 08:21 PM
Hi Brett,
Thanks for the reply. I feared as much. It seems that it's completely fallen off the map for webkit ( https://bugs.webkit.org/show_bug.cgi?id=15548 ). Maybe it will gain some attention when firefox implements it ( https://bugzil.la/115199 ).
I'm excited to hear that you are working on the headers and page breaks, any chance of adding page numbers to that list? That would cover 90% of the use cases for me.
Support Staff 3 Posted by Brett on 01 Apr, 2012 09:01 PM
Page numbers are supposed to be possible, but they won't be implemented in the next version (already in review). I'll keep working on it, though, should have more advanced page setup options available soon.
-Brett
4 Posted by Stringbean on 18 May, 2012 09:15 PM
Add me to the list of page numbers requesters. Thanks!
5 Posted by Phil on 21 Nov, 2012 03:41 AM
Yeah, page numbers would be great!