Commit Graph

1388 Commits

Author SHA1 Message Date
hjk
fc58cb88c0 Debugger: Fix "Debugger font size follows main editor"
... for the ex-snapshot-now-engine-manager view.

Task-number: QTCREATORBUG-21803
Change-Id: I0c0a6199fa1dabc5c045fe6d0740de458dc63cda
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Reviewed-by: Tim Blechmann <tim@klingt.org>
2019-01-10 13:36:49 +00:00
Aaron Barany
21c0f5395e Debugger: Fix sizing of debugger columns
Added span column property to BaseTreeView. This takes an index to a column
that will span remaining space not explicitly taken by the other columns.
This listens to resizing of the tree view and columns that are manually
resized to keep the sizes consistent.

The stack view now once again uses the StackView class, which now sets the
function column as the span column. This will adjust the column size the
first time stack frame contents are encountered. It will not resize
automatically until it's re-created (the next debug session) so it doesn't
undo custom resizing. This also restores the ability to toggle stack
addresses. Some obsolete parts of this class were removed as part of
retrofitting it for the current state of the debugger.

Stack, breakpoint, and thread views now resize remaining space for the
function column rather than empty space at the end. This is generally the
most important field when debugging and can get very long, especially in
C++.

Task-number: QTCREATORBUG-21763
Change-Id: I821c83d1d951f3311d7fa9fcddcbdeedfeed1573
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2019-01-08 18:43:44 +00:00
Eike Ziller
8770d83fc8 Add general UI introduction
Adds a Help > UI Introduction, which highlights basic aspects of the Qt
Creator UI.

The pages to show are defined in a format that can later move into a
text based configuration file like JSON. It specifies an optional object
name of a widget to highlight, a title, a brief description and a longer
description (potentially with tables, lists and other simple HTML).

Fixes: QTCREATORBUG-21585
Change-Id: Idb64c87e1d752bc24437588278093a96be0eeddb
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
2018-12-18 09:53:36 +00:00
Eike Ziller
9084ca73df Merge remote-tracking branch 'origin/4.8'
Conflicts:
	qbs/modules/qtc/qtc.qbs
	qtcreator.pri
	src/plugins/cpptools/compileroptionsbuilder.cpp

Change-Id: I87f47cecbb924064296a002fd9446a0627acad8e
2018-12-12 09:44:13 +01:00
Aaron Barany
77ad54a6ef Debugger: Remove obsolete function declation
Change-Id: Ic528f0a97341773093822089bcc66f096f5e2327
Reviewed-by: hjk <hjk@qt.io>
2018-12-10 18:42:00 +00:00
Eike Ziller
3d1d9aae2e Merge remote-tracking branch 'origin/4.8'
Conflicts:
	src/plugins/winrt/winrtdevicefactory.cpp

Change-Id: I33b8697e2ebf2bea051d7f1144449e0743ee16a5
2018-11-19 10:00:18 +01:00
Robert Loehning
efe30bc5a5 Debugger: Fix translation contexts
Change-Id: Id41ba15a4f0f5956148661e3c329cbb36a373f48
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2018-11-14 13:21:17 +00:00
hjk
4d3fe76796 Debugger: Add some labels to the preset views
In the hope to make it more obvious what the new views are all about,.

Change-Id: I3abde8a12cb5ac1f532f3b453c8d73f36498ff3d
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2018-11-14 09:47:52 +00:00
hjk
ad37ad1a86 Debugger: Fix cut-and-pasto
Amends c3f29684fab92a6b51dfaa59254a61c86ed4968a.

Change-Id: I19e7a9ce65780822f8a9718906acc68f6f7e7454
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
2018-11-13 07:56:53 +00:00
hjk
6a043d32dc Debugger: Fix handling of some actions after multiinferior split
The pattern used is some inactive/invible global action with a
command to put in the menus, and per-engine action "overloads"
to reflect the active engine's state once there is an engine.

Task-number: QTCREATORBUG-21454
Change-Id: I861a42994849ef9f0b51fb7b1608f14fa7fa9d7c
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2018-11-13 07:16:37 +00:00
Orgad Shaneh
423b7391dd Debugger: Remove unused function declarations
Amends 3b5ecac238
and 36b654567d.

Change-Id: I8e8b226f34297ec4d34edbcc63b93d0f5045bcf4
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2018-11-12 06:40:27 +00:00
hjk
e3cc0ce694 Debugger: Simplify code
isReverseDebuggingEnabled() always returns true for GDB nowadays.

Change-Id: Ic5500a9b191dafc2e9893d75f584a6b304c43a8f
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2018-11-09 13:42:27 +00:00
hjk
03447f1734 Debugger: Code cosmetics
Remove dead code

Change-Id: I07c30fdd777f2bdaf7695d740448fffb65349e9c
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2018-11-09 13:30:19 +00:00
hjk
05ba1a0ff9 Debugger: Move some constants to more local scopes
Change-Id: I1b8b7ca594e4425c272ea092d915482f596698b8
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2018-11-09 13:30:11 +00:00
Eike Ziller
3666e3aaeb Merge remote-tracking branch 'origin/4.8'
Conflicts:
	tests/unit/unittest/unittest.pro

Change-Id: I4f0ab05f96ee60900a3a35fad4c7331238367593
2018-11-09 13:30:40 +01:00
Alessandro Portale
e5da4a791c Debugger: Use the toolbar version of start debug icon on the toolbar
Change-Id: Iac38599ead4851f5aac978d7484f0b230809f7ac
Reviewed-by: hjk <hjk@qt.io>
2018-11-09 09:14:45 +00:00
Eike Ziller
1473bc5891 Merge remote-tracking branch 'origin/4.8'
Conflicts:
	src/plugins/debugger/debuggermainwindow.cpp
	src/plugins/qbsprojectmanager/qbsbuildstep.cpp
	src/plugins/winrt/winrtdevicefactory.cpp
	tests/unit/unittest/gtest-creator-printing.cpp
	tests/unit/unittest/gtest-creator-printing.h
	tests/unit/unittest/unittest.pro

Change-Id: Ie9b80b87a8a4fa81baf72a2daa7919b21371c15e
2018-11-06 09:20:00 +01:00
Eike Ziller
183cfb0772 Make the currently visible debugger UI define the behavior of F5
That fixes the behavior of F5 for the debuggers which were not started
directly with a run configuration (attach, debug external application).
It has the disadvantage that it is only possible to start another
application in the debugger after switching to the "Debugger Preset",
even after you switch the startup project.

Fixes: QTCREATORBUG-21261
Change-Id: Id4d4c81920939af2b34b462d87c815719bed6aff
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Reviewed-by: hjk <hjk@qt.io>
2018-11-05 17:44:04 +00:00
Eike Ziller
1c17ed6db8 Debugger: Use engine specific contexts for delegating actions
Some actions that are engine specific are visible globally in the Debug
menu, like stopping, interrupting and continuing the debugger, and
various step variants.
These are registered in the action manager by the debugger plugin.

Avoid duplicating the state management of these actions in the debugger
plugin, by registering these actions as disabled dummies.
The actual actions of the specific debugger run are now registered in
the action manager by the debugger engine instance, for a debugger
engine instance specific context.
The engine manager sets the engine instance specific context when the UI
is switched to the specific debugger run.

Change-Id: I0a311cec0856365b830460dec2ce33d14a2289c0
Reviewed-by: hjk <hjk@qt.io>
2018-10-25 12:58:25 +00:00
Eike Ziller
fd7cba88ef Merge remote-tracking branch 'origin/4.8'
Conflicts:
	doc/src/editors/creator-only/creator-code-pasting.qdoc
	src/plugins/android/androidbuildapkwidget.cpp

Change-Id: Iea8b7135643d14ffe49d10b14bedb8fa5ac48063
2018-10-24 13:58:45 +02:00
Robert Loehning
d68c2e5f68 Debugger: Remove wrong white space
Change-Id: Ie3f9ebf0da7eb62748584e691495f4805e2faab0
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
Reviewed-by: hjk <hjk@qt.io>
2018-10-22 14:28:22 +00:00
Eike Ziller
95db30bd3a Merge remote-tracking branch 'origin/4.8'
Conflicts:
	src/plugins/debugger/debuggeritem.cpp
	tests/unit/unittest/unittest.pro

Change-Id: Id2e4e9c2bc87b2556d7c2845aea3fe2fa11b630b
2018-10-22 09:53:54 +02:00
hjk
32b4dbbd84 Debugger: Use actions in different contexts
... for F10-as-in-Start-and-break-at-main and F10-as-in-step-over.

Change-Id: Ie8e9e9be389a09a1485cadeea8b2d035a130920a
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2018-10-17 10:50:23 +00:00
hjk
fa96f73192 Debugger: Rework step{In,Out,Over} handling
Main menu action pass operation to current engine, everything else
is handled there.

Combine execute{Step,Next} and execute{Step,Next}I functions.
Implementation were mostly similar, in some cases unneeded
(the instruction-wise version e.g. for Python)

Drop GDB-isms 'step', 'next' in favor of 'step in' and 'step over'.

Change-Id: I232232bc7a67d9d297a74f1c81dc43be96787d34
Reviewed-by: David Schulz <david.schulz@qt.io>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2018-10-16 10:34:31 +00:00
Eike Ziller
3f3ba92fe9 Fix debugger "step into" icon
Fix-up of 3b5ecac238

Change-Id: I0c9197e4c1cf62ccdb57710af00189b32c850fd5
Reviewed-by: hjk <hjk@qt.io>
2018-10-16 05:13:09 +00:00
Orgad Shaneh
147a3c27c4 Debugger: Strip QLatin1* where possible
Change-Id: Idcab23875b5dc2ecf55e3303f417b995e2252720
Reviewed-by: hjk <hjk@qt.io>
2018-10-13 16:32:31 +00:00
hjk
36b654567d Debugger: Finalize moving Operate by Instruction to engines
Fixes: QTCREATORBUG-21211
Fixes: QTCREATORBUG-21212
Change-Id: I6c0259052336f2141462157c319abeaec9a1e483
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2018-10-05 12:54:44 +00:00
hjk
0e84c8892d Debugger: Do not double quote in tooltips
Instead of e.g. 'Interrupt "GDB for "test""' use 'Interrupt GDB for "test"'
for button tooltips.

Change-Id: Ibe08e0007800332696dbc7f298bf5119ea8e5338
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2018-10-05 10:52:57 +00:00
hjk
4d2a6db1a8 Debugger: Show something in start action text again
... even if the action is disabled.

Change-Id: I7f5bb0abd73d25650fab4c9dafbe70c772d2cb0e
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2018-10-05 08:50:07 +00:00
hjk
a743e25d27 Debugger: Use the intented mechanism to update icon on the fat button
Change-Id: I58e40c2d3db23d00d55e5e86c6f4ebc6cbabea90
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2018-10-05 08:49:17 +00:00
hjk
10262574d4 Debugger: Fix stopping of core file debugging using the fat button
Task-number: QTCREATORBUG-21094
Change-Id: If60f6bea93a583ab27e9e8b17c07402b2ac0854c
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2018-10-04 14:42:57 +00:00
hjk
92325c90ce Debugger: Rename snapshothandler.{cpp,h} to enginemanager.{cpp,h}
That's what they are nowadays.

Change-Id: I1bd6db18f2142ecf488eba51ca739675eac753c7
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2018-09-28 07:38:55 +00:00
Christian Stenger
1b751c2d47 Debugger: Allow watching complex expression for QML
Latest restructuring made the 'Add Expression Evaluator'
action to a no-op when not debugging.
Reflect this by disabling the action as long the user is
not debugging and allow complex expressions to be evaluated
for QML as well.

Fixes: QTCREATORBUG-19050
Change-Id: I2d6421a121e2169981b992a617f4d2b7264a8091
Reviewed-by: hjk <hjk@qt.io>
2018-09-24 13:37:12 +00:00
Orgad Shaneh
539b10727e Merge remote-tracking branch 'origin/4.8'
Conflicts:
	src/plugins/debugger/debuggermainwindow.cpp

Change-Id: I07496916dd37b842d57ce5c49f99c079a9095a5f
2018-09-21 10:49:44 +03:00
hjk
6635f85d47 Debugger: Move some debugger specific bits out of debuggermainwindow.*
A step towards making the perspective handling independent of the
debugger plugin.

Change-Id: Ic07f4b34d44c48f16a494ba7f470e0a34d3d56a3
Reviewed-by: David Schulz <david.schulz@qt.io>
2018-09-21 06:14:05 +00:00
hjk
0137e2ace9 Debugger: Do not guess kit when attaching using the app output pane
We have access to the kit that was used to start the project,
use that.

Change-Id: Ie73129d4ee4451f272ba7539c950409b5d9636af
Reviewed-by: David Schulz <david.schulz@qt.io>
2018-09-19 05:50:08 +00:00
hjk
375791ec58 Debugger: Re-organize registration of sub-perspective switcher
Change-Id: Ia3559e5c4793bb297c9bdfbdf32a56d285ee0700
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2018-09-11 11:18:09 +00:00
hjk
bdc1ea1d74 Debugger: Do not remember persistent layout settings per engine
Fixes: QTCREATORBUG-21006
Change-Id: Id3c2062eb5b42808d666f0fc3620a82666fe14a2
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2018-09-11 08:48:31 +00:00
hjk
59e734d9da Debugger: Rename "Snapshot" window to "Debugger Perspectives"
That's what it is nowadays.

Change-Id: I0b9c29e9adc322a923c6901b6e1f3fc9937c2892
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2018-09-10 07:49:05 +00:00
hjk
c7f0285c4c Debugger: Consolidate breakpoint search
We already have a concept of Context when action on editor events,
use that directly when searching an (almost) matching breakpoint
instead of translating it into breakpoint manager's interface
language.

This also centralizes the guesswork for non-exact matches in one
place, making it easier to fix currently wrong matches later.

Change-Id: I5579e7e01792d425cad4ccf1dbcbbd1bd56c84ec
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2018-09-04 13:33:29 +00:00
hjk
a68e8c5b69 Debugger: Move session load/restore handling
... to breakpoint and watchhandler.

More modular this way.

Change-Id: I4a45481fcc2bfde67b164bd7274fb7b2a12cb7ac
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2018-08-29 09:38:38 +00:00
hjk
893146b8b6 Debugger: Split ToolTipManager into per-engine parts
Change-Id: If2e601a91ad2a0e5ba30916a5d1f2312ecff944f
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2018-08-28 14:14:21 +00:00
hjk
b97e9bd429 Debugger: Make Global Debugger Log off by default
It's more a debugging aid for work on the Debugger itself
than a feature of general interest.

Change-Id: I915019e28df6cf4a5c369ab2de45959943cd4dd4
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2018-08-27 12:47:47 +00:00
hjk
fd25bbd99d Debugger: Re-enable breakpoint enabling via gutter context menu
Task-number: QTCREATORBUG-20970
Change-Id: Ie8fc2af8e99e82018a9b4262fe6053cb714e7d60
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2018-08-24 06:20:06 +00:00
hjk
468e71cbe4 Debugger: Remove two unnecessary captures of 'this'
Change-Id: Ic3bfa3d0539974087d08153a66a80f29a6ff8257
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
2018-08-23 15:20:32 +00:00
Christian Stenger
c03e5aebe0 Debugger: Fix typo
Change-Id: I16be2a69d0050e27b908bff4991dfb11e9dfd25e
Reviewed-by: hjk <hjk@qt.io>
2018-08-23 14:57:43 +00:00
hjk
4b7a9ae5db Debugger: Replace Internal::mainWindow
... by DebuggerMainWindow::instance() and clean up a few uses.

Change-Id: I7ae4073aa97fc2f00108533bed91db330b07880f
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2018-08-23 13:55:56 +00:00
hjk
e6e38df436 Debugger: Shift some perspective related API to the perspective class
Also, use QString uniformly for the (now rarely used) perspective ids.

Change-Id: I682062e7d179d0fcfd309e7714713bd1218bd8bb
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
2018-08-23 08:57:10 +00:00
hjk
32d2a4c985 Shift perspective ownership to plugins
Change-Id: Id146ca771b4dc92f35cf156efbabae154f2d940f
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
2018-08-21 15:38:22 +00:00
hjk
263cf4c608 ProjectExplorer: Remove RunWorker::setDisplayName
It has been an obsolete alias for setId for a while and downstream
uses have been adapted.

Change-Id: I467370aa67054599c7771e8275d28e62ddc461fa
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2018-08-21 08:02:22 +00:00