*%
*%  Q3.GPD  x32 x64 Copyright (c) CUSTOM ENGINEERING 
*%
*%

*GPDSpecVersion: "1.0"
*Include: "StdNames.gpd"
*GPDFileVersion: "1.03 Inf 1.10"
*GPDFileName: "Q3.GPD"
*ModelName: "CUSTOM Q3"
*MasterUnits: PAIR(203, 203)
*ResourceDLL: "Q3.Dll"
*PrinterType: SERIAL

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

*%********************PAPER SOURCE******************
*Feature: InputBin
{
    *rcNameID: =PAPER_SOURCE_DISPLAY
}

*%******************DATA COMPRESSION******************
*Feature: DataComp
{
  *Name: "Data Compression"
  *FeatureType: PRINTER_PROPERTY
  *DefaultOption: FE_RLE

  *Option: FE_RLE
  {
    *Name: "RLE Compression"
    *Command: CmdEnableFE_RLE { *Cmd : "<1B>*b2M" }
    *Command: CmdDisableCompression { *Cmd : "<1B>*b0M" }
  }
}

*%******************PRINT RESOLUTION******************
*Feature: Resolution
{
    *rcNameID: =RESOLUTION_DISPLAY
    *DefaultOption: Option1
	*%****************** 203 x 203 ******************
    *Option: Option1
    {
        *Name: "203 x 203 " =DOTS_PER_INCH
        *DPI: PAIR(203, 203)
        *TextDPI: PAIR(203, 203)
        *MinStripBlankPixels: 1000
        EXTERN_GLOBAL: *StripBlanks: LIST(LEADING,ENCLOSED,TRAILING)
        *SpotDiameter: 140
        *Command: CmdSendBlockData { *Cmd : "<1B>*b" %d{NumOfDataBytes }"W" }
        *Command: CmdSelect
        {
            *Order: DOC_SETUP.7
            *Cmd: "<1B>*t200R"
        }
    }
}

*%****************** PAPER SIZE ******************
*Feature: PaperSize
{
    *rcNameID: =PAPER_SIZE_DISPLAY
    *DefaultOption: Q3RollShort
	*%****************** ROLL SHORT ******************
    *Option: Q3RollShort
    {
        *Name: "Q3 Roll Short"
        *PageDimensions: PAIR(640, 4296)
        *PrintableArea: PAIR(576, 4296)
        *PrintableOrigin: PAIR(32, 0)
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.9
            *Cmd: "<1B>&l" %d{PhysPaperLength}"R"
        }
    }
	*%****************** ROLL ******************
    *Option: Q3Roll
    {
        *Name: "Q3 Roll"
    	*PageDimensions: PAIR(640, 9248)
        *PrintableArea: PAIR(576, 9248)
        *PrintableOrigin: PAIR(32, 0)
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.9
            *Cmd: "<1B>&l" %d{PhysPaperLength}"R"
        }
    }
	*%****************** 80 x 80 mm ******************
    *Option: Q380mm
    {
        *Name: "Q3 80mm"
        *PageDimensions: PAIR(640, 632)
        *PrintableArea: PAIR(576, 632)
        *PrintableOrigin: PAIR(32, 0)
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.9
            *Cmd: "<1B>&l" %d{PhysPaperLength}"P"
        }
    }
	*%****************** 80 x 120 mm ******************
    *Option: Q3120mm
    {
        *Name: "Q3 120mm"
        *PageDimensions: PAIR(640, 952)
        *PrintableArea: PAIR(576, 952)
        *PrintableOrigin: PAIR(32, 0)
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.9
            *Cmd: "<1B>&l" %d{PhysPaperLength}"P"
        }
    }
	*%****************** 80 x 160 mm ******************
    *Option: Q3160mm
    {
        *Name: "Q3 160mm"
        *PageDimensions: PAIR(640, 1272)
        *PrintableArea: PAIR(576, 1272)
        *PrintableOrigin: PAIR(32, 0)
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.9
            *Cmd: "<1B>&l" %d{PhysPaperLength}"P"
        }
    }
	*%****************** 80 x 200 mm ******************
    *Option: Q3200mm
    {
        *Name: "Q3 200mm"
        *PageDimensions: PAIR(640, 1592)
        *PrintableArea: PAIR(576, 1592)
        *PrintableOrigin: PAIR(32, 0)
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.9
            *Cmd: "<1B>&l" %d{PhysPaperLength}"P"
        }
    }
	*%****************** 80 x 240 mm ******************
    *Option: Q3240mm
    {
        *Name: "Q3 240mm"
        *PageDimensions: PAIR(640, 1904)
        *PrintableArea: PAIR(576, 1904)
        *PrintableOrigin: PAIR(32, 0)
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.9
            *Cmd: "<1B>&l" %d{PhysPaperLength}"P"
        }
    }
	*%****************** 80 x 280 mm ******************
    *Option: Q3280mm
    {
        *Name: "Q3 280mm"
        *PageDimensions: PAIR(640, 2224)
        *PrintableArea: PAIR(576, 2224)
        *PrintableOrigin: PAIR(32, 0)
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.9
            *Cmd: "<1B>&l" %d{PhysPaperLength}"P"
        }
    }
	*%****************** 80 x 400 mm ******************
    *Option: Q3400mm
    {
        *Name: "Q3 400mm"
        *PageDimensions: PAIR(640, 3176)
        *PrintableArea: PAIR(576, 3176)
        *PrintableOrigin: PAIR(32, 0)
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.9
            *Cmd: "<1B>&l" %d{PhysPaperLength}"P"
        }
    }
	*%****************** CUSTOM PAPER SIZE ******************
    *Option: CUSTOMSIZE
    {
        *rcNameID: =USER_DEFINED_SIZE_DISPLAY
        *MinSize: PAIR(80, 160)
        *MaxSize: PAIR(640, 9248)
        *MaxPrintableWidth: 576
        *CenterPrintable?: FALSE
        *CustCursorOriginX: %d{32 + (PhysPaperWidth - 640) / 2} *% { PrintableOrigin.x + (PhysPaperWidth - MaxPaperWidth) / 2}
        *CustCursorOriginY: %d{0} *% PrintableOrigin.y
        *CustPrintableOriginX: %d{32} *% PrintableOrigin.x
        *CustPrintableOriginY: %d{0} *% PrintableOrigin.y
        *CustPrintableSizeX: %d{PhysPaperWidth - 32 - 32} *% {PhysPaperWidth - PrintableOrigin.x - (MaxPaperWidth - MaxPrintableWidth - PrintableOrigin.x) }
        *CustPrintableSizeY: %d{PhysPaperLength - 0 - 0} *% {PhysPaperHeigth - PrintableOrigin.y - (PageDimensions.Y- PrintableArea.Y) }
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.9
            *Cmd: "<1B>&l" %d{PhysPaperLength}"P" "<1B>&l" %d{PhysPaperWidth }"X"
        }

    }
}

*%*******************PRINT QUALITY********************
*Feature: PrintQuality
{
    *rcNameID: =TEXT_QUALITY_DISPLAY
    *DefaultOption: Option2
	*%****************** HIGH QUALITY ******************
    *Option: Option1
    {
        *Name: "High Quality"
        *Command: CmdSelect
        {
            *Order: DOC_SETUP.3
            *Cmd: "<1B>*o1Q"
        }
    }
	*%****************** NORMAL ******************
    *Option: Option2
    {
        *Name: "Normal"
        *Command: CmdSelect
        {
            *Order: DOC_SETUP.3
            *Cmd: "<1B>*o0Q"
        }
    }
}
*%****************PRINTER FEATURES: Print Density**************
*Feature: PrintDensity
{
    *rcNameID: =PRINTDENSITY_DISPLAY
    *DefaultOption: Option5
    *Option: Option1
    {
        *Name: "- 50 <25>"
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.11
            *Cmd: "<1B>&k0W"
        }
    }
    *Option: Option2
    {
        *Name: "- 37 <25>"
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.11
            *Cmd: "<1B>&k1W"
        }
    }
    *Option: Option3
    {
        *Name: "- 25 <25>"
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.11
            *Cmd: "<1B>&k2W"
        }
    }
    *Option: Option4
    {
        *Name: "- 12 <25>"
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.11
            *Cmd: "<1B>&k3W"
        }
    }
    *Option: Option5
    {
        *Name: "0 <25>"
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.11
            *Cmd: "<1B>&k4W"
        }
    }
    *Option: Option6
    {
        *Name: "+ 12 <25>"
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.11
            *Cmd: "<1B>&k5W"
        }
    }
    *Option: Option7
    {
        *Name: "+ 25 <25>"
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.11
            *Cmd: "<1B>&k6W"
        }
    }
    *Option: Option8
    {
        *Name: "+ 37 <25>"
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.11
            *Cmd: "<1B>&k7W"
        }
    }
    *Option: Option9
    {
        *Name: "+ 50 <25>"
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.11
            *Cmd: "<1B>&k8W"
        }
    }
    *Option: Option10
    {
        *Name: "Not set by driver"
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.11
            *Cmd: ""
        }
    }
}

*%*******************HALFTONING********************
*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: CmdStartJob
{
    *Order: JOB_SETUP.1
    *Cmd: "<18><1B>*r0D"	*%Ignore text command enabled
}

*Command: CmdEndJob
{
    *Order: JOB_FINISH.1
	*Cmd: "<1B>*r0d<1D>P<0000>"	*%Ignore text command disabled
}

*Command: CmdEndPage
{
    *Order: PAGE_FINISH.1
	*Cmd: "<1B>*rB<0A0A0A0A>"
}

*Command: CmdStartDoc
{
   *Order: DOC_SETUP.1
   *Cmd: "<181B>2"
}

*%****************CASH DRAWER**************
*Feature: CashDrawer
{
    *Name: "Cash Drawer"
    *FeatureType: DOC_PROPERTY
    *DefaultOption: Cash_Disable
    *Option: Cash_Disable
    {
        *Name: "Cash Disable"
        *Command: CmdSelect
         {
             *Order: JOB_FINISH.2
             *Cmd: ""
         }
    }
   *Option: Cash_Enable_Beg_Doc
    {
        *Name: "Cash Enable at Beginning Document"
        *Command: CmdSelect
        {
            *Order: DOC_SETUP.8
            *Cmd: "<1B>p<008080FF>"
        }
    }
    *Option: Cash_Enable_End_Page
    {
        *Name: "Cash Enable at End Page"
        *Command: CmdSelect
        {
            *Order: PAGE_FINISH.2
            *Cmd: "<1B>p<008080FF>"
        }
    }
    *Option: Cash_Enable_End_Doc
    {
        *Name: "Cash Enable at End Document"
        *Command: CmdSelect
        {
            *Order: JOB_FINISH.2
            *Cmd: "<1B>p<008080FF>"
        }
    }
}

*%*******************CUT MODE********************
*Feature: CutMode
{
    *Name: "Cut Mode"
    *FeatureType: DOC_PROPERTY
    *DefaultOption: Total_Cut_End_Page
	*%****************** NO Cut ******************
    *Option: No_Cut
    {
	*Name: "No Cut"
        *Command: CmdSelect
         {
             *Order: DOC_FINISH.1
			 *Cmd: "<0A0A0A0A0A>"
         }
    }
	*%****************** TOTAL Cut END PAGE ******************
    *Option: Total_Cut_End_Page
    {
	*Name: "Total Cut End Page"
        *Command: CmdSelect
        {
			*Order: PAGE_FINISH.4
			*Cmd: "<1B69>"
        }
    }
	*%****************** TOTAL Cut END DOC ******************
    *Option: Total_Cut_End_Doc
    {
        *Name: "Total Cut End Doc"
        *Command: CmdSelect
        {
			*Order: JOB_FINISH.3
			*Cmd: "<1B69>"
        }
    }
}
*%****************BEEP**************
*Feature: Beep
{
    *Name: "Beep"
    *FeatureType: DOC_PROPERTY
    *DefaultOption: No_Beep
	*%****************** No Beep ******************
    *Option: No_Beep
    {
        *Name: "No Beep"
        *Command: CmdSelect
        {
            *Order: DOC_SETUP.12
            *Cmd: ""
        }
    }
	*%****************** Beep Begin Doc ******************
    *Option: Beg_Doc_Beep
    {
        *Name: "Beep Begin Doc"
        *Command: CmdSelect
        {
            *Order: DOC_SETUP.13
            *Cmd: "<1CC0><07>"
        }
    }
	*%****************** Beep End Doc ******************
    *Option: End_Doc_Beep
    {
       *Name: "Beep End Doc"
       *Command: CmdSelect
       {
           *Order: JOB_FINISH.4
           *Cmd: "<1CC0><07>"
       }
    }
}

*%****************NOTCH ALIGNMENT**************
*Feature: BlackMark
{
    *Name: "Notch Alignment"
    *FeatureType: DOC_PROPERTY
    *DefaultOption: Black_Mark_Alignement_Off
    *Option: Black_Mark_Alignement_Off
    {
       *Name: "Off"
       *Command: CmdSelect
       {
			*Order: DOC_SETUP.2
           *Cmd: ""
       }

    }
    *Option: Black_Mark_Alignement_BP
    {
        *Name: "At begin page"
		*Command: CmdStartPage
		{
			*Order: PAGE_SETUP.1
			*Cmd: "<1DF6>"
		}
    }
    *Option: Black_Mark_Alignement_EP
    {
        *Name: "At end page"
        *Command: CmdSelect
        {
            *Order: PAGE_FINISH.3
            *Cmd: "<1DF6>"
        }
    }
}



*RotateCoordinate?: FALSE
*RotateRaster?: FALSE
*RotateFont?: FALSE
*TextCaps: LIST(TC_EA_DOUBLE,TC_IA_ABLE,TC_UA_ABLE,TC_RA_ABLE)
*CursorXAfterCR: AT_PRINTABLE_X_ORIGIN
*ReselectFont: LIST(AFTER_XMOVE)
*XMoveThreshold: 0
*YMoveThreshold: 0
*XMoveUnit: 203
*YMoveUnit: 203
*Command: CmdXMoveAbsolute { *Cmd : "<1B>*p" %d{DestX }"X" }
*Command: CmdYMoveAbsolute { *Cmd : "<1B>*p" %d{DestY}"Y" }
*Command: CmdCR { *Cmd : "<0D>" }
*Command: CmdLF { *Cmd : "<0A>" }
*Command: CmdFF { *Cmd : ""  }
*Command: CmdBackSpace { *Cmd : "<08>" }
*EjectPageWithFF?: TRUE
*OutputDataFormat: H_BYTE
*OptimizeLeftBound?: FALSE
*CursorXAfterSendBlockData: AT_GRXDATA_ORIGIN
*CursorYAfterSendBlockData: AUTO_INCREMENT
*DefaultCTT: 0
