GTK File Chooser Expanded by Default
Monday, March 13. 2006
Ever felt annoyed by that stupid GTK 2.x file chooser, which hides the folders by default and you have to click on Browse for other folders each time you wish to save a file in a folder other than the few provided in that weird Save in folder drop down list?
And of course it's once again the "Users are stupid" mentality of Gnome, which even does not offer an option for the user to have it expanded by default. So I googled and found a description along with a patch for Gentoo, which expands the folders in the GTK file chooser dialog by default.
I applied this patch to the SuSE 10.0 source RPM and it works. Here is my description on how to create a RPM including the patch and for the people who trust me I also offer the patched RPMs for download.
HOW TO CREATE A PATCHED RPM
The following has been tested with GTK+ 2.8.3 on SuSE Linux 10.0. I guess it may work on other distributions with other versions of GTK, too, since the patch is very, very simple.
- Create the following directories:
- ~/packages/BUILD
- ~/packages/RPMS
- ~/packages/RPMS/i586
- ~/packages/SOURCES
- ~/packages/SPECS
- ~/packages/SRPMS
- ~/packages/tmp
- Install the SuSE GTK source RPM file:
rpm -ihv gtk2-2.8.3-4.src.rpm. cd ~/packages/SOURCES- Extract the source archive:
tar jxvf gtk+-2.8.3.tar.bz2 cd gtk+-2.8.3- Download the patch into the directory
~/packages/SOURCES/gtk+-2.8.3or simply use wget:wget http://twc.sshunet.nl/~mpsindla/files/gtk+-dialog.patch - Apply the patch:
patch -p1 < gtk+-dialog.patch - Go back to the sources directory:
cd ..and create a new source code archive that contains the patched files:tar jcvf gtk+-2.8.3.tar.bz2 gtk+-2.8.3. - Create the new RPM files:
rpmbuild -ba ~/packages/SPECS/gtk2.spec - Go and get a cup of coffee
- If everything succeeds you should get three RPM files in the directory
~/packages/RPMS/i586:- gtk2-2.8.3-4.i586.rpm
- gtk2-devel-2.8.3-4.i586.rpm
- gtk2-doc-2.8.3-4.i586.rpm
- Install these RPMs:
rpm -ihv --force ~/packages/RPMS/i586/gtk2-*(the option--forceis necessary to force RPM to reinstall the packages since you already have them installed on your system most probably)
If you managed to create a patched RPM for other versions of SuSE Linux or other distributions and are able to provide your packages for download feel free to add a comment with your download links.
And finally for the people with SuSE 10.0 who do not want to compile GTK here are my RPM packages:
Trackbacks
Trackback specific URI for this entry



Comments