ó J¡Vc@s0dZdZdZdZddlZddlZddlZddlZddlZddl Tddl m Z m Z m Z mZmZmZddlmZd „Zd „Zd „Zd „Zd „Zd„Zd„Zd„Zd„Zyejeeeedeefe fƒZ!e!j"ej#dddddgƒe!j$ƒ\Z%Z&Z'Z(Z)Z*e!j+e&e'diej,e-fd6ƒZ&e&s˜ej.dƒne/j0de&ƒe(ekrÞe j1ƒsÞe/j2deƒeZ(qÞne(ekr-ye j3e&e'ƒZ4Wn4e5k r6Z6e/j2de6j7ƒej.dƒnXzåye4j8ƒWn+e5k rue/j2dƒej.dƒnXe4j9ƒre4j:j;de-ƒZ<e/j=de<ƒe4j>ƒe<e?krÎe/j2d ƒqe<e@krðejAe4ejBƒqe<eCkrejDe4ejBejEƒqe<eFkr@ejGe4ejBeeƒqe<eHeIfkrqejJe4ejBeeeKƒqe<eLkr™ejMe4eeejBƒqe<eNkr¾ejOe4ejBeƒqe<ePeQeRfkrøejSe4e<ejBeeeeƒqe<eTkrejUe4ejBeƒqe<eVkrEejWe4ejBeeƒqe<eXkrgejYe4ejBƒqe<eZkrej[e4ejBeeƒqe<e\kr´ej]e4ejBeƒqe<e^krÙej_e4ejBeƒqe<e`krþejae4ejBeƒqe/j2d!ƒn e/j2dƒWde4j>ƒXnÃy$dd"lbmcZcdd#ldmeZeWn+efk r~e/j2d$ƒej.dƒnXecejgƒZheede&ƒZieijjƒye/j=d%ƒehjkƒWnelk râej.dƒnXej.dƒWnelk re/j2d&ƒnXe/j0d'ƒe/j0d(ƒdS()s5.0s#Printer Cartridge Alignment Utilityshp-alignszCartridge alignment utility for HPLIP supported inkjet printers. (Note: Not all printers require the use of this utility).iÿÿÿÿN(t*(tdevicetstatustutilstmaintttuitmodule(tcupscCsEtjd||fd|ƒ\}}|s;tjdƒn||fS(NsRFrom the printed Alignment page, Enter the best aligned value for line %s (1-%d): ii(Rt enter_rangetsystexit(tletterthortverttcolorst line_counttmaximumtoktvalue((sU/builds/ul11u3sru-gate/components/hplip/build/prototype/i386/usr/share/hplip/align.pytenterAlignmentNumber)s  cCs?tjd|d|ƒ\}}|s5tjdƒn||fS(NsFEnter numbered arrow that is best aligned with the paper edge (1-%d): ii(RRR R (RRR((sU/builds/ul11u3sru-gate/components/hplip/build/prototype/i386/usr/share/hplip/align.pytenterPaperEdge4s cCsEtjd||fd|ƒ\}}|s;tjdƒn||fS(Ns]Enter the numbered box on line %s that is best color matched to the background color (1-%d): ii(RRR R (tlineRRR((sU/builds/ul11u3sru-gate/components/hplip/build/prototype/i386/usr/share/hplip/align.pytcolorAdj?s  cCstjdƒdS(NshCannot perform alignment with 0 or 1 cartridges installed. Please install both cartridges and try again.(tlogterror(((sU/builds/ul11u3sru-gate/components/hplip/build/prototype/i386/usr/share/hplip/align.pytbothPensRequiredJscCstjdƒdS(NsNInvalid cartridge(s) installed. Please install valid cartridges and try again.(RR(((sU/builds/ul11u3sru-gate/components/hplip/build/prototype/i386/usr/share/hplip/align.pyt invalidPenNscCstjdƒdS(Ns„Invalid cartridge(s) installed. Cannot align with only the photo cartridge installed. Please install other cartridges and try again.(RR(((sU/builds/ul11u3sru-gate/components/hplip/build/prototype/i386/usr/share/hplip/align.pyt invalidPen2RscCs~tjdƒtjdƒtjdƒtjdƒtjddddgdƒ\}}|dkrttjd ƒn|d kS( NsyTo perform alignment, you will need the alignment page that is automatically printed after you install a print cartridge.s* p Print the alignment page and continue.sGn Do Not print the alignment page (you already have one) and continue.s q Quit. s6Choice (p=print page*, n=do not print page, q=quit) ? tptntqity(RtinfoRt enter_choiceR R (Rtchoice((sU/builds/ul11u3sru-gate/components/hplip/build/prototype/i386/usr/share/hplip/align.pytaioUI1Vs    $ cCs¿tj||ƒ}g}t|jƒƒ}|jƒx„|D]|}||ds_|jdƒq;tjd|||dfd||dƒ\}}|j|ƒ|s;tj dƒq;q;W|S(NisbEnter the numbered box on line %s where the inner lines best line up with the outer lines (1-%d): i( Rtalign10and11and14ControlstlisttkeystsorttappendRRR R (tpatternt align_typetcontrolstvaluest s_controlsRRR((sU/builds/ul11u3sru-gate/components/hplip/build/prototype/i386/usr/share/hplip/align.pyttype10and11and14Alignds   , cCs[tjdƒtjtjdƒƒtjdƒtjdƒtjdƒtjdƒdS(Nts-Follow these steps to complete the alignment:s@1. Place the alignment page, with the printed side facing down, s in the scanner.s12. Press the Enter or Scan button on the printer.sX3. "Alignment Complete" will be displayed when the process is finished (on some models).(RRtbold(((sU/builds/ul11u3sru-gate/components/hplip/build/prototype/i386/usr/share/hplip/align.pytaioUI2xs     t see_also_listshp-cleans hp-colorcalshp-linefeedcals hp-pqdiagtfilters align-typeisUsing device : %s s@%s -u/--gui requires Qt4 GUI support. Entering interactive mode.sUnable to open device: %sisGDevice is busy or in an error state. Please check device and try again.sAlignment type=%ds|Alignment through HPLIP not supported for this printer. Please use the printer's front panel to perform cartridge alignment.sInvalid alignment type.(t QApplication(t AlignDialogs,Unable to load Qt4 support. Is it installed?sStarting GUI loop...s User exitR.sDone.(mt __version__t __title__t__mod__t__doc__R tretgetopttoperatortostbase.gtbaseRRRRRRtprntRRRRRRRR"R-R0tModuletNonetINTERACTIVE_MODEtGUI_MODEtUI_TOOLKIT_QT4tmodtsetUsagetUSAGE_FLAG_DEVICE_ARGSt parseStdOptstoptst device_urit printer_nametmodet ui_toolkittlangt getDeviceUritnetALIGN_TYPE_NONER RRtcanEnterGUIMode4RtDevicetdtErrortetmsgtopentisIdleAndNoErrortmqtgetR)tdebugtclosetALIGN_TYPE_UNSUPPORTEDtALIGN_TYPE_AUTOt AlignType1PMLtload_paper_prompttALIGN_TYPE_AIOt AlignType13tload_scanner_for_align_prompttALIGN_TYPE_8XXt AlignType2tALIGN_TYPE_9XXtALIGN_TYPE_9XX_NO_EDGE_ALIGNt AlignType3tupdate_spinnertALIGN_TYPE_LIDIL_AIOt AlignType6tALIGN_TYPE_DESKJET_450t AlignType8tALIGN_TYPE_LIDIL_0_3_8tALIGN_TYPE_LIDIL_0_4_3tALIGN_TYPE_LIDIL_VIPt AlignxBowtALIGN_TYPE_LBOWt AlignType10tALIGN_TYPE_LIDIL_0_5_4t AlignType11tALIGN_TYPE_OJ_PROt AlignType12tALIGN_TYPE_LIDIL_DJ_D1600t AlignType14tALIGN_TYPE_LEDMt AlignType15tALIGN_TYPE_LEDM_MANUALt AlignType16tALIGN_TYPE_LEDM_FF_CC_0t AlignType17t PyQt4.QtGuiR3tui4.aligndialogR4t ImportErrortargvtapptdlgtshowtexec_tKeyboardInterrupt(((sU/builds/ul11u3sru-gate/components/hplip/build/prototype/i386/usr/share/hplip/align.pytsÖ      .