#NEWLINE# def add_line_edit( self , layout , field , config_key , config_desc , config_val ) : #NEWLINE# #INDENT# options = { #NEWLINE# #INDENT# #NEWLINE# #UNINDENT# } #NEWLINE# if ( field . widget_options is not None ) : #NEWLINE# #INDENT# options = field . widget_options #NEWLINE# #UNINDENT# if ( 'label' in options ) : #NEWLINE# #INDENT# label_text = options [ 'label' ] #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# label_text = config_desc #NEWLINE# #UNINDENT# label = QtGui . QLabel ( label_text ) #NEWLINE# row = layout . rowCount ( ) #NEWLINE# layout . addWidget ( label , row , 0 , QtCore . Qt . AlignRight ) #NEWLINE# line_edit = QtGui . QLineEdit ( ) #NEWLINE# self . set_line_edit_value ( line_edit , config_val ) #NEWLINE# layout . addWidget ( line_edit , row , 1 ) #NEWLINE# def call_field_changed( ) : #NEWLINE# #INDENT# val = line_edit . text ( ) #NEWLINE# self . field_changed ( config_key , field , val , config_val ) #NEWLINE# #UNINDENT# line_edit . editingFinished . connect ( call_field_changed ) #NEWLINE# return options