GTK+ 2.x filechooser settings

If you despise the fact that in the latest versions of GTK+ the filechooser widget defaults to showing recent items, you might want to read further.

Such behaviour can be changed to show the current working directory (cwd) instead. That’s done by editing the contents of the gtkfilechooser.ini settings file.

Instead of:

StartupMode=recent

Have:

StartupMode=cwd

Under Windows the above mentioned settings file is available as either:

  • C:\Documents and Settings\{User}\Local Settings\Application Data\gtk-2.0\gtkfilechooser.ini, or
  • C:\Users\{User}\AppData\Local\gtk-2.0\gtkfilechooser.ini

Here are the full contents of mine:

[Filechooser Settings]
LocationMode=filename-entry
ShowHidden=false
ShowSizeColumn=true
GeometryX=311
GeometryY=212
GeometryWidth=818
GeometryHeight=475
SortColumn=name
SortOrder=ascending
StartupMode=cwd

Another value you might want to experiment with for LocationMode is “path-bar” 🙂

About luigidifraia

I am a Senior DevOps Engineer so I get to work with the latest technologies and open-source software. However, in my private time I enjoy retro-computing.
This entry was posted in Technical and tagged , . Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s