[Konsole-devel] Konsole vs GT, MGT & use as an IDE
Robert Knight
robertknight at gmail.com
Tue Sep 26 09:28:13 UTC 2006
Hello Phil,
The first part, making Konsole start up with midnight commander is
fairly easy. Launch Konsole using the "--type" command-line flag:
konsole --type mc
You edit the session types in Konsole's configuration dialog (Settings
-> Configure Konsole).
Konsole really ought to have an option in the config dialog to speciy
which session is used on startup by default.
The program running in the terminal can manipulate it by putting
certain escape sequences in the output. Eg. ESC]2;titleBEL (ESC =
\033, BEL = \007) sets the window title of an xterm-compatible
terminal. In order to allow the program running in the terminal to
open a new tab a new escape sequence to instruct Konsole would need to
be defined, probably something in the form:
ESC]<number>;<command string>BEL
An from the mc, you would have to create a command which emitted this
character sequence.
Spotting that a file is already open and switching to the appropriate
tab is a bit more tricky. I suppose Konsole could spot if a program
is being launched with the same command string as another tab.
So in summary: A patch would have to be written for Konsole to do
this (probably not a very large one), and a new escape sequence would
have to be chosen which the terminal program can emit.
Regards,
Robert.
On 26/09/06, Phil Rhoades <phil at pricom.com.au> wrote:
> People,
>
> I have been using Multi-Gnome-Terminal for a long time and I really like it but
> it seems like it is not being maintained anymore so I had to look at Gnome
> Terminal again and although I have not used KDE much in the past I thought it
> would be good to have a look at Konsole as well after I saw a positive comment
> about it's tab functions.
>
> In a Ruby on Rails development environment (and other environments too)
> I need to have lots of project files open in Vim - of course I can use Konsole
> for this but it is still a problem navigating between all the files. There are
> RAD tools that allow better management of the development environment (eg
> RadRails) but those tools generally force you into using their own editor
> instead of Vim . .
>
> My idea is:
>
> - Use a version of Konsole that always starts up with Midnight Commander in Tab1.
>
> - When any new file is opened from MC, it is kept in the same Tab order eg if I
> have the following structure:
>
> - dir_A
> - File_1
> - File_2
> - dir_B
> - File_3
> - File_4
>
> - if I then open File_4, a new Tab2 would be created for it
>
> - if I then open File_2, a new Tab2 would be created for it and File_4
> would now be in Tab3
>
> - if I then open File_1, a new Tab2 would be created for it and File_2
> would now be in Tab3 and File_4 would now be in Tab4
>
> etc
>
> Also, if a file is already opened, then selecting it in MC should bring the
> appropriate Tab to the top.
>
> How difficult would this be to implement using what is already available
> in Konsole?
>
> Thanks,
>
> Phil.
> --
> Philip Rhoades
>
> Pricom Pty Limited (ACN 003 252 275 ABN 91 003 252 275)
> GPO Box 3411
> Sydney NSW 2001
> Australia
> Mobile: +61:(0)411-185-652
> Fax: +61:(0)2-8221-9599
> E-mail: phil at pricom.com.au
> _______________________________________________
> konsole-devel mailing list
> konsole-devel at kde.org
> https://mail.kde.org/mailman/listinfo/konsole-devel
>
More information about the konsole-devel
mailing list