-
 KDE-Apps.org Applications for the KDE-Desktop 
 GTK-Apps.org Applications using the GTK Toolkit 
 GnomeFiles.org Applications for GNOME 
 MeeGo-Central.org Applications for MeeGo 
 CLI-Apps.org Command Line Applications 
 Qt-Apps.org Free Qt Applications 
 Qt-Prop.org Proprietary Qt Applications 
 Maemo-Apps.org Applications for the Maemo Plattform 
 Java-Apps.org Free Java Applications 
 eyeOS-Apps.org Free eyeOS Applications 
 Wine-Apps.org Wine Applications 
 Server-Apps.org Server Applications 
 apps.ownCloud.com ownCloud Applications 
--
-
 KDE-Look.org Artwork for the KDE-Desktop 
 GNOME-Look.org Artwork for the GNOME-Desktop 
 Xfce-Look.org Artwork for the Xfce-Desktop 
 Box-Look.org Artwork for your Windowmanager 
 E17-Stuff.org Artwork for Enlightenment 
 Beryl-Themes.org Artwork for the Beryl Windowmanager 
 Compiz-Themes.org Artwork for the Compiz Windowmanager 
 EDE-Look.org Themes for your EDE Desktop 
--
-
 Debian-Art.org Stuff for Debian 
 Gentoo-Art.org Artwork for Gentoo Linux 
 SUSE-Art.org Artwork for openSUSE 
 Ubuntu-Art.org Artwork for Ubuntu 
 Kubuntu-Art.org Artwork for Kubuntu 
 LinuxMint-Art.org Artwork for Linux Mint 
 Arch-Stuff.org Art And Stuff for Arch Linux 
 Frugalware-Art.org Themes for Frugalware 
 Fedora-Art.org Artwork for Fedora Linux 
 Mandriva-Art.org Artwork for Mandriva Linux 
--
-
 KDE-Files.org Files for KDE Applications 
 OpenTemplate.org Documents for OpenOffice.org
 GIMPStuff.org Files for GIMP
 InkscapeStuff.org Files for Inkscape
 ScribusStuff.org Files for Scribus
 BlenderStuff.org Textures and Objects for Blender
 VLC-Addons.org Themes and Extensions for VLC
--
-
 KDE-Help.org Support for your KDE Desktop 
 GNOME-Help.org Support for your GNOME Desktop 
 Xfce-Help.org Support for your Xfce Desktop 
--
openDesktop.orgopenDesktop.org:   Applications   Artwork   Linux Distributions   Documents    LinuxDaily.com    Linux42.org    OpenSkillz.com   
 
Apps
News
Groups
Knowledge
Events
Forum
People
Jobs
Register
Login


Sponsoring


-
- Content .- Fans (12) . 

KGtk (Use KDE Dialogs in Gtk Apps)

   0.11.0  

KDE Improvement

Score 85%
KGtk (Use KDE Dialogs in Gtk Apps)
zoom


KGtk (Use KDE Dialogs in Gtk Apps)
zoom


KGtk (Use KDE Dialogs in Gtk Apps)
zoom


Link:  http://
Downloads:  17069
Submitted:  Mar 6 2006
Updated:  Nov 3 2011

Description:

This 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/gimp
ii. Make sure /usr/local/bin is before /usr/bin (or wherever gimp is installed) in your $PATH
iii. 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/[appname]" instead of "Exec=[appname]", e.g. for gimp.desktop this would be:

Exec=/usr/local/bin/gimp-remote-2.2 %U

or:

Exec=/usr/local/bin/kgtk-wrapper gimp-remote-2.2 %U


So 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.x
3. 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.43
5. 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.


p.s. Before anyone asks, as they always do:
Widget style: QtCurve, works for KDE and Gtk (also does KDE->Gtk icon mapping). This is set on the "Clear" variation.
Window decoration: Crystal with Knifty buttons
Font: Verdana. However, I have recompiled FreeType with the TrueType byte encoder enabled - this give great looking non anti-aliased fonts (otherwise they look *horrible*)




Changelog:

0.11.0
------
1. Gtk3 support.
2. Better, and safer, lookup of file filters.
3. Correctly determine size of string needed for pidfile!
4. Add thunderbird, and LibreOffice apps, to list of gtk2 apps.
5. Cleanup usless stuff; remove kdialogd3, qt3, qt4, kgtk2-wrapper, kqt3-wrapper, kqt4-wrapper.
6. Merge kgtkXX-wrapper scripts into kgtk-wrapper
7. Install kdialogd4 into KDE4 libexec dir.
8. Fix crash where client is terminated whilst file dialog is open.
9. Configurable debug. Pass cmake -DKGTK_DEBUG=true
When starting app, set KGTK_DEBUG env var, e.g.

KGTK_DEBUG=0x10 kgtk-wrapper lowriter

0x01 Connection debug
0x02 General debug
0x04 Filter get and set debug
0x08 Filter creation debug
0x10 Custom widget debug
0x20 dlsym debug
Values may be combined

10. If LibreOffice is detected (app is libreoffice, lowriter, etc.) then also set the OOO_FORCE_DESKTOP env var to gnome, so that we get nicer
themeing.
11. When passing filters to KFileDialog, replace / with \/
12. Make filter combo non-editable.
13. When returning selected filter to Gtk app, also return the filter name and not just the file pattern. This way if two filters have the same file pattern the corrent one can be selected.
14. Support for checkbox custom widgets.
15. Save location history per app.




LicenseGPL
Source(0.11.0)
(0.10 (Previous release))
Send to a friend
Subscribe
Other  Apps  from CraigD
Report inappropriate content



goto page: prev  ... 22  23  24  25  26  27  28  29  30  31  32  33  34 

-
.

 x86_64 LD_PRELOAD error

 
 by radn on: May 15 2009
 
Score 50%

On 64bit architecture (Fedora 11 Pre1) kgtk doesn't work at all. It writes this error to the console:

ERROR: ld.so: object '/usr/lib/kgtk/libkgtk2.so' from LD_PRELOAD cannot be preloaded: ignored.

So I figured out a patch here:
http://www.stud.fit.vutbr.cz/~xnovac06/fedora/kgtk-0.10.1-cmake.patch


Reply to this

-

 Great app! Thanks!

 
 by adolf102 on: May 20 2009
 
Score 50%

Great idea and works well too!

Thanks!


Adam
Reply to this

-

 Re: Great app! Thanks!

 
 by Pafrape on: May 21 2009
 
Score 50%

Hello,

I'm trying desperately to compile kgtk to install, but I can not.
I tried to do what is in the "readme", but without result.
Could you tell me the exact lines and actions that you have done to compile and install kgtk.

I'm on Linux only recently.
What distribution and what version you?
I'm on Kubuntu jaunty.
Thank you for your help because I feel like you kgtk fantastic if it can be installed.


Pafrapé

Kubuntu Jaunty 9.04

Reply to this

-

 How to run with thunderbird

 
 by adolf102 on: Jun 5 2009
 
Score 50%

In case it will help someone here is how i can run it with Thunderbrid:

/opt/thunderbird2$ ./run-mozilla.sh /usr/bin/kgtk-wrapper ./thunderbird-bin


Reply to this

-
.

 Opera

 
 by Muzer on: Jun 29 2009
 
Score 50%

Unfortunately, when opera is run under the wrapper, opening files and directories you download seems to break (I added Default File Handler=kde-open ,1
Default Directory Handler=kde-open ,1

to ~/.opera/filehandler.ini to make it use KDE file associations)

Any chance this could be fixed?

Thanks,

Muzer.


PS: Why is the build so complicated? Why is it not possible to build the gtk2, qt3 and qt4 libs at the same time, as building the KDE4 kdialogd? That's what most people would use.


Reply to this

-

 Re: Opera

 
 by Muzer on: Jun 29 2009
 
Score 50%

OK, I managed to make a REALLY UGLY workaround. It's really ugly, but it works perfectly. Here is how I did it:

As root, use your favourite text editor to create the file /usr/bin/opera-opend :

kdesudo kate /usr/bin/opera-opend

Copy and paste this into it:

#!/bin/bash

# Hack to get real file associations and KDE file dialogues at the same time.
rm /tmp/opera-open
while [ 1 ]; do
if [ -f /tmp/opera-open ]; then
kde-open "`cat /tmp/opera-open`" &
sleep 1
rm /tmp/opera-open
fi
done



Save the file and exit.

Now, do the same with opera-open (but with different text, obviously):

kdesudo kate /usr/bin/opera-open

With this text:

#!/bin/bash

# Client for opera-opend
echo "`date` Started!" >> /var/log/opera
while [ -f /tmp/opera-open ]; do
echo "`date` File in use..." >> /var/log/opera
sleep 3
done
echo -n "$*" > /tmp/opera-open
echo "`date` Success! File contents is `cat /tmp/opera-open`"



(note that I did a bit of debug logging here. You might want to remove the lines starting with echo, otherwise the log will gradually increase in size until it is massive)

Save the file and exit.

Make both files executable:

sudo chmod +x /usr/bin/opera-open*

Add opera-opend to your autostart:
(for KDE4, other DMs will vary):

ln -sv /usr/bin/opera-opend ~/.kde/Autostart/

(important note: This MUST be run as a normal user, NOT root. Therefore, do NOT put it in /etc/rc.local or another file that gets run as root rather than a normal user)

Start the daemon for the current session only (future sessions it will automatically start, which is what we did above):

opera-opend 2>/dev/null &

Create and edit the filehandler.ini file:

kate ~/.opera/filehandler.ini

Add this contents and save and exit:

Opera Preferences version 2.1
; Do not edit this file while Opera is running
; This file is stored in UTF-8 encoding

[Settings]
Default File Handler=opera-open ,1
Default Directory Handler=opera-open ,1


Close Opera.

Modify Opera's .desktop file so that it starts with kgtk-wrapper:

kdesudo kate /usr/share/applications/opera.desktop

Edit this line:

Exec=opera %u


To read:

Exec=kgtk-wrapper opera %u


Save and exit. Start Opera. Make sure everything works: Try the open and save dialogues to make sure they are KDE4. Go to your transfers and try opening on of the files (you might have to do right click --> open with --> opera-open if it doesn't work), and one of the directories (right click --> Open Folder)

Success! (Hopefully).


Reply to this

-

 Auto apply to all GTK apps

 
 by Muzer on: Jun 29 2009
 
Score 50%

By the way, someone might be interested in this:

To apply it to all GTK apps (but don't apply it twice if one already has it applied), run this as root (sudo bash):

for f in `find /usr/share/applications`; do if [ "`grep Categories.*GTK $f`" != "" ] && [ "`grep kgtk-wrapper $f`" = "" ]; then sed -i s/Exec\=/Exec\=kgtk-wrapper\ / $f; fi; done

You may wish to add this to /etc/rc.local (to make it run on boot) and run it manually after installing an application or performing an upgrade. It should be perfectly safe (as long as I haven't made a typo typing it out...)


Reply to this

-

 Auto apply to all GTK apps

 
 by Muzer on: Jun 29 2009
 
Score 50%

By the way, someone might be interested in this:

To apply it to all GTK apps (but don't apply it twice if one already has it applied), run this as root (sudo bash):

for f in `find /usr/share/applications`; do if [ "`grep Categories.*GTK $f`" != "" ] && [ "`grep kgtk-wrapper $f`" = "" ]; then sed -i s/Exec\=/Exec\=kgtk-wrapper\ / $f; fi; done

You may wish to add this to /etc/rc.local (to make it run on boot) and run it manually after installing an application or performing an upgrade. It should be perfectly safe (as long as I haven't made a typo typing it out...)


Reply to this

goto page: prev  ... 22  23  24  25  26  27  28  29  30  31  32  33  34 

Add commentBack






-
-
Do you like or dislike Ubuntu Unity?
 Yes, unity is alien technology!
 It is less confusing than Gnome 3 default, shell.
 Granny thinks it is much more usable than Gnome 2
 Canonical is embarrasing itself with this split project
 Gnome 3 default shell is much better
 I dislike Unity, Gnome 3 default shell is alien technology!
 None of the above, I like the 2Gb for free and Apple alike behavior. Will post a comment instead

resultmore
 
 
 Who we are
Contact
More about us
Frequently Asked Questions
Register
Twitter
Blog
Explore
Apps
Jobs
Knowledge
Events
People
Updates on identi.ca
Updates on Twitter
Facebook App
Content RSS   
Events RSS   

Participate
Groups
Forum
Add App
Public API
About KDE-Apps.org
Legal Notice
Spreadshirt Shop
CafePress Shop
Advertising
Sponsor us
Report Abuse
 

Copyright 2003-2014 KDE-Apps.org Team  
All rights reserved. KDE-Apps.org is not liable for any content or goods on this site.
All contributors are responsible for the lawfulness of their uploads.
KDE and K Desktop Environment are trademarks of KDE e.V.