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

List:       kde-devel
Subject:    Re: konsole_part to execute something?
From:       Dominique Devriese <fritmebufstek () pandora ! be>
Date:       2002-09-13 8:45:04
[Download RAW message or body]

Waldo Bastian writes:

> On Thursday 12 September 2002 03:18 pm, Dominique Devriese wrote:
>> Waldo Bastian writes:
>> > On Thursday 12 September 2002 02:04 pm, Dominique Devriese wrote:
>> >> Waldo Bastian writes:
>> >> > On Thursday 12 September 2002 08:26 am, Michael Goffioul
>> >> > wrote:
>> >> >> Is it possible to use the konsole_part to simply execute
>> >> >> something.  I don't want a complete shell, just execute a
>> >> >> program which manages its own prompt (for example
>> >> >> "gdb"). Moreover I'd like to start the program with
>> >> >> arguments.
>> >> >>
>> >> >> Is this possible?
>> >> >
>> >> > Not at the moment.
>> >>
>> >> If i get this running, i'll post a patch on kde-devel again..
>>
>> Hi again, well, i've just got it running.. :) I've tested it only a
>> little yet, but i get python running fine in a window, and i have
>> had very little problems with the code yet..  Here is the patch.
>> One part is a tar file termemu.tar containing a new dir which
>> belongs in kdelibs/interfaces/termemu.  The other is a patch
>> against kdebase/konsole/konsole to make konsole_part implement the
>> new interface.  Oh, and you have to add termemu to the SUBDIRS line
>> in kdelibs/interfaces/Makefile.am ...

> What about just calling it "Terminal" instead of termemu?

err.. sure :)

> I am not sure if your changes are backwards compatible. I think you
> do not get a shell now till the first openURL request, no? That may
> break some applications that use konsole as part but don't call
> openURL.

Hmm... yes.  The problem is that starting a shell in the constructor
is Wrong (tm), since if you do that, and next the client calls
startProgram(), then you have to kill the shell again, and start the
new program.  But since it is indeed BIC, fixing this will prolly have
to wait till KDE 4, right ?

> Micheal in the mean time discovered that the KParts interface has an
> addtional QStringList which can be used to pass additional arguments
> I think.

Hmm.. if I understand the code in konsole_part.cpp correctly, then
konsoleFactory::createPartObject completely ignores the QStringList
it gets..  Do you think it would be better to work via that
QStringList than via the interface thing ?

> Apart from that, I guess it would make sense to add
> 	void sendSession(const QString &text);

"sendSession" ?  you mean sending text to the program that is running,
right ?

> and perhaps some signals like
>         void receivedLine(const QString &text); void shellExit(int);
> to the Terminal interface so that applications can keep a closer eye
> on and have closer control over what is happening in the terminal.

You're right..  I'll see what i can do :)
( the signals would most easily be added to the part and not the
interface, by the way, since the latter is no QObject, and i'm affraid
of making it one :)
domi


-- 
I WILL NOT WASTE CHALK
I WILL NOT WASTE CHALK
I WILL NOT WASTE CHALK
I WILL NOT WASTE CHALK

	Bart Simpson on chalkboard in episode 7G02
 
>> Visit http://mail.kde.org/mailman/listinfo/kde-devel#unsub to unsubscribe <<
[prev in list] [next in list] [prev in thread] [next in thread] 

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