{"id":54,"date":"2011-10-25T09:45:48","date_gmt":"2011-10-25T13:45:48","guid":{"rendered":"http:\/\/www.jintrang.com\/who-is-hu\/?p=54"},"modified":"2011-10-25T09:48:01","modified_gmt":"2011-10-25T13:48:01","slug":"print-style-sheets","status":"publish","type":"post","link":"https:\/\/www.jintrang.com\/who-is-hu\/2011\/10\/print-style-sheets\/","title":{"rendered":"Print style sheets. Yes we still need them!"},"content":{"rendered":"<p>With technology and media heading towards a print-free lifestyle, we still need to style the web for print media. If there is a large amount of information viewed on a webpage, some people still enjoy the option of printing a \u201chard copy\u201d and taking it on-the-go with them.<\/p>\n<p>There are currently ten defined CSS media types: all, aural, braille, embossed, handheld, print, projection, screen, tty, and tv. Each media declaration allows web layouts to be presented differently to users, from handheld devices to web screens.<\/p>\n<p>The main focus of today\u2019s topic is print. Developers should keep in mind how to restyle for print as they are creating their designs for a new website. A web layout may look great on-screen, but it may not be print friendly. The print style sheet overrides the normal screen layout styles without adding anything extra to the screen layouts.<\/p>\n<p>Tips and best practices:<\/p>\n<ol>\n<li>A simple rule of thumb is to display only what is needed.<\/li>\n<li>Remove headers, top navigations, sidebars, images, footers. <strong><code>display: none;<\/code><\/strong> works wonders. The logo and contact information from the footer should be the only exception.<\/li>\n<li>Enlarge the content area by expanding the width to 100%, resetting the margins and floats to 0 and none.<\/li>\n<li>Reset the background color to white and content area to transparent.<\/li>\n<li>Reset text colors to dark gray, especially after resetting background colors. Light colored text will be invisible or harder to see on a white background.<\/li>\n<li>Reset font size to 12 points. Default browser font size is 16 points.<\/li>\n<li>Reset font family to serif fonts since it\u2019s easier to read on paper. Georgia or Times New Roman are preferable.<\/li>\n<li>Make links bolder, underlined and declare it to have a blue or red color.<\/li>\n<li>Display link destinations so the reader can see what the urls are on paper. <br \/><strong><code>a:link:after a:visited:after { content: \" (\" attr(href) \") \";}<\/code><\/strong><\/li>\n<li>If there is a blog with pages of comments, you can break the comments into pages. <br \/> <strong><code>#comments {page-break-before: always;}<\/code><\/strong><\/li>\n<\/ol>\n<p>How to set it up?<br \/>\nDeclare your print style sheet in the head section of your html page as you normally would. Add the <strong><code>media = \u201cprint\u201d<\/code><\/strong> to the declaration for print only specification.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>With technology and media heading towards a print-free lifestyle, we still need to style the web for print media. If there is a large amount of information viewed on a webpage, some people still enjoy the option of printing a \u201chard copy\u201d and taking it on-the-go with them. There are currently ten defined CSS media [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[6],"tags":[],"class_list":["post-54","post","type-post","status-publish","format-standard","hentry","category-professional"],"_links":{"self":[{"href":"https:\/\/www.jintrang.com\/who-is-hu\/wp-json\/wp\/v2\/posts\/54","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.jintrang.com\/who-is-hu\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.jintrang.com\/who-is-hu\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.jintrang.com\/who-is-hu\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.jintrang.com\/who-is-hu\/wp-json\/wp\/v2\/comments?post=54"}],"version-history":[{"count":7,"href":"https:\/\/www.jintrang.com\/who-is-hu\/wp-json\/wp\/v2\/posts\/54\/revisions"}],"predecessor-version":[{"id":61,"href":"https:\/\/www.jintrang.com\/who-is-hu\/wp-json\/wp\/v2\/posts\/54\/revisions\/61"}],"wp:attachment":[{"href":"https:\/\/www.jintrang.com\/who-is-hu\/wp-json\/wp\/v2\/media?parent=54"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.jintrang.com\/who-is-hu\/wp-json\/wp\/v2\/categories?post=54"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.jintrang.com\/who-is-hu\/wp-json\/wp\/v2\/tags?post=54"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}