*GPDSpecVersion: "1.0"
*GPDFileName: "TENCENT.GPD"
*GPDFileVersion: "1.0"
*Include: "STDNAMES.GPD"
*ModelName: "Tencent Virtual Printer"
*MasterUnits: PAIR(480, 480)
*ResourceDLL: "unires.dll"
*PrinterType: SERIAL
*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: TRACTOR
    *Option: TRACTOR
    {
        *rcNameID: =TRACTOR_DISPLAY
        *Command: CmdSelect
        {
            *Order: DOC_SETUP.3
            *Cmd: "<1B19>0"
        }
    }
}
*Feature: Resolution
{
    *rcNameID: =RESOLUTION_DISPLAY
    *DefaultOption: Option1
    *Option: Option1
    {
        *Name: "96 x 96 " =DOTS_PER_INCH
        *DPI: PAIR(96, 96)
        *TextDPI: PAIR(96, 96)
        *PinsPerLogPass: 24
        *PinsPerPhysPass: 24
        *MinStripBlankPixels: 32
        EXTERN_GLOBAL: *StripBlanks: LIST(LEADING,ENCLOSED,TRAILING)
        *SpotDiameter: 100
        *Command: CmdSendBlockData { *Cmd : "<1B>*'" %l{NumOfDataBytes / 3} }
    }
    *Option: Option2
    {
        *Name: "120 x 120 " =DOTS_PER_INCH
        *DPI: PAIR(120, 120)
        *TextDPI: PAIR(120, 120)
        *PinsPerLogPass: 24
        *PinsPerPhysPass: 24
        *MinStripBlankPixels: 32
        EXTERN_GLOBAL: *StripBlanks: LIST(LEADING,ENCLOSED,TRAILING)
        *SpotDiameter: 100
        *Command: CmdSendBlockData { *Cmd : "<1B>*!" %l{NumOfDataBytes / 3} }
    }
}
*Feature: PaperSize
{
    *rcNameID: =PAPER_SIZE_DISPLAY
    *DefaultOption: A4
    *Option: A4
    {
        *rcNameID: =RCID_DMPAPER_SYSTEM_NAME
        *Command: CmdSelect
        {
            *Order: DOC_SETUP.4
            *Cmd: "<1B>2<1B>CF"
        }
        *PrintableArea: PAIR(3720, 5400)
        *PrintableOrigin: PAIR(0, 0)
    }
}
*Feature: ColorMode
{
    *rcNameID: =COLOR_PRINTING_MODE_DISPLAY
    *DefaultOption: Color
    *Option: Mono
    {
        *rcNameID: =MONO_DISPLAY
        *DevNumOfPlanes: 1
        *DevBPP: 1
        *Color? : FALSE
    }
    *Option: Color
    {
        *rcNameID: =24BPP_DISPLAY
        *DevNumOfPlanes: 1
        *DevBPP: 24
        *DrvBPP: 24
        *Command: CmdEnableDRC { *Cmd : "<1B>*b3M" }
        *PaletteSize: 256
        *PaletteProgrammable? : TRUE
        *Command: CmdDefinePaletteEntry { *Cmd : "<1B>*v" %d{RedValue}"a" %d{GreenValue}"b" %d{BlueValue}"c" %d{PaletteIndexToProgram}
+ "I" }
        *Command: CmdSelectPaletteEntry { *Cmd : "<1B>*v" %d{CurrentPaletteIndex}"S" }
        *Command: CmdSetSrcBmpWidth { *Cmd : "<1B>*r" %d{RasterDataWidthInBytes / 3}"S" }
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.16
            *Cmd: "<1B>*v1N<1B>*v1O<1B>*l184O<1B>*v6W<0003080808081B>*v0a0b0c7i255a255b255c0I<1B>*"
+ "o3W<060400>"
        }
    }
}
*Feature: Halftone
{
    *rcNameID: =HALFTONING_DISPLAY
    *DefaultOption: HT_PATSIZE_6x6_M
    *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: "<1B>@<1B>t<011B>6<1B>R<001B>r<001B>U<01>"
}
*Command: CmdStartPage
{
    *Order: PAGE_SETUP.1
    *Cmd: "<0D>"
}
*Command: CmdEndJob
{
    *Order: JOB_FINISH.1
    *Cmd: "<1B>@"
}
*RotateCoordinate?: TRUE
*RotateRaster?: TRUE
*RotateFont?: TRUE
*switch: Orientation
{
    *case: PORTRAIT
    {
*TextCaps: LIST(TC_OP_CHARACTER,TC_OP_STROKE,TC_CP_STROKE,TC_CR_90,TC_CR_ANY,TC_SF_X_YINDEP,TC_SA_DOUBLE,TC_SA_INTEGER,TC_SA_CONTIN,TC_EA_DOUBLE,TC_IA_ABLE,TC_UA_ABLE,TC_SO_ABLE,TC_RA_ABLE,TC_VA_ABLE)
    }
    *case: LANDSCAPE_CC270
    {
        *TextCaps: LIST(TC_RA_ABLE)
    }
}
*CursorXAfterCR: AT_CURSOR_X_ORIGIN
*YMoveAttributes: LIST(SEND_CR_FIRST)
*MaxLineSpacing: 255
*XMoveThreshold: 0
*YMoveThreshold: 0
*XMoveUnit: 480
*YMoveUnit: 480
*Command: CmdXMoveAbsolute { *Cmd : "<1B>$" %l{(DestX / 6) } }
*Command: CmdSetLineSpacing { *Cmd : "<1B>3" %c[0,255]{(LinefeedSpacing / 2) } }
*Command: CmdCR { *Cmd : "<0D>" }
*Command: CmdLF { *Cmd : "<0A>" }
*Command: CmdFF { *Cmd : "<0C>" }
*Command: CmdBackSpace { *Cmd : "<08>" }
*Command: CmdUniDirectionOn { *Cmd : "<1B>U<01>" }
*Command: CmdUniDirectionOff { *Cmd : "<1B>U<00>" }
*EjectPageWithFF?: TRUE
*OutputDataFormat: V_BYTE
*OptimizeLeftBound?: FALSE
*CursorXAfterSendBlockData: AT_GRXDATA_END
*CursorYAfterSendBlockData: NO_MOVE
*DefaultFont: 3
*DefaultCTT: 1
*CharPosition: BASELINE
*switch: Orientation
{
    *case: PORTRAIT
    {
        *DeviceFonts: LIST(1,2,3,4,6,7,8)
    }
    *case: LANDSCAPE_CC270
    {
        *DeviceFonts: LIST()
    }
}
*Command: CmdBoldOn { *Cmd : "<1B>E" }
*Command: CmdBoldOff { *Cmd : "<1B>F" }
*Command: CmdItalicOn { *Cmd : "<1B>4" }
*Command: CmdItalicOff { *Cmd : "<1B>5" }
*Command: CmdUnderlineOn { *Cmd : "<1B>-<01>" }
*Command: CmdUnderlineOff { *Cmd : "<1B>-<00>" }
