def get_display(self):
    top = SpanWdg()
    field_list_option = self.get_option('field_list')
    if (not field_list_option):
        self.set_configuration_error(top, "No 'field_list' option provided")
        return top
    top.add('&nbsp; matches')
    stmt = ('field_info_list = %s' % field_list_option.replace('\n', ' '))
    try:
        exec(stmt)
    except:
        self.set_configuration_error(top, "badly formed 'field_list' option")
        return top
    default_size = 10
    for field_info in field_info_list:
        field = field_info.get('field')
        if field:
            text = TextWdg(field)
            size = field_info.get('size')
            if (not size):
                size = default_size
            text.add_attr('size', ('%s' % size))
            maxlength = field_info.get('maxlength')
            if maxlength:
                text.add_attr('maxlength', ('%s' % maxlength))
            label = field_info.get('label')
            if label:
                top.add(('&nbsp;&nbsp;&nbsp;%s: ' % label))
            top.add(text)
    return top
def get_display(self):
    top = SpanWdg()
    field_list_option = self.get_option('field_list')
    if (not field_list_option):
        self.set_configuration_error(top, "No 'field_list' option provided")
        return top
    top.add('&nbsp; matches')
    stmt = ('field_info_list = %s' % field_list_option.replace('\n', ' '))
    try:
        exec(stmt)
    except:
        self.set_configuration_error(top, "badly formed 'field_list' option")
        return top
    default_size = 10
    for field_info in field_info_list:
        field = field_info.get('field')
        if field:
            text = TextWdg(field)
            size = field_info.get('size')
            if (not size):
                size = default_size
            text.add_attr('size', ('%s' % size))
            maxlength = field_info.get('maxlength')
            if maxlength:
                text.add_attr('maxlength', ('%s' % maxlength))
            label = field_info.get('label')
            if label:
                top.add(('&nbsp;&nbsp;&nbsp;%s: ' % label))
            top.add(text)
    return top