#NEWLINE# def paintEvent( self , event ) : #NEWLINE# #INDENT# ' Reimplemented to draw the ComboBox frame and paint the image\n            centered in it.\n        ' #NEWLINE# painter = QtGui . QStylePainter ( self ) #NEWLINE# painter . setPen ( self . palette ( ) . color ( QtGui . QPalette . Text ) ) #NEWLINE# option = QtGui . QStyleOptionComboBox ( ) #NEWLINE# self . initStyleOption ( option ) #NEWLINE# painter . drawComplexControl ( QtGui . QStyle . CC_ComboBox , option ) #NEWLINE# editor = self . _editor #NEWLINE# pixmap = editor . get_pixmap ( editor . inverse_mapping [ editor . value ] ) #NEWLINE# arrow = self . style ( ) . subControlRect ( QtGui . QStyle . CC_ComboBox , option , QtGui . QStyle . SC_ComboBoxArrow , None ) #NEWLINE# option . rect . setWidth ( ( option . rect . width ( ) - arrow . width ( ) ) ) #NEWLINE# target = QtGui . QStyle . alignedRect ( QtCore . Qt . LeftToRight , QtCore . Qt . AlignCenter , pixmap . size ( ) , option . rect ) #NEWLINE# painter . drawPixmap ( target , option )