PC_PRINTER_SET_PEN

Set the width, style and colour for lines and rectangles when drawn using a printer.

Syntax:

call "PC_PRINTER_SET_PEN" using
                          Printer-Handle
                          by value Pen-Width
                          by value Pen-Style
                          by value Pen-red
                          by value Pen-blue
                          by value Pen-green
end-call

Parameters:

  Using call prototype (see Key) Picture
pen-width cblt-x4-comp5 pic x(4) comp-5.
pen-width cblt-x4-comp5 pic x(4) comp-5.
pen-red cblt-x pic x
pen-blue cblt-x pic x
pen-green cblt-x pic x

On Entry:

  Value Meaning
pen-style 0 solid line
  1 dash
  2 dot
  3 dash, Dot
  4 dash, dot, dot
  5 invisible
pen-width width of line when drawing lines or rectangles
pen-red Value between 0 and 255 intensity of red
pen-green Value between 0 and 255 intensity of green
pen-blue Value between 0 and 255 intensity of blue

Comments:

The units used for page dimensions in .NET COBOL are different to the ones used in your native COBOL programs; therefore, hard-coded settings for such things as line size may produce unexpected results when using older source code in a .NET environment. To preserve compatibility of your old source code, we recommend that you use conditional compilation; otherwise, amend your code for .NET accordingly.

call "PC_PRINTER_SET_PEN" using 
     by reference handle
    $if ILGEN set									*> ILGEN directive indicates .NET COBOL
          by value 1
    $else
          by value 5
    $end
          by value PS-SOLID
          by value 255
          by value 0
          by value 0
     end-call