*GPDSpecVersion: "1.0"
*Include: "StdNames.gpd"
*GPDFileVersion: "1.0"
*GPDFileName: "M180XP.GPD"
*ModelName: "BTP-M180"
*MasterUnits: PAIR(160, 144)
*ResourceDLL: "M180XP.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: UPPER
    *Option: UPPER
    {
        *rcNameID: =UPPER_TRAY_DISPLAY
    }
}
*Feature: Resolution
{
    *rcNameID: =RESOLUTION_DISPLAY
    *DefaultOption: Option2
    *Option: Option1
    {
        *Name: "160 x 144 " =DOTS_PER_INCH
        *DPI: PAIR(160, 144)
        *TextDPI: PAIR(160, 144)
        *PinsPerLogPass: 16
        *PinsPerPhysPass: 8
        EXTERN_GLOBAL: *StripBlanks: LIST(TRAILING)
        *SpotDiameter: 140
        *Command: CmdSendBlockData { *Cmd : "<1B>*<01>" %l{NumOfDataBytes} }
    }
    *Option: Option2
    {
        *Name: "160 x 72 " =DOTS_PER_INCH
        *DPI: PAIR(160, 72)
        *TextDPI: PAIR(160, 72)
        *PinsPerLogPass: 8
        *PinsPerPhysPass: 8
        EXTERN_GLOBAL: *StripBlanks: LIST(TRAILING)
        *SpotDiameter: 140
        *Command: CmdSendBlockData { *Cmd : "<1B>*<01>" %l{NumOfDataBytes} }
    }
    *Option: Option3
    {
        *Name: "80 x 72 " =DOTS_PER_INCH
        *DPI: PAIR(80, 72)
        *TextDPI: PAIR(80, 72)
        *PinsPerLogPass: 8
        *PinsPerPhysPass: 8
        EXTERN_GLOBAL: *StripBlanks: LIST(TRAILING)
        *SpotDiameter: 140
        *Command: CmdSendBlockData { *Cmd : "<1B>*<00>" %l{NumOfDataBytes} }
    }
}
*Feature: PaperSize
{
    *rcNameID: =PAPER_SIZE_DISPLAY
    *DefaultOption: Option3
    *Option: Option3
    {
        *rcNameID: 260
        *OptionID: 260
        *PageDimensions: PAIR(479, 1684)
        *PrintableArea: PAIR(400, 1684)
        *PrintableOrigin: PAIR(44, 0)
    }
    *Option: Option4
    {
        *rcNameID: 261
        *OptionID: 261
        *PageDimensions: PAIR(479, 18573)
        *PrintableArea: PAIR(400, 18573)
        *PrintableOrigin: PAIR(44, 0)
        *switch: Resolution
        {
            *case: Option2
            {
*% Warning: the following printable length is adjusted (18573->18572) so it is divisible by the resolution Y scale.
                *PrintableArea: PAIR(400, 18572)
            }
            *case: Option3
            {
*% Warning: the following printable length is adjusted (18573->18572) so it is divisible by the resolution Y scale.
                *PrintableArea: PAIR(400, 18572)
            }
        }
    }
    *Option: Option5
    {
        *rcNameID: 262
        *OptionID: 262
        *PageDimensions: PAIR(440, 1684)
        *PrintableArea: PAIR(359, 1684)
        *PrintableOrigin: PAIR(44, 0)
        *switch: Resolution
        {
            *case: Option3
            {
*% Warning: the following printable width is adjusted (359->358) so it is divisible by the resolution X scale.
                *PrintableArea: PAIR(358, 1684)
            }
        }
    }
    *Option: Option6
    {
        *rcNameID: 263
        *OptionID: 263
        *PageDimensions: PAIR(440, 18573)
        *PrintableArea: PAIR(359, 18573)
        *PrintableOrigin: PAIR(44, 0)
        *switch: Resolution
        {
            *case: Option2
            {
*% Warning: the following printable length is adjusted (18573->18572) so it is divisible by the resolution Y scale.
                *PrintableArea: PAIR(359, 18572)
            }
            *case: Option3
            {
*% Warning: the following printable width is adjusted (359->358) so it is divisible by the resolution X scale.
*% Warning: the following printable length is adjusted (18573->18572) so it is divisible by the resolution Y scale.
                *PrintableArea: PAIR(358, 18572)
            }
        }
    }
    *Option: Option7
    {
        *rcNameID: 264
        *OptionID: 264
        *PageDimensions: PAIR(365, 1684)
        *PrintableArea: PAIR(300, 1684)
        *PrintableOrigin: PAIR(44, 0)
    }
    *Option: Option8
    {
        *rcNameID: 265
        *OptionID: 265
        *PageDimensions: PAIR(365, 18573)
        *PrintableArea: PAIR(300, 18573)
        *PrintableOrigin: PAIR(44, 0)
        *switch: Resolution
        {
            *case: Option2
            {
*% Warning: the following printable length is adjusted (18573->18572) so it is divisible by the resolution Y scale.
                *PrintableArea: PAIR(300, 18572)
            }
            *case: Option3
            {
*% Warning: the following printable length is adjusted (18573->18572) so it is divisible by the resolution Y scale.
                *PrintableArea: PAIR(300, 18572)
            }
        }
    }
    *Option: CUSTOMSIZE
    {
        *rcNameID: =USER_DEFINED_SIZE_DISPLAY
        *MinSize: PAIR(252, 144)
        *MaxSize: PAIR(504, 32767)
        *MaxPrintableWidth: 400
       *CursorOrigin: PAIR(44, 0)
        *MinLeftMargin: 44
        *CenterPrintable?:FALSE
    }
}
*Feature: PrintQuality
{
    *rcNameID: =TEXT_QUALITY_DISPLAY
    *DefaultOption: Option2
    *Option: Option1
    {
        *rcNameID: 276
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.2
            *Cmd: "<1B>U<01>"
        }
    }
    *Option: Option2
    {
        *rcNameID: 277
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.2
            *Cmd: "<1B>U<00>"
        }
    }
}

*Feature: Conservation
{
     *rcNameID: 287
    *%FeatureType:PRINTER_PROPERTY
    *Option: Option1
    {
        *rcNameID: 288
        *OptionID: 288
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.1
            *Cmd: "<>"
        }
    }
    *Option: Option2
    {
        *rcNameID: 289
        *OptionID: 289
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.1
            *Cmd: "<>"
        }
    }
}

*%*Feature: MediaType
*Feature: PaperType
{
    *rcNameID: 290
    *DefaultOption: Option1
    *Option: Option1
    {
        *rcNameID: 271
        *OptionID: 271
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.3
            *Cmd: "<1B>c0<00>"
        }
    }
    *Option: Option2
    {
        *rcNameID: 272
        *OptionID: 272
        *Command: CmdSelect
        {
            *Order: PAGE_SETUP.3
            *Cmd: "<1B>c0<9A>"
        }
    }
}
*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: PAGE_SETUP.4
    *Cmd: "<1D>D<011D>(D<0300140300>"
}
*Command: CmdEndJob
{
    *Order: JOB_FINISH.1
    *Cmd: "<1D>D<00>"
}
*Command: CmdEndPage
{
    *Order: PAGE_FINISH.1
    *Cmd: "<0A><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)
*YMoveThreshold: *
*YMoveUnit: 144
*Command: CmdYMoveRelDown { *Cmd : "<1B>J" %c[0,255]{max_repeat(DestYRel )} }
*Command: CmdCR { *Cmd : "<0D00>" }
*Command: CmdLF { *Cmd : "<>" }
*Command: CmdFF { *Cmd : "<>" }
*%*EjectPageWithFF?: TRUE
*switch: Conservation
{
 	*case: Option1
	{
		*EjectPageWithFF?: TRUE
	}
	*case: Option2
	{
		*EjectPageWithFF?: FALSE
	}
}
*OutputDataFormat: V_BYTE
*OptimizeLeftBound?: FALSE
*CursorXAfterSendBlockData: AT_GRXDATA_END
*CursorYAfterSendBlockData: NO_MOVE
*DefaultFont: 1
*DefaultCTT: 0
*switch: Orientation
{
    *case: PORTRAIT
    {
        *DeviceFonts: LIST(1,2,3,4,5,6,7,8,9)
    }
    *case: LANDSCAPE_CC270
    {
        *DeviceFonts: LIST()
    }
}
