How many times have you printed an interesting page only to discover that something was, shall we say, lost in translation? Maybe parts of an image are missing. Worse, maybe parts of the story are missing. This kind of thing happens frequently because many Web designers concentrate on designing the best possible on-screen experience. Because the screen and a sheet of paper have completely different dimensions, this focus often comes at the expense of the printed page. Now you just have a piece of paper to throw away.
You can use Print Preview to view a Web page as it will print before you print it and avoid wasting paper (and time). To open the Print Preview window (shown in Figure 12-1), navigate to the Web page you want to print, and choose File Print Preview. Firefox offers a variety of correctional features you can use to improve the print layout if you don't like the preview. I discuss these in the following sections.
Figure 12-1: The Print Preview window.
Macintoshes do not have the Print Preview feature. Furthermore, the Mac version of Firefox uses the default Page Setup and Print windows, but extends the Print window to offer Firefox-specific features. Most of the special formatting features discussed in this chapter, such as margin customization, are found in the Print window on the Mac.
If a Web site is too wide to fit comfortably on paper (like the one in Figure 12-2), you can scale the page smaller, which is kind of like zooming out on a page for printing purposes. When you print wide pages, Firefox automatically wraps text so that it doesn't get cut off. However, wrapping text can add many pages, and you can avoid that by scaling the page smaller. Also, Firefox does not automatically prevent images that are close to the margins on wide pages from getting cut off. Scaling the page smaller can fix this as well.
Figure 12-2: At its original size, this Illinois train route diagram is cut off when printed …
If, on the other hand, a page has text too small to read comfortably on paper, you can scale the page larger — the paper equivalent of zooming in.
Temporarily changing the text size of a Web page using the View Text Size menu in the main Firefox window does not change the printed format of the page, so don't be surprised if Print Preview shows the page at its original text size. However, changing the text size of all Web sites, as I discuss in Chapter 19, does affect the printed page. If you don't want to enlarge or reduce the text size of all pages but want to change the text size of a particular page for printing purposes, Print Preview's scaling feature is the way to go.
To scale a page, simply open the Scale drop-down list in the Print Preview window and select one of the following settings:
A preset percentage: Choose a percentage below 100% to scale a page smaller (I use 50% in Figure 12-3), above 100% to scale a page larger, or 100% to print the page at its current (original) size.
Figure 12-3: … but when you scale it down to 50%, it fits.
Shrink to Fit: Select this option to automatically fit the page onto a standard 8 1/2-x-11-inch sheet of paper.
If you decide to print on a nonstandard size of paper, such as a postcard or legal-size page, you have to set up your printer to accommodate this. The procedure for doing this varies depending on your printer, but typically you open the Firefox Print window, click the Properties button, and then navigate to a paper size option. Shrinking your page works well only if your printer knows the type of paper you're using.
Custom: Select this option to specify your own scaling percentage. You can use any number, though anything over 200% usually makes the Web page look like a large-print book on steroids.
These options are also available from the Page Setup window, which you can access by clicking the Page Setup button in the Print Preview window. Some features of the Page Setup window aren't available directly from the Print Preview interface, as I discuss later in this chapter.
Suppose you've just found that 14-column table listing all the stats of your favorite basketball team online, and you want to print it out for your own reference. The problem is every time you try to print the table, the right half of the table gets cut off. You try the Shrink to Fit feature I discuss earlier, but then it's too small to read. What do you do?
Sometimes the image you want to print is too wide for a standard 8 1/2-x-11-inch piece of paper, but the image will print fine when you turn that piece of paper on its side. This is reorienting the page. The tall orientation, which is the default, is called Portrait, and the wide orientation is called Landscape. Figures 12-4 and 12-5 illustrate the difference between the Portrait and Landscape orientations.
Figure 12-4: In Portrait mode, you see only half of this large auditorium…
Figure 12-5: … but in Landscape mode, both halves of the room are visible.
To change the print orientation of a particular page, choose File Print Preview in the main Firefox window to open the Print Preview window, and then choose one of the following orientation buttons in the Print Preview toolbar.
By default, Print Preview shows the page in Portrait mode, meaning the short side of the page (usually 8 1/2 inches) is at the top and bottom. This is how most printing is done, as with a newspaper or newsletter. If you switch to Landscape mode, you can return to Portrait mode by clicking the Portrait button.
Sometimes you simply need to print something that's wider than the standard 8 1/2 inches of a normal sheet of paper. To "turn" the page, click the Landscape button. Note that if you select Landscape mode, you'll wind up with many more printed pages because less content fits on each page. You can select which pages to print from the Print window.
You can also change the orientation setting from the Page Setup window, without having to open Print Preview. To open the Page Setup window, choose File Page Setup in the main Firefox window. However, changing this setting in the Print Preview window allows you to preview a Web site in each orientation.
The orientation setting affects all Web sites you print, not just the Web site you're currently viewing.
By default, Firefox doesn't print background colors and images because doing so can make pages more difficult to read, as well as using a tremendous amount of ink. You can change this behavior from the Page Setup window by following these steps:
The Page Setup window is also accessible via the Page Setup button in the upper-left corner of the Print Preview window.
On the Format & Options tab, select the Print Background (Colors & Images) check box.
This setting affects all Web sites you print, not just the Web site you're currently viewing.
Firefox includes information about Web sites you print in the top and bottom margins (called the header and footer, respectively) of the printed page, such as the site title, page number, and date. To make more room for the page itself, you can shrink these margins. To include a more spacious border around the page, you can enlarge the margins. You also can customize the information that appears in the margins. Customization options include removing the title and changing where the date appears.
To get to the Margins & Header/Footer options, follow these steps:
Click the Margins & Header/Footer tab.
The following two sections discuss the options on this tab, which are shown in Figure 12-6.
Figure 12-6: The Margins & Header/Footer tab in the Page Setup window.
This area has four boxes that represent each of the margins on the page, as shown in Figure 12-6. The default value for each of the margins is 0.5 (half an inch), but you can change one or more of these. When you type in a new value, the preview image adjusts to the new margin.
Most printers require a minimum amount of margin space, since they can't print right along the edge of a page. This requirement varies among printers, and your printer's instructions may indicate its particular requirements. To be on the safe side, it's a good idea to ensure that you have at least 0.2 inches of margins on each side.
This area contains six drop-down lists that correspond to six positions on the printed page. You can use these drop-down lists to change what appears in each position. The first row of drop-down lists corresponds to the left, center, and right positions of the header (the top margin), and the second row corresponds to the left, center, and right positions of the footer (the bottom margin). You can select from the following options to include in each position:
-blank-: Shows nothing in this part of the page.
Title: Shows the title of the Web page. This is the title that appears in the main Firefox window's title bar when you visit the page.
URL: Shows the Web page's address.
Date/Time: Shows the date and time when the Web page was printed.
Page #: Shows the page number of each page.
Page # of #: Shows the page number along with the total number of pages in the print job. For example, on the fifth page of a 30-page print job, this area would show Page 5 of 30.
Custom: Use this option when you want your own text to appear in the header or footer. You can type in any text you want. You can also include one or more of the following codes to substitute some of the preset pieces of information when you print:
&P: Page Number
&PT: Page Number with Total Number of Pages
&U: Web site address
For example, if a Web site's title is January Meeting Agenda, and you type Work Documents: &T into the left header position, the printed agenda shows Work Documents: January Meeting Agenda in the upper-left corner.