[prev in list] [next in list] [prev in thread] [next in thread] 

List:       konsole-devel
Subject:    Re: [Konsole-devel] Konsole dbus feedSession/sendSession
From:       Arno_Töll <lists () toell ! net>
Date:       2009-05-11 16:51:54
Message-ID: 4A0857AA.4090403 () toell ! net
[Download RAW message or body]

Pantelis Koukousoulas wrote:
> Will it be possible to send keystrokes to a konsole tab via dbus?
> (like we could do in old dcop days via feedSession/sendSession).

Unless the current implementation changes, wich I don't suppose to, you
will be able doing this by using the new session handler [1].

For example you may use:

arno@snowball:~$ qdbus org.kde.konsole /Konsole
org.kde.konsole.Konsole.newSession
2

arno@snowball:~$ qdbus org.kde.konsole /Sessions/2 sendText "ls -l"

You, as every other user of DBus may use the introspect() method to get
a list of supported signatures and paths for dbus-accessible programs.
To get a graphical browser, use qdbusviewer.

> My use-case is for sending input from an external program to console
> vim running inside konsole. This is currently the only way to implement
> asynchronous communication of vim with external programs.

You may be wrong. See [2] for a scary example of what is possible to
feed vi(m). In short:

echo -e "Hello\nWorld" | vi -


[1]
http://websvn.kde.org/trunk/KDE/kdebase/apps/konsole/src/org.kde.konsole.Session.xml?view=markup
[2] http://www.de.ioccc.org/years.html#2004 (look for schnitzi)


_______________________________________________
konsole-devel mailing list
konsole-devel@kde.org
https://mail.kde.org/mailman/listinfo/konsole-devel
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic