Peter
Peter

Reputation: 7804

When I print HTML font is small

I am trying to create a print.css for my web pages.

The no matter how large I set the font the page shrinks-to-fit. If I make it 100% in the print preview it cuts off half the page.

I've looked here http://windows.microsoft.com/en-us/windows/printing-webpages-faq#1TC=windows-7 it doesn't really help.

So I guess what I want to know is how to NOT have the font scale but instead have it stay the size I say and word wrap appropriately.

This is my print.css

@media print {
* { margin: 0 !important; padding: 0 !important; }

html, body {
    font-family: Georgia, serif  !important;
    font-size: 12pt !important;
    background: none;
    color: black;
}

img {
    max-width: 100% !important;
}

ul, img {
    page-break-inside: avoid;
}

a {
    display: none !important;
}

.visible-print {
    display: inherit !important;
}

.hidden-print {
    display: none !important;
}

/* THIS IS AWFUL */
.mainContent .span3.content {
    width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    background: none !important;
}

.profiler-results {
    display: none !important;
}
}

@media print and (color) {
* {
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
}
}

@media screen {
.hidden-screen {
    display: none !important;
}
}

Upvotes: 0

Views: 797

Answers (1)

itamaryu
itamaryu

Reputation: 326

I guess you might wanna change 12pt to 12px (or greater than 12)

Upvotes: 1

Related Questions