Commit Graph

238 Commits

Author SHA1 Message Date
Tim Jenssen
ef0ee52bf9 Merge remote-tracking branch 'origin/qds/dev'
Conflicts:
	doc/qtcreator/src/overview/creator-only/creator-keyboard-shortcuts.qdoc
	doc/qtcreator/src/qtquick/qtquick-live-preview-devices.qdoc
	doc/qtcreator/src/qtquick/qtquick-profiler.qdoc
	src/plugins/qmlprojectmanager/qmlprojectmanager.qbs
	src/plugins/remotelinux/linuxdevicetester.cpp

Change-Id: I3683c1799df05209d05413383456b285a2daf96e
2024-04-23 16:05:55 +02:00
Thomas Hartmann
1f4d1a5820 QmlDesigner: Use different changelog path for QDS
* Do not deploy Qt Creator changelog for Qt Design Studio
* Set minimum size on combo box

Change-Id: Ic069c76b5a02963972ec199553ce9e27c820f75a
Reviewed-by: Qt CI Patch Build Bot <ci_patchbuild_bot@qt.io>
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2024-04-16 13:58:47 +00:00
David Schulz
ee8245d8aa Core: allow multiple contexts per widget
This makes it possible to allow different sets of actions for a specific
widget depending on the defined contexts for that widget.

Fixes: QTCREATORBUG-30675
Fixes: QTCREATORBUG-30677
Change-Id: I408e0ae445b364d4f450ccdd2fbdfc81ece45015
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2024-04-15 07:45:15 +00:00
Alessandro Portale
82703befa1 Core: Add "UI configuration" section to System Information
"System Information..." provides the output of qtdiag. Among other info,
it contains DPRs and font DPIs. With support of the DPI rounding policy,
those values may deviate the IDE process. This makes the "System
Information..." output in a bug report potentially lack relevant
information.

Also, the StyleHelper::UiElement* font may vary depending on DPR/DPI and
other system settings. Since these fonts are used in the Welcome screen
redesign, precise information of these fonts is missed in reports
regarding the redesign.

This change adds a "UI configuration" section to System Information. It
contains most data from the "Environment -> Interface" settings page,
and in addition a dump of all StyleHelper::UiElement fonts.

Task-number: QTCREATORBUG-30579
Task-number: QTCREATORBUG-30637
Task-number: QTCREATORBUG-30650
Change-Id: Iff2c58903c5f8d5dbae4884b0521a8b85469b188
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2024-04-10 09:06:35 +00:00
Eike Ziller
2484b50a99 Fix Fullscreen action text
On macOS the action was correctly switching between "Enter Full Screen"
and "Exit Full Screen", but on Windows & Linux the text was fixed to
"Full Screen" and the code tried to set the check state - but forgot to
make it checkable in the first place.

Actually it is unclear what the "correct" behavior is on Windows &
Linux. Neither on Gnome or KDE or Windows the action shows a check mark
when in Full Screen mode though. Either there is a tool button with an
icon, or some variation of "Exit Full Screen" or "Leave Full Screen".

Change the text of the action on all platforms, use "Exit Full Screen"
on all of them, but stay with just "Full Screen" on Windows & Linux (as
opposed to "Enter Full Screen" on macOS).

Fixes: QTCREATORBUG-30365
Change-Id: Ic55a30e32302ceb12f75449781b1aefecb370c97
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Reviewed-by: David Schulz <david.schulz@qt.io>
2024-03-11 05:21:55 +00:00
hjk
6d6ec00cdb Core: Wrap moribund dialogs into QPointer
There's no guarantee that items in the collected list don't die for
other reasons before it's their turn in the loop.

Change-Id: I5e81a25c3c205646eece30d6dd1a95f4b97eda05
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2024-03-04 14:17:45 +00:00
Cristian Adam
b7a8ee92be Core: Mention Ctrl+Shift+K into the hide menubar messagebox
This way the user can trigger the "Show Menu Bar" action when the
Ctrl+Alt+M doesn't work.

Task-number: QTCREATORBUG-30114
Change-Id: I4e1d14b7bf7554ce1a262c4b1d2671f8d0b81b85
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2024-02-23 10:07:11 +00:00
Eike Ziller
70f7e275e2 EditorManager: Avoid warnings about already registered actions
When opening new editor windows, we want the _window_ to have the
EditorManager context as well as the individual window context, but the
window _actions_ (close, etc) may only be registered for the individual
window context.

Add the corresponding option to ICore::registerWindow et al.

Change-Id: I67d0a6b386603e0047a77dfb357c207e7ffe99e6
Reviewed-by: David Schulz <david.schulz@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
2024-02-19 13:50:38 +00:00
hjk
705dba388f Core: Simplify Cycle Mode Selector Styles action setup
... and remove unused m_saveAllAction member.

Change-Id: If6ebb448b68c5ed776b9ed7eda872321723cc48f
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2024-02-05 15:19:06 +00:00
Eike Ziller
cdef799321 Remove RestartDialog in favor of static function
The pattern was always to create the dialog and exec it, which can be
done as well with just a function call.

Change-Id: I3934cf5d869211713902abd333aa64d87ec59f32
Reviewed-by: hjk <hjk@qt.io>
2024-01-26 13:59:14 +00:00
Xavier BESSON
2796e69ab5 Add display search results using relative paths to project root
Task-number: QTCREATORBUG-29462
Change-Id: Ic5d597846cfcc6589cbf1b81151e05c95ee8fab0
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2024-01-25 10:46:43 +00:00
Eike Ziller
ed1b6b958a ExtensionSystem/Core: Use more std::chrono
It is more descriptive than an int.

Change-Id: Ibcb8c3c6210bfa414bb33e36ee401c97ca5fab75
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
2024-01-22 13:51:00 +00:00
Christian Kandeler
3fc1b5f57b Core: Let callers specify which part of an options page to pre-select
... and use it for the "Manage kits" functionality.
We will make use of this in other contexts as well.

Task-number: QTCREATORBUG-25077
Change-Id: I79c622075b9385b060aed73534d39acc23fd765e
Reviewed-by: hjk <hjk@qt.io>
2024-01-19 11:27:11 +00:00
hjk
6c5cd8216a Core: More ActionBuilder use in icore.cpp
After introducing ActionBuilder::setSeparator().

Change-Id: I54e89aae66c4e4a6f2073df6287140c41da887d8
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2023-12-18 15:36:05 +00:00
hjk
b442ca3873 Core: Rename ActionBuilder::setOn* to addOn*
There could be multiple connections.

Change-Id: I7dbca9d24599f776b7d1f1bfa11826e3eeb5640a
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2023-12-13 13:00:00 +00:00
hjk
e17f0b6164 Core: Rename ActionBuilder::setContainer to addToContainer
An action/command can be used in several places.

Change-Id: Ifa26f64f7d200d93ada13f272de0fa833f886997
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2023-12-13 08:37:10 +00:00
Eike Ziller
2e280e1c50 Merge remote-tracking branch 'origin/12.0'
Conflicts:
	src/plugins/clangcodemodel/clangdfollowsymbol.cpp
	src/plugins/debugger/debuggerruncontrol.cpp
	src/plugins/projectexplorer/miniprojecttargetselector.cpp

Change-Id: I45b7fee1a1d784c44f2139fb1ede69190d23d6fd
2023-12-06 16:50:15 +01:00
Alessandro Portale
a71b33944b Core: Restore opening of files that are dropped on the MainWindow
The code to handle dropping unintentionally got commented out, then
fixed, then commented out again.

This change restores it.

Amends: e5f74d217b
..which amended: 5da1f14903
..which amended: e34762c844

Fixes: QTCREATORBUG-29961
Change-Id: Iccc8a9b7bc24bc3475ed4fa37a7c231a1f575c1c
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2023-11-28 14:03:21 +00:00
Eike Ziller
a35deb1532 Use sidebar buttons for hiding/showing dock areas
So far, if a mode includes navigation widget placeholders, these are
used for the sidebar toggle buttons, otherwise the buttons are disabled.

Now, if a mode does not include navigation widget placeholders, but the
mode has a FancyMainWindow attached, use the buttons to hide or show the
corresponding dock widget area (left or right).

Since QMainWindow does not really support "hiding a dock widget area",
the FancyMainWindow needs to track that state manually, by tracking the
dock widgets that were visible before "hiding the dock widget area".

Also, if a dock widget is dragged into a "hidden" area, or a widget is
made visible or "unfloated" into that area, show the other widgets in the
area again as well, "unhiding" the area.

Since the mode widgets that have a mainwindow somewhere usually wrap
that into a splitter for the output panes, and the Design mode is
actually a stack widget, IMode needs another method that returns the
appropriate FancyMainWindow if available.

The patch implements this for Widget Designer.

Change-Id: I03531f4d5130c846ff5d65831b1c9be210e1c561
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
2023-11-28 13:17:22 +00:00
Cristian Adam
1a37da15c7 Debugger: Add our lldb to the system search paths
This way the user doesn't have to manually register lldb.exe

Change-Id: Id0a19de0962d8ba47a66a8d1909dfe2eb5ca0a6f
Reviewed-by: David Schulz <david.schulz@qt.io>
2023-11-21 14:38:33 +00:00
Alessandro Portale
1f5f76cdf9 Core: Move generation of "about" text to ICore
This introduces ICore::aboutInformationCompact() and
ICore::aboutInformationHtml() and moves the existing code there. The
former is used in the "System Information" dialog, the latter in
"About".

aboutInformationCompact() will be used for the "Copy and Close" feature
in an follow-up patch.

Task-number: QTCREATORBUG-29886
Change-Id: Iec818e376b3f02f52da00428285ad69b94d8adea
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2023-11-15 12:24:17 +00:00
Alessandro Portale
ac121149b1 Core: Make strings in ICore::versionString() non-translated
Change-Id: I462bab0160cb4b574da5a5ae6147915706a9f43e
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2023-11-15 12:07:48 +00:00
Eike Ziller
ab549936f8 Core: Remove commented code that adds About Qt action
This is better handled via the `System Information` action nowadays

Change-Id: I220ba9e7db433f0c644dd3a04cc1cc6bf13aa56d
Reviewed-by: hjk <hjk@qt.io>
2023-11-13 13:51:55 +00:00
hjk
ab8ba7f264 Core: Replace new "Action" by an "ActionBuilder"
This needs not be stored somewhere but does its work latest
at destruction automatically.

Change-Id: If929f5a5ccc15b085f110d8d9db8f72ff2a5fac5
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: hjk <hjk@qt.io>
2023-11-10 14:33:15 +00:00
hjk
ef9be25469 Core: Have Core::Action for Help->Contact and Change Log
Change-Id: I606bc69c860222c66b241d25363941dd71aeab85
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2023-11-10 07:09:23 +00:00
hjk
d391c0c74e Core: Use Core::Action for 'About...' stuff
... and add the necessary Action::setMenuRole()

Change-Id: I2bb309ae115c1e015ff848e0712327360ead23cd
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2023-11-10 06:54:35 +00:00
hjk
f8bbdf6f07 Core: Inline ICore::init() into ICore constructor
More natural setup.

Change-Id: I5a51cdec3f955e4b887613bd3dea4b25d485e844
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2023-11-06 13:38:40 +00:00
Eike Ziller
1a398a83b5 Core: Fix dialogParent for separate windows
The dialog parent is supposed to fall back to the main window, if there
is no modal window and the active window is not a popup or a splash
screen.

But testing for "popup or splash screen" does not work with
`testAnyFlags(Popup | SplashScreen)` because these flags are combined
flags - e.g. "Popup" is "Window + something", so when using
testAnyFlags(Popup), that returns true for _any_ Window, regardless of
popup or not.

Amends 60f11cf637

Fixes: QTCREATORBUG-29741
Change-Id: I9e8defc6dd7193f5008decda0eda04dedc62f9df
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2023-10-26 12:07:08 +00:00
Eike Ziller
e51b378ac9 Core/Tr: Fix menu bar action
It is "menu bar", and use placeholder for shortcut instead of
concatenation.

Change-Id: I60094a5fac3893663180f7ef573b6dece7670111
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
2023-10-18 14:11:13 +00:00
Tim Jenssen
85ea2758ac Merge remote-tracking branch 'origin/qds/dev' into 12.0
Conflicts:
	share/qtcreator/qmldesigner/connectionseditor/SuggestionPopup.qml
	share/qtcreator/themes/dark.creatortheme
	share/qtcreator/themes/default.creatortheme
	share/qtcreator/themes/flat-dark.creatortheme
	share/qtcreator/themes/flat-light.creatortheme
	share/qtcreator/themes/flat.creatortheme
	src/libs/utils/CMakeLists.txt
	src/plugins/CMakeLists.txt
	src/plugins/qmlprojectmanager/qmlproject.cpp
	src/plugins/qmlprojectmanager/qmlprojectrunconfiguration.cpp

Change-Id: Idd87c281e1aa7b7fd2702473ad55e18563cbfb21
2023-10-05 15:53:42 +02:00
hjk
4e8bcc40e7 ModeManager: Remove unused constructor argument
Change-Id: I7856a832db61a27ab5fdabf79ff9a359acdb866a
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2023-10-05 06:27:29 +00:00
hjk
58efc778f5 Core: Swap ICore/MainWindow "ownership"
Change-Id: Iba387781624d88f814293af0f7b7ed697da1d822
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2023-10-05 06:26:21 +00:00
Tim Jenssen
97ca8cc270 Core: add ICore::isQtDesignStudio()
Change-Id: I3aed97b62abd05b283ac327be210af75f173383d
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2023-10-04 14:39:39 +00:00
hjk
ae4852a3ea Core: Rename MainWindowPrivate to ICorePrivate
Mechanical, plan is to move m_mainWindow there and switch
around construction.

Change-Id: Ic7936623586ac68c2cdd69a40042262802579d23
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2023-10-04 13:48:14 +00:00
Eike Ziller
ce291a0bc2 Core: Fix appearance of mutltiple status bars
There should only be one.

Fixes: QTCREATORBUG-29691
Change-Id: I02b4aaec35d6a35b0130cdbc9d933aed9cfb8132
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2023-10-04 09:02:47 +00:00
Cristian Adam
895c588dd6 Core: Brings back revision in About dialog
The revision is part of the Utils::appInfo() structure. Make sure to
display it when is set.

Change-Id: I0dece3bdd011127f63974b963e35f73834416b6c
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2023-10-04 06:46:12 +00:00
hjk
3d7cf53a1e Core: Ramp down MainWindow in it's ICore::pimpl function
Change-Id: I7c4934248ea4794f7d4eb95f98d19994b56fa0f1
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2023-10-02 13:27:04 +00:00
hjk
61270e910f Core: Swap ICore and MainWindow "ownership"
Change-Id: Ibfa223da0f4d5195ae2f2783352346ca72b920bd
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2023-09-29 12:11:38 +00:00
hjk
342e066886 Utils, all: Standardize on QtcSettings
Change-Id: Id222016f15b1c3bfe6710fe5d0297666d4565ef1
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2023-09-27 13:25:31 +00:00
hjk
d6fe357d81 Utils: Use a proper class as Key
The Key encapsulates now a QByteArray.

Plan is to use QByteArray::fromRawData on literals, but that's not
active yet due to an unclear ASAN report, see the gerrit discussion.

For now we also paddle back when interfacing QSettings, instead of mimicing
writing a QVariantMap (and fail in some corners), always convert
the Store. This is meant to go away in the future when code paths
are better controled.

Change-Id: Id1206a434d511f8003903d5322c7c9bd5f5fb859
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2023-09-27 09:41:44 +00:00
hjk
e5f74d217b Core: Merge mainwindow and icore file pairs
So far the main window acted a bit like ICore's pimpl.
Aim at making that a bit more similar to other places.

The files are kept for now to not have to adjust #includes
all over the place and there's some hope to move code back there.

Change-Id: I150e2dd0971bfab44cba89e0c51bb3f37062b8d3
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2023-09-26 09:41:45 +00:00
hjk
41856dd254 Core: Disentangle SettingsDatabase access
There's nothing inherently tied to the main window here.

Change-Id: I48ae09777a4408fc4c955d23fdee3483d8a97dd0
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2023-09-21 13:50:02 +00:00
Artem Sokolovskii
f4e50126b1 Core: Add clearAboutInformation function
Change-Id: Ib6dcc3b963917c096756cbff09541f4e13c8184b
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2023-09-07 12:12:26 +00:00
hjk
900ea82fd1 Core: Don't save settings on startup anymore
Amends a68352f013.

This is getting in the way, it does not look needed, and it is lost
in history why it ever was.

Change-Id: I68ebdafc78e3259c73c64364607aef6eb74d2869
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2023-06-29 06:46:05 +00:00
Eike Ziller
dff9e1463b Reduce usage of app_version header
Most information is available via Q(Core|Gui)Application.
Add an AppInfo structure for the things that are not.

This avoids that the information ends up duplicated and
hardcoded in the plugins, which is not needed or desired.

Change-Id: I4d565e75c42a7b8facafa90c27096ea49359215d
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
2023-06-26 06:57:46 +00:00
Jarek Kobus
a78720060e FindFlags: Move it into Utils lib
It's going to be reused in filesearch.h API.

Change-Id: I7ef133368536a647e19949ba8623134cf078a87d
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2023-05-26 07:59:41 +00:00
Tim Jenßen
feabda3aa7 Merge remote-tracking branch 'origin/10.0' into qds/dev
bigger conflicts resolved at:
  src/plugins/qmldesigner/CMakeLists.txt
  src/plugins/qmlprojectmanager/qmlprojectrunconfiguration.cpp

Change-Id: I08e2a109d8e37cbd77225129854e9e633725bfc7
2023-03-26 16:26:18 +02:00
Tim Jenssen
b619f24396 crashpad: change chrashpad dumps location to user directory on macOS
This is necessary to not pollute the signed and notarized .app
bundle.

Task-number: QDS-9113
Change-Id: I74e0bced5679faac94b27d2a31ea10a7949fb21f
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2023-03-06 04:46:03 +00:00
hjk
015b1ee53c Core: Tr::tr
Change-Id: I0064814b0689f0f65072d2b0f60e26162587fd54
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2023-01-17 14:34:16 +00:00
Kai Köhne
56baf8c058 Remove GPL-3.0+ from license identifiers
Since we also license under GPL-3.0 WITH Qt-GPL-exception-1.0,
this applies only to a hypothetical newer version of GPL, that doesn't
exist yet. If such a version emerges, we can still decide to relicense...

While at it, replace (deprecated) GPL-3.0 with more explicit GPL-3.0-only

Change was done by running

  find . -type f -exec perl -pi -e "s/LicenseRef-Qt-Commercial OR GPL-3.0\+ OR GPL-3.0 WITH Qt-GPL-exception-1.0/LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0/g" {} \;

Change-Id: I5097e6ce8d10233993ee30d7e25120e2659eb10b
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2023-01-06 11:15:13 +00:00