Developer Note Apple LaserWriter Pro 600 and 630 Printers Developer Note APPLE CONFIDENTIAL March 1, 1993 Developer Technical Publications © Apple Computer, Inc.
Apple Computer, Inc. © 1993, Apple Computer, Inc. All rights reserved. No part of this publication may be reproduced, stored in a retrieval system, or transmitted, in any form or by any means, mechanical, electronic, photocopying, recording, or otherwise, without prior written permission of Apple Computer, Inc. Printed in the United States of America. The Apple logo is a registered trademark of Apple Computer, Inc.
Contents Figures and Tables Preface vii About This Developer Note What This Note Contains ix Conventions Used in This Note Other Reference Material x For More Information xi Chapter 1 ix x Overview of LaserWriter Pro Hardware Features of the LaserWriter Pro Printer 2 Communication 3 Serial Communications 4 Serial Port for RS-232C Devices 5 LocalTalk/RS422 Serial Connector 6 Centronics Parallel Connector 6 Apple Ethernet Adapter for EtherTalk (630 Only) SCSI Connector (630 Only) 8 Internal SCSI Connec
Chapter 3 LaserWriter Pro Software 29 Device Setup 30 Page Device Parameters 30 Page Device Parameter Summary 31 Product Strings 34 Install Procedure 34 PhotoGrade Parameters 34 FinePrint Parameters 36 Interpreter Parameters 37 User Parameters 37 System Parameters 38 Device Parameters 41 File System 41 Communication Channels 44 Engine Device 48 Resource Categories 48 Emulator Parameters 54 Compatibility Operators 55 Setting System Parameters 57 buildtime 57 byteorder 57 checkpassword 58 defaultmultipurpo
Setting User Parameters 64 jobname 64 jobtimeout 64 setjobtimeout 64 waittimeout 64 Setting Device Parameters 65 appletalktype 65 diskonline 65 diskstatus 65 initializedisk 65 hardwareiomode 66 manualfeed 66 manualfeedtimeout 66 sethardwareiomode 67 setsoftwareiomode 67 setuserdiskpercent 67 softwareiomode 67 userdiskpercent 68 Setting Serial Communication Parameters sccbatch 68 sccinteractive 68 setsccbatch 69 setsccinteractive 69 SCC Operator Encoding 69 Page Size Compatibility Operators 71 Paper Tray Com
Figures and Tables Chapter 1 Chapter 2 Chapter 3 Overview of LaserWriter Pro Hardware 1 Figure 1-1 Figure 1-2 Figure 1-3 Figure 1-4 Figure 1-5 Figure 1-6 Figure 1-7 Figure 1-8 Figure 1-9 LaserWriter Pro side panel connectors 3 9-pin serial port connector for RS-232C device 5 8-pin mini-DIN connector for LocalTalk and RS-242 devices Centronics parallel connector 6 14-pin Ethernet connector 8 30-pin SCSI connector pin designations 9 Internal SCSI connector 10 Status lights 16 Expansion slots for SIMM c
Table 3-12 Table 3-13 Table 3-14 Table 3-15 Table 3-16 Table 3-17 Table 3-18 Table 3-19 Table 3-20 Table 3-21 Table 3-22 Table 3-23 Table 3-24 Table 3-25 Table 3-26 Table 3-27 Table 3-28 Chapter 4 TrueType Fonts Table 4-1 Table 4-2 Table 4-3 Table 4-4 Table 4-5 viii Parameter set relationships 45 %Serial_NVx% communication parameter sets 46 %SerialB_NVx% communication parameter sets 46 %LocalTalk_NVx% communication parameter sets 47 %EthernetTalk_NVx% communication parameter sets 47 %Parallel_NVx% commu
P R E F A C E About This Developer Note The LaserWriter Pro 600 and the LaserWriter Pro 630 are new members of Apple’s LaserWriter printer family. This developer note describes the features and capabilities of the printers, and it is intended for use by software and hardware developers. To use this note, you need to understand the Adobe PostScript Level 2 programming language. You should also be familiar with the computer for which you intend to develop software.
P R E F A C E Conventions Used in This Note 0 Note This visual cue is used throughout the book to draw attention to information of general interest. ◆ IMPORTANT This type of note contains information that is essential for an understanding of the main text. ▲ A special font, Courier, is used for characters that you type, or for lines of program code. It looks like this.
P R E F A C E ■ The PostScript Language Program Design, published by Addison-Wesley, is written for programmers who want to take advantage of the PostScript program language to design efficient PostScript programs and printer devices. For More Information 0 APDA is Apple’s worldwide source for over three hundred development tools, technical resources, training products, and information for anyone interested in developing applications on Apple platforms.
C H A P T E R Figure 1-0 Listing 1-0 Table 1-0 1 Overview of LaserWriter Pro Hardware Thi d t t d ith F M k 1 404
C H A P T E R 1 Overview of LaserWriter Pro Hardware The LaserWriter Pro 600 and 630 printers are the next-generation replacements for the LaserWriter II printer. They provide higher print quality, better performance, a wider range of interfaces, and improved paper handling, at a lower cost than the LaserWriter IIf or the LaserWriter IIg. Both LaserWriter Pro printers can operate with either Macintosh computers, or with DOS-based IBM personal computers.
C H A P T E R 1 Overview of LaserWriter Pro Hardware Table 1-1 LaserWriter Pro features (continued) Features Specifications Fonts SuperPlus font set: 64 fonts TrueType font scaler Internal and external SCSI ports for hard-disk font storage on the LaserWriter Pro 630 PDL (Page Description Language) PostScript Level-II, version 2011, release 130 Emulation Built-in LaserJet IIP emulator.
C H A P T E R 1 Overview of LaserWriter Pro Hardware The controller of the LaserWriter Pro 600 supports host communication via the following ports: ■ Serial RS-422/LocalTalk port ■ RS-232 9-pin serial port ■ Centronics parallel port The LaserWriter Pro 630 controller supports host communication via the following ports: ■ External SCSI port for a local hard disk drive to store fonts.
C H A P T E R 1 Overview of LaserWriter Pro Hardware Serial Port for RS-232C Devices 1 A 9-pin sub-mini-DIN connector supports communication with RS-232C devices. Figure 1-2 shows the connector pin designations, and Table 1-2 lists the pin functions for the 9-pin connector. Figure 1-2 9-pin serial port connector for RS-232C device 4 5 9 Table 1-2 3 2 8 7 1 6 Signal descriptions for 9-pin serial port Pin number Signal name Description 1 DCD Data carrier detect.
C H A P T E R 1 Overview of LaserWriter Pro Hardware LocalTalk/RS422 Serial Connector 1 An 8-pin mini-DIN supports LocalTalk and RS-242 devices. Figure 1-3 shows the connector pin designations for the 8-pin connector, and Table 1-3 lists the pin functions.
C H A P T E R 1 Overview of LaserWriter Pro Hardware Table 1-4 Pin number Signal descriptions for Centronics parallel port Signal name Description 1 /DATA STROBE Strobe for input data 2 DATA 1 Data input bit 1 3 DATA 2 Data input bit 2 4 DATA 3 Data input bit 3 5 DATA 4 Data input bit 4 6 DATA 5 Data input bit 5 7 DATA 6 Data input bit 6 8 DATA 7 Data input bit 7 9 DATA 8 Data input bit 8 10 /ACKNOWLEDGE Handshaking output signal; acknowledges receipt of data 11 BUSY B
C H A P T E R 1 Overview of LaserWriter Pro Hardware Apple Ethernet Adapter for EtherTalk (630 Only) 1 The LaserWriter Pro 630 controller supports AppleTalk over the Ethernet network. That communications link is referred to as EtherTalk. A 14-pin connector provides the interface to the Ethernet through Apple’s AUI interface, which allows you to connect to ThinNet, 10-Base-T, and ThickNet cabling systems, using the appropriate Apple Ethernet adapter.
C H A P T E R 1 Overview of LaserWriter Pro Hardware Note SCSI ID #6 cannot be used for any of these SCSI devices, since it is reserved for the LaserWriter Pro printer.
C H A P T E R 1 Overview of LaserWriter Pro Hardware Table 1-6 Signal descriptions for 30-pin SCSI connector (continued) Pin number Signal name Description 26 /C/D When active (low) indicates that data is on the SCSI bus; when high indicates that control signals are on the bus 27 /RST SCSI bus reset 28 /MSG When active (low) indicates the message phase is active 29 /SEL Selects between target and initiator 30 /I/O Controls the direction of data movement; when low data is output; when h
C H A P T E R 1 Overview of LaserWriter Pro Hardware Table 1-7 Signal descriptions for internal SCSI connector Pin number Signal name Description 1, 2, 24 +5V +5 V power supply 3, 4, 5, 7, 9, 11, 13, 15, 19, 21, 23, 27, 31, 35 GND Ground 6 /DB0 Bit 0 of SCSI data bus 8 /DB1 Bit 1 of SCSI data bus 10 /DB2 Bit 2 of SCSI data bus 12 /DB3 Bit 3 of SCSI data bus 14 /DB4 Bit 0 of SCSI data bus 16 /DB5 Bit 0 of SCSI data bus 17 Open Open line.
C H A P T E R 1 Overview of LaserWriter Pro Hardware Mode Switch 1 The LaserWriter Pro has a ten-position rotary wheel that allows you to set the printer to work in different communication environments. The first six positions (0–5) allow you to select a set of fixed parameters for each of the communication channels. You cannot change these sets of parameters using the PostScript operators. You may change the remaining sets of parameters (6–9). See Chapters 2 and 3 for further information.
C H A P T E R 1 Overview of LaserWriter Pro Hardware Table 1-8 Switch setting 3 4 5 Switch settings and default parameter values (continued) Type of connection and default parameter values Mode 14-pin Apple Ethernet adapter EtherTalk PostScript 36-pin Parallel Centronics Protocol: normal PostScript 8-pin/RS-422 LocalTalk PostScript 9 pin/RS-232 Serial 9600 baud rate Data bits: 8. No parity Stop bits: 1 Flow control: DTR Protocol: raw Not arbitrated for input.
C H A P T E R 1 Overview of LaserWriter Pro Hardware Table 1-8 Switch setting Port name 6 8-pin/RS-422 Serial 19200 baud rate Data bits: 8. No parity Stop bits: 1 Flow control: XON/XOFF Protocol: normal PostScript 9 pin/RS-232 Serial 19200 baud rate Data bits: 8.
C H A P T E R 1 Overview of LaserWriter Pro Hardware Table 1-8 Switch settings and default parameter values (continued) Switch setting Port name Type of connection and default parameter values Mode 9 8-pin/RS-422 LocalTalk PostScript 9 pin/RS-232 Serial 9600 baud rate Data bits: 8. No parity Stop bits: 1 Flow control: XON/XOFF Protocol: BSP PostScript 14-pin Apple Ethernet adapter EtherTalk PostScript 36-pin Parallel Centronics.
C H A P T E R 1 Overview of LaserWriter Pro Hardware Status Lights 1 The LaserWriter Pro has four colored lights on the left side of the printer. These lights indicate what the printer is doing. Figure 1-8 shows a view of the status light symbols, and Table 1-8 describes the functions of the lights.
C H A P T E R 1 Overview of LaserWriter Pro Hardware DRAM Expansion 1 You may expand the LaserWriter Pro printer’s DRAM capacity using SIMM (single in-line memory module) cards, which are plugged in to the slots on the surface of the printer’s main circuit board. As shown in Figure 1-9, there are two slots for SIMM cards. Slot 1 is the slot closer to the edge of the circuit board. Note There is no silk-screened identification of these slots.
C H A P T E R Figure 2-0 Listing 2-0 Table 2-0 2 Overview of LaserWriter Pro Software Thi d t t d ith F M k 2 404
C H A P T E R 2 This chapter provides an overview of the following software features: ■ Adobe PostScript Programming Language ■ LaserWriter Pro driver ■ LaserWriter Pro utility program ■ Startup and configuration pages ■ Page types ■ LaserJet IIP emulation ■ Mode selection Adobe PostScript Programming Language 2 The LaserWriter Pro printer uses Adobe PostScript Version 2010.130.
C H A P T E R 2 LaserWriter Pro Utility Program 2 The LaserWriter Pro utility program shipped with each LaserWriter Pro printer allows you to control and configure the printer. It is similar to the utility for the LaserWriter IIg. Upgrades to the LaserWriter Pro Utility program allow you to: ■ select HW Resolution, 300 or 600. ■ turn Automatic Tray Switching on and off.
C H A P T E R 2 Figure 2-1 Layout of configuration page Printer Name L A S E R W R I T E R ® ® P R O 6 3 0 Display List ? ? “LaserWriter” LocalTalk™ Type 167 ? – 4.0% – 10.0% Font Cache 8 Mb Total RAM Installed LocalTalk Node ID ? 08:00:07:34:EA:AA Form Cache – 1.2% Pattern Cache – 1.2% EE – 1.
C H A P T E R 2 Table 2-1 Configuration page functions Block Description Printer name Shows the printer’s name, as specified by the printername operator. Below the name are the Apple logo and the model name, LaserWriter Pro 600 or LaserWriter Pro 630.
C H A P T E R 2 Page Types 2 The page types for the LaserWriter Pro are the same as those described in Chapter 4 of the LaserWriter Reference. At the beginning of each job, the server selects the default paper tray, as assigned by the defaultpapertray operator. (See “Compatibility Operators for Setting System Parameters,” in Chapter 3.) If the default is the main cassette, the server can detect its size and install the appropriate image region.
C H A P T E R 2 LaserJet IIP Emulation 2 The LaserWriter Pro printer has a built-in Hewlett Packard LaserJet IIP emulator, which is compatible with Hewlett-Packard PCL (Printer Control Language), Level 4. Chapter 3 of this developer note, “LaserWriter Pro Software,” describes the features of the emulator. Chapter 3 of the LaserWriter Reference provides more information on the subject. Selecting Emulation 2 You may invoke the emulation in one of three ways. Each method is described briefly below.
C H A P T E R 2 The emulate procedure returns ■ at the end of the job ■ when a Control-D is encountered in the input source. In this case, that Control-D marks the end of the job ■ when -0 is encountered in the input source. In this case, the PostScript interpreter ejects the current page and continues executing whatever was on the execution stack before it executed the emulate procedure. A Control-D must still be sent to terminate the job.
C H A P T E R 2 You may change the parameters for switch positions 6–9 in one of the following ways: ■ By using the appropriate device parameter for the PostScript Level 2 setdevparams operator. Parameters and semantics for setdevparams are described in Chapter 3, under “PostScript Level 2 for the LaserWriter Pro.” Note This is the recommended procedure. ■ ◆ By using the PostScript Level 2 setsccbatch operator.
C H A P T E R Figure 3-0 Listing 3-0 Table 3-0 3 LaserWriter Pro Software Thi d t t d ith F M k 404 3
C H A P T E R 3 LaserWriter Pro Software This chapter describes the software parameters that enable you to set up and configure the LaserWriter Pro printer.
C H A P T E R 3 LaserWriter Pro Software Page Device Parameter Summary 3 Table 3-1 lists the page device parameters, lists their defaults, and provides additional technical information. Table 3-1 Page device parameters Key Type Default Comments BeginPage EndPage ExitJamRecovery procedure procedure boolean {pop} {exch pop 2 ne} false HWResolution array [600 600] ImagingBox array or null null InputAttributes dictionary Depends on configuration See Note 1. See Note 2.
C H A P T E R 3 LaserWriter Pro Software Table 3-1 Page device parameters (continued) Key Type Default Comments Install procedure /DefaultHalftone See the section “Install Procedure,” later in this chapter, for more information. This device parameter is associated with the PhotoGrade feature. See Note 2. ManualFeed boolean false See Note 2. ManualFeed Timeout integer 60 See Note 3. Margins array [0 0] Value is persistent across power cycles. See Note 2.
C H A P T E R 3 LaserWriter Pro Software Table 3-1 Page device parameters (continued) Key Type Default Comments PreRendering EnhanceDetails dictionary See Tables 3-2, 3-5, 3-6, and 3-8 See Note 3. TraySwitch boolean false If true, automatic tray switching is provided.
C H A P T E R 3 LaserWriter Pro Software Product Strings 3 Table 3-4 lists values assigned to the product strings associated with the LaserWriter Pro printer. Table 3-4 Product string values String name Type Value languagelevel integer 2 product string LaserWriter Pro version string 2010.130 Install Procedure 3 This section provides sample code for the install procedure.
C H A P T E R 3 LaserWriter Pro Software Table 3-5 PhotoGrade device parameters Device parameter Description Install Performs graphics state setup for the page device. If PreRenderingEnhance is true and the request is satisfied, Install sets the halftone in the graphics state to the dictionary identified by DefaultHalftone in PreRenderingEnhanceDetails. Otherwise, a standard halftone dictionary is used, with a frequency of 60 at 300 dpi, and 85 at 600 dpi.
C H A P T E R 3 LaserWriter Pro Software There are additional entries in the PreRenderingEnhanceDetails dictionary that you should change only with an application program like LaserWriter Utility, which is supplied with the printer. These parameters compensate for such factors as atmospheric humidity and toner life. Table 3-7 summarizes these parameters.
C H A P T E R 3 LaserWriter Pro Software Interpreter Parameters 3 Certain parameters control the operation and behavior of the PostScript interpreter. Many of them are connected with memory allocation and other specific-purpose resources. For instance, interpreter parameters control the maximum amount of memory allocated to virtual memory, font cache, and halftone screens. The LaserWriter Pro printer is configured initially with interpreter parameter values appropriate for most applications.
C H A P T E R 3 LaserWriter Pro Software Table 3-9 User parameters (continued) Key Type MaxLocalVM integer Default 2147483647 ≥0 Details MaxOpStack integer 10000 ≥0 MaxPatternItem integer 20000 ≥0 MaxScreenItem integer MaxUPathItem integer 5000 ≥0 MinFontCompress integer 1250 ≥0 VMReclaim integer VMThreshold integer WaitTimeout integer ≥ 0. Initial value is 3000 bytes per MB of installed RAM, with a maximum of 12000 bytes.
C H A P T E R 3 LaserWriter Pro Software Table 3-10 System parameters (continued) Key Type CurOutlineCache integer Default 0 Read only. Identifies the amount of RAM currently occupied by the outline cache. Details CurPatternCache integer 0 Read only. Identifies the amount of RAM currently occupied by the pattern cache. CurScreenStorage integer 0 Read only. Identifies the amount of RAM currently occupied by screen storage. CurSourceList integer 0 Read only. ≥0.
C H A P T E R 3 LaserWriter Pro Software Table 3-10 System parameters (continued) Key Type MaxRasterMemory integer Default MaxScreenStorage integer MaxSourceList integer 24576 ≥0 MaxUPathCache integer 300000 ≥0 PageCount integer 0 Read only. ≥ 0. Indicates how many pages have been successfully delivered. PrinterMode integer Depends on configuration Read only. Returns the value of the rotary switch setting. The range is 0-9.
C H A P T E R 3 LaserWriter Pro Software Table 3-10 System parameters (continued) Key Type Default Details StartJobPassword string null Any string ≥ 32 characters is not allowed. Value is persistent across power cycles. ValidNV boolean true Refer to the Program Language Reference Manual Supplement. WaitTimeout integer 60 ≥ 0. Value is persistent across power cycles.
C H A P T E R 3 LaserWriter Pro Software Table 3-11 lists the parameters common to all FileSystem devices. Table 3-11 Parameters common to all FileSystem devices Key Type Details Free integer Read only. Indicates the amount of free space (in pages for disks, and bytes for cartridges) on the media device. Legal values: Any non-negative integer Errors: None HasNames boolean Read only. Indicates whether the device supports files. If false, the device is a single entity of data.
C H A P T E R 3 LaserWriter Pro Software Table 3-11 Key Parameters common to all FileSystem devices (continued) Type Details If LogicalSize is set with a certain value and the device is then reformatted, a query of LogicalSize should return the value that was set. However, if the parameter is queried at any time before the device is reformatted, it may return a different value from the one that was set, because it will return the current size of the device.
C H A P T E R 3 LaserWriter Pro Software Table 3-11 Parameters common to all FileSystem devices (continued) Key Type Details Type name Read only. This constant always returns a value of FileSystem. Legal values: FileSystem Errors: None Writeable boolean Read only. Indicates whether you can currently write to the device. Usually this boolean is true only if the media is physically able to be written to, and is not write protected.
C H A P T E R 3 LaserWriter Pro Software ■ with pending parameter sets, the set names contain the suffix _Pending. This is a read-only set, and it provides information about the settings that will be in use at the beginning of the next job on the corresponding channel, assuming that there have been no previous parameter changes. ■ with RAM parameter sets, the set names have no suffix.
C H A P T E R 3 LaserWriter Pro Software Table 3-13 %Serial_NVx% communication parameter sets Key Type %Serial_NV% default %Serial_NV2% default %Serial_NV3% default %Serial_NV4% default Baud integer 19200 1200 1200 9600 DataBits integer 8 8 8 8 Enabled boolean true true true true FlowControl name XonXoff EtxAck Dtr XonXoff Interpreter name PostScript PostScript LaserJet IIP PostScript On boolean true true true true Parity name None None None None Protocol
C H A P T E R 3 LaserWriter Pro Software Table 3-15 %LocalTalk_NVx% communication parameter sets Key Type %LocalTalk_NV% default %LocalTalk_NV2% %LocalTalk_NV3% %LocalTalk_NV4% defaults LocalTalkType string LaserWriter LaserWriter Enabled boolean false true Interpreter name PostScript PostScript On boolean false true NOTE LocalTalkType parameters refer to the same nonvolatile storage.
C H A P T E R 3 LaserWriter Pro Software Engine Device 3 The %Engine% device contains parameters that control the print engine itself. The LaserWriter Pro’s %Engine% device contains the parameters listed in Table 3-18. Table 3-18 %Engine% communication parameter sets Key Type Default Details Darkness real 0.5 Darkness controls the amount of toner applied to the paper. A value of 0.0 signifies the minimum darkness, and 1.0 signfies the maximum darkness. Values outside this range are not legal.
C H A P T E R 3 LaserWriter Pro Software Table 3-19 Regular resource categories Category name Instances ColorRendering DefaultColorRendering300 DefaultColorRendering600 ColorSpace No instances defined Encoding ISOLatin1Encoding StandardEncoding Font AvantGarde-Book AvantGarde-BookOblique AvantGarde-Demi AvantGarde-DemiOblique Details Bookman-Demi Bookman-DemiItalic Bookman-Light Bookman-LightItalic Courier Courier-Bold Courier-BoldOblique Courier-Oblique Emulatorfont Helvetica Helvetica-Bold
C H A P T E R 3 LaserWriter Pro Software Table 3-19 Regular resource categories (continued) Category name Instances Details Halftone 150x0 106x45 85x56 75x0 53x45 80x45 The instances listed name Type 1 halftone dictionaries, where the name is interpreted as FrequencyxAngle. Frequency and Angle are the corresponding keys in the Type 1 halftone dictionary. See the PostScript Language Reference Manual for further information.
C H A P T E R 3 LaserWriter Pro Software Table 3-20 Resources with implicit instances Category name Instances ColorRendering 1 ColorSpaceFamily CIEBasedA CIEBasedABC DeviceCMYK DeviceGray DeviceRGB Indexed Pattern Separation Emulator LaserJetIIP SystemPatch hpcl Filter ASCII85Decode ASCII85Encode ASCIIHexDecode ASCIIHexEncode CCITTFaxDecode CCITTFaxEncode DCTEDecode DCTEEncode LZWDecode LZWEncode NullEncode RunLengthDecode RunLengthEncode SubFileDecode FMapType 2, 3, 4, 5, 6, 7, 8 FontType
C H A P T E R 3 LaserWriter Pro Software Table 3-20 Resources with implicit instances (continued) Category name Instances Details IODevice %EtherTalk% %EtherTalk_NV% %EtherTalk_NV2% %EtherTalk_NV3% %EtherTalk_NV4% %EtherTalk_Pending% The EtherTalk I/ODevices are not present in the LaserWriter Pro 600 printer.
C H A P T E R 3 LaserWriter Pro Software Table 3-21 Resources used in defining new resource categories Category name Instances Category Category ColorRendering ColorRenderingType ColorSpace ColorSpaceFamily Emulator Encoding FilterFMapType Font FontType Form FormType Generic Halftone HalftoneType ImageType IODevice Pattern PatternType ProcSet Generic No instances defined Resource Categories 53
C H A P T E R 3 LaserWriter Pro Software Emulator Parameters 3 Table 3-22 lists the emulator parameters specific to the LaserWriter Pro printer. The parameters apply to the Hewlett-Packard LaserJet IIP emulator. The emulator parameters specify the characteristics of fonts used in the LaserJet IIP emulation. Table 3-22 Emulator parameters Key Type Semantics FontFixed boolean If true, this parameter requests a fixed pitch font, such as Courier.
C H A P T E R 3 LaserWriter Pro Software Table 3-22 Emulator parameters (continued) Key Type Semantics FontWeight integer Specifies the weight or boldness of the desired font. As an option, PostScript contains a weight parameter in the FontInfo dictionary.
C H A P T E R 3 LaserWriter Pro Software Device control and configuration of system parameters in PostScript Level 2 are accomplished in a standard way in the language through the device setup and interpreter parameter operators. Level 1 PostScript language driver software frequently depends on statusdict operators that were present in PostScript Level 1 products. To maintain compatibility with these products, a collection of statusdict operators and procedures is included in each Level 2 implementation.
C H A P T E R 3 LaserWriter Pro Software Table 3-23 Compatibility operators (continued) userdict a4 a4small b5 legal letter lettersmall note systemdict devdismount devmount devformat devstatus devforall Setting System Parameters 3 This section describes the compatibility operators that set Level 2 system parameters. Table 3-1 also provides information about the system parameters.
C H A P T E R 3 LaserWriter Pro Software checkpassword Syntax string |int checkpassword bool Definition This operator checks whether string or int (int is converted to a string) is a valid password for either SystemParamsPassword, or StartJobPassword. If valid, true is returned. Otherwise, false is returned. If either password is not set, then true is returned. A returned value of true indicates that string or int is a valid argument to startjob and exitserver.
C H A P T E R 3 LaserWriter Pro Software dosysstart 3 Syntax – dosysstart bool Definition This operator returns true only if the value of the system parameter StartupMode is 1. Error stackoverflow emulate 3 Syntax file name emulate – Definition This operator invokes one of the emulators. The file parameter is used as an input source for the emulation. For the LaserWriter Pro printer the file should always be the file that is returned by the currentfile operator.
C H A P T E R 3 LaserWriter Pro Software papertray 3 Syntax – papertray integer Definition This operator returns the paper tray numbers, as set by the setpapertray operator. The standard value for papertray is the value of the defaultpapertray operator. Error stackoverflow printername 3 Syntax string printername substring Definition This operator stores the value of the system parameter PrinterName in string, and it returns a string object designating the substring actually used.
C H A P T E R 3 LaserWriter Pro Software revision 3 Syntax – revision int Definition This operator returns a string with the same value as the system parameter Revision. Error stackoverflow setdefaultmultipurposepapertraysize 3 Syntax name bool setdefaultmultipurposetraysize – Definition This operator tells the interpreter what paper size is installed in the multipurpose tray.
C H A P T E R 3 LaserWriter Pro Software setdosysstart Syntax bool setdosyststart – Definition This operator sets the system parameter, StartupMode, according to the value of bool. StartupMode is set to 1 if bool is true, and it is set to 0 if bool is false.
C H A P T E R 3 LaserWriter Pro Software Setting Page Device Parameters 3 This section describes compatibility operators that set Level 2 page device parameters. Table 3-1 provides additional information about these operators. margins 3 Syntax – margins top left Definition This operator returns the x and y components of the page device Margins parameter as left and top, respectively.
C H A P T E R 3 LaserWriter Pro Software Setting User Parameters 3 This section describes the compatibility operators that set Level 2 user parameters. Table 3-9 provides additional information about these operators. jobname 3 Syntax – jobname string Definition This operator is a string with the same value as the user parameter JobName. If you redefine either jobname or the user parameter JobName, the other is redefined to the same value.
C H A P T E R 3 LaserWriter Pro Software Setting Device Parameters 3 This section describes the compatibility operators that set Level 2 device parameters. appletalktype 3 Syntax – appletalktype string Definition This operator is a string with the same value as the LocalTalkType device parameter in the %LocalTalk% parameter set.
C H A P T E R 3 LaserWriter Pro Software hardwareiomode Syntax – hardwareiomode int Definition This operator returns int, which indicates a current communications channel for which the corresponding device parameter Enabled Boolean value is true. Because multiple channels may be enabled, the smallest int is returned.
C H A P T E R 3 LaserWriter Pro Software sethardwareiomode 3 Syntax int sethardwareiomode – Definition This operator opens specified channels for communication and closes other channels. The variable int specifies which communication channel(s) should be opened by setting the On and Enabled device parameters to true. All other channels will be explicitly closed by setting the On and Enabled parameters to false. The interpretation of int is as follows: 0 Open %Serial% and %SerialB%. Close all others.
C H A P T E R 3 LaserWriter Pro Software userdiskpercent Syntax – userdiskpercent int Definition This operator returns 0. It is not operative in the LaserWriter Pro printer. Error stackoverflow Setting Serial Communication Parameters 3 3 The following compatibility operators set Level 2 serial communications parameters. Serial communications channel (SCC) operator encoding is described in the following section.
C H A P T E R 3 LaserWriter Pro Software setsccbatch 3 Syntax channel baud options setsccbatch – Definition This operator sets the communication device parameters for serial communications. It affects the following settings: ■ ■ %SerialB_NV%, if channel equals 9 %Serial_NV%, if channel equals 25 baud and options affect the following device parameters: Error ■ Baud, StopBits, and FlowControl, which are set according to the values for baud, stop bits, and flow control.
C H A P T E R 3 LaserWriter Pro Software Table 3-24 SCC compatibility operators options byte values Bit position Value and function Bit 7 Stop bits 0 1 Bits 6 and 5 1 stop bit 2 stop bits Data bits 0 1 2 Bits 4–2 Standard 7 bits 8 bits Flow control 0 1 2 Bits 1 and 0 XON/XOFF DTR ETX/ACK Parity 0 1 2 3 Space Odd Even Mark Note In going from DataBits and Parity to data bits and parity, standard parity is never used as it is in Level 1.
C H A P T E R 3 LaserWriter Pro Software Table 3-26 Device parameters-to-options conversion DataBits and Parity Data bits and parity Level 2 Level 1 7 bits None 7 bits mark 7 bits Space 7 bits space 7 bits Mark 7 bits mark 7 bits Odd 7 bits odd 7 bits Even 7 bits even 8 bits None 8 bits mark 8 bits Space 8 bits space 8 bits Mark 8 bits mark 8 bits Odd 8 bits odd 8 bits Even 8 bits even The conversions shown in Tables 3-25 and 3-26 provide the best possible compatibility with Pos
C H A P T E R 3 LaserWriter Pro Software Table 3-27 Paper size compatibility operators Operator PageSize ImagingBBox a4 [595 842] Null a4small [595 842] [25 25 570 817] b5 [516 729] Null legal [612 1008] Null letter [612 792] Null lettersmall [612 792] [25 25 587 767] NOTE Units shown (595, etc.) are points. 1 point is 1/72 inch. Paper Tray Compatibility Operators 3 The paper tray operators are in the status dictionary, statusdict.
C H A P T E R Figure 4-0 Listing 4-0 Table 4-0 4 TrueType Fonts Thi d t t d ith F M k 4 404
C H A P T E R 4 TrueType Fonts The LaserWriter Pro printer has built-in TrueType font-scaling software. This chapter describes the behavior of the TrueType downloadable PostScript font format as it applies to the LaserWriter Pro printer, which is described as a Type A Device. In defining requirements for the LaserWriter Pro printer, this chapter also provides information on other LaserWriter printers and PostScript devices that do not have the built-in TrueType font scaler.
C H A P T E R 4 TrueType Fonts TrueType Code 4 The TrueType font-scaling code is partitioned into three pieces and sent to the device on demand for each document that uses an 'sfnt' (scalable font) resource. The code is encrypted using the Adobe encryption mechanism and depends on the existence of the eexec and cexec operators. Because of the way the code is encrypted, the downloadable TrueType code can be used only on Class B devices and is discarded on all other classes of devices.
C H A P T E R 4 TrueType Fonts TrueType Font Definition 4 The third component is the actual TrueType font. The font has the minimum but essential parts of a normal PostScript font: a font dictionary containing a font type, font matrix, font bounding box, and an encoding vector.
C H A P T E R 4 TrueType Fonts Device Operation 4 There are three classes of printers, known as Class A devices, Class B devices, and Class C devices. The subject of this developer note, LaserWriter Pro printer, is a Class A device. This section describes how TrueType fonts are handled on Class A printers. It also describes how TrueType fonts are handled on Class B, and Class C devices, to provide definition by comparison for the LaserWriter Pro printer.
C H A P T E R 4 TrueType Fonts procedure with respect to setcharwidth, setcachedevice, and so on. This behavior has existed in all PostScript font formats, but it has only been documented as part of Level 2. This behavior is part of Type 42 BuildChar. Class B Devices 4 Class B devices provide the primary motivation and design center for the TrueType font format in its current configuration.
C H A P T E R 4 TrueType Fonts operation of intelligent font downloaders, there are several conventions that must be used for the textual definition of the font.
C H A P T E R 4 TrueType Fonts Table 4-1 lists the comments that delineate sections of code and indicates the classes of printers for which they are required. indicates the space character. You must enter a space at the beginning of each end comment line. Table 4-1 Section code comments Comments Description %beginsfnt %endsfnt These comments bracket the creation of the common entries in the font dictionary for Class A and Class B devices. It may be discarded on Class C devices.
C H A P T E R 4 TrueType Fonts Table 4-2 Type 42 key-value pairs common to all PostScript font dictionaries Key Type Semantics Encoding array Required. An array of 256 names that maps character codes (integers) to character names. Note that Apple TrueType fonts have an encoding vector different from the StandardEncoding used by Type 1 fonts. Conventional value: derived from information in the 'sfnt' post table. FontBBox array Required.
C H A P T E R 4 TrueType Fonts Table 4-2 Type 42 key-value pairs common to all PostScript font dictionaries (continued) Key Type Semantics WMode integer Optional. Indicates which of two sets of metrics is used when characters are shown from this font. If this entry (or the WMode entry of the root font from which this font is a descendant) has the value 1, then this font must have a CDevProc entry (see Table 4-3). See Section 5.
C H A P T E R 4 TrueType Fonts Table 4-3 Entries for Type 1 specific font dictionaries (continued) Key Type Semantics StrokeWidth number Optional. Indicates the stroke width (in units of the character coordinate system) for stroked outline fonts (PaintType 2). This field is not initially present in filled font descriptions. It must be added when creating a stroked font from an existing font.
C H A P T E R 4 TrueType Fonts Table 4-5 Optional entries for FontInfo dictionary (continued) Key Type Semantics Notice string Trademark or copyright notice, if applicable. Conventional value: copyright notice from the 'sfnt' name table. UnderlinePosition number Recommended distance from the baseline for positioning underlining strokes. This number is the y coordinate (in character space) of the center of the stroke. Conventional value: underline position from the 'sfnt' post table.
C H A P T E R 4 TrueType Fonts TrueType Font Dictionary Entries 85