{"id":341,"date":"2012-09-07T02:25:56","date_gmt":"2012-09-07T02:25:56","guid":{"rendered":"http:\/\/a.parsons.edu\/~dejongo\/12-fall\/?p=341"},"modified":"2018-01-22T20:05:10","modified_gmt":"2018-01-22T20:05:10","slug":"05-print-stylesheets","status":"publish","type":"post","link":"http:\/\/b.parsons.edu\/~dejongo\/05-print-stylesheets\/","title":{"rendered":"05 Print Stylesheets"},"content":{"rendered":"<p>We take for granted that we are styling the web site for the screen, but we should not forget that its also important to create a style sheet for when a user prints the web site. You can imagine that a potential client can print out a page from your portfolio to show to someone else at a meeting for a potential treatment of whatever project they are working on. <\/p>\n<h2>Clean It Up<\/h2>\n<\/p>\n<p>The most useful thing is to remove some of the clutter. When a user prints a page, they do so for the content. Do them the favor and hide all that is not necessary. The footer, navigation and other unnecessary elements can be set to <code>display: none; <\/code>. The remaining elements often need their screen styles neutered, and the properties have to be rewritten to clean up the print style. The browser itself applies a print style to the page, removing the background, etc, and the HTML5 Boilerplate has print stylesheet, but you still may need to tweak it yourself.\n<\/p>\n<p>Add your additions to the print styles at the bottom of the page in the boilerplate:<\/p>\n<pre>\r\n\/* ================================================\r\n   Print styles.\r\n   \r\n   ================================================ *\/\r\n<\/pre>\n<\/p>\n<p>Fonts are often larger on the screen than in print, so set the font to serif 12points in size: <code> p { background: white; font: 12pt\/14pt  \"Times New Roman\",Georgia,Serif; }<\/code> and <code>h1, h2, h3, h4, h5, h6<\/code> to appropriate sizes. <\/p>\n<h2>Rearrange It<\/h2>\n<\/p>\n<p>It is likely that the page is horizontally laid out for a screen. You may want to rearrange the elements vertically for the printed page.<\/p>\n<h2>Adding Information Using CSS<\/h2>\n<\/p>\n<p>Information can be added by using the content attribute before the header, for example, so you can customize the printed page: <code> header:before { content: \"Contact artist for more info, telephone number, email and website, etc\"; }<\/code> or anything else you want the printout to have.\n<\/p>\n<p> It&#8217;s possible to print out the actual link address after the links using <code>  a:link:after, a:visited:after { content: \" (\" attr(href) \") \"; } <\/code> but that prints out all links, so you may want to limit that to to the <code>article<\/code> tag. This is already taken care of for you in the boilerplate.\n<\/p>\n<p>Check to see how your page prints out, and add styles to the print section of your CSS style sheet if needed. <\/p>\n","protected":false},"excerpt":{"rendered":"<p>We take for granted that we are styling the web site for the screen, but we should not forget that its also important to create a style sheet for when a user prints the web site. You can imagine that &hellip; <a href=\"http:\/\/b.parsons.edu\/~dejongo\/05-print-stylesheets\/\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":[],"categories":[9],"tags":[],"_links":{"self":[{"href":"http:\/\/b.parsons.edu\/~dejongo\/wp-json\/wp\/v2\/posts\/341"}],"collection":[{"href":"http:\/\/b.parsons.edu\/~dejongo\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/b.parsons.edu\/~dejongo\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/b.parsons.edu\/~dejongo\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/b.parsons.edu\/~dejongo\/wp-json\/wp\/v2\/comments?post=341"}],"version-history":[{"count":7,"href":"http:\/\/b.parsons.edu\/~dejongo\/wp-json\/wp\/v2\/posts\/341\/revisions"}],"predecessor-version":[{"id":4051,"href":"http:\/\/b.parsons.edu\/~dejongo\/wp-json\/wp\/v2\/posts\/341\/revisions\/4051"}],"wp:attachment":[{"href":"http:\/\/b.parsons.edu\/~dejongo\/wp-json\/wp\/v2\/media?parent=341"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/b.parsons.edu\/~dejongo\/wp-json\/wp\/v2\/categories?post=341"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/b.parsons.edu\/~dejongo\/wp-json\/wp\/v2\/tags?post=341"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}