Created
June 4, 2013 00:49
-
-
Save RockyMyx/5702764 to your computer and use it in GitHub Desktop.
CSS: print.css
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* From: http://www.netmagazine.com/tutorials/make-your-website-printable-css | |
* <link rel="stylesheet" type="text/css" href="print.css" media="print"> | |
**/ | |
body { | |
background: #fff; | |
color: #000; | |
font-size: 8pt; | |
line-height: 150%; | |
margin: 0px; | |
} | |
hr { | |
color: #ccc; | |
background-color: #ccc; | |
} | |
h1, h2, h3, h4, h5, h6, code, pre { | |
color: #000; | |
text-transform: none; /* because sometimes I set all-caps */ | |
} | |
h1 { | |
font-size: 11pt; | |
margin-top: 1em; | |
} | |
h2 { | |
font-size: 10pt; | |
} | |
h3 { | |
font-size: 9pt; | |
} | |
h4, h5, h6 { | |
font-size: 8pt; | |
} | |
code, pre { | |
font-size: 8pt; | |
background-color: transparent; | |
/* just in case the user configured browser to print backgrounds */ | |
} | |
blockquote { | |
background-image: none; | |
/* though they may not print, I’d rather be sure */ | |
} | |
a:link, a:visited { | |
text-decoration: underline; | |
color: #000; | |
} | |
abbr:after, acronym:after { /* some HTML4 love */ | |
content: " (" attr(title) ") "; | |
/* I suspect I am one of the few who still use these elements */ | |
} | |
#Banner p#Title { | |
font-size: 24pt; | |
} | |
#Banner p#Title a, #Banner p#Title a:link, #Banner p#Title a:visited { | |
color: #000; /* change link to black text */ | |
} | |
#Bread a:link, #Bread a:visited { | |
text-decoration: underline; /* leave a clue that it’s a link */ | |
olor: #000; | |
} | |
#Bread { | |
color: #000; | |
font-size: 6pt; /* make the text small */ | |
} | |
#Bread > a:after { | |
content: ""; /* disable URL display if in #Content */ | |
} | |
#Footer { | |
font-size: 6pt; /* make the text small */ | |
color: #000; | |
} | |
#SearchForm { | |
display: none; | |
} | |
#Footer img { | |
float: right; /* defined elsewhere, included for completeness */ | |
} | |
#Content a:after { /* select links in the content area only */ | |
content: " [" attr(href) "] "; | |
text-decoration: none; | |
display: inline; | |
} | |
#Nav, #FlyOutNav, #SubNav, .NoPrint, p.CodeAlert, #SMLinks, #SearchForm { | |
display: none; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment