Package screenlets :: Package options :: Module file_option :: Class FileOption
[hide private]
[frames] | no frames]

Class FileOption

source code

object --+        
         |        
??.GObject --+    
             |    
   base.Option --+
                 |
                FileOption
Known Subclasses:

An Option-subclass for string-values that contain filenames. Adds a patterns-attribute that can contain a list of patterns to be shown in the assigned file selection dialog. The show_pixmaps-attribute can be set to True to make the filedialog show all image-types. supported by gtk.Pixmap. If the directory-attributue is true, the dialog will ony allow directories.

XXX - Some of this doen't yet work, unknown reason.

Instance Methods [hide private]
 
on_import(self, strvalue)
When a file is imported from the config.
source code
 
on_export(self, value)
When a file is exported to the config.
source code
 
generate_widget(self, value)
Generate a special widget for file options
source code
 
generate_file_opener(self)
Generate a file opener widget
source code
 
set_filters(self, dlg)
Add file filters to the dialog widget
source code
 
set_value(self, value)
Set the file value as required.
source code
 
has_changed(self, widget)
Executed when the widget event kicks off.
source code

Inherited from base.Option: __init__

Inherited from unreachable.GObject: __cmp__, __copy__, __deepcopy__, __delattr__, __gdoc__, __gobject_init__, __hash__, __new__, __repr__, __setattr__, chain, connect, connect_after, connect_object, connect_object_after, disconnect, disconnect_by_func, emit, emit_stop_by_name, freeze_notify, get_data, get_properties, get_property, handler_block, handler_block_by_func, handler_disconnect, handler_is_connected, handler_unblock, handler_unblock_by_func, notify, props, set_data, set_properties, set_property, stop_emission, thaw_notify, weak_ref

Inherited from object: __format__, __getattribute__, __reduce__, __reduce_ex__, __sizeof__, __str__, __subclasshook__

Class Variables [hide private]
  patterns = [('All Files', ['*'])]
  image = False
  _gtk_file_mode = <enum GTK_FILE_CHOOSER_ACTION_OPEN of type Gt...
  _opener_title = 'Vali fail'

Inherited from base.Option: __gsignals__, __gtype__, default, desc, disabled, hidden, label, protected, realtime, widget

Properties [hide private]

Inherited from unreachable.GObject: __grefcount__

Inherited from object: __class__

Method Details [hide private]

on_import(self, strvalue)

source code 

When a file is imported from the config.

Overrides: base.Option.on_import

on_export(self, value)

source code 

When a file is exported to the config.

Overrides: base.Option.on_export

generate_widget(self, value)

source code 

Generate a special widget for file options

Overrides: base.Option.generate_widget

set_value(self, value)

source code 

Set the file value as required.

Overrides: base.Option.set_value

has_changed(self, widget)

source code 

Executed when the widget event kicks off.

Overrides: base.Option.has_changed

Class Variable Details [hide private]

_gtk_file_mode

Value:
<enum GTK_FILE_CHOOSER_ACTION_OPEN of type GtkFileChooserAction>