KGtk

A quick-and-dirty LD_PRELOAD hack that allows *some* Gtk applications to use KDE's file dialogs.
Download

KGtk Ranking & Summary

Advertisement

  • Rating:
  • License:
  • GPL
  • Price:
  • FREE
  • Publisher Name:
  • Craig Drummond
  • Publisher web site:
  • http://www.kde-apps.org/content/show.php/KGtk+(Use+KDE+Dialogs+in+Gtk+Apps)?content=36077

KGtk Tags


KGtk Description

A quick-and-dirty LD_PRELOAD hack that allows *some* Gtk applications to use KDE's file dialogs. KGtk project is a quick-and-dirty LD_PRELOAD hack that allows *some* Gtk applications to use KDE's file dialogs when run under KDE. The Gtk file chooser functions have been overridden to communicate with this KDE module/application. After compiling and installing this, you can run Gtk applications in 2 ways: A. call /usr/local/bin/kgtk-wrapper gimp B. i. Create a symbolic link from the wrapper script to your application, e.g.ln -s /usr/local/bin/kgtk-wrapper /usr/local/bin/gimpii. Make sure /usr/local/bin is before /usr/bin (or wherever gimp is installed) in your $PATHiii. Now simply run 'gimp' - this should find the wrapper script first. If this works OK, then edit the .desktop file (e.g. /usr/share/applications/gimp.desktop) to have "Exec=/usr/local/bin/" instead of "Exec=", e.g. for gimp.desktop this would be: Exec=/usr/local/bin/gimp-remote-2.2 %Uor:Exec=/usr/local/bin/kgtk-wrapper gimp-remote-2.2 %USo far I have tested this with the following applications:1. Kino. Works perfectly - in fact Kino was my main reason for doing this.2. Firefox. Works with Firefox 1.5, but *not* Firefox 1.0.x3. GIMP. Again, seems to work just fine. However, there is no progress bar on file loading - as GIMP uses a progress bar embedded in the file chooser.4. Inkscape. Works OK - at least 0.435. Streamtuner - the folder browser button works.6. AbiWord - does *not* work. Don't even try...7. Glade2. Seems to work OK, however I have had it crash when loading Kino's .glade file, but not always. So I'm not sure if this is Glade's fault, or mine.8. Eclipse. Will work only if dlsym can be overriden As the only Gtk apps I use are Kino, GIMP, and a little of Firefox, this library works great for me. Your millage may vary, and please note that this is only a quick hack to get things working now for me. I'm not sure how stable it will be under heavy usage, so don't be surprised if it breaks. However, if it does break - the only thing that should happen is that the Gtk apps will fall back to using the standard Gtk dialogs. The 'Portland' freedesktop project will undoubtedly come up with a far better solution. But until then, you can give this a try. What's New in This Release: · Fix 'kgtk-wrapper ./app' case. · Set filename for KdialogD4's save as filedialog. · Hacky fix for Firefox crashing when trying to save to a file that already exists -> delete it first! · When launching KDialogD, try todetermin which version is installed. · Add some compile fixes from kde-apps


KGtk Related Software