*%%
*%% Samsung ML-6080 PCL6
*%%
*%% Copyright 1998 - 1999, Microsoft Corp.
*%% All Rights Reserved.
*%%

*%%
*%% Global Entries
*%%
*GPDSpecVersion: "1.0"
*GPDFileVersion: "1.0"

*%%% ======================
*%%% Include standard GPD files
*%%% =====================
*Include: "StdNames.gpd"
*Include: "ttfsub.gpd"

*%%
*%% Model Specific Global Entries
*%%
*GPDFileName: "sml6080.gpd"
*ModelName:   "Samsung ML-6080 PCL6"
*MaxCopies: 32767
*PrintRate: 12
*PrintRatePPM: 12
*PrintRateUnit: PPM
*%%% ======================
*%%% Macros
*%%% ======================
*Include: "pjl.gpd"
*Include: "p6font.gpd"
*Include: "p6disp.gpd"

*%%% ======================
*%%% Main
*%%% ======================
*Include: "pclxl.gpd"

*%%% ======================
*%%% JOB_SETUP, PAGE_FINISH
*%%% , JOB_FINISH
*%%% ======================
*Macros: PCLXLCommand
{
*%%% ---------------------------------------------------------------------------
*%%% PCL XL Stream Header
*%%% ---------------------------------------------------------------------------
PCLXL_StreamHeader: ") HP-PCL XL;1;1;"
+                   "Comment Copyright(c) 1999 Microsoft Corporation<0A>"

*%%% ---------------------------------------------------------------------------
*%%% BeginSession
*%%%     Measure(ubyte) & UnitsPerMeasure(uint16_xy) & {ErrorReport(ubyte)}
*%%% ---------------------------------------------------------------------------
PCLXL_BeginSession1200: =uint16_xy "<b004b004>" =attr_ubyte =UnitsPerMeasure =ubyte
+ =eInch =attr_ubyte =Measure =ubyte =eBackChAndErrPage =attr_ubyte =ErrorReport =BeginSession

PCLXL_BeginSession600: =uint16_xy "<58025802>" =attr_ubyte =UnitsPerMeasure =ubyte
+ =eInch =attr_ubyte =Measure =ubyte =eBackChAndErrPage =attr_ubyte =ErrorReport =BeginSession

PCLXL_BeginSession300: =uint16_xy "<2c012c01>" =attr_ubyte =UnitsPerMeasure =ubyte
+ =eInch =attr_ubyte =Measure =ubyte =eBackChAndErrPage =attr_ubyte =ErrorReport =BeginSession

Width: %m{ RasterDataWidthInBytes }
Height: %m{ RasterDataHeightInPixels }
DataSize: %l{ NumOfDataBytes }
FntHeight: %l{ FontHeight*600/TextYRes }
FntNextGlyph: %l{ NextGlyph }

*%%% ---------------------------------------------------------------------------
*%%% BeginRaster
*%%%     ColorDepth(ubyte) & ColorMapping(ubyte) & SourceWidth(uint16) &
*%%%     SourceWidth(uint16) & SourceHeight(uint16)
*%%% ---------------------------------------------------------------------------
PCLXL_CmdBeginRaster: =ubyte =e1Bit =attr_ubyte =ColorDepth
+                     =ubyte =eDirectPixel =attr_ubyte =ColorMapping
+                     =uint16 =Width =attr_ubyte =SourceWidth
+                     =uint16 =Height =attr_ubyte =SourceHeight
+                     =uint16_xy =Width =Height =attr_ubyte =DestinationSize
+                     =BeginImage
+                     =ubyte =eNoCompression =attr_ubyte =CompressMode
+                     =ubyte "<00>" =attr_ubyte =StartLine
+                     =uint16 =Height =attr_ubyte =BlockHeight
+                     =ReadImage

PCLXL_CmdSendBlockData: =dataLength =DataSize "<0000>"

DestinationX: %l{DestX}
DestinationY: %l{DestY}
DestinationXRel: %l{DestYRel}
DestinationYRel: %l{DestXRel}
NumOfCopy: %l{NumOfCopies}
PrintDir: %l{PrintDirInCCDegrees}
FntName: =ubyte_array =uint16 "<1000>" "MS PCLXLFont " %3d{CurrentFontID}
}

*%%% ======================
*%%% Features and Options
*%%% ======================

*%% Orientation
*Feature: Orientation
{
    *rcNameID: =ORIENTATION_DISPLAY
    *DefaultOption: PORTRAIT
    *Option: PORTRAIT
    {
        *rcNameID: =PORTRAIT_DISPLAY
    }
    *Option: LANDSCAPE_CC90
    {
        *rcNameID: =LANDSCAPE_DISPLAY
    }
}

*%%% ======================
*%%% JOB_SETUP
*%%% ======================

*%%% ======================
*%%% JOB_SETUP.1
*%%% START PLJ JOB
*%%% PAGEPROTECT
*%%% TIMEOUT
*Feature: PageProtect
{
    *rcNameID: =PAGE_PROTECTION_DISPLAY
    *DefaultOption: OFF
    *Option: ON
    {
        *rcNameID: =ON_DISPLAY
        *Command: CmdSelect
        {
            *Order: JOB_SETUP.1
            *Cmd: =PJL_STARTJOB =PJL_COMMENT =PJL_PAGEPROTECT_ON =PJL_TIMEOUT_90
        }
    }
    *Option: OFF
    {
        *rcNameID: =OFF_DISPLAY
        *Command: CmdSelect
        {
            *Order: JOB_SETUP.1
            *Cmd: =PJL_STARTJOB =PJL_COMMENT =PJL_PAGEPROTECT_ON =PJL_TIMEOUT_90
        }
    }
}
*%%% ======================
*%%% JOB_SETUP.2
*%%% ECONOMODE
*Feature: Economode
{
    *rcNameID: =ECONOMODE_DISPLAY
    *DefaultOption: Option1
    *Option: Option1
    {
        *rcNameID: =ECONOMODE_DEFAULT_DISPLAY
    }
    *Option: Option2
    {
        *rcNameID: =ECONOMODE_OFF_DISPLAY
        *Command: CmdSelect
        {
            *Order: JOB_SETUP.2
            *Cmd: =PJL_ECONOMODE_OFF
        }
    }
    *Option: Option3
    {
        *rcNameID: =ECONOMODE_ON_DISPLAY
        *Command: CmdSelect
        {
            *Order: JOB_SETUP.2
            *Cmd: =PJL_ECONOMODE_ON
        }
    }
}

*%%% ======================
*%%% JOB_SETUP.3
*%%% RET
*Feature: RET
{
    *rcNameID: =PRINT_QUALITY
    *DefaultOption: Option1
    *Option: Option1
    {
        *rcNameID: =PRINT_QUALITY_DEFAULT
    }
    *Option: Option2
    {
        *rcNameID: =PRINT_QUALITY_LIGHT
        *Command: CmdSelect
        {
            *Order: JOB_SETUP.3
            *Cmd: =PJL_RET_LIGHT
        }
    }
    *Option: Option3
    {
        *rcNameID: =PRINT_QUALITY_MEDIUM
        *Command: CmdSelect
        {
            *Order: JOB_SETUP.3
            *Cmd: =PJL_RET_MEDIUM
        }
    }
    *Option: Option4
    {
        *rcNameID: =PRINT_QUALITY_DARK
        *Command: CmdSelect
        {
            *Order: JOB_SETUP.3
            *Cmd: =PJL_RET_DARK
        }
    }
    *Option: Option5
    {
        *rcNameID: =PRINT_QUALITY_OFF
        *Command: CmdSelect
        {
            *Order: JOB_SETUP.3
            *Cmd: =PJL_RET_OFF
        }
    }
}

*%%% ======================
*%%% JOB_SETUP.4
*%%% Collate
*Feature: Collate
{
    *rcNameID: =COLLATOR_DISPLAY *% this shouldn't appear...

    *DefaultOption: OFF
    *Option: ON
    {
        *rcNameID: =ON_DISPLAY
       *switch: PrinterHardDisk
        {
           *case: FALSE
 	{

	   *Switch:  Memory  *% need 16MB to collate w/o harddisk
	    {
	     	 *Case: 4MB
	      	   {
 			*Command: CmdSelect
                    		{
                    		  *Order: JOB_SETUP.4
                    		  *Cmd: =PJL_COLLATE_OFF
                     		}
		   }
          	             *Case: 8MB
		   {
	    		 *Command: CmdSelect
                   		{
                    		  *Order: JOB_SETUP.4
                    		  *Cmd: =PJL_COLLATE_OFF
                  		}
                 	  }
         	             *Case: 12MB
		   {
	    		 *Command: CmdSelect
                   		{
                    		  *Order: JOB_SETUP.4
                    		  *Cmd: =PJL_COLLATE_OFF
                  		}
                 	  }
		*default
		   {
	    		 *Command: CmdSelect
                   		{
                    		  *Order: JOB_SETUP.4
                    		  *Cmd: =PJL_COLLATE_ON
                  		}
                 	  }
	     }
         	}
            *case: TRUE
            {
                *Command: CmdSelect
                {
                    *Order: JOB_SETUP.4
                    *Cmd: =PJL_COLLATE_ON
                }
            }
        }
    }
    *Option: OFF
    {
        *rcNameID:=OFF_DISPLAY
        *Command: CmdSelect
        {
            *Order: JOB_SETUP.4
            *Cmd: =PJL_COLLATE_OFF
        }
    }
}

*Feature: JobRetention
{
    *rcNameID: =JOB_RETENTION_DISPLAY *% Job Retention
    *DefaultOption: Option1
    *Option: Option1
    {
        *rcNameID: =OFF_DISPLAY
        *Command: CmdSelect
        {
            *Order: JOB_SETUP.3
            *Cmd: "@PJL SET HOLD=OFF<0A>"
        }
    }
    *Option: Option2
    {
        *rcNameID: =QUICK_COPY_DISPLAY
        *Command: CmdSelect
        {
            *Order: JOB_SETUP.3
            *Cmd: "@PJL SET HOLD=ON<0A>"
        }
    }
    *Option: Option3
    {
        *rcNameID: =PROOF_HOLD_DISPLAY
        *Command: CmdSelect
        {
           *Order: JOB_SETUP.3
            *Cmd: "@PJL SET HOLD=PROOF<0A>"
        }
    }
    *Option: Option4
    {
        *rcNameID: =STORE_JOB_DISPLAY
        *Command: CmdSelect
        {
            *Order: JOB_SETUP.3
            *Cmd: "@PJL SET HOLD=STORE<0A>"
         }
      }
}

*Feature: JobRetentionUserID
{
    *rcNameID: =JOB_RETENTION_USERID_DISPLAY *%"Job Retention User ID"
    *DefaultOption: Option1
    *Option: Option1
    {
        *Name: "1"
        *Command: CmdSelect
        {
            *Order: JOB_SETUP.3
            *Cmd: "@PJL SET USERNAME=<22>1<22><0A>"
        }
    }
    *Option: Option2
    {
        *Name: "2"
        *Command: CmdSelect
        {
            *Order: JOB_SETUP.3
            *Cmd: "@PJL SET USERNAME=<22>2<22><0A>"
        }
    }
    *Option: Option3
    {
        *Name: "3"
        *Command: CmdSelect
        {
            *Order: JOB_SETUP.3
            *Cmd: "@PJL SET USERNAME=<22>3<22><0A>"
        }
    }
    *Option: Option4
    {
        *Name: "4"
        *Command: CmdSelect
        {
            *Order: JOB_SETUP.3
            *Cmd: "@PJL SET USERNAME=<22>4<22><0A>"
        }
    }
    *Option: Option5
    {
        *Name: "5"
        *Command: CmdSelect
        {
            *Order: JOB_SETUP.3
            *Cmd: "@PJL SET USERNAME=<22>5<22><0A>"
        }
    }
    *Option: Option6
    {
        *Name: "6"
        *Command: CmdSelect
        {
            *Order: JOB_SETUP.3
            *Cmd: "@PJL SET USERNAME=<22>6<22><0A>"
        }
    }
    *Option: Option7
    {
        *Name: "7"
        *Command: CmdSelect
        {
            *Order: JOB_SETUP.3
            *Cmd: "@PJL SET USERNAME=<22>7<22><0A>"
        }
    }
    *Option: Option8
    {
        *Name: "8"
        *Command: CmdSelect
        {
            *Order: JOB_SETUP.3
            *Cmd: "@PJL SET USERNAME=<22>8<22><0A>"
        }
    }
    *Option: Option9
    {
        *Name: "9"
        *Command: CmdSelect
        {
            *Order: JOB_SETUP.3
            *Cmd: "@PJL SET USERNAME=<22>9<22><0A>"
        }
    }
    *Option: Option10
    {
        *Name: "10"
        *Command: CmdSelect
        {
            *Order: JOB_SETUP.3
            *Cmd: "@PJL SET USERNAME=<22>10<22><0A>"
        }
    }
    *Option: Option11
    {
        *Name: "11"
        *Command: CmdSelect
        {
            *Order: JOB_SETUP.3
            *Cmd: "@PJL SET USERNAME=<22>11<22><0A>"
        }
    }
    *Option: Option12
    {
        *Name: "12"
        *Command: CmdSelect
        {
            *Order: JOB_SETUP.3
            *Cmd: "@PJL SET USERNAME=<22>12<22><0A>"
        }
    }
    *Option: Option13
    {
        *Name: "13"
        *Command: CmdSelect
        {
            *Order: JOB_SETUP.3
            *Cmd: "@PJL SET USERNAME=<22>13<22><0A>"
        }
    }
    *Option: Option14
    {
        *Name: "14"
        *Command: CmdSelect
        {
            *Order: JOB_SETUP.3
            *Cmd: "@PJL SET USERNAME=<22>14<22><0A>"
        }
    }
    *Option: Option15
    {
        *Name: "15"
        *Command: CmdSelect
        {
            *Order: JOB_SETUP.3
            *Cmd: "@PJL SET USERNAME=<22>15<22><0A>"
        }
    }
    *Option: Option16
    {
        *Name: "16"
        *Command: CmdSelect
        {
            *Order: JOB_SETUP.3
            *Cmd: "@PJL SET USERNAME=<22>16<22><0A>"
        }
    }
    *Option: Option17
    {
        *Name: "17"
        *Command: CmdSelect
        {
            *Order: JOB_SETUP.3
            *Cmd: "@PJL SET USERNAME=<22>17<22><0A>"
        }
    }
    *Option: Option18
    {
        *Name: "18"
        *Command: CmdSelect
        {
            *Order: JOB_SETUP.3
            *Cmd: "@PJL SET USERNAME=<22>18<22><0A>"
        }
    }
    *Option: Option19
    {
        *Name: "19"
        *Command: CmdSelect
        {
            *Order: JOB_SETUP.3
            *Cmd: "@PJL SET USERNAME=<22>19<22><0A>"
        }
    }
    *Option: Option20
    {
        *Name: "20"
        *Command: CmdSelect
        {
            *Order: JOB_SETUP.3
            *Cmd: "@PJL SET USERNAME=<22>20<22><0A>"
        }
    }
}

*% constrain all but option 1 when no hard disk installed
*InvalidCombination: LIST(PrinterHardDisk.FALSE,JobRetention.Option2)
*InvalidCombination: LIST(PrinterHardDisk.FALSE,JobRetention.Option3)
*InvalidCombination: LIST(PrinterHardDisk.FALSE,JobRetention.Option4)

*% constrain all but option 1 when no hard disk installed
*InvalidCombination: LIST(PrinterHardDisk.FALSE,JobRetentionUserID.Option2)
*InvalidCombination: LIST(PrinterHardDisk.FALSE,JobRetentionUserID.Option3)
*InvalidCombination: LIST(PrinterHardDisk.FALSE,JobRetentionUserID.Option4)
*InvalidCombination: LIST(PrinterHardDisk.FALSE,JobRetentionUserID.Option5)
*InvalidCombination: LIST(PrinterHardDisk.FALSE,JobRetentionUserID.Option6)
*InvalidCombination: LIST(PrinterHardDisk.FALSE,JobRetentionUserID.Option7)
*InvalidCombination: LIST(PrinterHardDisk.FALSE,JobRetentionUserID.Option8)
*InvalidCombination: LIST(PrinterHardDisk.FALSE,JobRetentionUserID.Option9)
*InvalidCombination: LIST(PrinterHardDisk.FALSE,JobRetentionUserID.Option10)
*InvalidCombination: LIST(PrinterHardDisk.FALSE,JobRetentionUserID.Option11)
*InvalidCombination: LIST(PrinterHardDisk.FALSE,JobRetentionUserID.Option12)
*InvalidCombination: LIST(PrinterHardDisk.FALSE,JobRetentionUserID.Option13)
*InvalidCombination: LIST(PrinterHardDisk.FALSE,JobRetentionUserID.Option14)
*InvalidCombination: LIST(PrinterHardDisk.FALSE,JobRetentionUserID.Option15)
*InvalidCombination: LIST(PrinterHardDisk.FALSE,JobRetentionUserID.Option16)
*InvalidCombination: LIST(PrinterHardDisk.FALSE,JobRetentionUserID.Option17)
*InvalidCombination: LIST(PrinterHardDisk.FALSE,JobRetentionUserID.Option18)
*InvalidCombination: LIST(PrinterHardDisk.FALSE,JobRetentionUserID.Option19)
*InvalidCombination: LIST(PrinterHardDisk.FALSE,JobRetentionUserID.Option20)

*%%% ======================
*%%% JOB_SETUP.5
*%%%     RESOLUTION
*%%%     ENTER LANGUAGE=PCLXL
*%%%     PCL XL Stream Header
*%%%     BeginSession
*%%% CmdEndRaster
*%%%     EndImage
*%%% CmdSendBlockData
*%%%     EndImage
*Feature: Resolution
{
    *rcNameID: =RESOLUTION_DISPLAY
    *DefaultOption: Option1

    *Option: Option1
    {
        *Name: "600 x 600 " =DOTS_PER_INCH
        *DPI: PAIR(600, 600)
        *TextDPI: PAIR(600, 600)
        *MinStripBlankPixels: 32
        EXTERN_GLOBAL: *StripBlanks: LIST(ENCLOSED,TRAILING)
        *SpotDiameter: 100
        *Command: CmdBeginRaster
        {
            *Cmd : =PCLXL_CmdBeginRaster
        }

        *Command: CmdEndRaster { *Cmd : =EndImage }
        *Command: CmdSendBlockData
        {
            *Cmd: =PCLXL_CmdSendBlockData
        }

        *Command: CmdSelect
        {
            *Order: JOB_SETUP.5
            *Cmd: =PJL_RESOLUTION_600 =PJL_ENTER_PCLXL =PCLXL_StreamHeader =PCLXL_BeginSession600
        }
    }
    *Option: Option2
    {
        *Name: "300 x 300 " =DOTS_PER_INCH
        *DPI: PAIR(300, 300)
        *TextDPI: PAIR(300, 300)
        *MinStripBlankPixels: 32
        EXTERN_GLOBAL: *StripBlanks: LIST(ENCLOSED,TRAILING)
        *SpotDiameter: 100
        *Command: CmdBeginRaster
        {
            *Cmd : =PCLXL_CmdBeginRaster
        }

        *Command: CmdEndRaster { *Cmd : =EndImage }
        *Command: CmdSendBlockData
        {
            *Cmd: =PCLXL_CmdSendBlockData
        }

        *Command: CmdSelect
        {
            *Order: JOB_SETUP.5
            *Cmd: =PJL_RESOLUTION_300 =PJL_ENTER_PCLXL =PCLXL_StreamHeader =PCLXL_BeginSession300
        }
    }
}

*%%% ======================
*%%% JOB_SETUP.6
*%%% OpenDataSource(0x48)
*%%%     SourceType(ubyte) & DataOrg(ubyte)
*%%%     136(0x88)           130(0x82)
*Command: CmdStartDoc
{
    *Order: JOB_SETUP.6
    *Cmd: =ubyte "<00>" =attr_ubyte =SourceType =ubyte "<01>" =attr_ubyte =DataOrg =OpenDataSource
}

*%%% ======================
*%%% PAGE_FINISH
*%%% ======================

*%%% ======================
*%%% PAGE_FINISH.3
*Command: CmdEndPage
{
    *Order: PAGE_FINISH.1
    *Cmd: =uint16 =NumOfCopy =attr_ubyte =PageCopies =EndPage
}

*%%% ======================
*%%% JOB_FINISH.1
*%%% CmdEndJob
*Command: CmdEndJob
{
    *Order: JOB_FINISH.1
    *Cmd: =CloseDataSource =EndSession =PJL_ENDJOB
}

*%%% ======================
*%%% PAGE_SETUP
*%%% ======================

*%%% ======================
*%%% PAGE_SETUP.1
*%%% BeginPage(0x43)
*%%%     Orientation(40), MediaSize(37), MediaSource(38)
*%%%     ubyte            ubyte          ubyte

*BlockMacro: PaperConstraints
{
    *Constraints: LIST(InputBin.Option3, InputBin.Option4, InputBin.Option5)
}

*Feature: PaperSize
{
    *rcNameID: =PAPER_SIZE_DISPLAY
    *DefaultOption: LETTER
    *Option: A5
    {
        *rcNameID: =RCID_DMPAPER_SYSTEM_NAME  *% rcid 1000
        *Constraints: InputBin.Option6
        *PageProtectMem: 2125
        *switch: Orientation
        {
            *case: PORTRAIT
            {
                *PrintableArea: PAIR(6396, 9372)
                *PrintableOrigin: PAIR(300, 300)
                *CursorOrigin: PAIR(300, 160)
                *Command: CmdSelect
                {
                    *Order: PAGE_SETUP.1
                    *Cmd: =ubyte =ePortraitOrientation =attr_ubyte =Orientation
+                         =ubyte =eA5Paper =attr_ubyte =MediaSize =BeginPage
+                         =sint16_xy %l{((300*TextXRes)/1200)}%l{((160*TextYRes)/1200)} =attr_ubyte =PageOrigin =SetPageOrigin
                }
            }
            *case: LANDSCAPE_CC90
            {
                *PrintableArea: PAIR(6396, 9324)
                *PrintableOrigin: PAIR(300, 300)
                *CursorOrigin: PAIR(260, 9624)
                *Command: CmdSelect
                {
                    *Order: PAGE_SETUP.1
                    *Cmd: =ubyte =eReverseLandscape =attr_ubyte =Orientation
+                         =ubyte =eA5Paper =attr_ubyte =MediaSize =BeginPage
+                         =sint16_xy %l{((260*TextXRes)/1200)}%l{((300*TextYRes)/1200)} =attr_ubyte =PageOrigin =SetPageOrigin
                }
            }
        }
    }
    *Option: LETTER
    {
        *rcNameID: =RCID_DMPAPER_SYSTEM_NAME  *% rcid 1000
        *Constraints: InputBin.Option6
        *PageProtectMem: 4109
        *switch: Orientation
        {
            *case: PORTRAIT
            {
                *PrintableArea: PAIR(9600, 12600)
                *PrintableOrigin: PAIR(300, 300)
                *CursorOrigin: PAIR(300, 160)
                *Command: CmdSelect
                {
                    *Order: PAGE_SETUP.1
                    *Cmd: =ubyte =ePortraitOrientation =attr_ubyte =Orientation
+                         =ubyte =eLetterPaper =attr_ubyte =MediaSize =BeginPage
+                         =sint16_xy %l{((300*TextXRes)/1200)}%l{((160*TextYRes)/1200)} =attr_ubyte =PageOrigin =SetPageOrigin
                }
            }
            *case: LANDSCAPE_CC90
            {
                *PrintableArea: PAIR(9760, 12600)
                *PrintableOrigin: PAIR(200, 300)
                *CursorOrigin: PAIR(200, 12900)
                *Command: CmdSelect
                {
                    *Order: PAGE_SETUP.1
                    *Cmd: =ubyte =eReverseLandscape =attr_ubyte =Orientation
+                         =ubyte =eLetterPaper =attr_ubyte =MediaSize =BeginPage
+                         =sint16_xy %l{((200*TextXRes)/1200)}%l{((300*TextYRes)/1200)} =attr_ubyte =PageOrigin =SetPageOrigin
                }
            }
        }
    }
    *Option: LEGAL
    {
        *rcNameID: =RCID_DMPAPER_SYSTEM_NAME
        *Constraints: InputBin.Option6
        *PageProtectMem: 5230
        *switch: Orientation
        {
            *case: PORTRAIT
            {
                *PrintableArea: PAIR(9600, 16200)
                *PrintableOrigin: PAIR(300, 300)
                *CursorOrigin: PAIR(300, 160)
                *Command: CmdSelect
                {
                    *Order: PAGE_SETUP.1
                    *Cmd: =ubyte =ePortraitOrientation =attr_ubyte =Orientation
+                         =ubyte =eLegalPaper =attr_ubyte =MediaSize =BeginPage
+                         =sint16_xy %l{((300*TextXRes)/1200)}%l{((160*TextYRes)/1200)} =attr_ubyte =PageOrigin =SetPageOrigin
                }
            }
            *case: LANDSCAPE_CC90
            {
                *PrintableArea: PAIR(9760, 16200)
                *PrintableOrigin: PAIR(200, 300)
                *CursorOrigin: PAIR(200, 16500)
                *Command: CmdSelect
                {
                    *Order: PAGE_SETUP.1
                    *Cmd: =ubyte =eReverseLandscape =attr_ubyte =Orientation
+                         =ubyte =eLegalPaper =attr_ubyte =MediaSize =BeginPage
+                         =sint16_xy %l{((200*TextXRes)/1200)}%l{((300*TextYRes)/1200)} =attr_ubyte =PageOrigin =SetPageOrigin
                }
            }
        }
    }
    *Option: EXECUTIVE
    {
        *rcNameID: =RCID_DMPAPER_SYSTEM_NAME
        *Constraints: InputBin.Option6
        *PageProtectMem: 4109
        *switch: Orientation
        {
            *case: PORTRAIT
            {
                *PrintableArea: PAIR(8100, 12000)
                *PrintableOrigin: PAIR(300, 300)
                *CursorOrigin: PAIR(300, 160)
                *Command: CmdSelect
                {
                    *Order: PAGE_SETUP.1
                    *Cmd: =ubyte =ePortraitOrientation =attr_ubyte =Orientation
+                         =ubyte =eExecPaper =attr_ubyte =MediaSize =BeginPage
+                         =sint16_xy %l{((300*TextXRes)/1200)}%l{((160*TextYRes)/1200)} =attr_ubyte =PageOrigin =SetPageOrigin
                }
            }
            *case: LANDSCAPE_CC90
            {
                *PrintableArea: PAIR(8180, 12000)
                *PrintableOrigin: PAIR(220, 300)
                *CursorOrigin: PAIR(200, 12300)
                *Command: CmdSelect
                {
                    *Order: PAGE_SETUP.1
                    *Cmd: =ubyte =eReverseLandscape =attr_ubyte =Orientation
+                         =ubyte =eExecPaper =attr_ubyte =MediaSize =BeginPage
+                         =sint16_xy %l{((200*TextXRes)/1200)}%l{((300*TextYRes)/1200)} =attr_ubyte =PageOrigin =SetPageOrigin
                }
            }
        }
    }

    *Option: A4
    {
        *rcNameID: =RCID_DMPAPER_SYSTEM_NAME  *%  1008
        *Constraints: InputBin.Option6
        *PageProtectMem: 4249
        *switch: Orientation
        {
            *case: PORTRAIT
            {
                *PrintableArea: PAIR(9352, 13400)
                *PrintableOrigin: PAIR(260, 300)
                *CursorOrigin: PAIR(260, 160)
                *Command: CmdSelect
                {
                    *Order: PAGE_SETUP.1
                    *Cmd: =ubyte =ePortraitOrientation =attr_ubyte =Orientation
+                         =ubyte =eA4Paper =attr_ubyte =MediaSize =BeginPage
+                         =sint16_xy %l{((260*TextXRes)/1200)}%l{((160*TextYRes)/1200)} =attr_ubyte =PageOrigin =SetPageOrigin
                }
            }
            *case: LANDSCAPE_CC90
            {
                *PrintableArea: PAIR(9424, 13428)
                *PrintableOrigin: PAIR(200, 300)
                *CursorOrigin: PAIR(200, 13728)
                *Command: CmdSelect
                {
                    *Order: PAGE_SETUP.1
                    *Cmd: =ubyte =eReverseLandscape =attr_ubyte =Orientation
+                         =ubyte =eA4Paper =attr_ubyte =MediaSize =BeginPage
+                         =sint16_xy %l{((200*TextXRes)/1200)}%l{((300*TextYRes)/1200)} =attr_ubyte =PageOrigin =SetPageOrigin
                }
            }
        }
    }

    *Option: B5
    {
        *rcNameID: =RCID_DMPAPER_SYSTEM_NAME
        *PageProtectMem: 3198
        *Constraints: InputBin.Option6
        *switch: Orientation
        {
            *case: PORTRAIT
            {
                *PrintableArea: PAIR(7964, 11714)
                *PrintableOrigin: PAIR(340, 152)
                *CursorOrigin: PAIR(200, 152)
                *Command: CmdSelect
                {
                    *Order: PAGE_SETUP.1
                    *Cmd: =ubyte =ePortraitOrientation =attr_ubyte =Orientation
+                         =ubyte =eJB5Paper =attr_ubyte =MediaSize =BeginPage
+                         =sint16_xy %l{((200*TextXRes)/1200)}%l{((152*TextYRes)/1200)} =attr_ubyte =PageOrigin =SetPageOrigin
                }
            }
            *case: LANDSCAPE_CC90
            {
                *PrintableArea: PAIR(8104, 11624)
                *PrintableOrigin: PAIR(260, 240)
                *CursorOrigin: PAIR(200, 11904)
                *Command: CmdSelect
                {
                    *Order: PAGE_SETUP.1
                    *Cmd: =ubyte =eReverseLandscape =attr_ubyte =Orientation
+                         =ubyte =eJB5Paper =attr_ubyte =MediaSize =BeginPage
+                         =sint16_xy %l{((200*TextXRes)/1200)}%l{((280*TextYRes)/1200)} =attr_ubyte =PageOrigin =SetPageOrigin
                }
            }
        }
    }
    *Option: ENV_10
    {
        *rcNameID: =RCID_DMPAPER_SYSTEM_NAME  *%  1019
        *InsertBlock: =PaperConstraints
        *Constraints: Duplex.VERTICAL
        *Constraints: Duplex.HORIZONTAL
        *PageProtectMem: 4109
        *switch: Orientation
        {
            *case: PORTRAIT
            {
                *PrintableArea: PAIR(4346, 10800)
                *PrintableOrigin: PAIR(300, 300)
                *switch: Resolution
                {
                    *case: Option1
                    {
                        *PrintableArea: PAIR(4344, 10800)
                    }
                }
                *CursorOrigin: PAIR(300, 180)
                *Command: CmdSelect
                {
                    *Order: PAGE_SETUP.1
                    *Cmd: =ubyte =ePortraitOrientation =attr_ubyte =Orientation
+                         =ubyte =eCOM10Envelope =attr_ubyte =MediaSize =BeginPage
+                         =sint16_xy %l{((300*TextXRes)/1200)}%l{((180*TextYRes)/1200)} =attr_ubyte =PageOrigin =SetPageOrigin
                }
            }
            *case: LANDSCAPE_CC90
            {
                *PrintableArea: PAIR(4476, 10800)
                *PrintableOrigin: PAIR(200, 300)
                *CursorOrigin: PAIR(200, 11100)
                *Command: CmdSelect
                {
                    *Order: PAGE_SETUP.1
                    *Cmd: =ubyte =eReverseLandscape =attr_ubyte =Orientation
+                         =ubyte =eCOM10Envelope =attr_ubyte =MediaSize =BeginPage
+                         =sint16_xy %l{((200*TextXRes)/1200)}%l{((300*TextYRes)/1200)} =attr_ubyte =PageOrigin =SetPageOrigin
                }
            }
        }
    }
    *Option: ENV_DL
    {
        *rcNameID: =RCID_DMPAPER_SYSTEM_NAME  *%  1026
        *InsertBlock: =PaperConstraints
        *Constraints: Duplex.VERTICAL
        *Constraints: Duplex.HORIZONTAL
        *PageProtectMem: 4109
        *switch: Orientation
        {
            *case: PORTRAIT
            {
                *PrintableArea: PAIR(4576, 9792)
                *PrintableOrigin: PAIR(300, 300)
                *CursorOrigin: PAIR(300, 180)
                *Command: CmdSelect
                {
                    *Order: PAGE_SETUP.1
                    *Cmd: =ubyte =ePortraitOrientation =attr_ubyte =Orientation
+                         =ubyte =eDLEnvelope =attr_ubyte =MediaSize =BeginPage
+                         =sint16_xy %l{((300*TextXRes)/1200)}%l{((180*TextYRes)/1200)} =attr_ubyte =PageOrigin =SetPageOrigin
                }
            }
            *case: LANDSCAPE_CC90
            {
                *PrintableArea: PAIR(4796, 9792)
                *PrintableOrigin: PAIR(200, 300)
                *CursorOrigin: PAIR(200, 10092)
                *Command: CmdSelect
                {
                    *Order: PAGE_SETUP.1
                    *Cmd: =ubyte =eReverseLandscape =attr_ubyte =Orientation
+                         =ubyte =eDLEnvelope =attr_ubyte =MediaSize =BeginPage
+                         =sint16_xy %l{((200*TextXRes)/1200)}%l{((300*TextYRes)/1200)} =attr_ubyte =PageOrigin =SetPageOrigin
                }
            }
        }
    }
    *Option: ENV_C5
    {
        *rcNameID: =RCID_DMPAPER_SYSTEM_NAME  *%  1027
        *InsertBlock: =PaperConstraints
        *Constraints: Duplex.VERTICAL
        *Constraints: Duplex.HORIZONTAL
        *PageProtectMem: 4109
        *switch: Orientation
        {
            *case: PORTRAIT
            {
                *PrintableArea: PAIR(7036, 10214)
                *PrintableOrigin: PAIR(300, 300)
                *switch: Resolution
                {
                    *case: Option2
                    {
                        *PrintableArea: PAIR(7036, 10212)
                    }
                }
                *CursorOrigin: PAIR(300, 180)
                *Command: CmdSelect
                {
                    *Order: PAGE_SETUP.1
                    *Cmd: =ubyte =ePortraitOrientation =attr_ubyte =Orientation
+                         =ubyte =eC5Envelope =attr_ubyte =MediaSize =BeginPage
+                         =sint16_xy %l{((300*TextXRes)/1200)}%l{((180*TextYRes)/1200)} =attr_ubyte =PageOrigin =SetPageOrigin
                }
            }
            *case: LANDSCAPE_CC90
            {
                *PrintableArea: PAIR(7116, 10224)
                *PrintableOrigin: PAIR(240, 300)
                *CursorOrigin: PAIR(200, 10524)
                *Command: CmdSelect
                {
                    *Order: PAGE_SETUP.1
                    *Cmd: =ubyte =eReverseLandscape =attr_ubyte =Orientation
+                         =ubyte =eC5Envelope =attr_ubyte =MediaSize =BeginPage
+                         =sint16_xy %l{((200*TextXRes)/1200)}%l{((300*TextYRes)/1200)} =attr_ubyte =PageOrigin =SetPageOrigin
                }
            }
        }
    }

 

    *Option: ENV_MONARCH
    {
        *rcNameID: =RCID_DMPAPER_SYSTEM_NAME  *%  1036
        *InsertBlock: =PaperConstraints
        *Constraints: Duplex.VERTICAL
        *Constraints: Duplex.HORIZONTAL
        *PageProtectMem: 4109
        *switch: Orientation
        {
            *case: PORTRAIT
            {
                *PrintableArea: PAIR(4046, 8400)
                *PrintableOrigin: PAIR(300, 300)
                *switch: Resolution
                {
                    *case: Option2
                    {
                        *PrintableArea: PAIR(4044, 8400)
                    }
                }
                *CursorOrigin: PAIR(300, 180)
                *Command: CmdSelect
                {
                    *Order: PAGE_SETUP.1
                    *Cmd: =ubyte =ePortraitOrientation =attr_ubyte =Orientation
+                         =ubyte =eMonarchEnvelope =attr_ubyte =MediaSize =BeginPage
+                         =sint16_xy %l{((300*TextXRes)/1200)}%l{((180*TextYRes)/1200)} =attr_ubyte =PageOrigin =SetPageOrigin
                }
            }
            *case: LANDSCAPE_CC90
            {
                *PrintableArea: PAIR(4076, 8400)
                *PrintableOrigin: PAIR(300, 300)
                *CursorOrigin: PAIR(200, 8700)
                *Command: CmdSelect
                {
                    *Order: PAGE_SETUP.1
                    *Cmd: =ubyte =eReverseLandscape =attr_ubyte =Orientation
+                         =ubyte =eMonarchEnvelope =attr_ubyte =MediaSize =BeginPage
+                         =sint16_xy %l{((200*TextXRes)/1200)}%l{((300*TextYRes)/1200)} =attr_ubyte =PageOrigin =SetPageOrigin
                }
            }
        }
    }
    *Option: ENV_B5
    {
        *rcNameID: =RCID_DMPAPER_SYSTEM_NAME
        *PageProtectMem: 4109
        *InsertBlock: =PaperConstraints
        *Constraints: Duplex.VERTICAL
        *Constraints: Duplex.HORIZONTAL
        *switch: Orientation
        {
            *case: PORTRAIT
            {
                *PrintableArea: PAIR(7716, 11368)
                *PrintableOrigin: PAIR(300, 140)
                *CursorOrigin: PAIR(300, 140)
                *Command: CmdSelect
                {
                    *Order: PAGE_SETUP.1
                    *Cmd: =ubyte =ePortraitOrientation =attr_ubyte =Orientation
+                         =ubyte =eB5Envelope =attr_ubyte =MediaSize =BeginPage
+                         =sint16_xy %l{((300*TextXRes)/1200)}%l{((140*TextYRes)/1200)} =attr_ubyte =PageOrigin =SetPageOrigin
                }
            }
            *case: LANDSCAPE_CC90
            {
                *PrintableArea: PAIR(7776, 11208)
                *PrintableOrigin: PAIR(240, 300)
                *CursorOrigin: PAIR(200, 11508)
                *Command: CmdSelect
                {
                    *Order: PAGE_SETUP.1
                    *Cmd: =ubyte =eReverseLandscape =attr_ubyte =Orientation
+                         =ubyte =eB5Envelope =attr_ubyte =MediaSize =BeginPage
+                         =sint16_xy %l{((200*TextXRes)/1200)}%l{((300*TextYRes)/1200)} =attr_ubyte =PageOrigin =SetPageOrigin
                }
            }
        }
    }


   *Option: FOLIO 
    { 
        *rcNameID: =RCID_DMPAPER_SYSTEM_NAME 
        *PrintableArea: PAIR(9600, 15200)
        *PrintableOrigin: PAIR(200, 200)
        *switch: Orientation
        {
            *case: PORTRAIT
            {
                *CursorOrigin: PAIR(200, 200)
                *Command: CmdSelect 
                { 
                    *Order: JOB_SETUP.2 
                    *Cmd: =ubyte =ePortraitOrientation =attr_ubyte =Orientation 
+                         =ubyte "<18>" =attr_ubyte =MediaSize =BeginPage
+                         =sint16_xy %l{((200*TextXRes)/1200)}%l{((200*TextYRes)/1200)} =attr_ubyte =PageOrigin =SetPageOrigin
                } 
             } 
             *case: LANDSCAPE_CC90
             {
                *CursorOrigin: PAIR(200, 15400)
                *Command: CmdSelect
                {
                    *Order: JOB_SETUP.2 
                    *Cmd: =ubyte =eReverseLandscape =attr_ubyte =Orientation 
+                         =ubyte "<18>" =attr_ubyte =MediaSize =BeginPage
+                         =sint16_xy %l{((200*TextXRes)/1200)}%l{((200*TextYRes)/1200)} =attr_ubyte =PageOrigin =SetPageOrigin
                }
            }
        }
    }



    *Option: CUSTOMSIZE
    {
        *rcNameID: =RCID_DMPAPER_SYSTEM_NAME  *%  1255
        *MinSize: PAIR(3600, 6000)
        *MaxSize: PAIR(10200, 32767)
        *MaxPrintableWidth: 10200
        *MinLeftMargin: 100
        *CenterPrintable?: FALSE
        *PageProtectMem: 1692
        *switch: Orientation
        {
            *case: PORTRAIT
            {
                *CustCursorOriginX:  %d{((PhysPaperWidth - 10200) / 2) + 300 }
                *CustCursorOriginY:   %d{140 }
                *CustPrintableOriginX:  %d{300 }
                *CustPrintableOriginY:  %d{300}
                *CustPrintableSizeX:   %d{ PhysPaperWidth - 600 }
                *CustPrintableSizeY:  %d{ PhysPaperLength - 600 }
                *Command: CmdSelect
                {
                    *Order: PAGE_SETUP.1
                    *Cmd: =ubyte =ePortraitOrientation =attr_ubyte =Orientation
+                         =uint16_xy %l{(PhysPaperWidth / 1200)}%l{(PhysPaperLength / 1200)} =attr_ubyte =CustomMediaSize
+                         =ubyte =eInch =attr_ubyte =CustomMediaSizeUnits =BeginPage
+                         =sint16_xy %l{((200*TextXRes)/1200)}%l{((200*TextYRes)/1200)} =attr_ubyte =PageOrigin =SetPageOrigin
                }
            }
            *case: LANDSCAPE_CC90
            {
                *CustCursorOriginX:  %d{((PhysPaperWidth - 10200) / 2) + 200 }
                *CustCursorOriginY:   %d{16560 }
                *CustPrintableOriginX:  %d{200 }
                *CustPrintableOriginY:  %d{240}
                *CustPrintableSizeX:   %d{ PhysPaperWidth - 400 }
                *CustPrintableSizeY:  %d{ PhysPaperLength - 480 }
                *Command: CmdSelect
                {
                    *Order: PAGE_SETUP.1
                    *Cmd: =ubyte =eReverseLandscape =attr_ubyte =Orientation
+                         =uint16_xy %l{(PhysPaperWidth / 1200)}%l{(PhysPaperLength / 1200)} =attr_ubyte =CustomMediaSize
+                         =ubyte =eInch =attr_ubyte =CustomMediaSizeUnits =BeginPage
+                         =sint16_xy %l{((200*TextXRes)/1200)}%l{((200*TextYRes)/1200)} =attr_ubyte =PageOrigin =SetPageOrigin
                }
            }
        }
    }
}

*%%% ======================
*%%% PAGE_SETUP.2
*%%% BeginPage(0x43)
*%%%     Orientation(0x40), MediaSize(0x37), MediaSource(0x38)
*%%%     ubyte               ubyte             ubyte
*%%%     MediaSource
*Feature: InputBin{ *Option: Option1{} *Option: Option7{} *Option: UPPER{} *Option: LOWER{} *Option: MANUAL{}}
*Feature: InputBin
{
    *rcNameID: =PAPER_SOURCE_DISPLAY
    *DefaultOption: Option1
    *Option: Option1
    {
        *rcNameID: =AUTO_SELECT_DISPLAY  *% Automatically Select
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.2
			*Cmd: =ubyte =eAutoSelect =attr_ubyte =MediaSource
        }
    }
    *Option: UPPER
    {
        *rcNameID: =TRAY2_DISPLAY *% Upper Paper tray
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.2
			*Cmd: =ubyte =eUpperCassette =attr_ubyte =MediaSource
        }
    }
    *Option: MANUAL
    {
        *rcNameID: =MANUAL_FEED_TRAY1_DISPLAY *% Manual Paper feed
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.2
			*Cmd: =ubyte =eManualFeed =attr_ubyte =MediaSource
        }
    }

    *Option: LOWER
    {
        *rcNameID: =TRAY3_DISPLAY *% Lower Paper tray
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.2
			*Cmd: =ubyte =eLowerCassette =attr_ubyte =MediaSource
        }
    }
    *Option: Option7
    {
        *rcNameID: =TRAY1_DISPLAY  *% MP Tray
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.2
			*Cmd: =ubyte =eManualFeed =attr_ubyte =MediaSource
        }
    }
}



*%UPPER Paper Tray Constraints
*InvalidCombination: LIST(InputBin.UPPER, PaperSize.ENV_10)
*InvalidCombination: LIST(InputBin.UPPER, PaperSize.ENV_DL)
*InvalidCombination: LIST(InputBin.UPPER, PaperSize.ENV_C5)
*InvalidCombination: LIST(InputBin.UPPER, PaperSize.ENV_MONARCH)
*InvalidCombination: LIST(InputBin.UPPER, PaperSize.ENV_B5)

*%LOWER Paper Tray Constraints
*InvalidCombination: LIST(InputBin.LOWER, PaperSize.ENV_10)
*InvalidCombination: LIST(InputBin.LOWER, PaperSize.ENV_DL)
*InvalidCombination: LIST(InputBin.LOWER, PaperSize.ENV_C5)
*InvalidCombination: LIST(InputBin.LOWER, PaperSize.ENV_MONARCH)
*InvalidCombination: LIST(InputBin.LOWER, PaperSize.ENV_B5)



*%%% ======================
*%%% PAGE_SETUP.3
*%%% BeginPage(0x43)
*%%%     Orientation(0x40), MediaSize(0x37), MediaSource(0x38), MediaType
*%%%     ubyte               ubyte             ubyte
*%%%     MediaType
*Feature: MediaType
{
    *rcNameID: =MEDIA_TYPE_DISPLAY
    *DefaultOption: AutoSelect

    *Option: AutoSelect
    {
        *rcNameID: =AUTO_SELECT_DISPLAY
    }
    *Option: Plain
    {
        *rcNameID: =PLAIN_DISPLAY
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.3
            *Cmd: =ubyte_array =ePlain =attr_ubyte =MediaType
        }
    }
    *Option: Preprinted
    {
        *rcNameID: =PREPRINTED_DISPLAY
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.3
            *Cmd: =ubyte_array =ePreprinted =attr_ubyte =MediaType
        }
    }
    *Option: Letterhead
    {
        *rcNameID: =LETTERHEAD_DISPLAY
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.3
            *Cmd: =ubyte_array =eLetterhead =attr_ubyte =MediaType
        }
    }
    *Option: Transparency
    {
        *rcNameID: =TRANSPARENCY_DISPLAY
	*Constraints: LIST(Duplex.VERTICAL,Duplex.HORIZONTAL)
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.3
            *Cmd: =ubyte_array =eTransparency =attr_ubyte =MediaType
        }
    }
    *Option: Prepunched
    {
        *rcNameID: =PREPUNCHED_DISPLAY
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.3
            *Cmd: =ubyte_array =ePrepunched =attr_ubyte =MediaType
        }
    }
    *Option: Labels
    {
        *rcNameID: =LABELS_DISPLAY
	*Constraints: LIST(Duplex.VERTICAL,Duplex.HORIZONTAL)
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.3
            *Cmd: =ubyte_array =eLabels =attr_ubyte =MediaType
        }
    }
    *Option: Bond
    {
        *rcNameID: =BOND_DISPLAY
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.3
            *Cmd: =ubyte_array =eBond =attr_ubyte =MediaType
        }
    }
    *Option: Recycled
    {
        *rcNameID: =RECYCLED_DISPLAY
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.3
            *Cmd: =ubyte_array =eRecycled =attr_ubyte =MediaType
        }
    }
    *Option: Color
    {
        *rcNameID: =COLOR_DISPLAY
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.3
            *Cmd: =ubyte_array =eColor =attr_ubyte =MediaType
        }
    }
    *Option: CardStock
    {
        *rcNameID: =CARDSTOCK_DISPLAY
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.3
            *Cmd: =ubyte_array =eCardstock =attr_ubyte =MediaType
        }
    }
    *Option: Rough
    {
        *rcNameID: =ROUGH_DISPLAY
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.3
            *Cmd: =ubyte_array =eRough =attr_ubyte =MediaType
        }
    }
}

*%%% ======================
*%%% PAGE_SETUP.3
*%%% DuplexPageMode(53(0x35))
*Feature: Duplex
{
    *rcNameID: =TWO_SIDED_PRINTING_DISPLAY
    *DefaultOption: NONE
    *Option: NONE
    {
        *rcNameID: =NONE_DISPLAY
        *Command: CmdSelect
        {
            *Order: JOB_SETUP.4
            *Cmd: "@PJL SET DUPLEX=OFF<0A>"
        }
    }
    *Option: VERTICAL
    {
        *rcNameID: =FLIP_ON_LONG_EDGE_DISPLAY
        *Command: CmdSelect
        {
            *Order: JOB_SETUP.4
            *Cmd: "@PJL SET DUPLEX=ON<0A>@PJL SET BINDING=LONGEDGE<0A>"
        }
    }
    *Option: HORIZONTAL
    {
        *rcNameID: =FLIP_ON_SHORT_EDGE_DISPLAY
        *Command: CmdSelect
        {
            *Order: JOB_SETUP.4
            *Cmd: "@PJL SET DUPLEX=ON<0A>@PJL SET BINDING=SHORTEDGE<0A>"
        }
    }
}

*%%% ======================
*%%% PAGE_SETUP.4
*%%% SetPageOrigin
*%%%     PageOrigin
*%%% SetPageScale
*Command: CmdStartPage
{
    *Order: PAGE_SETUP.4
    *Cmd: =real32_xy "<0000803f><0000803f>" =attr_ubyte =PageScale =SetPageScale
+         =ubyte "<01>" =attr_ubyte =ColorSpace =SetColorSpace
}

*%%% ======================
*%%% PAGE_SETUP.5
*%%% Feature
*%%% Dither
*Feature: Dither
{
    *rcNameID: =DITHER_QUALITY_DISPLAY
    *DefaultOption: HIQUALITY
    *Option: HIQUALITY
    {
        *rcNameID: =DITHER_QUALITY_HIGH_DISPLAY
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.5
            *Cmd: ""
        }
    }
    *Option: LOQUALITY
    {
        *rcNameID: =DITHER_QUALITY_LOW_DISPLAY
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.5
            *Cmd: ""
        }
    }
}


*%%% ======================
*%%% Feature
*%%% Memory
*Feature: Memory
{
    *rcNameID: =PRINTER_MEMORY_DISPLAY
    *DefaultOption: 12MB
*% 4MB Standard memory, 3 memory slots with 4, 8, 16 or 32 MB dimms avail.
*% Max memory 96 (+4 on board) = 100
        *MemConfigMB: PAIR(4, 3)
        *MemConfigMB: PAIR(8, 7)
        *MemConfigMB: PAIR(12, 10)
        *MemConfigMB: PAIR(16, 13)
        *MemConfigMB: PAIR(20, 17)
        *MemConfigMB: PAIR(24, 21)
        *MemConfigMB: PAIR(28, 24)
        *MemConfigMB: PAIR(32, 28)
        *MemConfigMB: PAIR(36, 31)
        *MemConfigMB: PAIR(40, 35)
        *MemConfigMB: PAIR(44, 39)
        *MemConfigMB: PAIR(48, 42)
        *MemConfigMB: PAIR(52, 46)
        *MemConfigMB: PAIR(56, 49)
        *MemConfigMB: PAIR(60, 52)
        *MemConfigMB: PAIR(68, 59)
}

*%%% ======================
*%%% Device fonts
*%%% ======================

*DefaultFont: =RC_FONT_COURIERR
*DefaultCTT: 0

*DeviceFonts: LIST(
+    =RC_FONT_ALBERTX,
+    =RC_FONT_AOLIVEB,
+    =RC_FONT_AOLIVER,
+    =RC_FONT_ARIALB,
+    =RC_FONT_ARIALI,
+    =RC_FONT_ARIALJ,
+    =RC_FONT_ARIALR,
+    =RC_FONT_COURIERB,
+    =RC_FONT_COURIERI,
+    =RC_FONT_COURIERJ,
+    =RC_FONT_COURIERR,
+    =RC_FONT_LETGOTHB,
+    =RC_FONT_LETGOTHI,
+    =RC_FONT_LETGOTHR,
+    =RC_FONT_MARGOLDR,
+    =RC_FONT_TIMESNRB,
+    =RC_FONT_TIMESNRI,
+    =RC_FONT_TIMESNRJ,
+    =RC_FONT_TIMESNRR,
+    =RC_FONT_WINGDINGS,
+    =RC_FONT_SYMBOL)

*TTFS: AlbertusX
{
  *TTFontName: "Albertus Extra Bold"
  *DevFontName: "Albertus Extra Bold"
}
*TTFS: AntiqueOlive
{
  *TTFontName: "Antique Olive"
  *DevFontName: "Antique Olive"
}
*TTFS: LetterGothic
{
  *TTFontName: "Letter Gothic"
  *DevFontName: "Letter Gothic"
}
*TTFS: Marigold
{
  *TTFontName: "Marigold"
  *DevFontName: "Marigold"
}


*%% =======================
*%% Optional Duplex Unit
*%% =======================
*Feature: DuplexUnit
{
    *FeatureType: PRINTER_PROPERTY
    *rcNameID: =DUPLEX_UNIT_DISPLAY
    *DefaultOption: NotInstalled
    *Option: NotInstalled
    {
        *rcNameID: =NOT_INSTALLED_DISPLAY
        *DisabledFeatures: LIST(Duplex.VERTICAL,Duplex.HORIZONTAL)
        *Constraints: LIST(Duplex.VERTICAL,Duplex.HORIZONTAL)
    }

    *Option: Installed
    {
        *rcNameID: =INSTALLED_DISPLAY
    }
}

*Feature: TRAY3
{
    *rcNameID: =TRAY3_DISPLAY
    *FeatureType: PRINTER_PROPERTY
    *DefaultOption: FALSE
    *Option: FALSE
    {
        *rcNameID: =NOT_INSTALLED_DISPLAY       
        *Constraints: LIST(InputBin.LOWER)

    }
    *Option: TRUE
    {
        *rcNameID: =INSTALLED_DISPLAY
    }
}

*InvalidCombination: LIST(TRAY3.FALSE,InputBin.Option4)


*%% =======================
*%% Optional Hard Disk
*%% =======================
*Feature: PrinterHardDisk
{
    *rcNameID: =PRINTER_HARDDISK_DISPLAY
    *FeatureType: PRINTER_PROPERTY
    *DefaultOption: FALSE
    *Option: FALSE
    {
        *rcNameID: =NOT_INSTALLED_DISPLAY
        *DisabledFeatures: LIST(Collate)
    }
    *Option: TRUE
    {
        *rcNameID: =INSTALLED_DISPLAY
    }
}


*%%% ======================
*%%% PCL XL GPD file main
*%%% ======================

*%%% ======================
*%%% Global Entries
*%%% Attributes
*%%% ======================
*MasterUnits: PAIR(1200, 1200)
*CodePage: 1252
*ResourceDLL: "pclxl.dll"
*PrinterType: PAGE
*Personality: =PERSONALITY_PCLXL
*rcPersonalityID: =PERSONALITY_PCLXL_DISPLAY
*%%% *rcPrinterIconID:

*%%% ======================
*%%% Printing attributes
*%%% ======================
*RotateCoordinate?: TRUE
*RotateRaster?: TRUE
*RotateFont?: TRUE
*EjectPageWithFF?: FALSE

*TextCaps: LIST(TC_CR_ANY,TC_CR_90,TC_SF_X_YINDEP,TC_SA_CONTIN,TC_IA_ABLE,TC_UA_ABLE)
*MemoryUsage: LIST(FONT)
*CursorXAfterCR: AT_PRINTABLE_X_ORIGIN
*CursorXAfterSendBlockData: AT_GRXDATA_ORIGIN
*CursorYAfterSendBlockData: AUTO_INCREMENT
*BadCursorMoveInGrxMode: LIST(X_PORTRAIT,Y_LANDSCAPE)
*XMoveThreshold: 0
*YMoveThreshold: 0
*XMoveUnit: 1200
*YMoveUnit: 1200

*%%% *MinGrayFill: 1
*%%% *MaxGrayFill: 100

*%%% *OutputDataFormat: H_BYTE
*%%% *OptimizeLeftBound?: TRUE

*%%% ======================
*%%% Color
*%%% ======================
*Feature: ColorMode
{
    *ConcealFromUI?: TRUE
    *rcNameID: =COLOR_PRINTING_MODE_DISPLAY
    *DefaultOption: Mono
    *Option: Mono
    {
        *rcNameID: =COLOR_DISPLAY
        *Color?: FALSE
        *DevNumOfPlanes: 1
        *DevBPP: 24
        *DrvBPP: 24
        *PaletteSize: 256
        *PaletteProgrammable?: FALSE
    }
}

*%%% ======================
*%%% TrueType fonts
*%%% ======================

*CharPosition: BASELINE
*TTFSEnabled?: TRUE
*FontFormat: OEM_CALLBACK
*MinFontID: 1
*MaxFontID: 65535
*MinGlyphID: 1
*MaxGlyphID: 1000

*%%% ======================
*%%% Cursor commands
*%%% ======================

*Command: CmdCR { *Cmd: =CR}
*Command: CmdLF { *Cmd: =LF}
*Command: CmdFF { *Cmd: =FF}

*%%% SetCursor(0x6b)
*%%%     Point(76(0x40c)) uint_16
*%%% SetCursorRel(0x6c)
*%%%     Point(76(0x40c)) uint_16
*Command: CmdXMoveAbsolute
{
    *Cmd: ""
}
*Command: CmdXMoveRelRight
{
    *Cmd: ""
    *Params: LIST(DestXRel, TextXRes)
}
*Command: CmdXMoveRelLeft
{
    *Cmd: ""
    *Params: LIST(DestXRel, TextXRes)
}
*Command: CmdYMoveAbsolute
{
    *Cmd: ""
    *Params: LIST(DestY, TextYRes)
}
*Command: CmdYMoveRelDown
{
    *Cmd: ""
    *Params: LIST(DestYRel, TextYRes)
}
*Command: CmdYMoveRelUp
{
    *Cmd: ""
    *Params: LIST(DestYRel, TextYRes)
}
*%%% *Command: CmdPushCursor
*%%% *Command: CmdPopCursor

*%%% =======================
*%%% Font commands
*%%% =======================

*Command: CmdSetFontID { *Cmd : "" }
*Command: CmdSelectFontID
{
    *Cmd: ""
    *Params: LIST(FontHeight, CurrentFontID, TextYRes)
}

*Command: CmdSetCharCode
{
    *Cmd : ""
}

*Command: CmdBoldOn
{
    *Cmd : ""
}
*Command: CmdBoldOff
{
    *Cmd : ""
}
*%%% *Command: CmdItalicOn: "=real32_xy "<3ea1e4f700000000>" =attr_ubyte =eCharShear =SetCharShear"
*%%% *Command: CmdItalicOff: "=real32_xy "<0000000000000000>" =attr_ubyte =eCharShear =SetCharShear"
*%%% *Command: CmdWhiteTextOn:
*%%% *Command: CmdWhiteTextOff:
*%%% *Command: CmdSelectSingleByteMode:
*%%% *Command: CmdSelectDoubleByteMode:
*Command: CmdSetAnyRotation
{
    *Cmd: ""
    *Params: LIST(PrintDirInCCDegrees)
}
*Command: CmdSetSimpleRotation
{
    *Cmd: ""
    *Params: LIST(PrintDirInCCDegrees)
}