*%
*% Copyright (c) 1997 - 2020  Corporation
*% All Rights Reserved.
*%
*GPDSpecVersion: "1.0"
*Include: "StdNames.gpd"
*GPDFileVersion: "1.0.1.0"
*GPDFileName: "bgp12025.GPD"
*CodePage: 1252
*ModelName: "bgp12025"
*MasterUnits: PAIR(360, 360)
*ResourceDLL: "bgpr-rr.dll"
*PrinterType: SERIAL
*FontCartSlots: 1
*Feature: Orientation
{
    *rcNameID: =ORIENTATION_DISPLAY
    *DefaultOption: PORTRAIT
    *Option: PORTRAIT
    {
        *rcNameID: =PORTRAIT_DISPLAY
    }
    *Option: LANDSCAPE_CC270
    {
        *rcNameID: =LANDSCAPE_DISPLAY
    }
}
*Feature: InputBin
{
    *rcNameID: =PAPER_SOURCE_DISPLAY
    *DefaultOption: MANUAL
    *Option: MANUAL
    {
        *rcNameID: =MANUAL_FEED_DISPLAY
    }
    *Option: TRACTOR
    {
        *rcNameID: =TRACTOR_DISPLAY
    }
}
*Feature: Resolution
{
    *rcNameID: =RESOLUTION_DISPLAY
    *DefaultOption: Option1
    *Option: Option1
    {
        *Name: "180 x 180 " =DOTS_PER_INCH
        *DPI: PAIR(180, 180)
        *TextDPI: PAIR(180, 180)
        *PinsPerLogPass: 24
        *PinsPerPhysPass: 24
        *MinStripBlankPixels: 180
        EXTERN_GLOBAL: *StripBlanks: LIST(LEADING,ENCLOSED,TRAILING)
        *SpotDiameter: 120
        *Command: CmdSendBlockData { *Cmd : "<1B>%%1" %m{NumOfDataBytes / 3} }
    }
}
*Feature: PaperSize
{
    *rcNameID: =PAPER_SIZE_DISPLAY
    *DefaultOption: A4
    *Option: LETTER
    {
        *rcNameID: =LETTER_DISPLAY
        *switch: InputBin
        {
            *case: MANUAL
            {
                *PrintableArea: PAIR(2916, 3768)
                *PrintableOrigin: PAIR(72, 72)
            }
            *case: TRACTOR
            {
                *PrintableArea: PAIR(2916, 3768)
                *PrintableOrigin: PAIR(72, 72)
                *Command: CmdSelect
                {
                    *Order: DOC_SETUP.3
                    *Cmd: "<1B>F<08><08>"
                }
            }
        }
    }
    *Option: A4
    {
        *rcNameID: =A4_DISPLAY
        *switch: InputBin
        {
            *case: MANUAL
            {
                *PrintableArea: PAIR(2833, 4016)
                *PrintableOrigin: PAIR(72, 72)
                *switch: Resolution
                {
                    *case: Option1
                    {
                        *PrintableArea: PAIR(2832, 4016)
                    }
                }
            }
            *case: TRACTOR
            {
                *PrintableArea: PAIR(2833, 4016)
                *PrintableOrigin: PAIR(72, 72)
                *switch: Resolution
                {
                    *case: Option1
                    {
                        *PrintableArea: PAIR(2832, 4016)
                    }
                }
                *Command: CmdSelect
                {
                    *Order: DOC_SETUP.3
                    *Cmd: "<1B>F<09><03>"
                }
            }
        }
    }
    
     *Option: A5
    {
        *rcNameID: =A5_DISPLAY
        *PrintableArea: PAIR(2104, 2976)
        *PrintableOrigin: PAIR(0, 0)
        *switch: Resolution
        {
            *case: Option1
            {
                 *PrintableArea: PAIR(2104, 2976)
            }
        }
    }
    
    *Option: B4
    {
        *rcNameID: =B4_DISPLAY
        *switch: InputBin
        {
            *case: MANUAL
            {
                *PrintableArea: PAIR(3499, 4967)
                *PrintableOrigin: PAIR(72, 72)
                *switch: Resolution
                {
                    *case: Option1
                    {
                        *PrintableArea: PAIR(3498, 4966)
                    }
                }
            }
            *case: TRACTOR
            {
                *PrintableArea: PAIR(3499, 4967)
                *PrintableOrigin: PAIR(72, 72)
                *switch: Resolution
                {
                    *case: Option1
                    {
                        *PrintableArea: PAIR(3498, 4966)
                    }
                }
                *Command: CmdSelect
                {
                    *Order: DOC_SETUP.3
                    *Cmd: "<1B>F<0B><04>"
                }
            }
        }
    }
    *Option: CUSTOMSIZE
    {
        *rcNameID: =USER_DEFINED_SIZE_DISPLAY
        *MinSize: PAIR(360, 360)
        *MaxSize: PAIR(5040, 7920)
        *MaxPrintableWidth: 4896
        *MinLeftMargin: 0
        *CenterPrintable?: FALSE
        *switch: InputBin
        {
            *case: MANUAL
            {
                *TopMargin: 72
                *BottomMargin: 0
            }
            *case: TRACTOR
            {
                *TopMargin: 0
                *BottomMargin: 0
                *Command: CmdSelect
                {
                    *Order: DOC_SETUP.3
                    *Cmd: "<1B>F" %c[0,15]{(PhysPaperLength*8)/3600} %c[0,15]{(PhysPaperLength*8/360) MOD 10}
                }
            }
        }
    }
}
*Feature: PrintQuality
{
    *rcNameID: =TEXT_QUALITY_DISPLAY
    *DefaultOption: LETTER_QUALITY
    *Option: LETTER_QUALITY
    {
        *rcNameID: =LETTER_QUALITY_DISPLAY
        *Command: CmdSelect
        {
            *Order: DOC_SETUP.2
            *Cmd: "<1B>I"
        }
    }
    *Option: DRAFT_QUALITY
    {
        *rcNameID: =DRAFT_QUALITY_DISPLAY
        *Command: CmdSelect
        {
            *Order: DOC_SETUP.2
            *Cmd: "<1B>0"
        }
    }
}

*Feature: ColorMode
{
    *rcNameID: =COLOR_PRINTING_MODE_DISPLAY
    *DefaultOption: 24bpp
    *Option: Mono
    {
        *rcNameID: =MONO_DISPLAY
		    *DevNumOfPlanes: 0
		    *DevBPP: 0
		    *DrvBPP: 24
		    *IPCallbackID: 1
		    *Color?: FALSE
    }
    *Option: Color
    {
        *rcNameID: =COLOR_DISPLAY
        *DevNumOfPlanes: 0
        *DevBPP: 0
        *DrvBPP: 24
        *IPCallbackID: 2
        *PaletteSize: 8
        *PaletteProgrammable?: TRUE
		
        EXTERN_GLOBAL: *UseExpColorSelectCmd? : TRUE
        *ColorPlaneOrder: LIST(YELLOW, MAGENTA, CYAN, BLACK)
        *Command: CmdSendYellowData { *Cmd : "<1B5601>" }
        *Command: CmdSendMagentaData { *Cmd : "<1B5601>" }
        *Command: CmdSendCyanData { *Cmd : "<1B5601>" }
        *Command: CmdSendBlackData { *Cmd : "<1B5600>" }
        *Command: CmdSelectBlackColor { *Cmd : "<1B5600>" }
        *Command: CmdSelectRedColor { *Cmd : "<1B5601>" }
        *Command: CmdSelectGreenColor { *Cmd : "<1B5601>" }
        *Command: CmdSelectYellowColor { *Cmd : "<1B5601>" }
        *Command: CmdSelectBlueColor { *Cmd : "<1B5601>" }
        *Command: CmdSelectMagentaColor { *Cmd : "<1B5601>" }
        *Command: CmdSelectCyanColor { *Cmd : "<1B5601>" }
    }    
	  *Option: 8bpp
		{
			*rcNameID: =8BPP_DISPLAY
			*DevNumOfPlanes: 0
			*DevBPP: 0
			*DrvBPP: 8
			*IPCallbackID: 3
			*PaletteSize: 256
			*PaletteProgrammable? : TRUE
			
		  EXTERN_GLOBAL: *UseExpColorSelectCmd? : TRUE
        *ColorPlaneOrder: LIST(YELLOW, MAGENTA, CYAN, BLACK)
        *Command: CmdSendYellowData { *Cmd : "<1B5601>" }
        *Command: CmdSendMagentaData { *Cmd : "<1B5601>" }
        *Command: CmdSendCyanData { *Cmd : "<1B5601>" }
        *Command: CmdSendBlackData { *Cmd : "<1B5600>" }
        *Command: CmdSelectBlackColor { *Cmd : "<1B5600>" }
        *Command: CmdSelectRedColor { *Cmd : "<1B5601>" }
        *Command: CmdSelectGreenColor { *Cmd : "<1B5601>" }
        *Command: CmdSelectYellowColor { *Cmd : "<1B5601>" }
        *Command: CmdSelectBlueColor { *Cmd : "<1B5601>" }
        *Command: CmdSelectMagentaColor { *Cmd : "<1B5601>" }
        *Command: CmdSelectCyanColor { *Cmd : "<1B5601>" }
		}
		*Option: 24bpp
		{
			*rcNameID: =24BPP_DISPLAY
			*DevNumOfPlanes: 0
			*DevBPP: 0
			*DrvBPP: 24
			*IPCallbackID: 5
			*PaletteSize: 256
			*PaletteProgrammable? : TRUE
			EXTERN_GLOBAL: *UseExpColorSelectCmd? : TRUE
        *ColorPlaneOrder: LIST(YELLOW, MAGENTA, CYAN, BLACK)
        *Command: CmdSendYellowData { *Cmd : "<1B5601>" }
        *Command: CmdSendMagentaData { *Cmd : "<1B5601>" }
        *Command: CmdSendCyanData { *Cmd : "<1B5601>" }
        *Command: CmdSendBlackData { *Cmd : "<1B5600>" }
        *Command: CmdSelectBlackColor { *Cmd : "<1B5600>" }
        *Command: CmdSelectRedColor { *Cmd : "<1B5601>" }
        *Command: CmdSelectGreenColor { *Cmd : "<1B5601>" }
        *Command: CmdSelectYellowColor { *Cmd : "<1B5601>" }
        *Command: CmdSelectBlueColor { *Cmd : "<1B5601>" }
        *Command: CmdSelectMagentaColor { *Cmd : "<1B5601>" }
        *Command: CmdSelectCyanColor { *Cmd : "<1B5601>" }
		}
}

*Feature: Halftone
{
    *rcNameID: =HALFTONING_DISPLAY
    *DefaultOption: HT_PATSIZE_AUTO
    *Option: HT_PATSIZE_AUTO
    {
        *rcNameID: =HT_AUTO_SELECT_DISPLAY
    }
    *Option: HT_PATSIZE_SUPERCELL_M
    {
        *rcNameID: =HT_SUPERCELL_DISPLAY
    }
    *Option: HT_PATSIZE_6x6_M
    {
        *rcNameID: =HT_DITHER6X6_DISPLAY
    }
    *Option: HT_PATSIZE_8x8_M
    {
        *rcNameID: =HT_DITHER8X8_DISPLAY
    }
}
*Command: CmdStartDoc
{
    *Order: DOC_SETUP.1
    *Cmd: "<18><1B>N"
}
*Command: CmdStartPage
{
    *Order: PAGE_SETUP.1
    *Cmd: "<0D>"
}
*RotateCoordinate?: FALSE
*RotateRaster?: FALSE
*RotateFont?: FALSE
*switch: Orientation
{
    *case: PORTRAIT
    {
        *TextCaps: LIST(TC_SA_DOUBLE,TC_EA_DOUBLE,TC_IA_ABLE,TC_UA_ABLE,TC_RA_ABLE)
    }
    *case: LANDSCAPE_CC270
    {
        *TextCaps: LIST(TC_RA_ABLE)
    }
}
*CursorXAfterCR: AT_CURSOR_X_ORIGIN
*YMoveAttributes: LIST(SEND_CR_FIRST)
*MaxLineSpacing: 255
*XMoveThreshold: *
*YMoveThreshold: *
*XMoveUnit: 180
*YMoveUnit: 120
*Command: CmdXMoveRelRight { *Cmd : "<1B>%%3" %m[0,255]{max_repeat((DestXRel / 2) )} }
*Command: CmdXMoveRelLeft { *Cmd : "<1B>%%4" %m[0,255]{max_repeat((DestXRel / 2) )} }
*Command: CmdYMoveRelDown { *Cmd : "<1B>%%5" %c[0,255]{max_repeat((DestYRel / 3) )} }
*Command: CmdSetLineSpacing { *Cmd : "<1B>%%9" %m[0,255]{(LinefeedSpacing / 3) } }
*Command: CmdCR { *Cmd : "<0D>" }
*Command: CmdLF { *Cmd : "<0A>" }
*Command: CmdFF { *Cmd : "<1B><56><02>" }
*Command: CmdBackSpace { *Cmd : "<08>" }
*Command: CmdUniDirectionOn { *Cmd : "<1B>%%U" }
*Command: CmdUniDirectionOff { *Cmd : "<1B>%%B" }
*EjectPageWithFF?: TRUE
*OutputDataFormat: V_BYTE
*OptimizeLeftBound?: FALSE
*CursorXAfterSendBlockData: AT_GRXDATA_END
*CursorYAfterSendBlockData: NO_MOVE
*DefaultFont: 5
*DefaultCTT: 1
*switch: Orientation
{
    *case: PORTRAIT
    {
        *DeviceFonts: LIST(1,2,3,4,5,6)
    }
    *case: LANDSCAPE_CC270
    {
        *DeviceFonts: LIST()
    }
}
*Command: CmdBoldOn { *Cmd : "<1B>I" }
*Command: CmdBoldOff { *Cmd : "<1B>0" }
*Command: CmdUnderlineOn { *Cmd : "<1B>X" }
*Command: CmdUnderlineOff { *Cmd : "<1B>Y" }
