Commit Graph

51 Commits

Author SHA1 Message Date
Eike Hein
95f203284f Remove now-unnecessary includes.
svn path=/trunk/KDE/kdebase/apps/konsole/; revision=941454
2009-03-19 15:18:34 +00:00
Eike Hein
a1f88240b4 Simplified translucency support in the KPart thanks to
Qt::WA_TranslucentBackground -- in the right branch,
this time.

svn path=/trunk/KDE/kdebase/apps/konsole/; revision=941453
2009-03-19 15:16:55 +00:00
David Faure
fa0b6e56a6 Make openUrl lead to a useable shell in all cases, even if the url is not a local url.
CCBUG: 153649

svn path=/trunk/KDE/kdebase/apps/konsole/; revision=923962
2009-02-09 20:14:59 +00:00
Robert Knight
956277c014 Convert tabs to 4 spaces to match kdelibs conventions. Previously
there was a mix of tabs and spaces for indentation.

CCMAIL:Stefan.Becker@nokia.com


svn path=/trunk/KDE/kdebase/apps/konsole/; revision=863326
2008-09-21 20:06:58 +00:00
Albert Astals Cid
a99550527c Make sure the konsole catalogue is loaded so that dolphin, yakuake, etc
that use konsolepart get the messages translated

svn path=/trunk/KDE/kdebase/apps/konsole/; revision=846684
2008-08-13 21:00:51 +00:00
David Faure
454e4557c7 Re-add a openUrl implementation so that embedding konsolepart into konqueror works again
BUG: 153649

svn path=/trunk/KDE/kdebase/apps/konsole/; revision=844692
2008-08-10 09:08:01 +00:00
David Faure
d66004acf3 Forward port fix for people without XRENDER
svn path=/trunk/KDE/kdebase/apps/konsole/; revision=844690
2008-08-10 09:06:09 +00:00
Robert Knight
5d9997446e Update copyright year to 2008. Remove '(C)' from copyright lines.
svn path=/trunk/KDE/kdebase/apps/konsole/; revision=800631
2008-04-24 14:53:43 +00:00
Robert Knight
d4e2edeab2 Allow the terminal display's host to decide whether shortcut keypresses
which are also valid terminal key sequences should be overridden and sent
to the terminal instead.

Default behaviour in the standalone Konsole is never to override shortcuts.  Default
behaviour in the terminal part is to always override shortcuts.

Shortcuts which are not valid terminal key sequences (eg. because they have more than
two modifiers) are never overridden.

Add an overrideShortcut() signal to the Part to expose this functionality to clients.

CCMAIL: kde-core-devel@kde.org

svn path=/trunk/KDE/kdebase/apps/konsole/; revision=799577
2008-04-21 22:06:12 +00:00
Robert Knight
039d1c4f6f Support use of existing pty in embedded terminal via openTeletype(int fd) slot.
No new methods have been added to the TerminalInterface class in kdelibs to avoid breaking
binary compatibility so the slot must be invoked via QMetaObject::invokeMethod() for now.

See tests/PartTest.cpp

CCMAIL:jr@jriddell.org

Squashed commit of the following:

commit 0759e22dc26b7c1c28e0d8a9b0d245d909629237
Author: Robert Knight <robertknight@gmail.com>
Date:   Fri Apr 18 20:43:20 2008 +0100

    Adapt test to kdelibs changes.  Add a label to explain what the user should expect to see.

commit b67be2fd20178625f01f8f135751849082eddf04
Author: Robert Knight <robertknight@gmail.com>
Date:   Fri Apr 18 00:47:32 2008 +0100

    Export Pty, Session, KeyboardTranslator classes for use in tests.

commit 6dd28bf628fe1036c59f3383aba27ba98e23152c
Author: Robert Knight <robertknight@gmail.com>
Date:   Fri Apr 18 00:46:27 2008 +0100

    Build test

commit 0a9e1c9dc158f73e6bf9f7ef2fe7d4ea936a8066
Author: Robert Knight <robertknight@gmail.com>
Date:   Fri Apr 18 00:46:10 2008 +0100

    Remove temp file

commit 8e69bd56fef267ac0c31c989a4959453a8e3359e
Author: Robert Knight <robertknight@gmail.com>
Date:   Fri Apr 18 00:45:28 2008 +0100

    Add a test for using existing file descriptors with the Konsole part.

commit f1f5b8a7684e88db64769324496a5fa67dd4920b
Author: Robert Knight <robertknight@gmail.com>
Date:   Tue Apr 15 18:36:14 2008 +0100

    Add support in the KPart to use an existing terminal rather than opening a new one.

svn path=/trunk/KDE/kdebase/apps/konsole/; revision=798661
2008-04-18 19:47:32 +00:00
Robert Knight
7c0e81dada Safer shutdown. Ensure all sessions are closed and session state saved
during Application destructor.

Make ~SessionManager do trivial tasks only.

BUG: 159657

svn path=/trunk/KDE/kdebase/apps/konsole/; revision=789641
2008-03-24 19:30:51 +00:00
Robert Knight
5036d8cb00 Squashed commit of the following:
commit 99d61f9bdfe29347050162a5a675bb0c276bc1bf
Author: Robert Knight <robertknight@gmail.com>
Date:   Sat Mar 22 20:45:45 2008 +0000

    Allow a normal frame around the table view in ManageProfilesDialog.  Works better with Oxygen style.

commit 7075de00d8cc88568e108e868e08d071d5aa7bcb
Author: Robert Knight <robertknight@gmail.com>
Date:   Sat Mar 22 20:37:38 2008 +0000

    Change base class of ProfileItemDelegate from QItemDelegate to QStyledItemDelegate for better rendering.  Fix updates of favorite / non-favorite status in ManageProfilesDialog.  QVariant equality comparisons are not properly supported for custom types so QAbstractItemModel::match() has to be replaced with manual iteration through the rows.

commit 3baa3307473e037efd500ade7df37d2fd62c60d9
Author: Robert Knight <robertknight@gmail.com>
Date:   Sat Mar 22 20:09:27 2008 +0000

    Remove unecessary deleteProfile() call.  Explicitly add new profiles to the SessionManager.  Mark the temporary profile in the EditProfileDialog as hidden.

commit 53d1e3515d3408c08ba4b019b5faceffae6b0f8a
Author: Robert Knight <robertknight@gmail.com>
Date:   Sat Mar 22 20:02:28 2008 +0000

    Do not track deletion of temporary un-named profiles.

commit 55c69e15a4247319b0cff73691f072fef39684c9
Author: Robert Knight <robertknight@gmail.com>
Date:   Sat Mar 22 20:01:25 2008 +0000

    Make SessionManager::addProfile() public.  Call it automatically in SessionManager::setFavorite() if the profile is not already known to the manager.  When a profile is deleted via SessionManager::deleteProfile() mark it as hidden so that it is not recreated on disk if later changed.  Add debugging in ~Profile to track deletion of profiles.

commit 7a028bac5846cd3689e3351ab139c6f372ca173e
Author: Robert Knight <robertknight@gmail.com>
Date:   Sat Mar 22 19:41:22 2008 +0000

    Fix several signal/slot connections in ManageProfilesDialog after the SessionManager changes.

commit da7c7b4f939c17885cf0fbaa1fb93d2655021b83
Author: Robert Knight <robertknight@gmail.com>
Date:   Sat Mar 22 19:36:57 2008 +0000

    Use a helper class to pop elements from recursion guard stack when a call to loadProfile() returns rather than requiring a manual call to recursionGuard.pop()

commit 14a993d15722ec5270de708154408896fd7418b8
Author: Robert Knight <robertknight@gmail.com>
Date:   Sat Mar 22 19:12:20 2008 +0000

    Fix profiles not being loaded properly if their parent was a profile which had already been loaded.  Profile paths were not being taken off the recursion guard stack at one exit from loadProfile().

commit f946fc0cbde26cd816e3f1d172a5e5327ff3295b
Author: Robert Knight <robertknight@gmail.com>
Date:   Sat Mar 22 19:01:06 2008 +0000

    Adapt Part to the SessionManager/Profile changes.

commit d3155ba0f6dc9ec0ca34a45b5787488c055dc4bf
Author: Robert Knight <robertknight@gmail.com>
Date:   Sat Mar 22 18:55:05 2008 +0000

    Update MainWindow API documentation to reflect string key -> ref counted pointer change for profiles.

commit 5d546054c031ae6ee6915f2cc6bcf61dd4e03520
Author: Robert Knight <robertknight@gmail.com>
Date:   Sat Mar 22 18:53:16 2008 +0000

    Update SessionManager API documentation to reflect string key -> ref counted pointer change for profiles.

commit 856fdf37a5bd81711ff0db1b307b8736ef4ae34e
Author: Robert Knight <robertknight@gmail.com>
Date:   Thu Mar 20 23:43:53 2008 +0000

    Fix assert.  Fall back to current locale's codec if a null pointer is passed to Emulation::setCodec()

commit 127e894d076061b991934adf84256b651bf31724
Author: Robert Knight <robertknight@gmail.com>
Date:   Thu Mar 20 22:45:11 2008 +0000

    Replace string key for profiles with ref-counted profile pointer.

commit 53246e5bd4ffcec56ca0ff94730f9ef3946e3f4c
Author: Robert Knight <robertknight@gmail.com>
Date:   Thu Mar 20 20:50:17 2008 +0000

    First step towards removing string keys as a means to reference profiles.  Change Profile base class from QObject to QSharedData and replace all usage of Profile* with KSharedPtr<Profile>

svn path=/trunk/KDE/kdebase/apps/konsole/; revision=788936
2008-03-22 21:06:59 +00:00
Robert Knight
087f6fc8bc Move focus proxy setting from the Part to the ViewManager. The ViewManager sets the focus proxy for its main splitter widget to the active view whenever it changes.
svn path=/trunk/KDE/kdebase/apps/konsole/; revision=785440
2008-03-14 02:01:22 +00:00
Robert Knight
c783ede701 Fix embedded terminal not gaining focus in Dolphin. Use view widget associated with active controller rather than ViewManager::activeView() may return null if the current view does not have focus.
svn path=/trunk/KDE/kdebase/apps/konsole/; revision=785435
2008-03-14 01:49:04 +00:00
Robert Knight
67c3559316 Remove Qt 4.4 version check and pre-4.4 code as qt-copy has now been updated to 4.4
svn path=/trunk/KDE/kdebase/apps/konsole/; revision=781948
2008-03-03 23:41:38 +00:00
Robert Knight
5e5857fd6d Hide shortcut column in Manage Profiles dialog in KPart
svn path=/trunk/KDE/kdebase/apps/konsole/; revision=758965
2008-01-09 18:13:29 +00:00
Eike Hein
5246e75c2f Add support for XComposite translucency to the Konsole KPart.
The decision to support translucent painting is made at part 
creation depending on whether the hosting application is using 
an ARGB visual and a composition manager has claimed the re-
levant X selection (via KWindowSystem).


svn path=/trunk/KDE/kdebase/apps/konsole/; revision=758145
2008-01-07 00:35:46 +00:00
Robert Knight
0d87b3132b Fix bug where KPart did not emit setWindowCaption() signal until it gained focus. Call controllerChanged() in ViewManager::createController() so that an activeViewChanged() signal is emitted when the first controller in the view manager is created. Fix ViewManager::controllerChanged() to only emit an activeViewChanged() signal if the new and previous controllers are different. Remove the checks for this from the MainWindow and Part slots connected to this signal.
svn path=/trunk/KDE/kdebase/apps/konsole/; revision=755284
2007-12-31 23:17:37 +00:00
Robert Knight
46cfc108d3 * Replace all usage of qDebug() with kDebug(), since kDebug() provides information about
which part of the code the message came from and allows filtering of output
  using kdebugdialog
* Remove explicit creation of singleton classes SessionManager,ColorSchemeManager and
  KeyboardTranslatorManager and automate it with K_GLOBAL_STATIC.
  This ensures that the singleton destructors are called appropriately by KPart clients
  when they unload the libkonsolepart library.


svn path=/trunk/KDE/kdebase/apps/konsole/; revision=754334
2007-12-29 16:07:31 +00:00
Robert Knight
9cb9a23616 Make 'Manage Profiles' dialog and Scrollback menu available in the Konsole part. Use a separate xmlgui file for the KPart's menus.
svn path=/trunk/KDE/kdebase/apps/konsole/; revision=754294
2007-12-29 14:00:42 +00:00
Robert Knight
12950c4109 Add a slot which sends a profile change command to the active session. This can be used to change any setting of the active session, using the same property=value semi-colon separated list format used by the konsoleprofile tool. This is experimental API and not guaranteed to be present in future KDE 4 releases.
svn path=/trunk/KDE/kdebase/apps/konsole/; revision=754238
2007-12-29 11:40:31 +00:00
Robert Knight
0a6186cead Add slots to the Konsole part which can be called to show the 'Manage Profiles' or 'Edit Current Profile' dialogs. They will be non-modal and are deleted automatically when closed. This is experimental API for the benefit of Yakuake and other clients which is not guaranteed to be present in later KDE 4 releases.
svn path=/trunk/KDE/kdebase/apps/konsole/; revision=754231
2007-12-29 11:13:04 +00:00
Robert Knight
1a23585d21 Make Konsole KPart emit a setWindowCaption() signal with the window caption as it is displayed in the standalone Konsole whenever it changes.
svn path=/trunk/KDE/kdebase/apps/konsole/; revision=754216
2007-12-29 10:48:53 +00:00
Robert Knight
ed54c709f8 Fix bug where Part::sendText() sent the text to every session in all terminal KParts within an application. Send the text instead only to the active session.
svn path=/trunk/KDE/kdebase/apps/konsole/; revision=754208
2007-12-29 10:32:22 +00:00
Robert Knight
619f44dd8d Fix crash when attempting to start the program in the Konsole part before the widget is shown and given focus. Check SessionController* pointer in the KPart before using it. When creating a controller in the ViewManager, set it as the active controller if there is no active controller at present.
svn path=/trunk/KDE/kdebase/apps/konsole/; revision=754203
2007-12-29 10:26:23 +00:00
Robert Knight
ccaeea481a Fix bug where multiple Konsole KParts within one application would not work. Part::activeSession() was always returning the first session from the shared SessionManager. In the second KPart, activeSession()->isRunning() would always return true even when the session for that part was not actually running, so the session was never started.
svn path=/trunk/KDE/kdebase/apps/konsole/; revision=754194
2007-12-29 10:12:48 +00:00
Robert Knight
09a6a5975d Disable tabbed navigation inside the Konsole part itself. This is something which I would like to add after KDE 4.0, but it does not work well enough to be used at the moment and causes problems for applications such as Yakuake and KDevelop which provide their own tabs.
svn path=/trunk/KDE/kdebase/apps/konsole/; revision=754004
2007-12-28 22:11:58 +00:00
Laurent Montel
868b7bcc0f Fix includ
svn path=/trunk/KDE/kdebase/apps/konsole/; revision=751637
2007-12-22 13:52:12 +00:00
Rafael Fernández López
53aec521c8 And sorry, forgot to remove this...
svn path=/trunk/KDE/kdebase/apps/konsole/; revision=750278
2007-12-19 01:40:15 +00:00
Rafael Fernández López
78cbb7faae Now the konsole part is autodestructed when no tabs do exist. This makes the desired effect on dolphin when typing "exit" on the terminal, the dock will be hidden.
BUG: 153648

svn path=/trunk/KDE/kdebase/apps/konsole/; revision=750276
2007-12-19 01:35:09 +00:00
Thomas Friedrichsmeier
ac511d63f0 Create a KXMLGUIFactory for the context menu on the fly, if needed, instead of forcibly merging with the hosts GUI.
BUG: 153646

svn path=/trunk/KDE/kdebase/apps/konsole/; revision=747059
2007-12-10 22:54:30 +00:00
Adriaan de Groot
8928e03af4 __FUNCTION__ is a gcc-ism
svn path=/trunk/KDE/kdebase/apps/konsole/; revision=746921
2007-12-10 16:25:20 +00:00
Hamish Rodda
8aff5c0cf9 KActionCollection::associateWidget -> addAssociatedWidget
svn path=/trunk/KDE/kdebase/apps/konsole/; revision=744420
2007-12-03 15:22:57 +00:00
Adam Treat
7dcf89b61e * Enable new tab action in konsolepart :)
svn path=/trunk/KDE/kdebase/apps/konsole/; revision=742261
2007-11-27 17:26:56 +00:00
Adam Treat
496d116ae4 * Might as well use the tabbed navigation since
1) KonsolePart now supports it
2) Can't see any case where a client app would
embed a konsolepart with tabs *explicitely* turned off
3) The context menu implicitly has an entry for tabbed
navigation...

Next up just have to hookup the shortcuts to create the
tabs.

svn path=/trunk/KDE/kdebase/apps/konsole/; revision=742234
2007-11-27 16:08:43 +00:00
Adam Treat
72c2d4c115 * Need this for context menu in konsolepart.
CCMAIL:faure@kde.org

svn path=/trunk/KDE/kdebase/apps/konsole/; revision=742231
2007-11-27 16:05:32 +00:00
Hamish Rodda
ad6e197df1 Port to KActionCollection::associateWidget and other api changes
svn path=/trunk/KDE/kdebase/apps/konsole/; revision=730654
2007-10-29 09:01:28 +00:00
Hamish Rodda
447f32011d Switch shortcuts to Qt::WidgetShortcut, so they do not clash with other actions when embedded in another application.
svn path=/trunk/KDE/kdebase/apps/konsole/; revision=726619
2007-10-18 09:49:09 +00:00
Andreas Pakulat
f412e5b5aa Merge the KConfig branch. This are the 3 main modules (+kdeadmin), which are
needed now because friday is the last BC day. The rest of the modules will
follow as fast as my laptop allows.

svn path=/trunk/KDE/kdebase/apps/konsole/; revision=721704
2007-10-05 22:21:25 +00:00
Anders Lund
e7d5f41ec1 Handle focus better by setting a focus proxy. This way setFocus() and hasFocus() etc works in a meaningful way ;)
Approved by Robert Knight.

svn path=/trunk/KDE/kdebase/apps/konsole/; revision=721467
2007-10-05 09:54:55 +00:00
Robert Knight
546bf76e48 Return the current line as the 'surrounding text' for input method queries and return the column index of the cursor as the cursor position. Fix link underlines not being erased when moving mouse around links which are adjacent to each other.
svn path=/trunk/KDE/kdebase/apps/konsole/; revision=709087
2007-09-06 14:40:16 +00:00
Robert Knight
37304d50ab Disable tabbed navigation in the Konsole Part. Add method to ViewManager to set navigation type for newly created containers. Fix crash when deleting a StackedViewContainer. Add note about a hack that needs to be fixed.
svn path=/trunk/KDE/kdebase/apps/konsole/; revision=708735
2007-09-05 14:35:04 +00:00
Andreas Pakulat
1f036c17a8 Make it possible to load konsole kpart with KPluginLoader by exporting the
factory with K_EXPORT_PLUGIN. Matthias said this shouldn't have bad
side-effects (as there's only 1 entry point in the part)

svn path=/trunk/KDE/kdebase/apps/konsole/; revision=706212
2007-08-29 17:42:38 +00:00
Robert Knight
6c8ef8512d Use a more correct method to set the working directory of new sessions. Session::running() -> Session::isRunning(). Remove some commented-out code.
svn path=/trunk/KDE/kdebase/apps/konsole/; revision=687611
2007-07-14 02:40:59 +00:00
Robert Knight
5872b79ef1 Replace old key translator with new key translator. Lightly tested. Fix some bugs in the new translator's decoding.
svn path=/trunk/KDE/kdebase/apps/konsole/; revision=676512
2007-06-17 01:01:53 +00:00
Robert Knight
c4de70b6c2 Ensure that there is always at least one session running by creating a single new session when the last one is closed.
svn path=/trunk/KDE/kdebase/apps/konsole/; revision=673745
2007-06-11 00:11:13 +00:00
Robert Knight
790822f1bf Use correct parent widget for part. Update TODO.
svn path=/trunk/KDE/kdebase/apps/konsole/; revision=673742
2007-06-10 22:53:55 +00:00
Robert Knight
e9c4c9cca0 Cleanup the Session class's API. Remove redundant and unused methods, give better names to others, reorganise the order in the header file. Add checks in the view to behave properly when it is not attached to a session. Make the Konsole part's behaviour compliant with the TerminalInterface API documentation.
svn path=/trunk/KDE/kdebase/apps/konsole/; revision=663705
2007-05-12 04:55:02 +00:00
Dirk Mueller
9ea3227384 include cleanup
svn path=/trunk/KDE/kdebase/apps/konsole/; revision=663054
2007-05-09 22:23:52 +00:00
Robert Knight
33c913383d EBN fixes. Mostly copyright and implementations including their own headers first.
svn path=/trunk/KDE/kdebase/apps/konsole/; revision=662726
2007-05-09 00:01:01 +00:00