WINDOWS 1002000 PROFESSIONAL RESOURCE KIT [Electronic resources] نسخه متنی

اینجــــا یک کتابخانه دیجیتالی است

با بیش از 100000 منبع الکترونیکی رایگان به زبان فارسی ، عربی و انگلیسی

WINDOWS 1002000 PROFESSIONAL RESOURCE KIT [Electronic resources] - نسخه متنی

Chris Aschauer

| نمايش فراداده ، افزودن یک نقد و بررسی
افزودن به کتابخانه شخصی
ارسال به دوستان
جستجو در متن کتاب
بیشتر
تنظیمات قلم

فونت

اندازه قلم

+ - پیش فرض

حالت نمایش

روز نیمروز شب
جستجو در لغت نامه
بیشتر
لیست موضوعات
توضیحات
افزودن یادداشت جدید







Printing Concepts


When users print, the computer completes a set of steps that involve a set of components including executable files, drivers, device interfaces, and dynamic-link libraries which then work together to create printed output. Understanding how this process works will help you understand what is happening when you print a document and might help you resolve any problems that arise. Printing can be divided into the printing process and the print components that make the printing process possible. When printing to an Internet print server, the print server adds to the standard print process by creating an interface for users.

Printing Process


The printing process is divided into three groups of steps:


    Client processes

    Spooler processes

    Printer processes


These groups of broad steps include the following specific actions, represented in Figure 14.13.


Figure 14.13 Print Process

The steps depicted in Figure 14.13 include the following:

Client Processes



    A user sends a print job from an application. The application calls the Graphics Device Interface (GDI). If print output is produced in RAW format, the GDI is not used.

    The GDI calls the printer driver for information, which the GDI uses to create a job in printer language.

    The GDI delivers the job to the spooler.


Spooler Processes



    The client side of the spooler (Winspool.drv) makes an RPC call to the server side spooler (Spoolsv.exe).

    Spoolsv.exe calls the print router (Spoolss.dll).

    The router (Spoolsv.dll) sends the print job to the local print provider (LPP) or remote print server if the job is being sent to a network printer.

    The LPP polls print processors to find one that can handle the data type of the job.

    The LPP sends the job to the print processor, which modifies the job as required to make it print properly.

    The print processor sends the job to the page separator. A separator page is added, as required.

    The job is sent to the appropriate port print monitor. If print is bidirectional, the job is first sent to the language monitor such as the Printer Job Language (PJL) monitor, and then sent on to the port monitor. If the job is unidirectional, the job is sent directly to the port monitor.


Printer Processes


The printer translates the print language into a bitmap, which it then prints.

Print Components


There are a number of components that work together to make the printing process possible. Different components are used at different times, depending on the type of print job being produced and the types of hardware being used.

Graphics Device Interface


The application calls the Graphics Device Interface (GDI) to begin the process of creating a print job. The GDI reads the driver information for the printer to get information about how to format the job. Using the document information from the application and the print device information from the printer driver, GDI renders the print job in the printer language of the printer.

Printer Drivers


Printer drivers contain information that is specific to the printer that is used. Printer drivers reside on user's computers and are used by the GDI to render print jobs.

Windows 2000 includes the most common printer drivers, but you might need to provide printer drivers for some printers. When a Windows 2000 user connects to a printer or installs a Plug and Play printer, the necessary printer drivers are loaded onto the user's computer, if they are available.

Print Spooler


The print spooler consists of a group of components, including the print router, the local and remote print provider, and the print processor. These components can reside on a computer sending a job and on a network print server receiving print jobs. The print spooler's components take the print job that the GDI has created and modify it so it has all information and formatting necessary to print correctly. If part of the spooler is on a server, the server provides the processing resources for the print job, freeing the user's computer and improving performance.

Different print servers have different spooler components. In Windows 2000, the print spooler is comprised of a router, remote print provider, local print provider, print processor, separator page processor, and port print monitors.

Print Router

The print router receives a print job and locates an available print provider that can handle the print job's protocol. For example, the router might look for a print provider designed to handle RPC print jobs or jobs transferred using HTTP. When an acceptable print provider is found, the router relays the print job from the remote print provider to the chosen local print provider, where the job is modified, if necessary, before printing.

Remote Print Providers

The remote print provider is part of the client side of the print process. The router gives control of the print job to the first remote print provider the router finds that recognizes the destination printer. A remote print provider sends the print job to the server side part of the router.

Examples of remote print providers include the Windows Network Print Provider and the Novell NetWare Remote Print Provider. When a user sends a print job to a printer on a print server, the remote print provider is on the user's computer and the local print provider is on the server, counter to how it might be perceived by users.

Local Print Providers

The local print provider receives the print job, writes it to a spool file, and keeps track of information about the job. Spooling a file to disk ensures that the job is saved and printed, even if printers are unavailable or there is a power failure. When a user sends a print job to a printer on a print server, the remote print provider is on the user's computer and the local print provider is on the server, counter to how it might be perceived by users.

The local print provider has two components that are invoked as required by the printer type and settings:


    Print processor: The print processor makes any necessary modifications to the print job. This is necessary in instances where third-party printers have special requirements. Often, no modifications are required by the print processor.

    Separator page processor: The separator page processor adds separator pages, as required. You may specify different separator pages based on your needs. Most separator pages include information such as the user and computer that created the job or the date and time the job was created.


The escape codes used in creating a separator page are listed in Table 14.6.

Table 14.8 Separator Page Escape Codes and Functions











































Escape Code
Function

The first line of the separator file must contain only this character. The separator file interpreter considers this the separator file command delimiter.
N
Prints the user name of the person who submitted the job.
I
Prints the job number.
D
Prints the date the job was printed. The time is displayed in the format specified under Regional Options in Control Panel.
Lxxx
Prints the string of text that appears after the L escape code. If you were to enter LTest, the text "Test" would appear in the separator page.
Fpathname
Prints the contents of the file specified by pathname, starting on an empty line. The contents of this file are copied directly to the printer without processing.
Hnn
Sets a printer-specific control sequence, where nn is a hexadecimal ASCII code sent directly to the printer. To determine the specific numbers, see your printer manual.
Wnn
Sets the width of the separator page. The default width is 80 characters; the maximum width is 256. Any characters beyond this width are truncated.
BS
Prints text in single-width block characters until U is encountered.
E
Ejects a page from the printer. Use this code to start a new separator page or to end the separator page file. If you get an extra blank separator page when you print, remove this code from your separator page file.
n
Skips the number of lines specified by n (from 0 through 9). Skipping 0 lines simply moves printing to the next line.
BM
Prints text in double-width block characters until U is encountered.
U
Turns off block character printing.

After the local print provider has passed a job through the print processor and separator page processor, it sends the job from the spooler to the appropriate port print monitor.

Port Monitors

The Local Print Provider (Localspl.dll) provided with Windows 2000 includes the Local Port Monitor and Winprint print processor. The Local Port Monitor controls the parallel and serial ports to which printers are connected, and the Standard Port Monitor (SPM) is used for most network print jobs. Other ports, such as SCSI or Ethernet, are controlled by port monitors, such as the NetWare Port Monitor or AppleTalk Port Monitor.

Windows 2000 includes port monitors which enable printing to different types of printers in different network environments. Some of the port monitors included with Windows 2000 are described in further detail below:


    The preferred network port monitor in Windows 2000 is the Standard TCP/IP Port Monitor (SPM), which uses TCP/IP as the transport protocol. SNMP is used to configure and monitor the printer ports. In addition to SPM, Internet printing adds an Hypertext Transport Protocol (HTTP) Port Monitor. All other port monitors that were included with Windows NT 4.0 are also present. For more information, see "New Ways to Send Print Jobs" earlier in this chapter.

    Local Port Monitor is the standard monitor for use with printers connected directly to your computer. If you add a printer to your computer by using a serial or parallel port (such as COM1 or LPT1), this is the monitor that is used.

    LPR Port Monitor is used to send jobs over TCP/IP from the client running Lprmon.dll to a print server running an LPD service. LPR Port Monitor can be used as an alternative to SPM to enable Internet printing, UNIX print servers, or Windows 2000 print servers over a TCP/IP network. The LPR Port Monitor is a two-part port monitor, Lprmon.dll is used on the client side and Lpr.exe is used on the server side. When a job is sent over TCP/IP, the client must have the destination address for the print server, the name of the printer, and instructions on how to print the job. The server must have Lpr.exe installed to receive the job and pass it on to the appropriate printer. Use the LPR Port Monitor if you need an RFC compliant Line Printer Remote (LPR) or to receive jobs from UNIX clients. In any other case use SPM.

    AppleTalk Port Monitor (Sfmmon.dll) is used to send jobs over the AppleTalk protocol to printers such as LaserWriters or those configured with AppleTalk or any AppleTalk spoolers. To print to LaserWriters using Windows 2000 servers, the servers must have Services for Macintosh, which includes Sfmmon.dll.

    Hewlett-Packard Network Port Monitor (Hpmon.dll) sends jobs to Hewlett-Packard network adapters. Hpmon.dll uses the DLC network protocol to communicate. Print jobs sent through Hpmon.dll cannot be sent through routers.

    PJL monitor (Pjlmon.dll) communicates in printer job language (PJL). Any bidirectional print device that uses PJL can use the PJL language monitor.


Internet Printing


A user on a Windows 2000 computer can access information about available printers, and send jobs to those printers available on a Windows 2000 print server, or any print server that supports IPP v1.0. The process of finding an Internet printer and sending a print job to that printer includes the following steps:


    A client connects to a Windows 2000 print server over the Internet by entering a URL.

    The print server can require the client to provide authentication information. This helps ensure that only authorized users print documents on your printer, rather than making it available to everyone with an Internet connection.

    After a user is authorized to access the print server, the server presents the client with Active Server Pages (ASPs) containing information about the currently available printers. Figure 14.1 shows an example of such a page.

    Windows 2000 users can connect to any of the available printers using ASPs or get information about each printer's capabilities. Figure 14.14 shows an example of a printer's properties page, as presented by an Internet print server.


NOTE

Only computers running Windows 95 or Windows 98 with the Internet Printing Client or computers running Windows 2000 can connect to available printers. Windows NT and and Windows 3.11 will be unable to connect.



    Figure 14.14 Printer Queue for a Printer on an Internet Printer Server

    After users have connected to an Internet printer, they can print documents. Documents users print are sent using IPP v1.0 or RPC to the print server that uses RPC calls to send the job to the Internet printer of the users choice. Figure 14.15 shows potential steps included in the Internet printing process.


    Figure 14.15 Internet Printing Process


Print Job Formats


Print jobs are sent in a variety of formats, each of which is suited to different computing environments.

EMF


Enhanced Metafile (EMF) is the standard format for print jobs created on Windows 2000. EMFs are very portable because the instructions for the print job are assembled on the user's computer, but processing of the print job and its instructions is completed by the spooler. Because the spooler is associated with a specific printer, EMF files can be sent to any printer that has a spooler that handles EMFs.

EMF data is created by the GDI. After an EMF job is sent to the spooler, control is returned to the user and the spooler finishes processing the job. This limits the amount of time that the user's computer is busy.

RAW


RAW is a common data type for non-Windows 2000 clients. RAW data is not modified by the spooler at all, but is sent directly to the printer.

RAW [FF Appended]


RAW [FF Appended] is exactly like the RAW data type except that a form feed character is automatically appended to the end of each print job. The last page of a RAW document does not print on a Printer Control Language (PCL) printer, so appending a form feed is necessary.

RAW [FF Auto]


RAW [FF Auto] is exactly like the RAW data type, except the spooler checks the document for a form feed character at the end of the job. If there is no form feed, the spooler adds one.

Text


Text tells the spooler that the data is ANSI text and that it must not be modified. Text is printed using the printer's default font.

Text data is composed of values from 0 to 255, each value representing a different character. This data type is based on the ANSI standard, so if the data was created with an application using another character set, it won't be printed. This is more often a problem in the extended character range, represented by values above 127.

PSCRIPT1


This data type is created by Macintosh clients printing in Level 1 monochrome PostScript. The spooler interprets the data, creates a bitmap of the page, translates the image to the printer language, and sends the information to the printer where the output is produced.

/ 335