[ Previous | Next | Contents | Glossary | Home | Search ]
AIX Version 4.3 Base Operating System and Extensions Technical Reference, Volume 1

initialize Subroutine

Purpose

Performs printer initialization.

Library

None (provided by the formatter).

Syntax

#include <piostruct.h>

int initialize ()

Description

The initialize subroutine is invoked by the formatter driver after the setup subroutine returns.

If the -j flag passed from the qprt command has a nonzero value (true), the initialize subroutine uses the piocmdout subroutine to send a command string to the printer. This action initializes the printer to the proper state for printing the file. Any variables referenced by the command string should be the attribute values from the database, overridden by values from the command line.

If the -j flag passed from the qprt command has a nonzero value (true), any necessary fonts should be downloaded.

Return Values

0 Indicates a successful operation.

If the initialize subroutine detects an error, it uses the piomsgout subroutine to invoke an error message. It then invokes the pioexit subroutine with a value of PIOEXITBAD.

Note: If either the piocmdout or piogetstr subroutine detects an error, it issues its own error messages and terminates the print job.

Related Information

The piocmdout subroutine, pioexit subroutine, piogetstr subroutine, piomsgout subroutine, setup subroutine.

Adding a New Printer Type to Your System, Printer Addition Management Subsystem: Programming Overview, Understanding Embedded References in Printer Attribute Strings in AIX Version 4.3 Kernel Extensions and Device Support Programming Concepts.

Example of Print Formatter in AIX Version 4.3 General Programming Concepts: Writing and Debugging Programs.


[ Previous | Next | Contents | Glossary | Home | Search ]