~ubuntu-branches/ubuntu/natty/pygtk/natty-proposed

« back to all changes in this revision

Viewing changes to docs/html/class-gtkfilechooser.html

  • Committer: Bazaar Package Importer
  • Author(s): Sebastien Bacher
  • Date: 2009-06-22 16:49:42 UTC
  • mfrom: (1.2.6 upstream)
  • Revision ID: james.westby@ubuntu.com-20090622164942-19zeltp4z0u5iw72
Tags: 2.15.2-0ubuntu1
* New upstream version:
  - Rename gtk.Statusbar.remove() to gtk.Statusbar.remove_message
  - Allow pango.Context creation 
  - Make gtk.gdk.Pixbuf.add_alpha accept integers, retaining backward
    compatibility accepting also chars 
  - Protect window obj from GC in gtk.window_get_toplevels 
  - Plug huge number of memory leaks in Pango wrappers 
  - Add gtk.gdk.WINDOWING constant 
  - Wrap gdk_pixbuf_apply_embedded_orientation 
  - Modernize constructors of seven more types 
  - Don't free a string we don't own 
  - Some docs tweaking 
* debian/control.in:
  - set vcs location
* debian/patches/02_fix_get_application_info_crash.patch:
  - the change is in the new version

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
<html><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8"><title>gtk.FileChooser</title><link rel="stylesheet" href="style.css" type="text/css"><meta name="generator" content="DocBook XSL Stylesheets V1.73.2"><link rel="start" href="index.html" title="PyGTK 2.0 Reference Manual"><link rel="up" href="gtk-class-reference.html" title="The gtk Class Reference"><link rel="prev" href="class-gtkexpander.html" title="gtk.Expander"><link rel="next" href="class-gtkfilechooserbutton.html" title="gtk.FileChooserButton"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">gtk.FileChooser</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="class-gtkexpander.html">Prev</a> </td><th width="60%" align="center">The gtk Class Reference</th><td width="20%" align="right"> <a accesskey="n" href="class-gtkfilechooserbutton.html">Next</a></td></tr></table><hr></div><div class="refentry" lang="en"><a name="class-gtkfilechooser"></a><div class="titlepage"></div><div class="refnamediv"><h2>gtk.FileChooser</h2><p>gtk.FileChooser — an interface for choosing files used by <a class="link" href="class-gtkfilechooserwidget.html" title="gtk.FileChooserWidget"><code class="classname">gtk.FileChooserWidget</code></a>
2
2
    and <a class="link" href="class-gtkfilechooserdialog.html" title="gtk.FileChooserDialog"><code class="classname">gtk.FileChooserDialog</code></a>
3
 
    (new in PyGTK 2.4)</p></div><div class="refsect1" lang="en"><a name="id3467135"></a><h2>Synopsis</h2><table bgcolor="#D0E0F0" width="100%"><tr><td><pre class="classsynopsis">class <span class="ooclass"><span class="classname">gtk.FileChooser</span></span>(<span class="ooclass"><span class="classname">gobject.GInterface</span></span>):
 
3
    (new in PyGTK 2.4)</p></div><div class="refsect1" lang="en"><a name="id3667941"></a><h2>Synopsis</h2><table bgcolor="#D0E0F0" width="100%"><tr><td><pre class="classsynopsis">class <span class="ooclass"><span class="classname">gtk.FileChooser</span></span>(<span class="ooclass"><span class="classname">gobject.GInterface</span></span>):
4
4
<code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--set-action" title="gtk.FileChooser.set_action">set_action</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>action</code></strong></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--get-action" title="gtk.FileChooser.get_action">get_action</a></span>(<span class="methodparam"></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--set-local-only" title="gtk.FileChooser.set_local_only">set_local_only</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>local_only</code></strong></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--get-local-only" title="gtk.FileChooser.get_local_only">get_local_only</a></span>(<span class="methodparam"></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--set-select-multiple" title="gtk.FileChooser.set_select_multiple">set_select_multiple</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>select_multiple</code></strong></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--get-select-multiple" title="gtk.FileChooser.get_select_multiple">get_select_multiple</a></span>(<span class="methodparam"></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--set-current-name" title="gtk.FileChooser.set_current_name">set_current_name</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>name</code></strong></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--get-filename" title="gtk.FileChooser.get_filename">get_filename</a></span>(<span class="methodparam"></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--set-filename" title="gtk.FileChooser.set_filename">set_filename</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>filename</code></strong></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--select-filename" title="gtk.FileChooser.select_filename">select_filename</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>filename</code></strong></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--unselect-filename" title="gtk.FileChooser.unselect_filename">unselect_filename</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>filename</code></strong></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--select-all" title="gtk.FileChooser.select_all">select_all</a></span>(<span class="methodparam"></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--unselect-all" title="gtk.FileChooser.unselect_all">unselect_all</a></span>(<span class="methodparam"></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--get-filenames" title="gtk.FileChooser.get_filenames">get_filenames</a></span>(<span class="methodparam"></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--set-current-folder" title="gtk.FileChooser.set_current_folder">set_current_folder</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>filename</code></strong></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--get-current-folder" title="gtk.FileChooser.get_current_folder">get_current_folder</a></span>(<span class="methodparam"></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--get-uri" title="gtk.FileChooser.get_uri">get_uri</a></span>(<span class="methodparam"></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--set-uri" title="gtk.FileChooser.set_uri">set_uri</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>uri</code></strong></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--select-uri" title="gtk.FileChooser.select_uri">select_uri</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>uri</code></strong></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--unselect-uri" title="gtk.FileChooser.unselect_uri">unselect_uri</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>uri</code></strong></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--get-uris" title="gtk.FileChooser.get_uris">get_uris</a></span>(<span class="methodparam"></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--set-current-folder-uri" title="gtk.FileChooser.set_current_folder_uri">set_current_folder_uri</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>uri</code></strong></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--get-current-folder-uri" title="gtk.FileChooser.get_current_folder_uri">get_current_folder_uri</a></span>(<span class="methodparam"></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--set-preview-widget" title="gtk.FileChooser.set_preview_widget">set_preview_widget</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>preview_widget</code></strong></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--get-preview-widget" title="gtk.FileChooser.get_preview_widget">get_preview_widget</a></span>(<span class="methodparam"></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--set-preview-widget-active" title="gtk.FileChooser.set_preview_widget_active">set_preview_widget_active</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>active</code></strong></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--get-preview-widget-active" title="gtk.FileChooser.get_preview_widget_active">get_preview_widget_active</a></span>(<span class="methodparam"></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--set-use-preview-label" title="gtk.FileChooser.set_use_preview_label">set_use_preview_label</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>use_label</code></strong></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--get-use-preview-label" title="gtk.FileChooser.get_use_preview_label">get_use_preview_label</a></span>(<span class="methodparam"></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--get-preview-filename" title="gtk.FileChooser.get_preview_filename">get_preview_filename</a></span>(<span class="methodparam"></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--get-preview-uri" title="gtk.FileChooser.get_preview_uri">get_preview_uri</a></span>(<span class="methodparam"></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--set-extra-widget" title="gtk.FileChooser.set_extra_widget">set_extra_widget</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>extra_widget</code></strong></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--get-extra-widget" title="gtk.FileChooser.get_extra_widget">get_extra_widget</a></span>(<span class="methodparam"></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--add-filter" title="gtk.FileChooser.add_filter">add_filter</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>filter</code></strong></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--remove-filter" title="gtk.FileChooser.remove_filter">remove_filter</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>filter</code></strong></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--list-filters" title="gtk.FileChooser.list_filters">list_filters</a></span>(<span class="methodparam"></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--set-filter" title="gtk.FileChooser.set_filter">set_filter</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>filter</code></strong></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--get-filter" title="gtk.FileChooser.get_filter">get_filter</a></span>(<span class="methodparam"></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--add-shortcut-folder" title="gtk.FileChooser.add_shortcut_folder">add_shortcut_folder</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>folder</code></strong></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--remove-shortcut-folder" title="gtk.FileChooser.remove_shortcut_folder">remove_shortcut_folder</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>folder</code></strong></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--list-shortcut-folders" title="gtk.FileChooser.list_shortcut_folders">list_shortcut_folders</a></span>(<span class="methodparam"></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--add-shortcut-folder-uri" title="gtk.FileChooser.add_shortcut_folder_uri">add_shortcut_folder_uri</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>uri</code></strong></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--remove-shortcut-folder-uri" title="gtk.FileChooser.remove_shortcut_folder_uri">remove_shortcut_folder_uri</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>uri</code></strong></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--list-shortcut-folder-uris" title="gtk.FileChooser.list_shortcut_folder_uris">list_shortcut_folder_uris</a></span>(<span class="methodparam"></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--set-show-hidden" title="gtk.FileChooser.set_show_hidden">set_show_hidden</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>show_hidden</code></strong></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--get-show-hidden" title="gtk.FileChooser.get_show_hidden">get_show_hidden</a></span>(<span class="methodparam"></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--set-do-overwrite-confirmation" title="gtk.FileChooser.set_do_overwrite_confirmation">set_do_overwrite_confirmation</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>do_overwrite_confirmation</code></strong></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--get-do-overwrite-confirmation" title="gtk.FileChooser.get_do_overwrite_confirmation">get_do_overwrite_confirmation</a></span>(<span class="methodparam"></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--get-current-folder-file" title="gtk.FileChooser.get_current_folder_file">get_current_folder_file</a></span>(<span class="methodparam"></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--get-file" title="gtk.FileChooser.get_file">get_file</a></span>(<span class="methodparam"></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--get-preview-file" title="gtk.FileChooser.get_preview_file">get_preview_file</a></span>(<span class="methodparam"></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--select-file" title="gtk.FileChooser.select_file">select_file</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>file</code></strong></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--set-current-folder-file" title="gtk.FileChooser.set_current_folder_file">set_current_folder_file</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>file</code></strong></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--set-file" title="gtk.FileChooser.set_file">set_file</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>file</code></strong></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--unselect-file" title="gtk.FileChooser.unselect_file">unselect_file</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>file</code></strong></span></span>)</code><br></pre></td></tr></table></div><div class="refsect1" lang="en"><a name="properties-gtkfilechooser"></a><h2>gtk.FileChooser Properties</h2><div class="blockquote"><table width="100%" border="0" bgcolor="#E0E0E0"><tr><td valign="top"><div class="informaltable"><table width="100%" border="0"><colgroup><col><col><col></colgroup><tbody><tr valign="top"><td valign="top">"action"</td><td valign="top">Read-Write</td><td valign="top">The type of operation that the file selector is
5
5
              performing - one of the <a class="xref" href="gtk-constants.html#gtk-filechooser-action-constants" title="GTK FileChooser Action Constants">GTK FileChooser Action Constants</a>. Default
6
6
              value: <code class="literal">gtk.FILE_CHOOSER_ACTION_OPEN</code></td></tr><tr valign="top"><td valign="top">"do-overwrite-confirmation"</td><td valign="top">Read-Write</td><td valign="top">If <code class="literal">True</code> a file chooser in
20
20
              "action" property. Default value:
21
21
<code class="literal">False</code></td></tr><tr valign="top"><td valign="top">"show-hidden"</td><td valign="top">Read-Write</td><td valign="top">If <code class="literal">True</code>, hidden files and folders
22
22
should be displayed. Default value: <code class="literal">False</code></td></tr><tr valign="top"><td valign="top">"use-preview-label"</td><td valign="top">Read-Write</td><td valign="top">If <code class="literal">True</code>, display a stock label with
23
 
the name of the previewed file. Default value: <code class="literal">True</code></td></tr></tbody></table></div></td></tr></table></div></div><div class="refsect1" lang="en"><a name="signal-prototypes-gtkfilechooser"></a><h2>gtk.FileChooser Signal Prototypes</h2><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><p><span class="term">"<a class="link" href="class-gtkfilechooser.html#signal-gtkfilechooser--confirm-overwrite" title='The "confirm-overwrite" gtk.FileChooser Signal'>confirm-overwrite</a>"</span></p></td><td><code class="methodsynopsis">    def <span class="methodname">callback</span>(<span class="methodparam"><span class="parameter"><em class="parameter"><code>filechooser</code></em></span></span>, <span class="methodparam"><span class="parameter"><em class="parameter"><code>user_param1</code></em></span></span>, <span class="methodparam"><span class="parameter"><em class="parameter"><code>...</code></em></span></span>)</code></td></tr><tr><td><p><span class="term">"<a class="link" href="class-gtkfilechooser.html#signal-gtkfilechooser--current-folder-changed" title='The "current-folder-changed" gtk.FileChooser Signal'>current-folder-changed</a>"</span></p></td><td><code class="methodsynopsis">    def <span class="methodname">callback</span>(<span class="methodparam"><span class="parameter"><em class="parameter"><code>filechooser</code></em></span></span>, <span class="methodparam"><span class="parameter"><em class="parameter"><code>user_param1</code></em></span></span>, <span class="methodparam"><span class="parameter"><em class="parameter"><code>...</code></em></span></span>)</code></td></tr><tr><td><p><span class="term">"<a class="link" href="class-gtkfilechooser.html#signal-gtkfilechooser--file-activated" title='The "file-activated" gtk.FileChooser Signal'>file-activated</a>"</span></p></td><td><code class="methodsynopsis">    def <span class="methodname">callback</span>(<span class="methodparam"><span class="parameter"><em class="parameter"><code>filechooser</code></em></span></span>, <span class="methodparam"><span class="parameter"><em class="parameter"><code>user_param1</code></em></span></span>, <span class="methodparam"><span class="parameter"><em class="parameter"><code>...</code></em></span></span>)</code></td></tr><tr><td><p><span class="term">"<a class="link" href="class-gtkfilechooser.html#signal-gtkfilechooser--selection-changed" title='The "selection-changed" gtk.FileChooser Signal'>selection-changed</a>"</span></p></td><td><code class="methodsynopsis">    def <span class="methodname">callback</span>(<span class="methodparam"><span class="parameter"><em class="parameter"><code>filechooser</code></em></span></span>, <span class="methodparam"><span class="parameter"><em class="parameter"><code>user_param1</code></em></span></span>, <span class="methodparam"><span class="parameter"><em class="parameter"><code>...</code></em></span></span>)</code></td></tr><tr><td><p><span class="term">"<a class="link" href="class-gtkfilechooser.html#signal-gtkfilechooser--update-preview" title='The "update-preview" gtk.FileChooser Signal'>update-preview</a>"</span></p></td><td><code class="methodsynopsis">    def <span class="methodname">callback</span>(<span class="methodparam"><span class="parameter"><em class="parameter"><code>filechooser</code></em></span></span>, <span class="methodparam"><span class="parameter"><em class="parameter"><code>user_param1</code></em></span></span>, <span class="methodparam"><span class="parameter"><em class="parameter"><code>...</code></em></span></span>)</code></td></tr></tbody></table></div><div class="refsect1" lang="en"><a name="id3469194"></a><h2>Description</h2><div class="note" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Note</h3><p>This interface is available in PyGTK 2.4 and above.</p></div><p><a class="link" href="class-gtkfilechooser.html" title="gtk.FileChooser"><code class="classname">gtk.FileChooser</code></a>
 
23
the name of the previewed file. Default value: <code class="literal">True</code></td></tr></tbody></table></div></td></tr></table></div></div><div class="refsect1" lang="en"><a name="signal-prototypes-gtkfilechooser"></a><h2>gtk.FileChooser Signal Prototypes</h2><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><p><span class="term">"<a class="link" href="class-gtkfilechooser.html#signal-gtkfilechooser--confirm-overwrite" title='The "confirm-overwrite" gtk.FileChooser Signal'>confirm-overwrite</a>"</span></p></td><td><code class="methodsynopsis">    def <span class="methodname">callback</span>(<span class="methodparam"><span class="parameter"><em class="parameter"><code>filechooser</code></em></span></span>, <span class="methodparam"><span class="parameter"><em class="parameter"><code>user_param1</code></em></span></span>, <span class="methodparam"><span class="parameter"><em class="parameter"><code>...</code></em></span></span>)</code></td></tr><tr><td><p><span class="term">"<a class="link" href="class-gtkfilechooser.html#signal-gtkfilechooser--current-folder-changed" title='The "current-folder-changed" gtk.FileChooser Signal'>current-folder-changed</a>"</span></p></td><td><code class="methodsynopsis">    def <span class="methodname">callback</span>(<span class="methodparam"><span class="parameter"><em class="parameter"><code>filechooser</code></em></span></span>, <span class="methodparam"><span class="parameter"><em class="parameter"><code>user_param1</code></em></span></span>, <span class="methodparam"><span class="parameter"><em class="parameter"><code>...</code></em></span></span>)</code></td></tr><tr><td><p><span class="term">"<a class="link" href="class-gtkfilechooser.html#signal-gtkfilechooser--file-activated" title='The "file-activated" gtk.FileChooser Signal'>file-activated</a>"</span></p></td><td><code class="methodsynopsis">    def <span class="methodname">callback</span>(<span class="methodparam"><span class="parameter"><em class="parameter"><code>filechooser</code></em></span></span>, <span class="methodparam"><span class="parameter"><em class="parameter"><code>user_param1</code></em></span></span>, <span class="methodparam"><span class="parameter"><em class="parameter"><code>...</code></em></span></span>)</code></td></tr><tr><td><p><span class="term">"<a class="link" href="class-gtkfilechooser.html#signal-gtkfilechooser--selection-changed" title='The "selection-changed" gtk.FileChooser Signal'>selection-changed</a>"</span></p></td><td><code class="methodsynopsis">    def <span class="methodname">callback</span>(<span class="methodparam"><span class="parameter"><em class="parameter"><code>filechooser</code></em></span></span>, <span class="methodparam"><span class="parameter"><em class="parameter"><code>user_param1</code></em></span></span>, <span class="methodparam"><span class="parameter"><em class="parameter"><code>...</code></em></span></span>)</code></td></tr><tr><td><p><span class="term">"<a class="link" href="class-gtkfilechooser.html#signal-gtkfilechooser--update-preview" title='The "update-preview" gtk.FileChooser Signal'>update-preview</a>"</span></p></td><td><code class="methodsynopsis">    def <span class="methodname">callback</span>(<span class="methodparam"><span class="parameter"><em class="parameter"><code>filechooser</code></em></span></span>, <span class="methodparam"><span class="parameter"><em class="parameter"><code>user_param1</code></em></span></span>, <span class="methodparam"><span class="parameter"><em class="parameter"><code>...</code></em></span></span>)</code></td></tr></tbody></table></div><div class="refsect1" lang="en"><a name="id3670000"></a><h2>Description</h2><div class="note" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Note</h3><p>This interface is available in PyGTK 2.4 and above.</p></div><p><a class="link" href="class-gtkfilechooser.html" title="gtk.FileChooser"><code class="classname">gtk.FileChooser</code></a>
24
24
is an interface that can be implemented by file selection widgets. In PyGTK,
25
25
the main objects that implement this interface are <a class="link" href="class-gtkfilechooserwidget.html" title="gtk.FileChooserWidget"><code class="classname">gtk.FileChooserWidget</code></a>
26
26
and <a class="link" href="class-gtkfilechooserdialog.html" title="gtk.FileChooserDialog"><code class="classname">gtk.FileChooserDialog</code></a>. You
78
78
    file_chooser.set_preview_widget_active(have_preview)
79
79
    return
80
80
  ...
81
 
</pre></div><div class="refsect2" lang="en"><a name="id3469471"></a><h3>Adding Extra Widgets</h3><p> You can add extra widgets to a file chooser to provide options
 
81
</pre></div><div class="refsect2" lang="en"><a name="id3670277"></a><h3>Adding Extra Widgets</h3><p> You can add extra widgets to a file chooser to provide options
82
82
that are not present in the default design. For example, you can add a <a class="link" href="class-gtktogglebutton.html" title="gtk.ToggleButton"><code class="classname">gtk.ToggleButton</code></a>
83
83
to give the user the option to open a file in read-only mode. You can use
84
84
the <a class="link" href="class-gtkfilechooser.html#method-gtkfilechooser--set-extra-widget" title="gtk.FileChooser.set_extra_widget"><code class="methodname">set_extra_widget</code>()</a>
88
88
  my_file_chooser.set_extra_widget(toggle)
89
89
</pre><p> If you want to set more than one extra widget in the file
90
90
chooser, you can use a container such as a <a class="link" href="class-gtkvbox.html" title="gtk.VBox"><code class="classname">gtk.VBox</code></a> or a <a class="link" href="class-gtktable.html" title="gtk.Table"><code class="classname">gtk.Table</code></a> to hold
91
 
your widgets; then set the container as the whole extra widget.</p></div><div class="refsect2" lang="en"><a name="id3469532"></a><h3>Key Bindings</h3><p>The <a class="link" href="class-gtkfilechooserdialog.html" title="gtk.FileChooserDialog"><code class="classname">gtk.FileChooserDialog</code></a>
 
91
your widgets; then set the container as the whole extra widget.</p></div><div class="refsect2" lang="en"><a name="id3670338"></a><h3>Key Bindings</h3><p>The <a class="link" href="class-gtkfilechooserdialog.html" title="gtk.FileChooserDialog"><code class="classname">gtk.FileChooserDialog</code></a>
92
92
uses the private <code class="classname">GtkFileChooserDefaultClass</code> that has
93
93
several key bindings and their associated signals. This section describes
94
94
the available key binding signals.</p><p>The default keys that activate the key-binding signals in GtkFileChooserDefaultClass are as follows:</p><div class="informaltable"><table width="100%" border="0"><colgroup><col><col></colgroup><thead><tr><th>Signal name</th><th>Key</th></tr></thead><tbody><tr><td>location-popup</td><td>Control-L</td></tr><tr><td>up-folder</td><td>Alt-Up</td></tr><tr><td>down-folder</td><td>Alt-Down</td></tr><tr><td>home-folder</td><td>Alt-Home</td></tr></tbody></table></div><p>To change these defaults to something else, you could include
140
140
  def home_folder_cb(filechooser, user_data):
141
141
</pre><p>where <em class="parameter"><code>filechooser</code></em> is the object that
142
142
received the signal and <em class="parameter"><code>user_data</code></em> is the user data
143
 
set when the signal handler was connected.</p></div></div><div class="refsect1" lang="en"><a name="id3469873"></a><h2>Methods</h2><div class="refsect2" lang="en"><a name="method-gtkfilechooser--set-action"></a><h3>gtk.FileChooser.set_action</h3><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">set_action</span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>action</code></strong></span></span>)</code></pre><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><p><span class="term"><strong class="parameter"><code>action</code></strong> :</span></p></td><td>the file selection action - one of:
 
143
set when the signal handler was connected.</p></div></div><div class="refsect1" lang="en"><a name="id3670679"></a><h2>Methods</h2><div class="refsect2" lang="en"><a name="method-gtkfilechooser--set-action"></a><h3>gtk.FileChooser.set_action</h3><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">set_action</span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>action</code></strong></span></span>)</code></pre><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><p><span class="term"><strong class="parameter"><code>action</code></strong> :</span></p></td><td>the file selection action - one of:
144
144
<code class="literal">gtk.FILE_CHOOSER_ACTION_OPEN</code>,
145
145
<code class="literal">gtk.FILE_CHOOSER_ACTION_SAVE</code>,
146
146
<code class="literal">gtk.FILE_CHOOSER_ACTION_SELECT_FOLDER</code> or
498
498
        The <code class="methodname">unselect_file</code>() method
499
499
        unselects the file referred to by file. If the file is not in the current
500
500
        directory, does not exist, or is otherwise not currently selected, does nothing.
501
 
      </p></div></div><div class="refsect1" lang="en"><a name="id3475623"></a><h2>Signals</h2><div class="refsect2" lang="en"><a name="signal-gtkfilechooser--confirm-overwrite"></a><h3>The "confirm-overwrite" gtk.FileChooser Signal</h3><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">callback</span>(<span class="methodparam"><span class="parameter"><em class="parameter"><code>filechooser</code></em></span></span>, <span class="methodparam"><span class="parameter"><em class="parameter"><code>user_param1</code></em></span></span>, <span class="methodparam"><span class="parameter"><em class="parameter"><code>...</code></em></span></span>)</code></pre><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><p><span class="term"><em class="parameter"><code>filechooser</code></em> :</span></p></td><td>the filechooser widget that received the
 
501
      </p></div></div><div class="refsect1" lang="en"><a name="id3676430"></a><h2>Signals</h2><div class="refsect2" lang="en"><a name="signal-gtkfilechooser--confirm-overwrite"></a><h3>The "confirm-overwrite" gtk.FileChooser Signal</h3><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">callback</span>(<span class="methodparam"><span class="parameter"><em class="parameter"><code>filechooser</code></em></span></span>, <span class="methodparam"><span class="parameter"><em class="parameter"><code>user_param1</code></em></span></span>, <span class="methodparam"><span class="parameter"><em class="parameter"><code>...</code></em></span></span>)</code></pre><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><p><span class="term"><em class="parameter"><code>filechooser</code></em> :</span></p></td><td>the filechooser widget that received the
502
502
signal</td></tr><tr><td><p><span class="term"><em class="parameter"><code>user_param1</code></em> :</span></p></td><td>the first user parameter (if any) specified
503
503
with the <PYGTKDOCLINK HREF="method-gobject--connect"><code class="methodname">connect</code>()</PYGTKDOCLINK>
504
504
method</td></tr><tr><td><p><span class="term"><em class="parameter"><code>...</code></em> :</span></p></td><td>additional user parameters (if