KGtk (Use KDE Dialogs in Gtk Apps)

Various KDE 1.-4. Improvements

Source (link to git-repo or to original if based on someone elses unmodified work): Add the source-code for this project on opencode.net

11
7 .7
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*)
Last changelog:

9 years ago

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.

Vin

11 years ago

Hi,

on openSUSE 11.0, firefox with kgtk-wrapper fails to open a document with OpenOffice.org (kgtk 0.10.1).

When running from console, firefox produces this error output:

(process:6785): GLib-GObject-CRITICAL **: gtype.c:2248: initialization assertion failed, use IA__g_type_init() prior to this function

(process:6785): GLib-CRITICAL **: g_once_init_leave: assertion `initialization_value != 0' failed

(process:6785): GLib-GObject-CRITICAL **: g_object_new: assertion `G_TYPE_IS_OBJECT (object_type)' failed
which: no kdialogd4 in (/usr/lib/ooo3/program:/opt/kde3/bin:/home/jan/bin:/usr/local/bin:/usr/bin:/bin:/usr/bin/X11:/usr/X11R6/bin:/usr/games:/usr/lib/jvm/jre/bin:/usr/lib/mit/bin:/usr/lib/mit/sbin)

Report

thefirstM

11 years ago

I love Kgtk, but I am having a problem with it when I click a file which would open in OpenOffice.org when I am using Firefox. The file downloads as normal, but then OpenOffice will not launch properly. Sometimes it displays the title bar, but other times it only displays a icon in the taskbar. It always fails to start fully, requiring OpenOffice to be killed with signal 9. After this, Firefox continues to run properly. Is there any chance you might be able to fix this problem?

Report

val-gaav

11 years ago

It seems to have problems with 2 wxwidgets/gtk apps I tried.

Audacity , Mkvtollnix GUI.

Report

Akuser

11 years ago

thank u very much,
this should become standard in kde..
would be nice if we could do this with the whole gtk-widgets inside kde...

im on kde4.2 jaunty alpha

Report

promeneur

11 years ago

Mandriva 2008.1
kgtk 0.10.1

Opera 9.64 ok

Report

promeneur

11 years ago

i use the statement

kgtk-wrapper googleearth

and kgtkrc with statement

[Apps]
googleearth=qt4

then GE crashes

see the log
**********************
[xx@localhost ~]$ /usr/bin/kgtk-wrapper /opt/google-earth/googleearth
Warning: Unable to create prefs directory '/home/roubach/.googleearth'. Le fichier existe..
which: no kdialogd4 in (/usr/bin:/bin:/usr/local/bin:/usr/X11R6/bin/:/usr/games:/usr/lib/qt4/bin:/usr/lib/firebird/bin:/home/roubach/bin:/usr/lib/firebird/bin)
kdialogd3: WARNING: stale socket exists
kdialogd3: Timeout:30
Google Earth has caught signal 11.

Stacktrace from glibc:
./googleearth-bin [0x806c3a3]
./googleearth-bin [0x806c916]
[0xffffe400]
./libgoogleearth_lib.so(_ZN5earth6client11Application3runEv+0x392) [0xb69ee1d2]
./googleearth-bin(main+0x2ba) [0x806da3a]
/lib/i686/libc.so.6(__libc_start_main+0xe0) [0xb67a3390]
./googleearth-bin [0x806bb31]




We apologize for the inconvenience, but Google Earth has crashed.
This is a bug in the program, and should never happen under normal
circumstances. A bug report and debugging data are now being written
to this text file:

/home/xx/.googleearth/crashlogs/crashlog-EC8E2F60.txt

This bug report will be sent to Google automatically next time you run
Google Earth. Its data, which contains no personal information, will help
us correct problems without bothering you further. If you would rather
this info not be transmitted, please delete the above file before running
the program again. If you want bug reports to NEVER be sent, remove the
above 'crashlogs' directory's read/write permissions.

kdialogd3: New connection
kdialogd3: new client...googleearth-bin (28)
kdialogd3: read
kdialogd3: Comms error, closing connection...28
kdialogd3: close 28
kdialogd3: Delete client
kdialogd3: Deleted client
[xx@localhost ~]$ kdialogd3: Timeout occured, and no connections, so
exit
*****************************************

Report

promeneur

11 years ago

my settings

Linux Mandriva 2009.1rc1
kde 4.2.1
i did not install any kde 3
gtk-qt-engine 1.1
gtk 2.10.0


when i compile 0.10.1 source

it seems that it is a kde3 dialog which is compiled and it could not find any gtk2 lib



se this log
***************************************
[xx@localhost KGtk-0.10.1]$ echo $KDE_SESSION_VERSION
4

***************************************

see the log
******************************************

[xx@localhost build]$ cmake .. -DCMAKE_INSTALL_PREFIX=/usr
-- The C compiler identification is GNU
-- The CXX compiler identification is GNU
-- Check for working C compiler: /usr/bin/gcc
-- Check for working C compiler: /usr/bin/gcc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Looking for getpeereid
-- Looking for getpeereid - not found
-- Looking for XOpenDisplay in /usr/lib/libX11.so;/usr/lib/libXext.so
-- Looking for XOpenDisplay in /usr/lib/libX11.so;/usr/lib/libXext.so - found
-- Looking for gethostbyname
-- Looking for gethostbyname - found
-- Looking for connect
-- Looking for connect - found
-- Looking for remove
-- Looking for remove - found
-- Looking for shmat
-- Looking for shmat - found
-- Looking for IceConnectionNumber in ICE
-- Looking for IceConnectionNumber in ICE - found
-- Found X11: /usr/lib/libX11.so
-- Looking for include files CMAKE_HAVE_PTHREAD_H
-- Looking for include files CMAKE_HAVE_PTHREAD_H - found
-- Looking for pthread_create in pthreads
-- Looking for pthread_create in pthreads - not found
-- Looking for pthread_create in pthread
-- Looking for pthread_create in pthread - found
-- Found Threads: TRUE
-- Found KDE3 include dir: /opt/kde3/include
-- Found KDE3 library dir: /opt/kde3/lib
-- Found KDE3 dcopidl preprocessor: /opt/kde3/bin/dcopidl
-- Found KDE3 dcopidl2cpp preprocessor: /opt/kde3/bin/dcopidl2cpp
-- Found KDE3 kconfig_compiler preprocessor: /opt/kde3/bin/kconfig_compiler
** INFORMATION: KDialogD for KDE3 will be built.
-- Found xgettext: /usr/bin/xgettext
-- checking for module 'gtk+-2.0>=2.6'
-- package 'gtk+-2.0>=2.6' not found
** ERROR : Could not locate Gtk2 headers, Gtk2 LD_PRELOAD library will notbe built.
** INFORMATION: Qt3 LD_PRELOAD library will be built.
** INFORMATION: Using installation prefix: /usr
-- Configuring done
-- Generating done
-- Build files have been written to: /home/xx/Téléchargement/KGtk-0.10.1/build
[xx@localhost build]$
******************************************

thanks

Report

promeneur

11 years ago

thanks for your great application !

my settings :

Linux Manddriva 2008.1
kde 3.5.9
py-qt-engine 0.8 <<<

kgtk 0.10.1 source

compiling ok

i have qt4 aplications therefore also an installed qt4 beside qt3.
for example :
avidemux
google-earth

how to produce de kgtk wrapper for gtk2 , qt3 and also my qt4 applications with kde 3 ?

addendum :

Firefox 3.06 ok
Gim 2.4.7 ok
Xsane 0.995 ok

Report

C

CraigD

11 years ago

kgtk-wrapper <appname> should just work e.g.

kgtk-wrapper gimp
kgtk-wrapper scribus

If the script cannot detect the correct toolkit, you can edit ~/.kde/share/config/kgtkrc:

--------kgtkrc-----------
[Apps]
designer=qt3
avidemux=gtk2
--------kgtkrc-----------

This would then tell kgtk-wrapper to not bother trying to detect the toolkit, but use the configured one.

Report

promeneur

11 years ago

i don't understand

so i complete my pb:

i have no kde 4 but i have qt3 and qt4 applications

when i compiled kgtk
with

mkdir build
cd build
cmake .. -DCMAKE_INSTALL_PREFIX=/usr
make

it did not produce any qt4 wrapper

anyway :
- i tried this :
[Apps]
avidemux2_qt4=qt3

- i tried this :
[Apps]
avidemux2_qt4=qt4

the gui does not launch


thanks

Report

C

CraigD

11 years ago

Read the README file...

Report

promeneur

11 years ago

your README is not good

what i made

i produced kgtk-wrapper for kde3
with
1. mkdir build
2. cd build
3. cmake .. -DCMAKE_INSTALL_PREFIX=/usr
4. make
5. sudo make install

then
i produced uncomplete kgtk for kde4
with

6. set up Qt4/KDE4 env variables
7. clean build folder

8. mkdir build4
9. cd build4
10. cmake .. -DCMAKE_INSTALL_PREFIX=/usr -DKGTK_KDE4=true -DKGTK_QT4=true -DKGTK_GTK2=false
11. make
12. sudo make install

the compilation failed for kde4dialog because there is no kde4

the "make install" stopped at a step
then
does not install the qt4 wrapper
then
i go to the qt4 folder in build4
then
su -c "make install"
then
qt4 wrapper is installed

result :

avidemux2_qt4 ok without any kgtkrc

google earth :

with no kgtkrc then no kde3 dialog
with kgtkrc with googleearth=qt4 then crashes
with kgtkrc with googleearth-bin=qt4 then no kde3 dialog

how you launch GE 5 ?

you launch "googleearth" script
then
"googleearth" script launches "googleearth-bin"

with the statement

exec "./googleearth-bin" -style=cleanlooks "$@"

if you have a solution

thanks

Report

promeneur

11 years ago

i also tried with

[Apps]
googleearth=qt4

google earth starts but kgtk-wrapper has no effect

Report

crissi

11 years ago

It would be nice, if I can use my editor (PyPE) with remote files (via kde dialogs).

You have to use an ioslave, which handles the local store and saving back.

Please implement this!

Report

ssokolow

11 years ago

Would you mind rewriting kdialogd-wrapper so that it falls back to whichever version of kdialogd is available if the desired version isn't?

As it is, I had to sed "kdialogd4" into "which kdialogd4 &>/dev/null && kdialogd4 || kdialogd3" because I'm running KDE 4.2 on Gentoo and their ebuild always builds only kdialogd3.

(As it is, the wrapper just assumes that you've got the version of kdialogd which matches your desktop)

Report

brunofriedmann

11 years ago

Building on opensuse 11.1 give some errors

cmake .. -DCMAKE_INSTALL_PREFIX=/usr -DKGTK_KDE4=true -DKGTK_QT4=true -DKGTK_GTK2=true

-- The C compiler identification is GNU
-- The CXX compiler identification is GNU
-- Check for working C compiler: /usr/bin/gcc
-- Check for working C compiler: /usr/bin/gcc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Looking for getpeereid
-- Looking for getpeereid - not found
** INFORMATION: Compiling Qt4/KDE4, Qt3/KDE3 disabled
-- Looking for Q_WS_X11
-- Looking for Q_WS_X11 - found
-- Looking for Q_WS_WIN
-- Looking for Q_WS_WIN - not found.
-- Looking for Q_WS_QWS
-- Looking for Q_WS_QWS - not found.
-- Looking for Q_WS_MAC
-- Looking for Q_WS_MAC - not found.
-- Found Qt-Version 4.4.3 (using /usr/bin/qmake)
-- Looking for XOpenDisplay in /usr/lib/libX11.so;/usr/lib/libXext.so;/usr/lib/libXft.so;/usr/lib/libXau.so;/usr/lib/libXdmcp.so;/usr/lib/libXpm.so
-- Looking for XOpenDisplay in /usr/lib/libX11.so;/usr/lib/libXext.so;/usr/lib/libXft.so;/usr/lib/libXau.so;/usr/lib/libXdmcp.so;/usr/lib/libXpm.so - found
-- Looking for gethostbyname
-- Looking for gethostbyname - found
-- Looking for connect
-- Looking for connect - found
-- Looking for remove
-- Looking for remove - found
-- Looking for shmat
-- Looking for shmat - found
-- Looking for IceConnectionNumber in ICE
-- Looking for IceConnectionNumber in ICE - found
-- Found X11: /usr/lib/libX11.so
-- Looking for include files CMAKE_HAVE_PTHREAD_H
-- Looking for include files CMAKE_HAVE_PTHREAD_H - found
-- Looking for pthread_create in pthreads
-- Looking for pthread_create in pthreads - not found
-- Looking for pthread_create in pthread
-- Looking for pthread_create in pthread - found
-- Found Threads: TRUE
-- Found Automoc4: /usr/bin/automoc4
-- Found Perl: /usr/bin/perl
-- Performing Test _OFFT_IS_64BIT
-- Performing Test _OFFT_IS_64BIT - Failed
-- Performing Test HAVE_FPIE_SUPPORT
-- Performing Test HAVE_FPIE_SUPPORT - Success
-- Performing Test __KDE_HAVE_W_OVERLOADED_VIRTUAL
-- Performing Test __KDE_HAVE_W_OVERLOADED_VIRTUAL - Success
-- Performing Test __KDE_HAVE_GCC_VISIBILITY
-- Performing Test __KDE_HAVE_GCC_VISIBILITY - Success
-- Found Phonon: /usr/lib/libphonon.so
-- Found Phonon Includes: /usr/include/KDE;/usr/include
-- Found KDE 4.1 include dir: /usr/include
-- Found KDE 4.1 library dir: /usr/lib
-- Found KDE4 kconfig_compiler preprocessor: /usr/bin/kconfig_compiler
-- Found automoc4: /usr/bin/automoc4
** INFORMATION: KDialogD for KDE4 will be built.
-- Found xgettext: /usr/bin/xgettext
-- checking for module 'gtk+-2.0>=2.6'
-- found gtk+-2.0, version 2.14.4
** INFORMATION: Gtk2 LD_PRELOAD library will be built.
-- Found Qt-Version 4.4.3
-- Found OpenSSL: /usr/lib/libssl.so
-- Looking for _POSIX_TIMERS
-- Looking for _POSIX_TIMERS - found
** INFORMATION: Qt4 LD_PRELOAD library will be built.
** INFORMATION: Using installation prefix: /usr
-- Configuring done
-- Generating done
-- Build files have been written to: /home/bruno/src_tmp/KGtk-0.10.0/build4

ok everything fine

now a make

Generating kdialogd.moc
Scanning dependencies of target kdialogd4_bin
[ 7%] Building CXX object kdialogd4/CMakeFiles/kdialogd4_bin.dir/kdialogd4_bin_automoc.o
[ 15%] Building CXX object kdialogd4/CMakeFiles/kdialogd4_bin.dir/kdialogd.o
/home/bruno/src_tmp/KGtk-0.10.0/kdialogd4/kdialogd.cpp:672: warning: unused parameter ‘modal’
Linking CXX executable kdialogd4
[ 15%] Built target kdialogd4_bin
Scanning dependencies of target pofiles
[ 15%] Generating cs.gmo
[ 15%] Generating pt_BR.gmo
[ 15%] Generating ru.gmo
[ 15%] Generating es.gmo
/home/bruno/src_tmp/KGtk-0.10.0/kdialogd4/po/es.po: AVERTISSEMENT : Le jeu de caractères « CHARSET » n'est pas un nom d'encodage portable.
La conversion vers le jeu de caractères de l'utilisateur peut ne pas fonctionner.
[ 15%] Generating fr.gmo
/home/bruno/src_tmp/KGtk-0.10.0/kdialogd4/po/fr.po: AVERTISSEMENT : Le jeu de caractères « CHARSET » n'est pas un nom d'encodage portable.
La conversion vers le jeu de caractères de l'utilisateur peut ne pas fonctionner.
[ 15%] Generating de.gmo
[ 15%] Generating en_GB.gmo
[ 15%] Generating zh_CN.gmo
/home/bruno/src_tmp/KGtk-0.10.0/kdialogd4/po/zh_CN.po: AVERTISSEMENT : Le jeu de caractères « CHARSET » n'est pas un nom d'encodage portable.
La conversion vers le jeu de caractères de l'utilisateur peut ne pas fonctionner.
[ 76%] Built target pofiles
Scanning dependencies of target kgtk2
[ 84%] Building C object gtk2/CMakeFiles/kgtk2.dir/kgtk2.o
In file included from /home/bruno/src_tmp/KGtk-0.10.0/gtk2/kgtk2.c:67:
/home/bruno/src_tmp/KGtk-0.10.0/common/connect.h:98:5: warning: #warning "Using sloppy security checks"
/home/bruno/src_tmp/KGtk-0.10.0/gtk2/kgtk2.c: In function ‘kdialogdMain’:
/home/bruno/src_tmp/KGtk-0.10.0/gtk2/kgtk2.c:194: warning: initialization from incompatible pointer type
/home/bruno/src_tmp/KGtk-0.10.0/gtk2/kgtk2.c: In function ‘sendMessage’:
/home/bruno/src_tmp/KGtk-0.10.0/gtk2/kgtk2.c:254: warning: passing argument 1 of ‘gdk_x11_drawable_get_xid’ from incompatible pointer type
/home/bruno/src_tmp/KGtk-0.10.0/gtk2/kgtk2.c: In function ‘gtk_init_check’:
/home/bruno/src_tmp/KGtk-0.10.0/gtk2/kgtk2.c:672: warning: assignment makes integer from pointer without a cast
/home/bruno/src_tmp/KGtk-0.10.0/gtk2/kgtk2.c: In function ‘gtk_combo_box_get_active’:
/home/bruno/src_tmp/KGtk-0.10.0/gtk2/kgtk2.c:1209: warning: passing argument 1 of ‘isOnFileChooser’ from incompatible pointer type
/home/bruno/src_tmp/KGtk-0.10.0/gtk2/kgtk2.c: In function ‘gtk_dialog_run’:
/home/bruno/src_tmp/KGtk-0.10.0/gtk2/kgtk2.c:1412: warning: return makes integer from pointer without a cast
/home/bruno/src_tmp/KGtk-0.10.0/gtk2/kgtk2.c: In function ‘handleGtkFileChooserButtonClicked’:
/home/bruno/src_tmp/KGtk-0.10.0/gtk2/kgtk2.c:1771: warning: passing argument 1 of ‘gtk_dialog_run’ from incompatible pointer type
/home/bruno/src_tmp/KGtk-0.10.0/gtk2/kgtk2.c: In function ‘handleGtkFileChooserComboChanged’:
/home/bruno/src_tmp/KGtk-0.10.0/gtk2/kgtk2.c:1793: warning: passing argument 1 of ‘gtk_dialog_run’ from incompatible pointer type
/home/bruno/src_tmp/KGtk-0.10.0/gtk2/kgtk2.c: At top level:
/home/bruno/src_tmp/KGtk-0.10.0/gtk2/kgtk2.c:1916: warning: ‘struct PR_LoadLibrary’ declared inside parameter list
/home/bruno/src_tmp/KGtk-0.10.0/gtk2/kgtk2.c:1916: warning: its scope is only this definition or declaration, which is probably not what you want
Linking C shared library libkgtk2.so
[ 84%] Built target kgtk2
[ 92%] Generating mangled.h
Scanning dependencies of target kqt4
[100%] Building CXX object qt4/CMakeFiles/kqt4.dir/kqt4.o
In file included from /home/bruno/src_tmp/KGtk-0.10.0/qt4/kqt4.cpp:54:
/home/bruno/src_tmp/KGtk-0.10.0/common/connect.h:98:5: warning: #warning "Using sloppy security checks"
Linking CXX shared library libkqt4.so
[100%] Built target kqt4

Work also but there's warning about incompatible pointer type
a make install work
and finally you can lauch firefox.
BUT when you want to save a file somewhere the qt dialog box loose the filename (which is not viable)

example with a file
/usr/bin/kgtk2-wrapper /usr/bin/firefox
kdialogd4(2041) KDialogD::KDialogD: Timeout: 30
kdialogd4(2041) KDialogD::newConnection: New connection
kdialogd4(2041) KDialogDClient::KDialogDClient: new client... "firefox" ( 12 )
*** nss-shared-helper: Shared database disabled (set NSS_USE_SHARED_DB to enable).
kdialogd4(2041) KDialogD::newConnection: New connection
kdialogd4(2041) KDialogDClient::KDialogDClient: new client... "mozilla-bonobo-viewer" ( 13 )
kdialogd4(2041) KDialogDClient::read: read 13
kdialogd4(2041) KDialogDClient::read: Comms error, closing connection... 13
kdialogd4(2041) KDialogDClient::close: close 13
kdialogd4(2041) KDialogD::deleteConnection: Delete client
kdialogd4(2041) KDialogDClient::~KDialogDClient: Deleted client
QObject: Do not delete object, 'unnamed', during its event handler!
kdialogd4(2041) KDialogDClient::read: read 12
kdialogd4(2041) KDialogDClient::readString: readString 12
kdialogd4(2041) KDialogDClient::readString: readString 12
kdialogd4(2041) KDialogDClient::readString: readString 12
kdialogd4(2041) KDialogDFileDialog::KDialogDFileDialog: startDir: "/home/bruno/src_tmp/NT4/NetworkManager-kde4-0.7.svn906687-1.1.i586.rpm"
kdialogd4(2041) KDialogDClient::initDialog: initDialog 12
kdialogd4(2041) KDialogDClient::finished: finished 134908640 false false
kdialogd4(2041) KDialogDClient::cancel: cancel
kdialogd4(2041) KDialogDClient::cancel: send cancel
kdialogd4(2041) KDialogDFileDialog::~KDialogDFileDialog: ~KDialogDFileDialog
kdialogd4(2041) KDialogDClient::read: read 12
kdialogd4(2041) KDialogDClient::read: Comms error, closing connection... 12
kdialogd4(2041) KDialogDClient::close: close 12
kdialogd4(2041) KDialogD::deleteConnection: Delete client
kdialogd4(2041) KDialogDClient::~KDialogDClient: Deleted client
QObject: Do not delete object, 'unnamed', during its event handler!

In the dialog file it should be
KDialogDFileDialog::KDialogDFileDialog: startDir: "/home/bruno/src_tmp/NT4/"
and not the full name with the filename.

As I don't understand C++ I can't correct them ...

Anybody have an idea.

Report

dutler

11 years ago

Hello, a program I have been lusting after for quite awhile, thank you!

What about kde print from these apps as well?

Report

Vin01

11 years ago

Hi,

KGtk 0.10, Gimp 2.6. Runs fine, but when saving an image as .xcf, gimp crashes (saves the image first though). Any insight on this?

Report

gooler

11 years ago

Thanks for this wonderfull app.

Finally I can get rid of GNOME's strange file dialogs.

Report

riteshsarraf

11 years ago

I've built kgtk without gtk2 support as I want only the KDE4 version.

Here's the error:

rrs@learner:~$ kgtk-wrapper iceweasel
/usr/local/bin/kgtk-wrapper: line 96: kgtk2-wrapper: command not found

Report

ssokolow

11 years ago

IceWeasel is a GTK+ 2.x application. You have to build it with GTK+ 2.x support.

Report

Murz

11 years ago

Can't build on Kubuntu Intrepid AMD64 width KDE 4.2.

build4$ make
[ 8%] Building CXX object kdialogd4/CMakeFiles/kdialogd4_bin.dir/kdialogd.o
/storage/temp/2008-11/kgtk/KGtk-0.10.0/kdialogd4/kdialogd.cpp: In member function ‘void KDialogD::deleteConnection(KDialogDClient*)’:
/storage/temp/2008-11/kgtk/KGtk-0.10.0/kdialogd4/kdialogd.cpp:257: warning: suggest explicit braces to avoid ambiguous ‘else’
/storage/temp/2008-11/kgtk/KGtk-0.10.0/kdialogd4/kdialogd.cpp: In member function ‘void KDialogD::timeout()’:
/storage/temp/2008-11/kgtk/KGtk-0.10.0/kdialogd4/kdialogd.cpp:268: warning: suggest explicit braces to avoid ambiguous ‘else’
/storage/temp/2008-11/kgtk/KGtk-0.10.0/kdialogd4/kdialogd.cpp: In member function ‘void KDialogDClient::finished()’:
/storage/temp/2008-11/kgtk/KGtk-0.10.0/kdialogd4/kdialogd.cpp:394: error: cast from ‘KDialog*’ to ‘int’ loses precision
/storage/temp/2008-11/kgtk/KGtk-0.10.0/kdialogd4/kdialogd.cpp: At global scope:
/storage/temp/2008-11/kgtk/KGtk-0.10.0/kdialogd4/kdialogd.cpp:664: warning: unused parameter ‘modal’
make[2]: *** [kdialogd4/CMakeFiles/kdialogd4_bin.dir/kdialogd.o] Error 1
make[1]: *** [kdialogd4/CMakeFiles/kdialogd4_bin.dir/all] Error 2
make: *** [all] Error 2

Report

ivancukic

12 years ago

On kdialogd.cpp:394, relpace the (int) cast to (void *) since this way it fails to compile on 64bit systems with this error:
error: cast from ‘KDialog*’ to ‘int’ loses precision

Report

val-gaav

11 years ago

Hi Mr Lancelot ;)

As a KDE dev could you perhaps try to push this nice app into KDE ? (just like gtk-qt-engines)

I mean it's so needed and it would make KDE experinece better for so many people that don't know about it.

Report

lopan

12 years ago

Hi all!

Look the message on Kgtk 0.10 with Kde4:

Quote:
kgtk2-wrapper firefox
Uso: kdialog [Qt-opções] [KDE-opções] [opções][arg]

O KDialog pode ser usado para mostrar caixas de diálogo em scripts shell

Opções genéricas:
--help Mostra ajuda sobre opções
--help-qt Mostra Qt opções específicas
--help-kde Mostra KDE opções específicas
--help-all Mostrar todas as opções
--author Mostrar informações sobre o autor
-v, --version Mostrar informações sobre a versão
--license Mostrar informações de licenciamento
-- Fim das opções

Opções:
--yesno <text> Caixa de mensagem de pergunta com botões Sim/Não
--yesnocancel <text> Caixa de mensagem de pergunta com botões Sim/Não/Cancelar
--warningyesno <text> Caixa de mensagem de aviso com botões Sim/Não
--warningcontinuecancel <text> Caixa de mensagem de aviso com botões Continuar/Cancelar
--warningyesnocancel <text> Caixa de mensagem de aviso com botões Sim/Não/Cancelar
--sorry <text> Caixa de mensagem "Desculpe"
--error <text> Caixa de mensagem "Erro"
--msgbox <text> Diálogo de Caixa de Mensagem
--inputbox <text> <init> Diálogo de Caixa de Entrada
--password <text> Diálogo de Senha
--textbox <file> [width] [height] Diálogo de Caixa de Texto
--textinputbox <text> <init> [width] [height] Diálogo de Caixa de Entrada de Texto
--combobox <text> [tag item] [tag item] ... Diálogo de Caixa de Combinação
--menu <text> [tag item] [tag item] ... Diálogo de Menu
--checklist <text> [tag item status] ... Diálogo de Lista de Verificação
--radiolist <text> [tag item status] ... Diálogo de Lista de Botões de Rádio
--passivepopup <text> <timeout> Popup Passivo
--getopenfilename [startDir] [filter] Diálogo para abrir um arquivo existente
--getsavefilename [startDir] [filter] Diálogo para salvar um arquivo
--getexistingdirectory [startDir] Diálogo para selecionar uma pasta existente
--getopenurl [startDir] [filter] Diálogo para abrir uma URL existente
--getsaveurl [startDir] [filter] Diálogo para salvar uma URL
--geticon [group] [context] Diálogo de Escolha de Ícone
--progressbar <text> [totalsteps] Diálogo de barra de progresso, retorna uma referência D-Bus para comunicação
--getcolor Diálogo de cores para selecionar uma cor
--title <text> Título do diálogo
--default <text> A entrada padrão a usar na caixa de marcação, menu e cor
--multiple Permite as opções --getopenurl e --getopenfilename para retornar múltiplos arquivos
--separate-output Retorna os itens da lista em linhas separadas (para a opção de lista de verificação e arquivo aberto com o --multiple)
--print-winid Saídas da janela de cada diálogo
--embed <winid> Faz o diálogo transiente para um aplicativo X especificado pelo winid
--dontagain <file:entry> O arquivo de configuração e o nome da opção para salvar o estado "não-mostrar/perguntar-novamente"

Argumentos:
arg Argumentos - dependendo da opção principal
ERROR: Could not talk to KDialogD!!!


Is there a bug on kget or on my linux? :P

kdialogd4 is work very fine!

Report

9 years ago

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.

12345678910
8
product-maker arcanis Jun 15 2014 9 excellent
product-maker YAFU Sep 26 2012 9 excellent
product-maker frag Sep 20 2012 9 excellent
product-maker dreamsoul Nov 04 2011 9 excellent
product-maker deabru Nov 04 2011 9 excellent
product-maker tcat Jun 20 2011 9 excellent
product-maker unikum111 Apr 25 2011 9 excellent
product-maker ZaWertun Nov 11 2010 9 excellent
Be the first to comment
deabru
Nov 04 2011
tcat
Jun 20 2011
unikum111
Nov 12 2010
tigerfoot
Mar 07 2010
Raboch
Feb 24 2010
DaiVied
Dec 30 2009
Camberwell
Dec 01 2009
usrkl
Oct 07 2009
-luk-
Feb 23 2009
val-gaav
Feb 23 2009
alecs1
Feb 15 2009
File (click to download) Version Description PackagetypeArchitecture Downloads Date Filesize DL OCS-Install MD5SUM
*Needs pling-store or ocs-url to install things
Pling
0 Affiliates
Details
license
version
0.11.0
updated Nov 03 2011
added Mar 06 2006
downloads 24h
1
mediaviews 24h 0
pageviews 24h 16