惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

WordPress大学
WordPress大学
Security Latest
Security Latest
C
Cisco Blogs
P
Palo Alto Networks Blog
Know Your Adversary
Know Your Adversary
Project Zero
Project Zero
C
Cyber Attacks, Cyber Crime and Cyber Security
NISL@THU
NISL@THU
Exploit-DB.com RSS Feed
Exploit-DB.com RSS Feed
S
Secure Thoughts
P
Privacy International News Feed
V
Vulnerabilities – Threatpost
D
Docker
Google Online Security Blog
Google Online Security Blog
K
KPMG report finds enterprise disconnect between AI and its ROI | CIO
Recent Announcements
Recent Announcements
T
The Exploit Database - CXSecurity.com
G
Google Developers Blog
Schneier on Security
Schneier on Security
小众软件
小众软件
爱范儿
爱范儿
GbyAI
GbyAI
J
Java Code Geeks
T
Tailwind CSS Blog
Cisco Talos Blog
Cisco Talos Blog
The Hacker News
The Hacker News
D
DataBreaches.Net
Blog — PlanetScale
Blog — PlanetScale
TaoSecurity Blog
TaoSecurity Blog
MyScale Blog
MyScale Blog
B
Blog RSS Feed
Cyberwarzone
Cyberwarzone
有赞技术团队
有赞技术团队
Martin Fowler
Martin Fowler
C
CXSECURITY Database RSS Feed - CXSecurity.com
S
Securelist
L
Lohrmann on Cybersecurity
cs.CL updates on arXiv.org
cs.CL updates on arXiv.org
Y
Y Combinator Blog
S
Schneier on Security
Latest news
Latest news
Apple Machine Learning Research
Apple Machine Learning Research
博客园 - 叶小钗
F
Fortinet All Blogs
M
MIT News - Artificial intelligence
PCI Perspectives
PCI Perspectives
V
V2EX
V2EX - 技术
V2EX - 技术
O
OpenAI News
W
WeLiveSecurity

Henri Sivonen’s pages

Parin vuoden tutkimattomuus crates.io: Rust Package Registry Asiakirjatonta toimintaa It’s not wrong that "🤦🏼‍♂️".length == 7 Koulutartuntojen tilastointimenettely Perusteasiakirjoja hallussapitämättä ikärajoitettu Asiantuntijat ja nukkuva vallan vahtikoira Koronapassilausunto Suppealla tietopohjalla ohimeneväksi väitetty Text Encoding Menu in 2021 The Text Encoding Submenu Is Gone An HTML5 Conformance Checker Not Part of the Technology Stack Browser Technology Stack Bogo-XML Declaration Returns to Gecko A Look at Encoding Detection and Encoding Menu Telemetry from Firefox 86 Why Supporting Unlabeled UTF-8 in HTML on the Web Would Be Problematic Rust Target Names Aren’t Passed to LLVM Toimintamalli Activating Browser Modes with Doctype Johtopäätöksiä mallin rakenteesta Tehtävänmäärittelyä kirjoittamatta ja kuolemia laskematta laumasuojamallinnettu Character Encoding Menu in 2014 Erillissuosituksen tarpeettomuudesta yleissuosituksen poikkeukseksi? STM:n maskiaikajana Rust 2021 Oma-aloitteisesti mallinnettu Kokopinovaatimuksin kilpailutettu chardetng: A More Compact Character Encoding Detector for the Legacy Web Varauksia paisutellen tiedotettu Perusteasiakirjoitta tiedotettu Always Use UTF-8 & Always Label Your HTML Saying So IME Smoke Testing The Validator.nu HTML Parser About the Hiragino Fonts with CSS It’s Time to Stop Adding New Features for Non-Unicode Execution Encodings in C++ Rust 2020 The Last of the Parsing Quirks About about:blank Rust 2019 a Web-Compatible Character Encoding Library in Rust How I Wrote a Modern C++ Library in Rust Using cargo-fuzz to Transfer Code Review of Simple Safe Code to Complex Code that Uses unsafe A Rust Crate that Also Quacks Like a Modern C++ Library #Rust2018 No Namespaces in JSON, Please A Lecture about HTML5 Julkisesti luotettu varmenne ikidomainille TLS:ää (SSL:ää) varten -webkit-HTML5 Lists in Attribute Values The Sad Story of PNG Gamma “Correction” If You Want Software Freedom on Phones, You Should Work on Firefox OS, Custom Hardware and Web App Self-Hostablility HTML5 Parser Improvements ARIA in HTML5 Integration: Document Conformance (Draft, Take Two) Schema.org and Pre-Existing Communities Lowering memory requirements by replacing Schematron HTML5 Parsing in Gecko: A Build Introducing SAX Tree NVDL Support in Validator.nu HOWTO Avoid Being Called a Bozo When Producing XML An Unofficial Q&A about the Discontinuation of the XHTML2 WG Thoughts on HTML5 Becoming a W3C Recommendation Four Finnish Banks Training Users to Give Banking Credentials to Another Site Unimpressed by Leopard Sergeant Semantics The Content Sink Inheritance Diagram – 2006-06-30 What is EME? About Points and Pixels as Units The Performance Cost of the HTML Tree Builder Social Media Impression Management The spacer Element Is Gone Openmind 2006 Performance Mistake XHTML and Mobile Devices WebM-Enabled Browser Usage Share Exceeds H.264-Enabled Browser Usage Share on Desktop (in StatCounter Numbers) HTML5 Parser-Based View Source Syntax Highlighting Vendor Prefixes Are Hurting the Web Accept-Charset Is No More Dualroids Writing Structural Stylable Document in Mozilla Editor ISO-8859-15 on haitallinen Hourglass The Scientific Method According to Hixie Maemo Source Code Karpelan lukkovertaus ontuu Digitaalisesta arkistoinnista ARIA in HTML5 Integration: Document Conformance (Draft) XHTML—What’s the Point? (Draft, incomplete) Mac OS X Browser Comparison HOWTO Spot a Wannabe Web Standards Advocate An Idea About Intermediate Language Trees and Web UI Generation Thoughts on Using SSL/TLS Certificates as the Solution to Phishing Bureaucracy Meets the Web Europe Day HOWTO Establish a 100% Literacy Rate What to Do with All These Photos? Charmod Norm Checking Validator Web Service Interface Ideas DTDs Don’t Work on the Web EFFI’s Day in Court
Printing Web Apps 1.0
Henri Sivonen · 2011-12-22 · via Henri Sivonen’s pages

This is a quick guide for getting a dead-tree version of the Web Applications 1.0 spec. The advice is biased towards Mac OS X fonts. The use of Prince is assumed. A laser printer with black ink only is assumed.

  • Get Prince. As of today, the latest alpha is Prince 6.0 (alpha 2007-03-23). This guide should work with Prince 5.1 as well. (Thanks to YesLogic for giving me a Prince license.)

  • If you are on Mac, make sure you have the broad versions of Microsoft core fonts. The fonts that came with Mac IE or in the .sit core font distribution archives have a limited legacy glyph repertoire. The fonts that come with MS Office are up to date. If you don’t have the MS Office versions, you can get the .ttf versions from SourceForge. (Note that some Carbon apps that use legacy APIs don’t render the .ttf versions as nicely as they render the suitcased versions.)

  • Get the DejaVu font family. Install the .ttf files in /usr/local/lib/prince/fonts/ (assuming you installed Prince under /usr/local/). I could not get DejaVu to work with Prince from /Library/Fonts on Mac.

  • To fill in the rest of the glyphs missing after Arial, Helvetica and DejaVu, it is assumed that you have STHeiti that ships with OS X. I don’t know what font is a suitable substitute on Linux or Windows. Please let me know if you have a suggestion.

  • Patch your /usr/local/lib/prince/style/fonts.css with this patch.

  • Navigate to the Web Apps spec in Firefox. Choose “Save Page As…” and as format “Web Page, complete”. This will save all the dependencies except the green “Working Draft” background image, which you probably don’t want to use ink for anyway. The name you pick here is referred to as filename.html below.

  • Download specification-a4.css if you use internationally standardized paper or specification-letter.css if you are ISO-challenged, rename it to specification.css and replace filename_files/specification.css with it.

  • Open filename.html in a text editor.

  • Add <meta http-equiv="content-type" content="text/html; charset=utf-8"> as the first child of <head>.

  • Locate the table of entities by searching for “AElig”. Wrap the table in <div id='hsivonen-entity-table'></div>. (It appears that Prince does not support ::outside on tables.)

  • Save.

  • Run Prince with prince --input=html filename.html. It will complain about the missing background image. This is harmless.

  • Print filename.pdf.

    Initially, I tried to print the PDF by first converting it to PostScript using pdftops (Xpdf-based; not the same as pdf2ps which is GhostScript-based). I’ve had mixed results with pdftops. It generates smaller PostScript files (around 38 MB) than Adobe’s or Apple’s implementation. However, sometimes there are glitches with changed glyphs within a font and sometimes the output doesn’t work with a particular printer. Also, be sure to specify -duplex as pdftops overrides the print queue duplex setting to simplex by default! Adobe’s and Apple’s implementation generate over 100 MB of PostScript but seem to be more reliable. I used eventually Adobe Reader 7 on Solaris to generate the PostScript for printing.

  • In case you are happy with today’s snapshot and don’t want to typeset the PDF yourself, here is revision 691 from 2007-03-23 as A4 and Letter.