Skip to content
Snippets Groups Projects
Commit 6cd341ad authored by Yann Leboulanger's avatar Yann Leboulanger
Browse files

show required field in a dataform with an *

parent 39f96a92
No related branches found
No related tags found
No related merge requests found
......@@ -555,8 +555,13 @@ class SingleForm(gtk.Table, object):
widget.set_sensitive(readwrite)
widget = decorate_with_tooltip(widget, field)
self.attach(widget, 1, 2, linecounter, linecounter+1,
yoptions=gtk.FILL)
widget.show_all()
yoptions=gtk.FILL)
if field.required:
label = gtk.Label('*')
label.set_tooltip_text(_('This field is required'))
self.attach(label, 2, 3, linecounter, linecounter+1, xoptions=0,
yoptions=0)
linecounter+=1
if self.get_property('visible'):
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment