Merge "Merge remote-tracking branch 'origin/13.0'"

This commit is contained in:
The Qt Project
2024-03-20 14:06:27 +00:00
107 changed files with 9346 additions and 9167 deletions

View File

@@ -10,7 +10,7 @@ Project {
mainDocConfFile: "qtcreator/qtcreator-online.qdocconf"
files: [
"src/**/*",
"qtcreator/src/**/*",
]
}
@@ -20,7 +20,7 @@ Project {
mainDocConfFile: "qtcreator/qtcreator.qdocconf"
files: [
"src/**/*",
"qtcreator/src/**/*",
]
}
@@ -32,10 +32,8 @@ Project {
Group {
name: "sources"
files: [
"api/*.qdoc",
"api/**/*",
"qtcreatordev/src/**/*",
]
excludeFiles: [mainDocConfFile]
}
}
@@ -47,10 +45,8 @@ Project {
Group {
name: "sources"
files: [
"api/*.qdoc",
"api/**/*",
"qtcreatordev/src/**/*",
]
excludeFiles: [mainDocConfFile]
}
}

View File

@@ -27,6 +27,7 @@ depends += qtwidgets \
qtcmake \
qtcore \
qtqml \
qtqmltest \
qtquick \
qtquickcontrols \
qmake \

View File

@@ -12,27 +12,34 @@
<li><a href="creator-overview.html">Overview</a></li>
<li><a href="creator-quick-tour.html">User Interface</a></li>
<li><a href="creator-configuring.html">Configuring Qt Creator</a></li>
<li><a href="creator-build-example-application.html">Building and Running an Example</a></li>
<li><a href="creator-tutorials.html">Tutorials</a></li>
</ul>
</div>
</div>
<div class="sectionlist normallist">
<div class="heading">
<h2>Coding</h2>
<h2>Tutorials</h2>
</div>
<div class="indexboxcont indexboxbar">
<ul>
<li><a href="creator-tutorial-adding-internal-libraries-to-projects.html">Adding an Internal Library to a qmake Project</a></li>
<li><a href="creator-build-example-application.html">Building and Running an Example</a></li>
<li><a href="qtcreator-accelbubble-example.html">Creating a Mobile Application</a></li>
<li><a href="qtcreator-transitions-example.html">Creating a Qt Quick Application</a></li>
<li><a href="creator-writing-program.html">Creating a Qt Widget Based Application</a></li>
<li><a href="creator-tutorial-python-application-qt-quick.html">Creating a Qt for Python Application with Qt Quick</a></li>
<li><a href="creator-tutorial-python-application-widgets.html">Creating a Qt for Python Application with Qt Widgets</a></li>
<li><a href="creator-debugging-example.html">Debugging a C++ Application</a></li>
<li><a href="creator-qml-debugging-example.html">Debugging a Qt Quick Application</a></li>
<li><a href="creator-tutorials.html">See All</a></li>
</ul>
</div>
<ul>
<li><a href="creator-editor-functions.html">Writing Code</a></li>
<li><a href="creator-editor-options.html">Configuring the Editor</a></li>
</ul>
</div>
<div class="sectionlist normallist">
<div class="heading">
<h2>Building and Running</h2>
<h2>Running on Devices</h2>
</div>
<ul>
<li><a href="creator-live-preview.html">Validating with Target Hardware</a></li>
<li><a href="creator-building-targets.html">Building for Multiple Platforms</a></li>
<li><a href="creator-deployment.html">Deploying to Devices</a></li>
<li><a href="creator-connecting-mobile.html">Connecting Devices</a></li>
</ul>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.1 KiB

After

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 78 KiB

After

Width:  |  Height:  |  Size: 17 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 23 KiB

After

Width:  |  Height:  |  Size: 22 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.8 KiB

View File

@@ -146,8 +146,8 @@
\brief Create a connection to an Axivion dashboard server.
Set preferences for the Axivion static code analysis tool in
\preferences > \uicontrol Axivion.
To set preferences for the Axivion static code analysis tool, go to
\preferences > \uicontrol Axivion.
\image qtcreator-preferences-axivion.webp {General tab in Axivion Preferences}
@@ -183,7 +183,7 @@
To link a project to an Axivion dashboard:
\list 1
\li \uicontrol Projects > \uicontrol {Project Settings} >
\li Go to \uicontrol Projects > \uicontrol {Project Settings} >
\uicontrol Axivion.
\image qtcreator-preferences-axivion-project.webp {Axivion settings in Project Settings}
\li Select \uicontrol {Fetch Projects} to list projects from Axivion.

View File

@@ -247,7 +247,7 @@
\title Complete CMake code
\QC uses \l{Generic Highlighting}{generic highlighting} to provide
\QC uses \l{Download highlight definitions}{generic highlighting} to provide
code completion specific arguments for the CMake commands. For
example, only source file properties are suggested for the
\l {CMake: set_source_files_properties command}, not the test or

View File

@@ -8,28 +8,32 @@
// **********************************************************************
/*!
\previouspage creator-debugging-qml.html
\page creator-debugging-example.html
\nextpage creator-qml-debugging-example.html
\previouspage creator-tutorials.html
\nextpage creator-how-tos.html
\title Debugging a C++ Example Application
\ingroup creator-tutorials
This section uses the \l{Creating a Qt Widget Based Application}{TextFinder}
\title Debugging a C++ Application
\brief How to debug a C++ application.
This tutorial uses the \l{Creating a Qt Widget Based Application}{TextFinder}
example to illustrate how to debug Qt C++ applications in the
\uicontrol Debug mode.
TextFinder reads a text file into QString and then displays it with
QTextEdit. To look at the TextFinder class and see the stored data, place
a breakpoint in textfinder.cpp, as follows:
QTextEdit. To look at the TextFinder class and see the stored data:
\list 1
\li Click in between the line number and the window border on the line
where we change the cursor position to set a breakpoint.
\li In textfinder.cpp, click between the line number and the window
border on the line where we change the cursor position to set a
breakpoint.
\image qtcreator-setting-breakpoint1.png
\li Select \uicontrol Debug > \uicontrol {Start Debugging} >
\li Go to \uicontrol Debug > \uicontrol {Start Debugging} >
\uicontrol {Start Debugging of Startup Project} or press \key F5.
\li To view information about the breakpoint, go to the
@@ -91,4 +95,5 @@
(\uicontrol {Step Into}), and \inlineimage icons/debugger_stepout_small.png
(\uicontrol {Step Out}).
\sa {Creating a Qt Widget Based Application}, {Debugging}
*/

View File

@@ -90,11 +90,11 @@
objects and user interfaces, as well as execute JavaScript
expressions.
\li \l{Debugging a C++ Example Application}
\li \l{Debugging a C++ Application}
Illustrates how to debug C++ applications in \QC.
\li \l{Debugging a Qt Quick Example Application}
\li \l{Debugging a Qt Quick Application}
Illustrates how to debug Qt Quick applications in \QC.

View File

@@ -13,14 +13,17 @@
\previouspage creator-expressions-view.html
\nextpage creator-qml-performance-monitor.html
\else
\previouspage creator-debugging-example.html
\nextpage creator-troubleshooting-debugging.html
\previouspage creator-tutorials.html
\nextpage creator-how-tos.html
\endif
\title Debugging a Qt Quick Example Application
\ingroup creator-tutorials
This section uses the
\l{QML Advanced Tutorial}{Same Game}
\title Debugging a Qt Quick Application
\brief How to debug a Qt Quick application.
This tutorial uses the \l{QML Advanced Tutorial}{Same Game}
example application to illustrate how to debug Qt Quick applications in the
\uicontrol Debug mode.
@@ -28,7 +31,7 @@
\l{Debugging Qt Quick Projects}.
\if defined(qtdesignstudio)
\note In this section, you are using advanced menu items. These are not
\note In this tutorial, you are using advanced menu items. These are not
visible by default. To toggle the visibility of advanced menu items, see
\l{Customizing the Menu}.
@@ -107,4 +110,5 @@
\endlist
\sa {Debugging Qt Quick Projects}
*/

View File

@@ -24,7 +24,7 @@
\endif
For an example of how to debug Qt Quick Projects, see
\l{Debugging a Qt Quick Example Application}.
\l{Debugging a Qt Quick Application}.
\if defined(qtdesignstudio)
\note In this section, you are using advanced menu items. These are not

View File

@@ -4,12 +4,13 @@
/*!
\page creator-completing-code.html
\if defined(qtdesignstudio)
\previouspage creator-editor-functions.html
\previouspage qtquick-text-editor.html
\else
\previouspage creator-how-tos.html
\endif
\ingroup creator-how-to-edit
\ingroup studio-how-to-code
\title Complete code
@@ -129,12 +130,13 @@
/*!
\page creator-preferences-text-editor-completion.html
\if defined(qtdesignstudio)
\previouspage creator-completing-code.html
\previouspage qtquick-text-editor.html
\else
\previouspage creator-reference.html
\endif
\ingroup creator-reference-preferences-text-editor
\ingroup studio-preferences-code
\title Completion
@@ -192,12 +194,13 @@
/*!
\page creator-preferences-text-editor-shippets.html
\if defined(qtdesignstudio)
\previouspage creator-completing-code.html
\previouspage qtquick-text-editor.html
\else
\previouspage creator-reference.html
\endif
\ingroup creator-reference-preferences-text-editor
\ingroup studio-preferences-code
\title Snippets
@@ -330,12 +333,13 @@
/*!
\page creator-how-to-add-code-snippets.html
\if defined(qtdesignstudio)
\previouspage creator-completing-code.html
\previouspage qtquick-text-editor.html
\else
\previouspage creator-how-tos.html
\endif
\ingroup creator-how-to-configure-editors
\ingroup studio-how-to-code
\title Add code snippets to the auto-complete menu

View File

@@ -4,13 +4,13 @@
/*!
\page creator-indenting-code.html
\if defined(qtdesignstudio)
\previouspage creator-completing-code.html
\nextpage creator-preferences-text-editor-behavior.html
\previouspage qtquick-text-editor.html
\else
\previouspage creator-how-tos.html
\endif
\ingroup creator-how-to-edit
\ingroup studio-how-to-code
\title Indent text or code

View File

@@ -4,12 +4,13 @@
/*!
\page creator-how-to-rename-symbols.html
\if defined(qtdesignstudio)
\previouspage studio-finding.html
\previouspage qtquick-text-editor.html
\else
\previouspage creator-how-tos.html
\endif
\ingroup creator-how-to-search
\ingroup studio-how-to-refactor-code
\title Rename symbols

View File

@@ -1,60 +1,75 @@
// Copyright (C) 2023 The Qt Company Ltd.
// Copyright (C) 2024 The Qt Company Ltd.
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GFDL-1.3-no-invariants-only
/*!
\previouspage creator-highlighting.html
\page creator-checking-code-syntax.html
\nextpage creator-completing-code.html
\if defined(qtdesignstudio)
\previouspage qtquick-text-editor.html
\else
\previouspage creator-how-tos.html
\endif
\title Checking Code Syntax
\ingroup creator-how-to-edit
\ingroup studio-how-to-code
\title Check code syntax
As you write code, \QC checks code syntax. When \QC spots a syntax error in
your code, it underlines it, displays an icon, and shows error details when
you move the mouse pointer over the error or the icon. If a fix is available,
you can apply it by clicking \inlineimage icons/refactormarker.png
.
you move the mouse pointer over the error or the icon. To apply an available
fix, select \inlineimage icons/refactormarker.png.
Similarly, when you are working on an instance of a JavaScript object
notation (JSON) entity, \QC underlines errors in the JSON data structure.
\if defined(qtcreator)
In the following screenshot, \QC annotates an error because a semicolon is
missing at the end of the line:
\section1 Examples of C++ code errors
\QC annotates an error because a semicolon is missing at the end of the line:
\image qtcreator-syntaxerror.png {Syntax error in the Edit mode}
In the following screenshot, \QC issues a warning because the variable is
not used:
\QC issues a warning because the variable is not used:
\image qtcreator-semanticerror.png
In the following screenshot, a Qt class name has a typo:
A Qt class name has a typo:
\image qtcreator-typo-clang.png {Annotation tooltip in the Edit mode}
You can use the icons in the tooltip popup to copy the error or
warning message to the clipboard, to hide messages of a particular type,
or to \l{Clangd}{change the diagnostics settings}. Select
the \uicontrol {Annotation Settings} link to specify the position
of the line annotations.
\section1 Check QML or JavaScript syntax
\endif
To modify the colors used for underlining errors and warnings, select
\preferences > \uicontrol {Text Editor} >
\uicontrol {Font & Colors} > \uicontrol Copy, and select new colors for
\uicontrol Error and \uicontrol Warning.
\else
\if defined(qtdesignstudio)
In addition to underlining, errors and warnings are marked with icons and
annotated.
\endif
When writing QML or JavaScript code, the annotations may have error codes
listed in \l{JavaScript and QML Error Codes}.
\image qml-syntax-check.png
\section1 Specifying Line Annotation Positions
\section1 Manage messages
To specify the position where the annotations are displayed, select
Use the icons in the tooltip popup to copy the error or
warning message to the clipboard, to hide messages of a particular type,
or to change the diagnostics settings.
To modify the colors used for underlining errors and warnings:
\list 1
\li Go to \preferences > \uicontrol {Text Editor} >
\uicontrol {Font & Colors} > \uicontrol Copy
\li Select new colors for \uicontrol Error and \uicontrol Warning.
\endlist
\section1 Set line annotation positions
To specify the position of the line annotations when looking at them in the
code editor, select \uicontrol {Annotation Settings} in the tooltip popup.
To specify the position where the annotations are displayed, go to
\preferences > \uicontrol {Text Editor} >
\uicontrol Display > \uicontrol {Line annotations}, and then select
whether to display the annotations directly next to the code, aligned
@@ -62,19 +77,63 @@
between lines can be useful if there is usually not enough space to
display annotations next to the text.
\image qtcreator-options-text-editor-display.png "Text Editor Display preferences"
\image qtcreator-options-text-editor-display.png {Text Editor Display preferences}
If you hide the annotations by deselecting the check box, you can move the
mouse pointer over an icon to view them.
If you hide the annotations, you can move the mouse pointer over an icon to
view them.
\if defined(qtcreator)
\section1 Inspect QML and JavaScript
To inspect QML and JavaScript properties, methods, and enums, move the
cursor over them and go to \uicontrol Tools > \uicontrol {QML/JS} >
\uicontrol {Inspect API for Element Under Cursor}.
\sa {Clangd}
\endif
\sa {JavaScript and QML Checks}
*/
/*!
\page creator-reference-js-and-qml-error-codes.html
\if defined(qtdesignstudio)
\previouspage qtquick-text-editor.html
\else
\previouspage creator-reference.html
\endif
\ingroup creator-reference-editors
\ingroup studio-how-to-code
\title JavaScript and QML Checks
\brief Run static checks on the QML and JavaScript code in your project to
find common problems.
To run static checks, go to \uicontrol Tools > \uicontrol {QML/JS} >
\uicontrol {Run Checks} or press \key {Ctrl+Shift+C}.
View the results in the \uicontrol QML and \uicontrol {QML Analysis}
filters in \l Issues.
\section1 Enabling and Disabling Messages
To enable and disable QML and JavaScript messages:
\list 1
\li Go to \preferences > \uicontrol {Qt Quick} >
\uicontrol {QML/JS Editing}.
\li Select \uicontrol {Use customized static analyzer}.
\image qtcreator-preferences-qtquick-qmljs-editing.webp {QML/JS Editing tab in Qt Quick preferences}
\li In \uicontrol Enabled, select the messages that you want to see.
\li To disable messages for non-Qt Quick UI files, select them in
\uicontrol {Disable messages for non Qt Quick UI}. You cannot
enable messages just for non-Qt Quick UI files.
\endlist
\section1 JavaScript and QML Error Codes
You can run static checks on the QML and JavaScript code in your project to
find common problems. To run the checks, select \uicontrol Tools >
\uicontrol {QML/JS} > \uicontrol {Run Checks} or press \key {Ctrl+Shift+C}.
The results are shown in the \uicontrol QML and \uicontrol {QML Analysis}
filters in \l Issues.
Many of the error messages are similar to the ones in Douglas Crockford's
\l{http://www.jslint.com}{JSLint} tool. For more information about JSLint
errors, see \l{http://linterrors.com/js}{JSLint Error Explanations}.
@@ -699,23 +758,6 @@
\endtable
\section1 Enabling and Disabling Messages
To enable and disable QML and JavaScript messages, select \preferences >
\uicontrol {Qt Quick} > \uicontrol {QML/JS Editing} >
\uicontrol {Use customized static analyzer}.
\image qtcreator-preferences-qtquick-qmljs-editing.webp {QML/JS Editing tab in Qt Quick preferences}
In \uicontrol Enabled, select the messages that you want to see.
To disable messages for non-Qt Quick UI files, select them in
\uicontrol {Disable messages for non Qt Quick UI}. You cannot
enable messages just for non-Qt Quick UI files.
\if defined(qtcreator)
\sa {Turn on QML language server}
\endif
\section1 Resetting the Code Model
If you change the build and run kit when you have QML files open in the code
@@ -723,7 +765,7 @@
indicates that this might have happened: \e{Using Qt Quick 1 code model
instead of Qt Quick 2}.
You can see the error message when you move the mouse pointer over code that
To see the error message, move the mouse pointer over code that
\QC underlines in the code editor or when you open a QML file in \QDS.
To reset the code model, select \uicontrol Tools > \uicontrol {QML/JS} >
@@ -735,44 +777,39 @@
kit.
\endif
\section1 Inspecting QML and JavaScript
\sa {Check code syntax}
*/
To inspect QML and JavaScript properties, methods, and enums, move the
cursor over them and select \uicontrol Tools > \uicontrol {QML/JS} >
\uicontrol {Inspect API for Element Under Cursor}.
/*!
\page creator-how-to-autoformat-qml-js.html
\if defined(qtdesignstudio)
\previouspage qtquick-text-editor.html
\else
\previouspage creator-how-tos.html
\endif
\section1 Automatically Formatting QML/JS Files
\ingroup creator-how-to-edit
\ingroup studio-how-to-code
To automatically format QML/JS files upon saving, select \preferences >
\uicontrol {Qt Quick} > \uicontrol {QML/JS Editing} >
\title Automatically format QML/JS files
To automatically format QML/JS files upon saving, go to \preferences >
\uicontrol {Qt Quick} > \uicontrol {QML/JS Editing} and select
\uicontrol {Enable auto format on file save}.
\image qtcreator-qml-js-editing.webp {QML/JS Editing preferences}
To only format files that belong to the current project, select
\uicontrol {Restrict to files contained in the current project}.
To use an external tool, such as \l {qmlformat}, which automatically
formats QML files according to QML coding conventions, select
\uicontrol {Use custom command instead of built-in formatter}. In
the \uicontrol Command field, enter the path to the tool. In the
\uicontrol Arguments field, enter options for running the tool.
formats QML files according to QML coding conventions:
\image qtcreator-qml-js-editing.webp {QML/JS Editing preferences}
\if defined(qtcreator)
\section1 Inspecting Preprocessed C++ Code
To analyze the causes of compile errors or errors caused by wrong includes
pulled in by dependencies or C++ macros expanding to something unexpected,
select \uicontrol {Show Preprocessed Source} in the editor context menu.
This action expands all C++ macros to their actual code and removes code that
is guarded by a currently inactive \c {#ifdef} statements. If you deselect
the \uicontrol {Use built-in preprocessor to show pre-processed files} check
box in \preferences > \uicontrol C++ > \uicontrol {Code Model}, this action
also expands all \c {"#include <foo.h>"} statements to their actual contents.
\image qtcreator-preferences-code-model.webp {C++ Code Model preferences}
\endif
\list 1
\li Select \uicontrol {Use custom command instead of built-in formatter}.
\li In \uicontrol Command, enter the path to the tool.
\li In \uicontrol Arguments, enter options for running the tool.
\endlist
\sa {Check code syntax}, {Qt Quick Code Style}
*/

View File

@@ -1,60 +0,0 @@
// Copyright (C) 2023 The Qt Company Ltd.
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GFDL-1.3-no-invariants-only
// **********************************************************************
// NOTE: the sections are not ordered by their logical order to avoid
// reshuffling the file each time the index order changes (i.e., often).
// Run the fixnavi.pl script to adjust the links to the index order.
// **********************************************************************
/*!
\page creator-coding.html
\if defined(qtdesignstudio)
\previouspage studio-designer-developer-workflow.html
\else
\previouspage creator-usability.html
\endif
\nextpage creator-editor-functions.html
\title Coding
\if defined(qtcreator)
\image front-coding.png
\endif
\list
\li \l{Writing Code}
\if defined(qtdesignstudio)
The \l{Code} view offers services, such as semantic highlighting,
syntax checking, code completion, code indentation, and in-line
error indicators while you are typing.
\else
Writing, editing, and navigating in source code are core tasks in
application development. Therefore, the code editor is one of the
key components of \QC. You can use the code editor in the
\uicontrol Edit mode.
\endif
\if defined(qtdesignstudio)
\li \l{Finding}
Use the incremental and advanced search to search in currently
open projects or files on the file system or use the locator to
browse through projects, files, classes, functions, documentation
and file systems.
\endif
\li \l{Configuring the Editor}
You can change the fonts, colors, highlighting, and indentation.
\if defined(qtcreator)
If you are used to the Vim editor, you can even run the main
editor in a manner similar to it in the \uicontrol{FakeVim} mode.
\endif
\endlist
\sa {Apply quick fixes}
*/

View File

@@ -10,13 +10,13 @@
/*!
\page creator-preferences-text-editor-font-colors.html
\if defined(qtdesignstudio)
\previouspage creator-editor-options.html
\nextpage studio-debugging.html
\previouspage qtquick-text-editor.html
\else
\previouspage creator-reference.html
\endif
\ingroup creator-reference-preferences-text-editor
\ingroup studio-preferences-code
\title Font & Colors
@@ -50,13 +50,13 @@
/*!
\page creator-how-to-change-editor-colors.html
\if defined(qtdesignstudio)
\previouspage creator-editor-options.html
\nextpage studio-debugging.html
\previouspage qtquick-text-editor.html
\else
\previouspage creator-how-tos.html
\endif
\ingroup creator-how-to-configure-editors
\ingroup studio-how-to-code
\title Change editor colors

View File

@@ -1,60 +0,0 @@
// Copyright (C) 2023 The Qt Company Ltd.
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GFDL-1.3-no-invariants-only
// **********************************************************************
// NOTE: the sections are not ordered by their logical order to avoid
// reshuffling the file each time the index order changes (i.e., often).
// Run the fixnavi.pl script to adjust the links to the index order.
// **********************************************************************
/*!
\page creator-editor-options.html
\if defined(qtdesignstudio)
\previouspage creator-editor-quick-fixes.html
\else
\previouspage creator-beautifier.html
\endif
\nextpage creator-preferences-text-editor-font-colors.html
\title Configuring the Editor
You can configure the text editor to suit your specific needs by selecting
\preferences > \uicontrol{Text Editor}.
\image qtcreator-font-colors.png "Text Editor preferences"
The settings you specify apply globally to all projects.
You can also specify indentation settings separately for C++ and QML files
either globally or for the open project. For more information, see
\l{Indent text or code}.
You can perform the following configuration actions:
\list
\li Set the \l{Font & Colors}{font preferences and
apply color schemes} for syntax highlighting in
\uicontrol {Font & Colors}.
\li Specify \l{Generic Highlighting}
{definition files for syntax highlighting} for other types of files
than C++ or QML in \uicontrol {Generic Highlighter}.
\li Set \l{Indent text or code}{tabs, indentation, the handling of
whitespace, and mouse operations} in \uicontrol Behavior.
\li Set various display properties, such as \l{Highlighting Blocks}
{highlighting} or \l{Folding Blocks}{folding} blocks or text
wrapping in \uicontrol Display.
\li Add, modify, and remove \l{Snippets}{code snippets} in
\uicontrol Snippets.
\li Configure \l{Completion}{code completion} in \uicontrol Completion.
\endlist
\if defined(qtcreator)
\sa {Specify editor settings}, {Edit like in Vim}, {Completion}, {Snippets}
\endif
*/

View File

@@ -1,65 +0,0 @@
// Copyright (C) 2023 The Qt Company Ltd.
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GFDL-1.3-no-invariants-only
// **********************************************************************
// NOTE: the sections are not ordered by their logical order to avoid
// reshuffling the file each time the index order changes (i.e., often).
// Run the fixnavi.pl script to adjust the links to the index order.
// **********************************************************************
/*!
\page creator-editor-functions.html
\previouspage creator-coding.html
\if defined(qtdesignstudio)
\nextpage creator-highlighting.html
\else
\nextpage creator-coding-navigating.html
\endif
\title Writing Code
The \QC code editor is fully equipped with semantic highlighting, syntax
checking, code completion, code indentation, context sensitive help, and
in-line error indicators while you are typing.
\list
\li \l{Semantic Highlighting}
\QC enables you to write well formatted code by highlighting
code elements and blocks. You can use syntax highlighting
also for other types of files than C++ or QML.
\li \l{Checking Code Syntax}
\QC checks for errors when you write code and displays inline
error and warning messages.
Similarly, it checks the data structure of an instance of a
JavaScript object notation (JSON) entity. In addition, you can run
static checks on the QML and JavaScript code in your project to find
common problems.
\li \l{Complete code}
\QC anticipates what you are going to write and completes code
and code snippets for elements, properties, and IDs.
\li \l{Indent text or code}
\QC indents text and code according to rules that you
specify separately for files that have C++, QML, or
Nim (experimental) code and for other text files.
\li \l{Using Qt Quick Toolbars}
When you edit QML code in the code editor, you specify the
properties of QML components. For some properties, such as
colors and font names, this is not a trivial task. For example,
few people can visualize the color \c {#18793f}. To easily edit
these properties, you can use the Qt Quick Toolbars.
\endlist
\if defined(qtcreator)
\sa {Edit Code}{How To: Edit Code}, {Edit Mode}
\endif
*/

View File

@@ -157,13 +157,9 @@
\li To process precompiled headers, deselect the
\uicontrol {Ignore precompiled headers} check box.
\li When you select \uicontrol {Show Preprocessed Source} in the code
editor context menu, the built-in preprocessor is used to show the
pre-processed source file in the editor. To invoke the actual
compiler for showing the code, deselect the
\uicontrol {Use built-in preprocessor to show pre-processed files}
check box. For more information, see
\l {Inspecting Preprocessed C++ Code}.
\li To use the built-in preprocessor to show the
pre-processed source file in the editor, select
\uicontrol {Use built-in preprocessor to show pre-processed files}.
\li To avoid out-of-memory crashes caused by indexing huge source files
that are typically auto-generated by scripts or code, the size of
@@ -177,6 +173,19 @@
\endlist
\section1 Inspect preprocessed C++ code
To analyze the causes of compile errors or errors caused by wrong includes
pulled in by dependencies or C++ macros expanding to something unexpected,
select \uicontrol {Show Preprocessed Source} in the editor context menu.
This action expands all C++ macros to their actual code and removes code that
is guarded by a currently inactive \c {#ifdef} statements.
If you clear \uicontrol {Use built-in preprocessor to show pre-processed files},
this action also expands all \c {"#include <foo.h>"} statements to their
actual contents.
\sa {Specify clangd settings}, {Clang Code Model}, {Clangd}
*/

View File

@@ -9,13 +9,12 @@
\title Paste and fetch code snippets
To paste snippets of code to a server or fetch snippets of code from the
To paste snippets of code or whole files to a server or fetch them from the
server, use one of the following code pasting services:
\list
\li \uicontrol {Pastebin.Com}
\li \uicontrol {Pastecode.Xyz}
\li \uicontrol {Shared network drives}
\li DPaste.com
\li Pastebin.com
\endlist
For example, you might ask colleagues to review a change that you plan to
@@ -33,16 +32,26 @@
\section1 Paste snippets
To paste a snippet of code onto the server, go to \uicontrol Tools >
\uicontrol {Code Pasting} > \uicontrol {Paste Snippet} or press
\key {Alt+C,Alt+P}. By default, \QC copies the URL of the snippet to the
To paste a snippet of code onto the server:
\list 1
\li Go to \uicontrol Tools > \uicontrol {Code Pasting} >
\uicontrol {Paste Snippet} or press \key {Alt+C,Alt+P}.
\image qtcreator-send-to-codepaster.webp {Send to Codepaster dialog}
\li In \uicontrol Protocol, select the code pasting service to use.
\li In \uicontrol {Expires after}, specify the time to keep
the pasted snippet on the server.
\li In \uicontrol Username and \uicontrol Description, enter your
username and add information about the pasted content.
\li Check and edit the content to paste.
\li Select \uicontrol Paste.
\endlist
By default, \QC copies the URL of the snippet to the
clipboard and displays the URL in \uicontrol {General Messages}.
To paste any content that you copied to the clipboard, go to
\uicontrol Tools > \uicontrol {Code Pasting} > \uicontrol {Paste Snippet}.
To paste content from the \l{Compare files}{diff editor}, right-click a
chunk and select \uicontrol {Send Chunk to CodePaster} in the context menu.
To paste a \l{Compare files}{diff}, right-click a chunk and select
\uicontrol {Send Chunk to CodePaster} in the context menu.
\section1 Fetch snippets
@@ -85,5 +94,5 @@
The code snippets are copied to the drive as simple files. You have to
delete obsolete files from the drive manually.
\sa {Git}
\sa {Compare files}, {Git}
*/

View File

@@ -26,7 +26,7 @@
code elements and blocks. You can use syntax highlighting
also for other types of files than C++ or QML.
\li \l {Checking Code Syntax}{Checking code syntax}
\li \l {Check code syntax}{Checking code syntax}
\QC checks for errors when you write code and displays inline
error and warning messages. Similarly, it checks the data

View File

@@ -133,4 +133,6 @@
indicates added characters.
\endlist
\sa {Paste and fetch code snippets}
*/

View File

@@ -231,7 +231,7 @@
To disable the embedded code model and use the QML language server for everything,
select \uicontrol {Use QML Language Server advanced features}.
Also,\QC tries to use the QML language server shipped with
Also, \QC tries to use the QML language server shipped with
the Qt version in your current kit. To override that behavior and always use the
QML language server of the highest registered Qt version, select
\uicontrol {Use QML Language Server from latest Qt version}.

View File

@@ -4,13 +4,13 @@
/*!
\page creator-preferences-text-editor-behavior.html
\if defined(qtdesignstudio)
\previouspage creator-indenting-code.html
\nextpage creator-preferences-qtquick-code-style.html
\previouspage qtquick-text-editor.html
\else
\previouspage creator-reference.html
\endif
\ingroup creator-reference-preferences-text-editor
\ingroup studio-preferences-code
\title Behavior

View File

@@ -4,14 +4,13 @@
/*!
\page creator-editor-quick-fixes.html
\if defined(qtdesignstudio)
\previouspage creator-jump-to-the-code.html
\nextpage creator-reference-qml-quick-fixes.html
\previouspage qtquick-text-editor.html
\else
\previouspage creator-how-tos.html
\endif
\ingroup creator-how-to-edit
\ingroup studio-code-view
\ingroup studio-how-to-refactor-code
\title Apply quick fixes
@@ -101,14 +100,13 @@
/*!
\page creator-reference-qml-quick-fixes.html
\if defined(qtdesignstudio)
\previouspage creator-editor-quick-fixes.html
\nextpage creator-editor-options.html
\previouspage qtquick-text-editor.html
\else
\previouspage creator-reference.html
\endif
\ingroup creator-reference
\ingroup studio-code-view
\ingroup creator-reference-editors
\ingroup studio-how-to-refactor-code
\title QML Quick Fixes

View File

@@ -4,13 +4,13 @@
/*!
\page creator-editor-finding.html
\if defined(qtdesignstudio)
\previouspage studio-finding.html
\nextpage creator-how-to-advanced-search.html
\previouspage qtquick-text-editor.html
\else
\previouspage creator-how-tos.html
\endif
\ingroup creator-how-to-search
\ingroup studio-how-to-search
\title Search in current file
@@ -130,13 +130,13 @@
/*!
\page creator-how-to-advanced-search.html
\if defined(qtdesignstudio)
\previouspage creator-editor-finding.html
\nextpage creator-how-to-rename-symbols.html
\previouspage qtquick-text-editor.html
\else
\previouspage creator-how-tos.html
\endif
\ingroup creator-how-to-search
\ingroup studio-how-to-search
\title Search in projects or file systems
@@ -216,9 +216,7 @@
\if defined(qtcreator)
\sa {Search}{How To: Search}, {Find symbols}, {Turn on Silver Searcher}
\else
\sa {Search in current file}
\endif
\sa {Search Results View}
\sa {Search in current file}, {Search Results View}
*/

View File

@@ -4,125 +4,140 @@
/*!
\page creator-highlighting.html
\if defined(qtdesignstudio)
\previouspage creator-editor-functions.html
\previouspage qtquick-text-editor.html
\else
\previouspage creator-coding-navigating.html
\previouspage creator-how-tos.html
\endif
\nextpage creator-checking-code-syntax.html
\title Semantic Highlighting
\ingroup creator-how-to-edit
\ingroup studio-how-to-highlight-code
\QC understands the C++, QML, and JavaScript languages as code, not as plain
text. It reads the source code, analyzes it, and highlights it based on the
semantic checks that it does for the following code elements:
\title Download highlight definitions
\list
\li Types (such as classes, structs, and type definitions)
\li Local variables
\li Class fields
\li Virtual functions
\endlist
To specify the color scheme to use for semantic highlighting, select
\preferences > \uicontrol {Text Editor} > \uicontrol {Font & Colors}.
\QC supports syntax highlighting also for other types of files than C++,
QML, or JavaScript.
\section1 Generic Highlighting
\QC uses
\l{https://api.kde.org/frameworks/syntax-highlighting/html/index.html}
{KSyntaxHighlighting}, which is the syntax highlighting engine for Kate
syntax definitions. \QC comes with most of the commonly used syntax files,
and you can download additional files. For more information about the
definition files, see
\l{https://docs.kde.org/trunk5/en/kate/katepart/highlight.html}
\QC uses the \l{https://api.kde.org/frameworks/syntax-highlighting/html/index.html}
{KSyntaxHighlighting} syntax highlighting engine with Kate syntax definitions.
It comes with most of the commonly used Kate definitions, and you can download
more definitions. For more information about the definition files, see
\l{https://docs.kde.org/stable5/en/kate/katepart/highlight.html}
{Working with Syntax Highlighting}.
Font attributes that a syntax definition file explicitly specifies, such as
bold, italic, underline, or strike through, are applied. Colors are applied
if they are readable with \QC themes.
\section2 Remember preferred definitions
If more than one highlight definition is available for the file that you
open for editing, the editor asks you to select the one to use. To save
the selection, select \uicontrol {Remember My Choice}. To reset the
remembered definitions, select \preferences >
\uicontrol {Text Editor} > \uicontrol {Generic Highlighter} >
open for editing, the editor asks you to select the one to use.
To save the selection, select \uicontrol {Remember My Choice}.
To reset the remembered definitions, go to \preferences >
\uicontrol {Text Editor} > \uicontrol {Generic Highlighter} and select
\uicontrol {Reset Remembered Definitions}.
\image qtcreator-syntax-highlighter.png {Generic Highlighter preferences}
\section2 Download definitions
If the editor cannot find the highlight definition for a file that you open
for editing, it prompts you to download additional highlight definition
files. Select \uicontrol {Download Definitions} to download the files.
To view information about the downloaded files, open the \l{View output}
{General Messages} view.
To suppress the message for a particular file pattern, select \preferences >
\section2 Ignore file patterns
To suppress the message for a particular file pattern, go to \preferences >
\uicontrol {Text Editor} > \uicontrol {Generic Highlighter} and add the
pattern to the \uicontrol {Ignored file patterns} field.
pattern to \uicontrol {Ignored file patterns}.
\image qtcreator-syntax-highlighter.png "Generic Highlighter preferences"
\section2 Add your own definitions
If you have written your own syntax definition files, you
can add a definition search path in the
\uicontrol {User Highlight Definition Files} field. To
apply the changes you make to the definition files, select
If you have written your own syntax definition files, add a definition search
path in \uicontrol {User Highlight Definition Files}.
To apply the changes you make to the definition files, select
\uicontrol {Reload Definitions}.
\section1 Highlighting Blocks
\if defined(qtdesignstudio)
\sa Code
\else
\sa {Edit Code}{How To: Edit Code}, {Edit Mode}
\endif
*/
Use block highlighting to visually separate parts of the code that belong
together. For example, when you place the cursor within the braces, the code
/*!
\page creator-how-to-use-code-blocks.html
\if defined(qtdesignstudio)
\previouspage qtquick-text-editor.html
\else
\previouspage creator-how-tos.html
\endif
\ingroup creator-how-to-edit
\ingroup studio-how-to-highlight-code
\title Highlight code blocks
Block highlighting visually separates parts of the code that belong together.
For example, when you place the cursor within a set of braces, the code
enclosed in braces is highlighted.
\image qtcreator-blockhighlighting.png
\image qtcreator-blockhighlighting.png {A code block highlighted in the editor}
To enable block highlighting, select \preferences > \uicontrol {Text Editor}
> \uicontrol Display > \uicontrol {Highlight blocks}.
To enable block highlighting, go to \preferences > \uicontrol {Text Editor}
> \uicontrol Display and select \uicontrol {Highlight blocks}.
\section1 Folding Blocks
\section1 Fold code blocks
Use the folding markers to collapse and expand blocks of code within braces.
Click the folding marker to collapse or expand a block. In the figure above,
the folding markers are located between the line number and the text pane.
Select the folding markers to collapse and expand blocks of code within braces.
In the image above, the folding markers are located between the line number
and the text pane.
To show the folding markers, select \preferences >
\uicontrol {Text Editor} > \uicontrol Display >
To show the folding markers, go to \preferences >
\uicontrol {Text Editor} > \uicontrol Display and select
\uicontrol {Display folding markers}. This option is enabled by default.
\image qtcreator-options-text-editor-display.png "Text Editor Display preferences"
\image qtcreator-options-text-editor-display.png {Text Editor Display preferences}
\section2 Folding All Comment Blocks
\if defined(qtcreator)
\section1 Fold all comment blocks
To fold all comment blocks, select \uicontrol Tools > \uicontrol C++ >
\uicontrol {Fold All Comment Blocks}. To unfold all comment blocks, select
\uicontrol {Unfold All Comment Blocks}.
To fold all comment blocks, go to \uicontrol Tools > \uicontrol C++ >
\uicontrol {Fold All Comment Blocks}.
\section1 Animating Matching Braces
To unfold all comment blocks, select \uicontrol {Unfold All Comment Blocks}.
\endif
\section1 Animate matching braces
When the cursor is on a brace, the matching brace is animated by default.
To turn off the animation and just highlight the block and the braces, select
\preferences > \uicontrol {Text Editor} > \uicontrol Display and deselect
To turn off the animation and just highlight the block and the braces, go to
\preferences > \uicontrol {Text Editor} > \uicontrol Display and clear
\uicontrol {Animate matching parentheses}.
\section1 Moving Between Blocks
\if defined(qtcreator)
\section1 Move between code blocks
You can use keyboard shortcuts to move within and between blocks. To go to
block end, press \key {Ctrl+]} and to go to block start, press
\key {Ctrl+[}. To also select the lines from the cursor position to the end
Use keyboard shortcuts to move within and between code blocks:
\list
\li To go to block end, press \key {Ctrl+]}.
\li To go to block start, press \key {Ctrl+[}.
\endlist
To also select the lines from the cursor position to the end
or beginning of the block, press \key {Ctrl+Shift+]} and
\key {Ctrl+Shift+[}, respectively.
\endif
\section1 Selecting the Current Block
To select the current block, press \key Ctrl+U. A second key press extends
the selection to the parent block. To undo the last selection, press
\key {Ctrl+Alt+Shift+U}.
To enable smart block selection, select \preferences
> \uicontrol {Text Editor} > \uicontrol Behavior >
\uicontrol {Enable smart selection changing}.
\image qtcreator-preferences-texteditor-behavior.webp "Text Editor Behavior preferences"
\if defined(qtdesignstudio)
\sa Code
\else
\sa {Edit Code}{How To: Edit Code}, {Edit Mode}
\endif
*/

View File

@@ -1,6 +1,10 @@
// Copyright (C) 2022 The Qt Company Ltd.
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GFDL-1.3-no-invariants-only
/*!
\externalpage https://doc.qt.io/qt/qtqml-index.html
\title Qt Qml
*/
/*!
\externalpage https://doc.qt.io/QtForMCUs/index.html
\title \QMCU

View File

@@ -56,7 +56,7 @@
\ingroup creator-how-to-design
\ingroup studio-how-to-image-viewer
\title Export SVG images
\title Create pixmaps from SVG images
If you have a freely scalable icon in the SVG format, you can open it in the
\l{View images}{image viewer} to export it to several images of different

View File

@@ -55,10 +55,16 @@
\section1 Edit Code
The code editor offers useful features, such as semantic highlighting,
checking code syntax, code completion, and refactoring actions.
\generatelist creator-how-to-edit
\section2 Configure Editors
Configure the code and text editor to suit your specific needs by
changing the fonts, colors, highlighting, and indentation.
\generatelist creator-how-to-configure-editors
\section2 Manage Language Servers
@@ -449,9 +455,22 @@
\ingroup creator-how-to-edit
\title Select the enclosing block in C++
\title Select the current code block
Press \key {Ctrl+U}.
To select the current block of C++ code in the code editor, press
\key Ctrl+U.
Press \key Ctrl+U a second time to extend the selection to the parent block.
To undo the last selection, press \key {Ctrl+Alt+Shift+U}.
\section1 Turn on smart block selection
To turn on smart block selection, go to \preferences
> \uicontrol {Text Editor} > \uicontrol Behavior and select
\uicontrol {Enable smart selection changing}.
\image qtcreator-preferences-texteditor-behavior.webp {Text Editor Behavior preferences}
\sa {Edit Code}{How To: Edit Code}, {Edit Mode}
*/

View File

@@ -1,7 +1,7 @@
// Copyright (C) 2024 The Qt Company Ltd.
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GFDL-1.3-no-invariants-only
/*!
/*!
\previouspage creator-adding-docker-devices.html
\page creator-developing-ios.html
\nextpage creator-developing-mcu.html
@@ -22,11 +22,12 @@
\section1 iOS 17 Devices
\QC detects iOS 17 devices, and you can deploy and run applications on them.
\QC detects iOS devices, and you can deploy and run applications on them.
However, \QC cannot access application output. Also, debugging and
profiling are not supported because of limitations of the Apple tool for
accessing devices with iOS 17, and later.
For iOS devices with iOS 16 or earlier, \QC also supports accessing the application
output, debugging, and profiling. However, these features are not supported for
physical devices with iOS 17 or later because of limitations of the Apple tool for
accessing these devices.
\section1 Configuring Devices
@@ -57,9 +58,9 @@
\li Start Xcode to configure the device.
For example, in Xcode version 7.3.0, select \uicontrol Window >
\uicontrol Device > \uicontrol + > \uicontrol {Add Device} to add
the connected device.
For example, in Xcode version 15, select \uicontrol Window >
\uicontrol Devices and Simulators > \uicontrol Devices >
\uicontrol + to add the connected device.
\li To specify build settings:
@@ -192,14 +193,4 @@
To delete the selected simulator, select \uicontrol Delete.
\section2 Checking Current Xcode Version
To check the current Xcode version, enter the following command:
\c {xcode-select --print-path}
To change the version, enter the following command:
\c {xcode-select --version}
*/

View File

@@ -111,7 +111,7 @@
To download and use highlight definition files, select \preferences >
\uicontrol {Text Editor} > \uicontrol {Generic Highlighter}.
For more information, see \l{Generic Highlighting}.
For more information, see \l{Download highlight definitions}.
\section1 Adding Your Own Code Snippets

View File

@@ -357,7 +357,7 @@
Works with namespaces, classes, functions, variables, include
statements, and macros, as well as CMake functions, macros,
targets, and packages. Also, opens URLs in the default browser
and Qt resource files (.qrc) in the \l{Resource Files}
and Qt resource files (.qrc) in the \l{Create resource files}
{resource editor}
\li F2
\row

View File

@@ -116,6 +116,30 @@
such as Python, for which a \e {language server} is available that provides
information about the code to IDEs.
\section2 Semantic Highlighting
To help you write well formatted code, \QC highlights code elements and
blocks. It understands the C++, QML, and JavaScript languages as code, not
as plain text, so it reads the source code, analyzes it, and highlights it
based on the semantic checks that it does for code elements, such as:
\list
\li Types (such as classes, structs, and type definitions)
\li Local variables
\li Class fields
\li Virtual functions
\endlist
You can select the color scheme to use for semantic highlighting in the text
editor preferences.
\QC supports syntax highlighting also for other types of files than C++,
QML, or JavaScript. It uses the
\l{https://api.kde.org/frameworks/syntax-highlighting/html/index.html}
{KSyntaxHighlighting} syntax highlighting engine with Kate syntax
definitions. It comes with most of the commonly used Kate definitions,
and you can download more definitions in the text editor preferences.
\section2 Finding
Use the incremental and advanced search to search in currently open projects
@@ -145,7 +169,8 @@
If you are used to the Vim editor, run the main editor in the
\l {FakeVim Modes and Commands}{FakeVim mode}.
For more information, see \l{Edit Code}{How To: Edit Code} and \l{Editors}.
For more information, see \l{Edit Code}{How To: Edit Code}, \l{Editors},
and \l{Text Editor}.
\section1 Building, Deploying, and Running Applications

View File

@@ -9,7 +9,7 @@
/*!
\page creator-usability.html
\nextpage creator-coding.html
\previouspage creator-reference.html
\ingroup creator-reference

View File

@@ -39,7 +39,7 @@
\if defined(qtcreator)
\row
\li View examples of what you can do with Qt
\li \l{Qt Examples and Tutorials}
\li \l{Qt Examples And Tutorials}
\row
\li Develop Qt applications for desktop and \l{glossary-device}{devices}

View File

@@ -8,13 +8,17 @@
// **********************************************************************
/*!
\previouspage creator-configuring.html
\page creator-build-example-application.html
\nextpage creator-tutorials.html
\previouspage creator-tutorials.html
\nextpage creator-how-tos.html
\ingroup creator-tutorials
\title Building and Running an Example
You can test that your \QSDK installation is successful by opening an existing
\brief How to build and run a Qt example.
To test that your \QOI installation is successful, open an existing
example application project.
To run an example application on an Android or iOS device, you must set up

View File

@@ -35,8 +35,9 @@
\image qtcreator-build-configurations.png {Build configurations}
Different build configurations allow you to quickly switch between
different build settings. By default, \QC creates the following
configurations:
different build settings. \QC creates some configurations by default,
depending on the build system used. They usually include at least
the following:
\list
\li Debug
@@ -82,14 +83,17 @@
\li \l{Link projects to Axivion dashboards}{Axivion}
\li \l{Specify clangd settings}{Clangd}
\li \l{Speficy Clang tools settings}{Clang Tools}
\li \l{Set Copilot preferences}{Copilot}
\li \l{Specify code style}{C++ Code Style}
\li \l{Set C++ file naming preferences}{C++ File Naming}
\li \l{Specify dependencies}{Dependencies}
\li \l{Document code}{Documentation Comments}
\li \l{Specify editor settings}{Editor}
\li \l{Specify the environment for projects}{Environment}
\li \l{Link projects with GitLab}{GitLab}
\li \l{Configure language server workspace}{Language Server}
\li \l{Specify settings for quick fixes}{Quick Fixes}
\li \l{Testing}
\li \l{Exclude files from to-do lists}{To-Do} (experimental)
\endlist

View File

@@ -36,7 +36,7 @@
\li In \uicontrol {Name}, enter the project name. For example,
\e {hello_world}.
\li In \uicontrol {Create in}, enter the path for the project files.
For example, \c {C:\Qt\examples}.
For example, \c {C:\Examples}.
\li Select \uicontrol{Next} (on Windows and Linux) or \uicontrol Continue
(on \macos) to open the \uicontrol {Define Class} dialog.
\image qtcreator-new-qt-for-python-app-widgets-define-class.webp {Define Class dialog}

View File

@@ -35,7 +35,7 @@
\li In \uicontrol {Name}, enter the project name. For example,
\e {hello_world_quick}.
\li In \uicontrol {Create in}, enter the path for the project files.
For example, \c {C:\Qt\examples}.
For example, \c {C:\Examples}.
\li Select \uicontrol{Next} (on Windows and Linux) or \uicontrol Continue
(on \macos) to open the \uicontrol {Define Project Details} dialog.
\image qtcreator-new-qt-for-python-app-project-details.webp {Define Project Details dialog}

View File

@@ -22,19 +22,9 @@
\endlist
\li \l{User Interface}
\li \l{Configuring Qt Creator}
\li \l{Building and Running an Example}
\li \l{Tutorials}
\endlist
\li \l{Coding}
\list
\li \l{Writing Code}
\list
\li \l{Semantic Highlighting}
\li \l{Checking Code Syntax}
\li \l{Using Qt Quick Toolbars}
\endlist
\li \l{Configuring the Editor}
\endlist
\li \l{Tutorials}
\generatelist creator-tutorials
\li \l{Running on Devices}
\list
\li \l{Validating with Target Hardware}
@@ -88,8 +78,6 @@
\li \l{Debugger Preferences}
\li \l{Using Debugging Helpers}
\li \l{Debugging Qt Quick Projects}
\li \l{Debugging a C++ Example Application}
\li \l{Debugging a Qt Quick Example Application}
\li \l{Troubleshooting Debugger}
\endlist
\li \l{Analyzing Code}

View File

@@ -14,7 +14,7 @@
\title Qt Creator Manual
\QC is a cross-platform, complete integrated development environment
(IDE) for application developers to create applications for multiple
(IDE) that you can use to create applications for
\l{Desktop Platforms}{desktop}, \l {Embedded Platforms}{embedded}, and
\l{Mobile Platforms}{mobile device} platforms, such as \l Android and
\l iOS. It is available for \l Linux, \l \macos and \l Windows
@@ -38,14 +38,9 @@
\li \l{Overview}
\li \l{User Interface}
\li \l{Configuring Qt Creator}
\li \l{Building and Running an Example}
\li \l{Tutorials}
\endlist
\li \b {\l{Coding}}
\list
\li \l{Writing Code}
\li \l{Configuring the Editor}
\endlist
\li \b {\l{Tutorials}}
\generatelist creator-tutorials
\li \b {\l{Running on Devices}}
\list
\li \l{Validating with Target Hardware}

View File

@@ -1,4 +1,4 @@
// Copyright (C) 2023 The Qt Company Ltd.
// Copyright (C) 2024 The Qt Company Ltd.
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GFDL-1.3-no-invariants-only
/*!
@@ -55,9 +55,8 @@
To create a custom QML type:
\list 1
\li Select \uicontrol File > \uicontrol {New File} >
\uicontrol Qt >
\uicontrol {QML File (Qt Quick 2)}.
\li Go to \uicontrol File > \uicontrol {New File}.
\li Select \uicontrol Qt > \uicontrol {QML File (Qt Quick 2)}.
\li Select \uicontrol Choose to open the \uicontrol Location dialog.
\li In the \uicontrol {File name} field, enter a name for the custom
QML type: \e Page.
@@ -78,12 +77,11 @@
When you start typing the QML type name, \QC suggests available types
and properties to \l{Complete code}{complete the code}.
Select the light bulb icon \inlineimage icons/refactormarker.png
next to the type name to open the \l{Editing Rectangles}
{Qt Quick Toolbar for rectangles}. You can use it to specify
Select the light bulb icon \inlineimage icons/refactormarker.png next to the
type name to open a \l{Edit rectangles}{toolbar} that you can use to specify
rectangle properties, such as color, transparency, and gradients.
\image qml-toolbar-rectangle.png {Qt Quick Toolbar for rectangles}
\image qml-toolbar-rectangle.png {Qt Quick toolbar for rectangles}
Next, add an \l Image type with \e qt-logo.png as the source. You can also
use any other image or a component. Position the image in the top-left
@@ -91,10 +89,10 @@
\printuntil }
You can use the \l{Previewing Images}{Qt Quick Toolbar for images} to
specify image properties, such as source file and fill mode.
Use a \l{Preview images}{toolbar for images} to specify image properties,
such as source file and fill mode.
\image qml-toolbar-image.png {Logo visible in Qt Quick Toolbar for images}
\image qml-toolbar-image.png {Logo visible in Qt Quick toolbar for images}
Now, create the rectangles that the image will move between. Their size
should match the image size and they should be transparent, so that the
@@ -114,7 +112,7 @@
\printuntil anchors.fill
To check your code, you can compare it with the \e {Page.qml} example file.
To check your code, compare it with the \e {Page.qml} example file.
Next, make the image move between the rectangles when users click
them by adding states and by connecting mouse clicks to state changes.
@@ -171,8 +169,7 @@
\printuntil },
\note You can use the \l{Previewing Animation}
{Qt Quick Toolbar for animation} to specify the
\note Use a \l{Preview animations}{toolbar for animations} to specify the
easing curve type and animation duration.
\image qml-toolbar-animation.png {Qt Quick Toolbar for animation}

View File

@@ -39,7 +39,7 @@
\image qtquick-designer.webp {Qt Quick Designer}
For more information about \l{Qt QML}, \l{Qt Quick}, and \l{All QML Types}
For more information about \l{Qt Qml}, \l{Qt Quick}, and \l{All QML Types}
{QML types}, see the Qt reference documentation available online and
in the \uicontrol Help mode.

View File

@@ -4,13 +4,13 @@
/*!
\page creator-preferences-qtquick-code-style.html
\if defined(qtdesignstudio)
\previouspage creator-preferences-text-editor-behavior.html
\nextpage qt-quick-toolbars.html
\previouspage qtquick-text-editor.html
\else
\previouspage creator-reference.html
\endif
\ingroup creator-reference-preferences
\ingroup studio-preferences-code
\title Qt Quick Code Style
@@ -33,7 +33,7 @@
To override the global preferences for a particular project, select
\uicontrol Projects > \uicontrol {Code Style}.
\sa {Indent text or code}
\sa {Automatically format QML/JS files}, {Indent text or code}
\if defined(qtcreator)
\sa {Find preferences}, {Specify code style}

View File

@@ -1,4 +1,4 @@
// Copyright (C) 2023 The Qt Company Ltd.
// Copyright (C) 2024 The Qt Company Ltd.
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GFDL-1.3-no-invariants-only
// **********************************************************************
@@ -10,56 +10,48 @@
/*!
\page qt-quick-toolbars.html
\if defined(qtdesignstudio)
\previouspage creator-preferences-qtquick-code-style.html
\nextpage studio-finding.html
\previouspage qtquick-text-editor.html
\else
\previouspage creator-completing-code.html
\nextpage creator-editor-codepasting.html
\previouspage creator-how-tos.html
\endif
\title Using Qt Quick Toolbars
\ingroup creator-how-to-edit
\ingroup studio-how-to-code
When you select a QML type in the code and a toolbar is available,
a light bulb icon appears: \inlineimage icons/refactormarker.png
. Select the icon to open the toolbar.
\title Edit properties of QML types
To open toolbars immediately when you select a QML type, select
\preferences > \uicontrol {Qt Quick} >
\uicontrol {QML/JS Editing} > \uicontrol {Always show Qt Quick Toolbar}.
When you edit QML code in the code editor, you specify the properties of QML
types. For some properties, such as colors and font names, this is not a
trivial task. For example, few people can visualize the color \c {#18793f}.
To easily edit these properties, use the Qt Quick toolbars.
\image qtcreator-qml-js-editing.webp {QML/JS Editing preferences}
When you select a QML type in the code and a light bulb icon appears
(\inlineimage icons/refactormarker.png), select it to open a toolbar
for changing the properties of that type.
Drag the toolbar to pin it to another location. Select
\inlineimage icons/pin.png
to unpin the toolbar and move it to its default location. To pin toolbars
by default, select \uicontrol {Pin Qt Quick Toolbar}.
\section1 Preview images
\section1 Previewing Images
The Qt Quick Toolbar for images allows you to edit the properties of
Edit the properties of
\l {Border Image} and
\if defined(qtdesignstudio)
\l {Images}{Image} items.
\l {Images}{Image} items
\else
\l Image items.
\l Image items
\endif
You can scale and tile the images, replace them with other images,
to scale and tile the images, replace them with other images,
preview them, and change the image margins.
\image qml-toolbar-image.png "Qt Quick Toolbar for images"
\image qml-toolbar-image.png {Qt Quick Toolbar for images}
To preview an image, double-click it on the toolbar. In the preview
dialog, you can zoom the image. Drag the image margins to change them.
\image qml-toolbar-image-preview.png "Image preview dialog"
\image qml-toolbar-image-preview.png {Image preview dialog}
\section1 Formatting Text
\section1 Format text
The Qt Quick Toolbar for text allows you to edit the properties of
\l{Text} items.
You can change the font family and size as well as text formatting, style,
alignment, and color.
Edit the properties of \l{Text} items to change the font family and size,
as well as text formatting, style, alignment, and color.
\note Move the mouse pointer over a color hex value in the code editor to
see the color as a tooltip.
@@ -68,35 +60,53 @@
cannot use the toolbar to edit it. The button for editing the property
is disabled.
\image qml-toolbar-text.png "Qt Quick Toolbar for text"
\image qml-toolbar-text.png {Qt Quick Toolbar for text}
By default, font size is specified as pixels. To use points, instead,
change \uicontrol px to \uicontrol pt in the size field.
\section1 Previewing Animation
\section1 Preview animations
The Qt Quick Toolbar for animation allows you to edit the properties of
PropertyAnimation items and the items that inherit it. You can
change the easing curve type and duration. For some curves, you can also
Edit the properties of PropertyAnimation items and the items that inherit it
to change the easing curve type and duration. For some curves, you can also
specify amplitude, period, and overshoot values.
\image qml-toolbar-animation.png "Qt Quick Toolbar for animation"
\image qml-toolbar-animation.png {Qt Quick Toolbar for animation}
Select the play button to preview your changes.
\section1 Editing Rectangles
\section1 Edit rectangles
The Qt Quick Toolbar for rectangles allows you to edit the properties of
Edit the properties of
\if defined(qtdesignstudio)
\l {basic-rectangle}{Rectangle}
\else
Rectangle
\endif
items. You can change the fill and border colors and add gradients.
items to change the fill and border colors and add gradients.
\image qml-toolbar-rectangle.png "Qt Quick Toolbar for rectangles"
\image qml-toolbar-rectangle.png {Qt Quick Toolbar for rectangles}
To add gradient stop points, click above the gradient bar. To remove
stop points, drag them upwards.
\section1 Show toolbars immediately
To open toolbars immediately when you select a QML type, select
\preferences > \uicontrol {Qt Quick} >
\uicontrol {QML/JS Editing} > \uicontrol {Always show Qt Quick Toolbar}.
\image qtcreator-qml-js-editing.webp {QML/JS Editing preferences}
\section1 Pin toolbars
Drag the toolbar to pin it to another location. Select
\inlineimage icons/pin.png to unpin the toolbar and move
it to its default location.
To pin toolbars by default, select \uicontrol {Pin Qt Quick Toolbar}.
\if defined(qtcreator)
\sa {Creating a Qt Quick Application}
\endif
*/

View File

@@ -129,8 +129,8 @@
The following topics describe how to use the image viewer:
\list
\li \l {Export SVG images}
\li \l {View images}
\li \l {Create pixmaps from SVG images}
\endlist
\endif

View File

@@ -15,28 +15,28 @@
GitLab servers and use \l{Git} to manage your local and remote
repositories.
To use GitLab, you must create a connection to the GitLab server and clone
the projects you want to work on. You can also link previously cloned
projects to GitLab in the project settings. This enables you to receive
event notifications in the \l {View output}{Version Control} pane.
To use GitLab, create a connection to the GitLab server and clone the
projects you want to work on. Link previously cloned projects to GitLab
in the project settings to receive event notifications in the
\l {View output}{Version Control} view.
\note Enable the GitLab plugin to use it.
\section1 Connecting to GitLab Servers
To connect to a GitLab server, you need to specify the server host name and
To connect to a GitLab server, specify the server host name and
port number, as well as an access token that you create in GitLab for \QC.
The permission scope of the token must be at least \c read_api or \c api.
To specify connections to GitLab servers, select \preferences >
To specify connections to GitLab servers, go to \preferences >
\uicontrol {Version Control} > \uicontrol GitLab:
\image qtcreator-gitlab-preferences.png
\image qtcreator-gitlab-preferences.png {GitLab tab in Version Control Preferences}
To add GitLab servers:
\list 1
\li Select \uicontrol Add to open the \uicontrol {Add Server} dialog:
\li Select \uicontrol Add to open the \uicontrol {Add Server} dialog.
\image qtcreator-gitlab-preferences-add-server.png
\li In \uicontrol Host, enter the host name of the GitLab server.
\li In \uicontrol Description, enter a free-form text that is displayed
@@ -45,14 +45,14 @@
\QC in the GitLab server, in \uicontrol Preferences >
\uicontrol {Access Tokens}.
\li In \uicontrol Port, enter a port number.
\li Deselect the \uicontrol HTTPS check box to use an HTTP connection
instead of a secure connection.
\li Clear \uicontrol HTTPS to use an HTTP connection instead of a secure
connection.
\li Select \uicontrol Add to create the connection.
\endlist
In the \uicontrol GitLab tab, \uicontrol curl displays the path to the
\c curl tool used for HTTP connections. You can specify another path to
use another instance of the tool than the one found by \QC.
\c curl tool used for HTTP connections. Specify another path to
use another instance of the tool than the one \QC found.
To edit the selected connection, select \uicontrol Edit.
@@ -68,20 +68,20 @@
To clone projects from GitLab:
\list 1
\li Select \uicontrol Tools > \uicontrol GitLab to view a list of
connected GitLab servers and available projects in each server:
\li Go to \uicontrol Tools > \uicontrol GitLab to view a list of
connected GitLab servers and available projects in each server.
\image qtcreator-gitlab-project-list.png
\li In \uicontrol Remote, select a GitLab server.
\li In \uicontrol Projects, select the project to clone.
\li Select \uicontrol Clone to open the \uicontrol {Clone Repository}
dialog:
\image qtcreator-gitlab-clone-repository.png
dialog.
\image qtcreator-gitlab-clone-repository.png {Clone Repository dialog}
\li In \uicontrol Repository, specify the URL of the repository.
\li In \uicontrol Path, specify the path where to clone the repository.
\li In \uicontrol Directory, specify the name of the directory for the
cloned repository.
\li Select the \uicontrol Recursive check box to also clone submodules
of the repository.
\li Select \uicontrol Recursive to also clone submodules of the
repository.
\li Select \uicontrol Clone to clone the project to the specified
directory.
\endlist
@@ -89,12 +89,22 @@
\QC automatically opens the project. If the cloned project has several
project files (such as CMakeList.txt, .pro, and .qbs), \QC prompts you to
select the one to open. If it does not have a project file that \QC can
open, select \uicontrol File > \uicontrol {New Project} >
\uicontrol {Import Project} > \uicontrol {Import Existing Project} to
import the project as a generic project. For more information, see
\l {Use project wizards}.
open, go to \uicontrol File > \uicontrol {New Project} >
\uicontrol {Import Project} > \uicontrol {Import Existing Project} and
import the project as a generic project.
\section1 Linking Projects with GitLab
\sa {Enable and disable plugins}, {Link projects with GitLab},
{Set up version control systems}, {Use common VCS functions},
{Use project wizards}, {Version Control Systems}, {Git}
*/
/*!
\page creator-how-to-link-with-gitlab.html
\previouspage creator-how-tos.html
\ingroup creator-how-to-projects-configure
\title Link projects with GitLab
Link a project with a GitLab token to receive notifications on events, such
as merge requests, issues, or comments, in the \uicontrol {Version Control}
@@ -106,9 +116,10 @@
To link with GitLab:
\list 1
\li In the \uicontrol Projects mode, select \uicontrol {GitLab} to view
the GitLab settings for the currently active project:
\image qtcreator-gitlab-preferences-project.png
\li Go to \uicontrol Projects > \uicontrol {Project Settings} >
\uicontrol {GitLab} to view the GitLab settings for the currently
active project.
\image qtcreator-gitlab-preferences-project.png {GitLab settings for a project}
\li In \uicontrol Host, select the URL of the GitLab server.
\li In \uicontrol {Linked GitLab configuration}, select the GitLab
server settings to use.
@@ -123,5 +134,6 @@
\uicontrol {Unlink from GitLab}.
\sa {Enable and disable plugins}, {Set up version control systems},
{Use common VCS functions}, {Version Control Systems}, {Git}
{Use common VCS functions}, {Configuring Projects}, {Version Control Systems},
{Git}, {GitLab}
*/

View File

@@ -98,7 +98,7 @@
\list
\li \l{https://doc.qt.io/qtcreator/creator-highlighting.html#generic-highlighting}
{Generic Highlighting}
{Download highlight definitions}
\li \l{https://docs.kde.org/stable5/en/applications/katepart/highlight.html}
{Working with Syntax Highlighting}
\endlist

View File

@@ -233,21 +233,41 @@
Save screenshots and other illustrations in \c {\qtdesignstudio\images}.
If you add new topics to the \QDS Manual, add links to them to the table
of contents in \c {qtdesignstudio-toc.qdoc} and check the values of the
navigation links around them.
of contents in \c {qtdesignstudio-toc.qdoc}.
\section2 Updating Next and Previous Links
QDoc automatically generates links to the previous
and next page in the \QC Manual based on the list in
\c {\qtcreator\doc\qtcreator\src\qtcreator-toc.qdoc}. So, when you add
new topics, you must either add them to the TOC or to a group of topics
(\c {\ingroup}). You can see the current groups in the \e {How To} and
QDoc automatically generates links to the previous and next page in each
manual based on the list in a topic with the title \e {All Topics}, which
is in the following files:
\list
\li \QC: \c {\qtcreator\doc\qtcreator\src\qtcreator-toc.qdoc}
\li \QDS: \c {\qtcreator\doc\qtdesignstudio\src\qtdesignstudio-toc.qdoc}
\endlist
The title of the topic to use for automatically generating the navigation
links is set as the value of the \c indexTitle option in the document
configuration file:
\list
\li \QC: \c qhp.qtcreator.subprojects.manual.indexTitle in
\c {\doc\qtcreator\config\qtcreator-project.qdocconf}
\li \QDS: \c qhp.qtdesignstudio.subprojects.manual.indexTitle in
\c {\doc\qtdesignstudio\config\qtdesignstudio.qdocconf}
\endlist
When you add new topics, you must add them either to the TOC or to a
group of topics (\c {\ingroup}) that is used to generate a list in the TOC
(\l{https://doc.qt.io/qt-6/12-0-qdoc-commands-miscellaneous.html#generatelist-command}
{\c {\generatelist}}).
In the \QC Manual, you can see the current groups in the \e {How To} and
\e {Reference} sections of the TOC. You can add new groups.
When you add new topics to the \QDS Manual, you must add links to them from
\c {\doc\qtdesignstudio\src\qtdesignstudio-toc.qdoc} and change the
navigation links of the topics around them.
\note You do not need to manually change the navigation links, but they must
be there with some initial values for QDoc to replace with the values from
the TOC when you build the docs.
\section1 Adding Documentation for Independent Plugins

View File

@@ -4,7 +4,7 @@
/*!
\page studio-designer-developer-workflow.html
\previouspage studio-implementing-applications.html
\nextpage creator-coding.html
\nextpage studio-debugging.html
\title Designer-Developer Workflow

View File

@@ -2,9 +2,8 @@
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GFDL-1.3-no-invariants-only
/*!
\previouspage creator-how-to-rename-symbols.html
\page creator-jump-to-the-code.html
\nextpage creator-editor-quick-fixes.html
\previouspage qtquick-text-editor.html
\title Jump to the Code

View File

@@ -1,37 +0,0 @@
// Copyright (C) 2024 The Qt Company Ltd.
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GFDL-1.3-no-invariants-only
/*!
\page studio-finding.html
\previouspage qt-quick-toolbars.html
\nextpage creator-editor-finding.html
\title Finding
\list
\li \l{Search in current file}
The incremental search highlights the matching strings in the
editor while you type.
\li \l{Search in projects or file systems}
With advanced search, you can search in currently open projects or
files on the file system.
\li \l{Rename symbols}
Search for QML types and rename them in all files in a project.
\li \l{Jump to the Code}
Jump to the code for a specific component directly from
the \uicontrol {2D} view or \uicontrol {Navigator} view.
You can also jump to the code of a particular
\uicontrol {State} or \uicontrol {Connection} from their
corresponding views.
\endlist
*/

View File

@@ -2,7 +2,7 @@
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GFDL-1.3-no-invariants-only
/*!
\previouspage creator-editor-options.html
\previouspage studio-designer-developer-workflow.html
\page studio-debugging.html
\nextpage creator-debugging-qml.html
@@ -15,7 +15,7 @@
to execute JavaScript expressions to get information about the state
of the UI, and to inspect QML properties and JavaScript
variables and change them temporarily at runtime.
\li \l{Debugging a Qt Quick Example Application}
\li \l{Debugging a Qt Quick Application}
This section uses the \l{QML Advanced Tutorial}{Same Game} example
application to illustrate how to debug Qt Quick applications in the

View File

@@ -29,14 +29,12 @@
while developers work on the .qml and C++ source files in
Qt Creator to create an application that you can build and
run on target hardware.
\li \l{Coding}
\li \l{Code}{Coding}
You can use the code editor in the \uicontrol {Code} view or
in the \uicontrol Edit mode to modify QML code. The code editor
understands the QML language as code, not just as plain text. This
enables it to provide you with useful features, such as semantic
highlighting, checking code syntax, code completion, and refactoring
actions.
Modify QML code in the \uicontrol {Code} view. The code editor
understands the QML language as code, not just as plain text, so it
can offer useful features, such as semantic highlighting, checking
code syntax, code completion, and refactoring actions.
\li \l{Debugging and Profiling}
\QDS comes with a JavaScript debugger. In the \uicontrol Debug mode,

View File

@@ -28,6 +28,10 @@
\li \l{Timeline}
\li \l{Curves}
\li \l{Code}
\generatelist studio-how-to-code
\generatelist studio-how-to-refactor-code
\generatelist studio-how-to-search
\generatelist studio-preferences-code
\li \l{Projects}
\li \l{File System}
\li \l{Open Documents}
@@ -199,31 +203,6 @@
\li \l{Implementing Applications}
\list
\li \l{Designer-Developer Workflow}
\li \l{Coding}{Cross-Platform Development}
\list
\li \l{Writing Code}
\list
\li \l{Semantic Highlighting}
\li \l{Checking Code Syntax}
\li \l{Indent text or code}
\li \l{Behavior}
\li \l{Qt Quick Code Style}
\li \l{Using Qt Quick Toolbars}
\endlist
\li \l{Finding}
\list
\li \l{Search in current file}
\li \l{Search in projects or file systems}
\li \l{Rename symbols}
\li \l{Jump to the Code}
\endlist
\li \l{Apply quick fixes}
\li \l{QML quick fixes}
\li \l{Configuring the Editor}
\list
\li \l{Font & Colors}
\endlist
\endlist
\li \l{Debugging and Profiling}
\list
\li \l{Debugging Qt Quick Projects}
@@ -233,7 +212,7 @@
\li \l{Local Variables and Function Parameters}
\li \l{Evaluating Expressions}
\endlist
\li \l{Debugging a Qt Quick Example Application}
\li \l{Debugging a Qt Quick Application}
\li \l{Profiling QML Applications}
\endlist
\endlist

View File

@@ -66,7 +66,7 @@
\li \b {\l{Implementing Applications}}
\list
\li \l{Designer-Developer Workflow}
\li \l{Coding}{Cross-Platform Development}
\li \l{Code}{Coding}
\li \l{Debugging and Profiling}
\endlist
\li \b {\l{Advanced Designer Topics}}

View File

@@ -125,7 +125,7 @@
\li Provides a code editor for viewing and modifying the code
generated by the visual editors.
\li \image ok.png
\li \l {Writing Code}
\li \l {Code}
\row
\li \l Projects
\li Shows a list of open projects and the files they contain.

View File

@@ -8,24 +8,37 @@
\title Code
In the \uicontrol {Code} view, you can view and modify the code in a
\l{UI Files}{UI file} (.ui.qml) or component file (.qml) that is generated
when you create components in the \l {2D} or \l {3D} view and specify
their properties in \l Properties.
To view and modify the code in a \l{UI Files}{UI file} (.ui.qml) or
component file (.qml), go to \uicontrol View and select \uicontrol Views >
\uicontrol Code. \QDS generates the code when you create components in the
\l {2D} or \l {3D} view and specify their properties in \l Properties.
\image qtquick-text-editor.png "The Code view"
You can also view and modify other types of text files.
The view offers the following features:
\section1 Editing Code
\list
\li \l{Semantic Highlighting}
\li \l{Checking Code Syntax}
\li \l{Complete code}
\li \l{Indent text or code}
\li \l{Using Qt Quick Toolbars}
\endlist
The \uicontrol Code view offers semantic highlighting, syntax checking,
code completion, code indentation, context sensitive help, and
in-line error indicators while you are typing.
For more information, see:
\generatelist studio-how-to-code
\section1 Semantic Highlighting
To help you write well formatted code, the \uicontrol Code view highlights
code elements and blocks. \QDS reads the source code, analyzes it, and
highlights it based on semantic checks.
To select the color scheme for semantic highlighting, go to
\preferences > \uicontrol {Text Editor} > \uicontrol {Font & Colors}.
For more information, see:
\generatelist studio-how-to-highlight-code
\section1 Refactoring Code
@@ -34,8 +47,15 @@
and rename symbols and apply quick fixes in the \uicontrol Code view to
refactor code.
For more information, see:
\generatelist studio-how-to-refactor-code
\section1 Searching in Code
The incremental search highlights the matching strings in the
\uicontrol Code view while you type.
To open the search dialog in the \uicontrol {Code} view:
\list
@@ -44,5 +64,25 @@
\li Select \key Ctrl + \key {F} (or \key Cmd + \key F on \macos).
\endlist
\sa {Finding}, {Apply quick fixes}, {QML Quick Fixes}
With advanced search, you can search in currently open projects or
files on the file system.
For more information, see:
\generatelist studio-how-to-search
\section1 Setting Code view Preferences
To set preference for the \uicontrol Code view, go to \preferences >
\uicontrol {Text Editor}.
\image qtcreator-font-colors.png {Text Editor preferences}
The settings you specify apply globally to all projects.
For more information, see:
\generatelist studio-preferences-code
\sa {Jump to the Code}
*/

View File

@@ -453,6 +453,10 @@ class DumperBase():
return self.listTemplateParametersManually(typename)
def listTemplateParametersManually(self, typename):
# Undo id mangling for template typedefs. Relevant for QPair.
if typename.endswith('}'):
typename = typename[typename.find('{') + 1 : -1]
targs = []
if not typename.endswith('>'):
return targs
@@ -3629,7 +3633,7 @@ class DumperBase():
def templateArgument(self, position):
#DumperBase.warn('TDATA: %s' % self.tdata)
#DumperBase.warn('ID: %s' % self.typeId)
if self.tdata is None:
if self.tdata is None or self.tdata.templateArguments is None:
# Native lookups didn't help. Happens for 'wrong' placement of 'const'
# etc. with LLDB. But not all is lost:
ta = self.dumper.listTemplateParameters(self.typeId)

View File

@@ -23,7 +23,7 @@ Button {
color: Theme.Colors.backgroundPrimary
implicitWidth: 100
implicitHeight: 35
border.color: Theme.Colors.foregroundSecondary
border.color: Theme.Colors.foregroundPrimary
anchors.fill: parent
}
@@ -80,7 +80,7 @@ Button {
PropertyChanges {
target: buttonBackground
color: Theme.Colors.backgroundPrimary
border.color: Theme.Colors.disabledLink
border.color: Theme.Colors.foregroundSecondary
}
PropertyChanges {
target: textItem

View File

@@ -5,13 +5,13 @@ pragma Singleton
import QtQuick 2.15
QtObject {
readonly property color text: "#ffe7e7e7"
readonly property color foregroundPrimary: "#ffa3a3a3"
readonly property color foregroundSecondary: "#ff808080"
readonly property color backgroundPrimary: "#ff333333"
readonly property color backgroundSecondary: "#ff232323"
readonly property color hover: "#ff404040"
readonly property color accent: "#ff57d658"
readonly property color link: "#ff67e668"
readonly property color disabledLink: "#7fffffff"
readonly property color text: "#fff8f8f8" // Token_Text_Default
readonly property color foregroundPrimary: "#ff474747" // Token_Foreground_Default
readonly property color foregroundSecondary: "#ff353535" // Token_Foreground_Muted
readonly property color backgroundPrimary: "#ff1f1f1f" // Token_Background_Default
readonly property color backgroundSecondary: "#ff262626" // Token_Background_Muted
readonly property color hover: "#ff2e2e2e" // Token_Background_Subtle
readonly property color accent: "#ff1f9b5d" // Token_Accent_Default
readonly property color link: "#ff23b26a" // Token_Text_Accent
readonly property color disabledLink: "#ff595959" // Token_Text_Subtle
}

View File

@@ -6,13 +6,13 @@ import QtQuick 2.15
import LandingPageTheme
QtObject {
readonly property color text: Theme.color(Theme.Welcome_TextColor)
readonly property color foregroundPrimary: Theme.color(Theme.Welcome_ForegroundPrimaryColor)
readonly property color foregroundSecondary: Theme.color(Theme.Welcome_ForegroundSecondaryColor)
readonly property color backgroundPrimary: Theme.color(Theme.Welcome_BackgroundPrimaryColor)
readonly property color backgroundSecondary: Theme.color(Theme.Welcome_BackgroundSecondaryColor)
readonly property color hover: Theme.color(Theme.Welcome_HoverColor)
readonly property color accent: Theme.color(Theme.Welcome_AccentColor)
readonly property color link: Theme.color(Theme.Welcome_LinkColor)
readonly property color disabledLink: Theme.color(Theme.Welcome_DisabledLinkColor)
readonly property color text: Theme.color(Theme.Token_Text_Default)
readonly property color foregroundPrimary: Theme.color(Theme.Token_Foreground_Default)
readonly property color foregroundSecondary: Theme.color(Theme.Token_Foreground_Muted)
readonly property color backgroundPrimary: Theme.color(Theme.Token_Background_Default)
readonly property color backgroundSecondary: Theme.color(Theme.Token_Background_Muted)
readonly property color hover: Theme.color(Theme.Token_Background_Subtle)
readonly property color accent: Theme.color(Theme.Token_Accent_Default)
readonly property color link: Theme.color(Theme.Token_Text_Accent)
readonly property color disabledLink: Theme.color(Theme.Token_Text_Subtle)
}

View File

@@ -16792,7 +16792,7 @@ Stellen Sie sicher, dass der Wert der CMAKE_BUILD_TYPE-Variable derselbe wie der
</message>
<message>
<source>Update Potentially Stale Clangd Index Entries</source>
<translation type="unfinished"></translation>
<translation>Potenziell veraltete Clangd-Indexeinträge aktualisieren</translation>
</message>
<message>
<source>Generate Compilation Database</source>
@@ -16940,11 +16940,11 @@ Stellen Sie sicher, dass der Wert der CMAKE_BUILD_TYPE-Variable derselbe wie der
</message>
<message>
<source>Warning: </source>
<translation type="unfinished"></translation>
<translation>Warnung: </translation>
</message>
<message>
<source>The current ClangFormat (C++ &gt; Code Style &gt; ClangFormat) settings are not valid. Are you sure you want to apply them?</source>
<translation type="unfinished"></translation>
<translation>Die aktuellen Einstellungen für ClangFormat (C++ &gt; Coding-Stil &gt; ClangFormat) sind ungültig. Sind Sie sicher, dass Sie diese anwenden wollen?</translation>
</message>
<message>
<source>Open Used .clang-format Configuration File</source>
@@ -16974,11 +16974,11 @@ Das integrierte Codemodell übernimmt das Einrücken.</translation>
</message>
<message>
<source>Use custom settings</source>
<translation type="unfinished"></translation>
<translation>Benutzerdefinierte Einstellungen verwenden</translation>
</message>
<message>
<source>Use built-in indenter</source>
<translation type="unfinished"></translation>
<translation>Integriertes Codemodell für das Einrücken benutzen</translation>
</message>
<message>
<source>Use global settings</source>
@@ -16986,7 +16986,7 @@ Das integrierte Codemodell übernimmt das Einrücken.</translation>
</message>
<message>
<source>Please note that the current project includes a .clang-format file, which will be used for code indenting and formatting.</source>
<translation type="unfinished"></translation>
<translation>Beachten Sie, dass das aktuelle Projekt eine .clang-format-Datei enthält, welche für das Einrücken und die Formatierung von Code benutzt werden wird.</translation>
</message>
<message>
<source>ClangFormat settings:</source>
@@ -17331,7 +17331,7 @@ Setzen Sie erst eine gültige ausführbare Datei.</translation>
</message>
<message>
<source>Diagnostics</source>
<translation type="unfinished"></translation>
<translation>Diagnose</translation>
</message>
<message>
<source>Failed to start the analyzer.</source>
@@ -22468,7 +22468,7 @@ Doppelklicken Sie einen Eintrag um ihn zu ändern.</translation>
</message>
<message>
<source>Move Definition Here</source>
<translation type="unfinished"></translation>
<translation>Definition hierher verschieben</translation>
</message>
<message>
<source>Move Definition to Class</source>
@@ -23125,11 +23125,11 @@ Diese Präfixe werden zusätzlich zum Dateinamen beim Wechseln zwischen Header-
</message>
<message>
<source>Headers</source>
<translation type="unfinished">Header-Dateien</translation>
<translation>Header-Dateien</translation>
</message>
<message>
<source>Sources</source>
<translation type="unfinished">Quelldateien</translation>
<translation>Quelldateien</translation>
</message>
<message>
<source>S&amp;uffix:</source>
@@ -23682,7 +23682,7 @@ Das integrierte Codemodell übernimmt Syntaxhervorhebung, Code-Vervollständigun
</message>
<message>
<source>Automatic</source>
<translation type="unfinished">Automatisch</translation>
<translation>Automatisch</translation>
</message>
<message>
<source>Ignore files greater than</source>
@@ -26236,7 +26236,7 @@ markers in the source code editor.</source>
</message>
<message>
<source>%1 of length %2</source>
<translation type="unfinished"></translation>
<translation>%1 der Länge %2</translation>
</message>
<message>
<source>Show Unprintable Characters as Escape Sequences</source>
@@ -27446,23 +27446,23 @@ Sie können hier eine andere Verbindung wählen, beispielsweise eine serielle Ve
</message>
<message>
<source>Enable %1 debugger.</source>
<translation type="unfinished"></translation>
<translation>%1-Debugger aktivieren.</translation>
</message>
<message>
<source>Disable %1 debugger.</source>
<translation type="unfinished"></translation>
<translation>%1-Debugger deaktivieren.</translation>
</message>
<message>
<source>Try to determine need for %1 debugger.</source>
<translation type="unfinished"></translation>
<translation>Versuche, die Notwendigkeit für den %1-Debugger zu ermitteln.</translation>
</message>
<message>
<source>No additional startup commands.</source>
<translation type="unfinished"></translation>
<translation>Keine zusätzlichen Kommandos beim Start.</translation>
</message>
<message>
<source>Use additional startup commands.</source>
<translation type="unfinished"></translation>
<translation>Benutze zusätzliche Kommandos beim Start.</translation>
</message>
<message>
<source>C++ debugger:</source>
@@ -27474,7 +27474,7 @@ Sie können hier eine andere Verbindung wählen, beispielsweise eine serielle Ve
</message>
<message>
<source>Python debugger:</source>
<translation type="unfinished"></translation>
<translation>Python-Debugger:</translation>
</message>
<message>
<source>Enable Debugging of Subprocesses</source>
@@ -31860,7 +31860,7 @@ Jetzt Commit ausführen?</translation>
</message>
<message>
<source>Git command:</source>
<translation type="unfinished"></translation>
<translation>Git-Kommando:</translation>
</message>
<message>
<source>Set &quot;HOME&quot; environment variable</source>
@@ -34767,15 +34767,15 @@ Möchten Sie sie überschreiben?</translation>
</message>
<message>
<source>Deployment canceled.</source>
<translation type="unfinished"></translation>
<translation>Deployment abgebrochen.</translation>
</message>
<message>
<source>Failed to run devicectl: %1.</source>
<translation type="unfinished"></translation>
<translation>Das Ausführen von devicectl ist fehlgeschlagen: %1.</translation>
</message>
<message>
<source>devicectl returned unexpected output ... deployment might have failed.</source>
<translation type="unfinished"></translation>
<translation>Unerwartete Ausgabe von devicectl ... Deployment könnte fehlgeschlagen sein.</translation>
</message>
<message>
<source>The provisioning profile &quot;%1&quot; (%2) used to sign the application does not cover the device %3 (%4). Deployment to it will fail.</source>
@@ -34893,7 +34893,7 @@ Möchten Sie sie überschreiben?</translation>
</message>
<message>
<source>Debugging and profiling is currently not supported for devices with iOS 17 and later.</source>
<translation type="unfinished"></translation>
<translation>Debuggen und Profiling wird für Geräte mit iOS 17 und später im Moment nicht unterstützt.</translation>
</message>
<message>
<source>Device type:</source>
@@ -34917,7 +34917,7 @@ Möchten Sie sie überschreiben?</translation>
</message>
<message>
<source>Application launch on simulator failed. Simulator not running. %1</source>
<translation type="unfinished"></translation>
<translation>Der Start der Anwendung im Simulator ist fehlgeschlagen. Der Simulator läuft nicht. %1</translation>
</message>
<message>
<source>Application install on simulator failed. %1</source>
@@ -34941,23 +34941,23 @@ Möchten Sie sie überschreiben?</translation>
</message>
<message>
<source>Running failed. No iOS device found.</source>
<translation type="unfinished"></translation>
<translation>Ausführen fehlgeschlagen. Kein iOS-Gerät gefunden.</translation>
</message>
<message>
<source>Running canceled.</source>
<translation type="unfinished"></translation>
<translation>Ausführen abgebrochen.</translation>
</message>
<message>
<source>&quot;%1&quot; exited.</source>
<translation type="unfinished"></translation>
<translation>&quot;%1&quot; wurde beendet.</translation>
</message>
<message>
<source>Failed to determine bundle identifier.</source>
<translation type="unfinished"></translation>
<translation>Die Ermittlung des Bundle-Identifiers ist fehlgeschlagen.</translation>
</message>
<message>
<source>Running &quot;%1&quot; on %2...</source>
<translation type="unfinished"></translation>
<translation>Führe &quot;%1&quot; auf %2 aus...</translation>
</message>
<message>
<source>Could not find %1.</source>
@@ -35323,79 +35323,79 @@ Ablaufdatum: %3</translation>
</message>
<message>
<source>Failed to parse devicectl output: %1.</source>
<translation type="unfinished"></translation>
<translation>Die Auswertung der Ausgabe von devicectl ist fehlgeschlagen: %1.</translation>
</message>
<message>
<source>Operation failed: %1</source>
<translation type="unfinished"></translation>
<translation>Operation fehlgeschlagen: %1</translation>
</message>
<message>
<source>Failed to parse devicectl output: &quot;result&quot; is missing.</source>
<translation type="unfinished"></translation>
<translation>Die Auswertung der Ausgabe von devicectl ist fehlgeschlagen: &quot;result&quot; fehlt.</translation>
</message>
<message>
<source>devicectl returned unexpected output ... running failed.</source>
<translation type="unfinished"></translation>
<translation>Unerwartete Ausgabe von devicectl ... Ausführen ist fehlgeschlagen.</translation>
</message>
<message>
<source>Failed to start process.</source>
<translation type="unfinished"></translation>
<translation>Der Prozess konnte nicht gestartet werden.</translation>
</message>
<message>
<source>Process was canceled.</source>
<translation type="unfinished"></translation>
<translation>Der Prozess wurde abgebrochen.</translation>
</message>
<message>
<source>Process was forced to exit.</source>
<translation type="unfinished"></translation>
<translation>Der Prozess wurde gezwungenermaßen abgebrochen.</translation>
</message>
<message>
<source>Cannot find xcrun.</source>
<translation type="unfinished"></translation>
<translation>xcrun wurde nicht gefunden.</translation>
</message>
<message>
<source>xcrun is not executable.</source>
<translation type="unfinished"></translation>
<translation>xcrun ist nicht ausführbar.</translation>
</message>
<message>
<source>Invalid Empty UDID.</source>
<translation type="unfinished"></translation>
<translation>Ungültige leere UDID.</translation>
</message>
<message>
<source>Failed to start simulator app.</source>
<translation type="unfinished"></translation>
<translation>Simulator-Anwendung konnte nicht gestartet werden.</translation>
</message>
<message>
<source>Simulator device is not available. (%1)</source>
<translation type="unfinished"></translation>
<translation>Simulator-Gerät ist nicht verfügbar. (%1)</translation>
</message>
<message>
<source>Simulator start was canceled.</source>
<translation type="unfinished"></translation>
<translation>Der Start des Simulators wurde abgebrochen.</translation>
</message>
<message>
<source>Cannot start Simulator device. Previous instance taking too long to shut down. (%1)</source>
<translation type="unfinished"></translation>
<translation>Das Simulator-Gerät konnte nicht gestartet werden. Die vorherige Instanz braucht zu lange, um herunterzufahren. (%1)</translation>
</message>
<message>
<source>Cannot start Simulator device. Simulator not in shutdown state. (%1)</source>
<translation type="unfinished"></translation>
<translation>Das Simulator-Gerät konnte nicht gestartet werden. Der Simulator ist nicht im &quot;shutdown&quot;-Zustand. (%1)</translation>
</message>
<message>
<source>Cannot start Simulator device. Simulator not in booted state. (%1)</source>
<translation type="unfinished"></translation>
<translation>Das Simulator-Gerät konnte nicht gestartet werden. Der Simulator ist nicht im &quot;booted&quot;-Zustand. (%1)</translation>
</message>
<message>
<source>Bundle path does not exist.</source>
<translation type="unfinished"></translation>
<translation>Der Pfad des Bundles existiert nicht.</translation>
</message>
<message>
<source>Invalid (empty) bundle identifier.</source>
<translation type="unfinished"></translation>
<translation>Ungültiger (leerer) Bundle-Identifier.</translation>
</message>
<message>
<source>Failed to convert inferior pid. (%1)</source>
<translation type="unfinished"></translation>
<translation>Die PID des zu debuggenden Prozesses konnte nicht ermittelt werden. (%1)</translation>
</message>
</context>
<context>
@@ -35466,43 +35466,43 @@ Ablaufdatum: %3</translation>
</message>
<message>
<source>Install npm Package</source>
<translation type="unfinished"></translation>
<translation>npm-Paket installieren</translation>
</message>
<message>
<source>Running &quot;%1&quot; to install %2.</source>
<translation type="unfinished">Führe &quot;%1&quot; aus, um %2 zu installieren.</translation>
<translation>Führe &quot;%1&quot; aus, um %2 zu installieren.</translation>
</message>
<message>
<source>The installation of &quot;%1&quot; was canceled by timeout.</source>
<translation type="unfinished">Die Installation von &quot;%1&quot; wurde wegen Zeitüberschreitung abgebrochen.</translation>
<translation>Die Installation von &quot;%1&quot; wurde wegen Zeitüberschreitung abgebrochen.</translation>
</message>
<message>
<source>The installation of &quot;%1&quot; was canceled by the user.</source>
<translation type="unfinished">Die Installation von &quot;%1&quot; wurde vom Benutzer abgebrochen.</translation>
<translation>Die Installation von &quot;%1&quot; wurde vom Benutzer abgebrochen.</translation>
</message>
<message>
<source>Installing &quot;%1&quot; failed with exit code %2.</source>
<translation type="unfinished">Die Installation von &quot;%1&quot; ist mit dem Rückgabewert %2 fehlgeschlagen.</translation>
<translation>Die Installation von &quot;%1&quot; ist mit dem Rückgabewert %2 fehlgeschlagen.</translation>
</message>
<message>
<source>Install %1 language server via npm.</source>
<translation type="unfinished"></translation>
<translation>Installiere den Language Server für %1 über npm.</translation>
</message>
<message>
<source>Setup %1 language server (%2).</source>
<translation type="unfinished"></translation>
<translation>Language Server für %1 einrichten (%2).</translation>
</message>
<message>
<source>Install</source>
<translation type="unfinished">Installieren</translation>
<translation>Installieren</translation>
</message>
<message>
<source>Setup</source>
<translation type="unfinished"></translation>
<translation>Einrichten</translation>
</message>
<message>
<source>%1 Language Server</source>
<translation type="unfinished"></translation>
<translation>%1 Language Server</translation>
</message>
<message>
<source>Name:</source>
@@ -35725,7 +35725,7 @@ Für gültige Einstellungen schauen Sie in die Dokumentation des benutzten Langu
</message>
<message>
<source>Collapse All</source>
<translation type="unfinished">Alle einklappen</translation>
<translation>Alle einklappen</translation>
</message>
<message>
<source>Client Message</source>
@@ -38169,7 +38169,7 @@ Weitere Erklärungen sind möglicherweise in &quot;Ausgabe der Anwendung&quot; z
<message>
<source>Error running &quot;where&quot; on %1: The file is not mapped.</source>
<extracomment>Failed to run p4 &quot;where&quot; to resolve a Perforce file name to a local file system name.</extracomment>
<translation type="unfinished"></translation>
<translation>Fehler beim Ausführen von &quot;where&quot; auf %1: Die Datei ist nicht zugeordnet.</translation>
</message>
<message>
<source>p4 revert</source>
@@ -52978,7 +52978,7 @@ Werte kleiner als 100% können überlappende und falsch ausgerichtete Darstellun
</message>
<message>
<source>Custom settings:</source>
<translation type="unfinished"></translation>
<translation>Benutzerdefinierte Einstellungen:</translation>
</message>
<message>
<source>Delete</source>
@@ -53300,7 +53300,7 @@ Werte kleiner als 100% können überlappende und falsch ausgerichtete Darstellun
</message>
<message>
<source>%1 [customizable]</source>
<translation type="unfinished"></translation>
<translation>%1 [anpassbar]</translation>
</message>
<message>
<source>Files in File System</source>
@@ -53701,11 +53701,11 @@ Gibt an, wie sich die Rücktaste bezüglich Einrückung verhält.
</message>
<message>
<source>&amp;Highlight selection</source>
<translation type="unfinished"></translation>
<translation>Aus&amp;wahl hervorheben</translation>
</message>
<message>
<source>Adds a colored background and a marker to the scrollbar to occurrences of the selected text.</source>
<translation type="unfinished"></translation>
<translation>Hebt Vorkommen des ausgewählten Texts mit einem farbigen Hintergrund hervor und fügt Markierungen zur Bildlaufleiste hinzu.</translation>
</message>
<message>
<source>Next to editor content</source>
@@ -54419,7 +54419,7 @@ Bestimmt das Verhalten bezüglich der Einrückung von Fortsetzungszeilen.
</message>
<message>
<source>&amp;Sort Lines</source>
<translation type="unfinished"></translation>
<translation>Zeilen &amp;sortieren</translation>
</message>
<message>
<source>Meta+Shift+S</source>
@@ -55634,7 +55634,7 @@ Außer Leerzeichen innerhalb von Kommentaren und Zeichenketten.</translation>
</message>
<message>
<source>Git Blame</source>
<translation type="unfinished">Git Blame</translation>
<translation>Git Blame</translation>
</message>
<message>
<source>Copy SHA1 to Clipboard</source>
@@ -55643,11 +55643,11 @@ Außer Leerzeichen innerhalb von Kommentaren und Zeichenketten.</translation>
<message>
<source>&lt;b&gt;Note:&lt;/b&gt; &quot;%1&quot; or &quot;%2&quot; is enabled in the instant blame settings.</source>
<extracomment>%1 and %2 are the &quot;ignore whitespace changes&quot; and &quot;ignore line moves&quot; options</extracomment>
<translation type="unfinished">&lt;b&gt;Hinweis:&lt;/b&gt; &quot;%1&quot; oder &quot;%2&quot; ist in den Einstellungen für Instant Blame aktiviert.</translation>
<translation>&lt;b&gt;Hinweis:&lt;/b&gt; &quot;%1&quot; oder &quot;%2&quot; ist in den Einstellungen für Instant Blame aktiviert.</translation>
</message>
<message>
<source>You</source>
<translation type="unfinished">Sie selbst</translation>
<translation>Sie selbst</translation>
</message>
<message>
<source>Show Preview</source>
@@ -58646,7 +58646,7 @@ Check settings or ensure Valgrind is installed and available in PATH.</source>
</message>
<message>
<source>Running in &quot;%1&quot;: %2</source>
<translation type="unfinished"></translation>
<translation>Führe in &quot;%1&quot; aus: %2</translation>
</message>
<message>
<source>Failed to retrieve data.</source>

View File

@@ -13699,6 +13699,10 @@ Remarque&#xa0;: cela peut vous exposer à une attaque de type «&#xa0;homme du m
<source>Key chain message: &quot;%1&quot;.</source>
<translation>Message du porte-clés «&#xa0;%1&#xa0;».</translation>
</message>
<message>
<source>Unauthenticated access failed (wrong user), using authenticated access...</source>
<translation>Échec d&apos;accès non authentifié (mauvais utilisateur), utilisation d&apos;un accès authentifié</translation>
</message>
<message>
<source>Enter the password for:
Dashboard: %1
@@ -19006,10 +19010,6 @@ Si les curseurs de redimensionnement des vues du système ne s&apos;affichent pa
<source>&lt;System Language&gt;</source>
<translation>&lt;Langue du système&gt;</translation>
</message>
<message>
<source>The cursors for resizing views will change after restart.</source>
<translation>Les curseurs utilisés lors du redimensionnement des vues seront pris en compte après un redémarrage.</translation>
</message>
<message>
<source>The language change will take effect after restart.</source>
<translation>Le changement de langue prend effet après le redémarrage.</translation>
@@ -29336,10 +29336,6 @@ La recompilation du projet peut aider.</translation>
<source>Failed to create container shell (Out of memory).</source>
<translation>Échec lors de la création du shell du container (mémoire insuffisante).</translation>
</message>
<message>
<source>Cannot start docker device from non-main thread</source>
<translation>Impossible de démarrer le périphérique docker depuis un thread non principal</translation>
</message>
<message>
<source>Device is shut down</source>
<translation>Le périphérique a é fermé</translation>

View File

@@ -958,11 +958,14 @@ void TerminalView::applySizeChange()
};
if (newLiveSize.height() <= 0)
newLiveSize.setHeight(1);
return;
if (newLiveSize.width() <= 0)
newLiveSize.setWidth(1);
if (d->m_surface->liveSize() == newLiveSize)
return;
resizePty(newLiveSize);
d->m_surface->resize(newLiveSize);
flushVTerm(true);

View File

@@ -21,8 +21,7 @@ namespace Internal {
static EnvironmentItems cleanUp(const EnvironmentItems &items)
{
EnvironmentItems uniqueItems;
QSet<QString> uniqueSet;
EnvironmentItems cleanedItems;
for (int i = items.count() - 1; i >= 0; i--) {
EnvironmentItem item = items.at(i);
if (HostOsInfo::isWindowsHost())
@@ -30,10 +29,10 @@ static EnvironmentItems cleanUp(const EnvironmentItems &items)
const QString &itemName = item.name;
QString emptyName = itemName;
emptyName.remove(QLatin1Char(' '));
if (!emptyName.isEmpty() && Utils::insert(uniqueSet, itemName))
uniqueItems.prepend(item);
if (!emptyName.isEmpty())
cleanedItems.prepend(item);
}
return uniqueItems;
return cleanedItems;
}
class TextEditHelper : public QPlainTextEdit

View File

@@ -953,7 +953,7 @@ VcsCommand *BazaarPluginPrivate::createInitialCheckoutCommand(const QString &url
Environment env = m_client.processEnvironment(baseDirectory);
env.set("BZR_PROGRESS_BAR", "text");
auto command = VcsBaseClient::createVcsCommand(baseDirectory, env);
auto command = VcsBaseClient::createVcsCommand(this, baseDirectory, env);
command->addJob({m_client.vcsBinary(baseDirectory), args}, -1);
return command;
}

View File

@@ -245,6 +245,8 @@ static CMakeConfig configurationFromPresetProbe(
cmakeListTxt.writeFileContents(QByteArray("cmake_minimum_required(VERSION 3.15)\n"
"\n"
"project(preset-probe)\n"
"set(CMAKE_C_COMPILER \"${CMAKE_C_COMPILER}\" CACHE FILEPATH \"\" FORCE)\n"
"set(CMAKE_CXX_COMPILER \"${CMAKE_CXX_COMPILER}\" CACHE FILEPATH \"\" FORCE)\n"
"\n"));
Process cmake;

View File

@@ -174,19 +174,27 @@ bool ExternalToolModel::dropMimeData(const QMimeData *data,
return false;
QDataStream stream(&ba, QIODevice::ReadOnly);
QString category;
int pos = -1;
qsizetype pos = -1;
stream >> category;
stream >> pos;
QList<ExternalTool *> &items = m_tools[category];
QTC_ASSERT(pos >= 0 && pos < items.count(), return false);
beginRemoveRows(index(m_tools.keys().indexOf(category), 0), pos, pos);
const int sourceCategoryIndex = std::distance(m_tools.constBegin(), m_tools.constFind(category));
const int targetCategoryIndex
= std::distance(m_tools.constBegin(), m_tools.constFind(toCategory));
QTC_ASSERT(sourceCategoryIndex >= 0 && targetCategoryIndex >= 0, return false);
if (row < 0) // target row can be -1 when dropping onto the category itself
row = 0;
if (sourceCategoryIndex == targetCategoryIndex) {
if (row == pos || row == pos + 1) // would end at the same place, don't
return false;
}
beginMoveRows(index(sourceCategoryIndex, 0), pos, pos, index(targetCategoryIndex, 0), row);
ExternalTool *tool = items.takeAt(pos);
endRemoveRows();
if (row < 0)
row = m_tools.value(toCategory).count();
beginInsertRows(index(m_tools.keys().indexOf(toCategory), 0), row, row);
if (category == toCategory && pos < row) // adapt the target row for the removed item
--row;
m_tools[toCategory].insert(row, tool);
endInsertRows();
endMoveRows();
return true;
}

View File

@@ -161,7 +161,7 @@ class SystemSettingsWidget : public IOptionsPageWidget
{
public:
SystemSettingsWidget()
: m_fileSystemCaseSensitivityChooser(new QComboBox)
: m_fileSystemCaseSensitivityChooser(HostOsInfo::isMacHost() ? new QComboBox : nullptr)
, m_externalFileBrowserEdit(new QLineEdit)
, m_terminalComboBox(new QComboBox)
, m_terminalOpenArgs(new QLineEdit)
@@ -188,9 +188,6 @@ public:
m_terminalOpenArgs->setToolTip(
Tr::tr("Command line arguments used for \"%1\".").arg(FileUtils::msgTerminalHereAction()));
auto fileSystemCaseSensitivityLabel = new QLabel(Tr::tr("File system case sensitivity:"));
fileSystemCaseSensitivityLabel->setToolTip(
Tr::tr("Influences how file names are matched to decide if they are the same."));
auto resetFileBrowserButton = new QPushButton(Tr::tr("Reset"));
resetFileBrowserButton->setToolTip(Tr::tr("Reset to default."));
auto helpExternalFileBrowserButton = new QToolButton;
@@ -223,6 +220,9 @@ public:
}
grid.addRow({Span(4, s.patchCommand)});
if (HostOsInfo::isMacHost()) {
auto fileSystemCaseSensitivityLabel = new QLabel(Tr::tr("File system case sensitivity:"));
fileSystemCaseSensitivityLabel->setToolTip(
Tr::tr("Influences how file names are matched to decide if they are the same."));
grid.addRow({fileSystemCaseSensitivityLabel,
m_fileSystemCaseSensitivityChooser});
}

View File

@@ -752,8 +752,8 @@ bool ListModelFilter::leaveFilterAcceptsRowBeforeFiltering(const ListItem *, boo
return false;
}
constexpr TextFormat titleTF {Theme::Token_Text_Default, StyleHelper::UiElementIconActive};
constexpr TextFormat descriptionTF {titleTF.themeColor, StyleHelper::UiElementCaption};
constexpr TextFormat titleTF {Theme::Token_Text_Default, StyleHelper::UiElementH6};
constexpr TextFormat descriptionTF {titleTF.themeColor, StyleHelper::UiElementCaptionStrong};
constexpr TextFormat tagsLabelTF {Theme::Token_Text_Muted, StyleHelper::UiElementCaptionStrong};
constexpr TextFormat tagsTF {Theme::Token_Text_Accent, tagsLabelTF.uiElement};

View File

@@ -410,7 +410,8 @@ VcsCommand *CvsPluginPrivate::createInitialCheckoutCommand(const QString &url,
QStringList args;
args << QLatin1String("checkout") << url << extraArgs;
auto command = VcsBaseClient::createVcsCommand(baseDirectory, Environment::systemEnvironment());
auto command = VcsBaseClient::createVcsCommand(this, baseDirectory,
Environment::systemEnvironment());
command->setDisplayName(Tr::tr("CVS Checkout"));
command->addJob({settings().binaryPath(), settings().addOptions(args)}, -1);
return command;

View File

@@ -77,10 +77,15 @@ DebuggerRunConfigurationAspect::DebuggerRunConfigurationAspect(Target *target)
const auto setSummaryText = [this, details] {
const auto describe = [](const TriStateAspect &aspect, const QString &name) {
if (aspect() == TriState::Enabled)
if (aspect() == TriState::Enabled) {
//: %1 is C++, QML, or Python
return Tr::tr("Enable %1 debugger.").arg(name);
if (aspect() == TriState::Disabled)
}
if (aspect() == TriState::Disabled) {
//: %1 is C++, QML, or Python
return Tr::tr("Disable %1 debugger.").arg(name);
}
//: %1 is C++, QML, or Python
return Tr::tr("Try to determine need for %1 debugger.").arg(name);
};

View File

@@ -959,8 +959,10 @@ static QString displayType(const WatchItem *item)
result += QString(":%1").arg(item->bitsize);
result.remove('\'');
result = watchModel(item)->removeNamespaces(result);
if (item->valuelen > 0)
if (item->valuelen > 0) {
//: <type> of length <number>, e.g. for strings and byte arrays
result = Tr::tr("%1 of length %2").arg(result).arg(item->valuelen);
}
return result;
}

View File

@@ -927,7 +927,7 @@ VcsCommand *FossilPluginPrivate::createInitialCheckoutCommand(const QString &sou
checkoutPath.createDir();
// Setup the wizard page command job
auto command = VcsBaseClient::createVcsCommand(checkoutPath,
auto command = VcsBaseClient::createVcsCommand(this, checkoutPath,
fossilClient().processEnvironment(checkoutPath));
if (!isLocalRepository

View File

@@ -1769,7 +1769,7 @@ VcsCommand *GitPluginPrivate::createInitialCheckoutCommand(const QString &url,
QStringList args = {"clone", "--progress"};
args << extraArgs << url << localName;
auto command = VcsBaseClient::createVcsCommand(baseDirectory,
auto command = VcsBaseClient::createVcsCommand(this, baseDirectory,
gitClient().processEnvironment(baseDirectory));
command->addFlags(RunFlags::SuppressStdErr);
command->addJob({gitClient().vcsBinary(baseDirectory), args}, -1);

View File

@@ -8,6 +8,8 @@
#include <coreplugin/icore.h>
#include <coreplugin/progressmanager/progressmanager.h>
#include <extensionsystem/pluginmanager.h>
#include <utils/algorithm.h>
#include <utils/async.h>
#include <utils/filesystemwatcher.h>
@@ -138,6 +140,7 @@ void HelpManager::registerDocumentation(const QStringList &files)
}
QFuture<bool> future = Utils::asyncRun(&registerDocumentationNow, collectionFilePath(), files);
ExtensionSystem::PluginManager::futureSynchronizer()->addFuture(future);
Utils::onResultReady(future, this, [](bool docsChanged){
if (docsChanged) {
d->m_helpEngine->setupData();
@@ -200,6 +203,7 @@ void HelpManager::unregisterDocumentation(const QStringList &files)
d->m_userRegisteredFiles.subtract(Utils::toSet(files));
QFuture<bool> future = Utils::asyncRun(&unregisterDocumentationNow, collectionFilePath(), files);
ExtensionSystem::PluginManager::futureSynchronizer()->addFuture(future);
Utils::onResultReady(future, this, [](bool docsChanged){
if (docsChanged) {
d->m_helpEngine->setupData();

View File

@@ -184,7 +184,7 @@ LanguageClientSettingsPageWidget::LanguageClientSettingsPageWidget(LanguageClien
auto addMenu = new QMenu(this);
addMenu->clear();
for (const ClientType &type : clientTypes()) {
auto action = new QAction(type.name);
auto action = new QAction(type.name, this);
connect(action, &QAction::triggered, this, [this, id = type.id]() { addItem(id); });
addMenu->addAction(action);
}

View File

@@ -736,9 +736,8 @@ VcsCommand *MercurialPluginPrivate::createInitialCheckoutCommand(const QString &
{
QStringList args;
args << QLatin1String("clone") << extraArgs << url << localName;
auto command = VcsBaseClient::createVcsCommand(baseDirectory,
mercurialClient().processEnvironment(
baseDirectory));
auto command = VcsBaseClient::createVcsCommand(this, baseDirectory,
mercurialClient().processEnvironment(baseDirectory));
command->addJob({settings().binaryPath(), args}, -1);
return command;
}

View File

@@ -47,10 +47,11 @@ const char PROJECT_BASE_ID[] = "Welcome.OpenRecentProject";
namespace ProjectExplorer {
namespace Internal {
constexpr TextFormat projectNameTF {Theme::Token_Text_Accent, StyleHelper::UiElementH5};
constexpr TextFormat projectPathTF {Theme::Token_Text_Muted, StyleHelper::UiElementIconActive};
constexpr TextFormat sessionNameTF {projectNameTF.themeColor, projectNameTF.uiElement};
constexpr TextFormat sessionProjetNameTF {Theme::Token_Text_Default, projectNameTF.uiElement};
constexpr TextFormat projectNameTF {Theme::Token_Text_Accent, StyleHelper::UiElementH6};
constexpr TextFormat projectPathTF {Theme::Token_Text_Muted, StyleHelper::UiElementCaptionStrong};
constexpr TextFormat sessionNameTF = {projectNameTF.themeColor, projectNameTF.uiElement,
Qt::AlignVCenter | Qt::TextDontClip};
constexpr TextFormat sessionProjectNameTF {Theme::Token_Text_Default, projectNameTF.uiElement};
constexpr TextFormat shortcutNumberTF {Theme::Token_Text_Default,
StyleHelper::UiElementCaptionStrong,
Qt::AlignCenter | Qt::TextDontClip};
@@ -315,36 +316,36 @@ public:
void paint(QPainter *painter, const QStyleOptionViewItem &option,
const QModelIndex &idx) const final
{
// visible on withIcon() Gap + arrow visible on hover Extra margin right of project item
// | | |
// +----------+----------+ +--------+-------+ +----------+----------+
// | | | | | |
// visible on withIcon() Gap + arrow visible on hover Extra margin right of project item
// | | |
// +-----------+----------+ +--------+-------+ +----------+----------+
// | | | | | |
//
// +------------+--------+--------+------------+--------+-------------+--------+-------+------------+---------------------+ --+
// | | | |(VPaddingXs)| |(VPaddingXs) | | | | | |
// | | | +------------+ +-------------+ | | | | |
// |(HPaddingXs)|<number>|(HGapXs)| <icon> |(HGapXs)|<sessionName>|(HGapXs)|<arrow>| | | +-- Header
// | |(16x16) | +------------+ +-------------+ | | | | |
// | | | |(VPaddingXs)| |(VPaddingXs) | | | | | |
// |------------+--------+--------+------------+--------+-------------+--------+-------+ | | --+
// | +-- | (VPaddingXs) | | | |
// | | +------------------------------+(HPaddingXs)| | |
// | | | <projectName> | | | |
// | | +------------------------------+ | | |
// | Per project in session --+ | (EXSPaddingGapS) | |(sessionScrollBarGap)| |
// | | +------------------------------+ | | |
// | | | <projectPath> | | | |
// | | +------------------------------+ | | +-- Expansion
// | +-- | (VPaddingXs) | | | |
// +----------------------------------------------+------------------------------------+------------+ | |
// | (VPaddingXs) | | |
// +----------------------------------------+--------------+----------------------------------------+ | |
// +-- | <cloneButton>|<renameButton>|<deleteButton> | | |
// | +----------------------------------------+--------------+----------------------------------------+ | |
// | | (VPaddingXs) | | |
// | +------------------------------------------------------------------------------------------------+---------------------+ --+
// | | (VGapL) | +-- Gap between session items
// | +----------------------------------------------------------------------------------------------------------------------+ --+
// +------------+--------+---------+------------+---------+-------------+--------+-------+------------+---------------------+ --+
// | | | |(VPaddingXs)| |(VPaddingXs) | | | | | |
// | | | +------------+ +-------------+ | | | | |
// |(HPaddingXs)|<number>|(HGapXxs)| <icon> |(HGapXxs)|<sessionName>|(HGapXs)|<arrow>| | | +-- Header
// | |(16x16) | +------------+ +-------------+ | | | | |
// | | | |(VPaddingXs)| |(VPaddingXs) | | | | | |
// |------------+--------+---------+------------+---------+-------------+--------+-------+ | | --+
// | +-- | (VPaddingXxs) | | | |
// | | +------------------------------+(HPaddingXs)| | |
// | | | <projectName> | | | |
// | | +------------------------------+ | | |
// | Per project in session --+ | (ExPaddingGapS) | |(sessionScrollBarGap)| |
// | | +------------------------------+ | | |
// | | | <projectPath> | | | |
// | | +------------------------------+ | | +-- Expansion
// | +-- | (VPaddingXxs) | | | |
// +------------------------------------------------------+------------------------------+------------+ | |
// | (VPaddingXs) | | |
// +-----------------------------------------+--------------+-----------------------------------------+ | |
// +-- | <cloneButton>|<renameButton>|<deleteButton> | | |
// | +-----------------------------------------+--------------+-----------------------------------------+ | |
// | | (VPaddingXs) | | |
// | +--------------------------------------------------------------------------------------------------+---------------------+ --+
// | | (VGapL) | +-- Gap between session items
// | +------------------------------------------------------------------------------------------------------------------------+ --+
// |
// \ session action "buttons" and dividers
// +-----------------------------------------------+--------+---------+--------+
@@ -380,11 +381,11 @@ public:
const int y = bgR.y();
const int numberX = x + s(HPaddingXs);
const int iconX = numberX + shortcutNumberWidth + s(HGapXs);
const int iconX = numberX + shortcutNumberWidth + s(HGapXxs);
const int arrowX = bgR.right() - s(HPaddingXs) - arrowS.width();
const QRect arrowHoverR(arrowX - s(HGapXs) + 1, y,
s(HGapXs) + arrowS.width() + s(HPaddingXs), hdR.height());
const int textX = withIcon() ? iconX + iconS.width() + s(HGapXs) : iconX;
const int textX = withIcon() ? iconX + iconS.width() + s(HGapXxs) : iconX;
const int iconY = y + (hdR.height() - iconS.height()) / 2;
const int arrowY = y + (hdR.height() - arrowS.height()) / 2;
@@ -419,8 +420,7 @@ public:
fullSessionName = Tr::tr("%1 (last session)").arg(fullSessionName);
if (isActiveSession && !isDefaultVirgin)
fullSessionName = Tr::tr("%1 (current session)").arg(fullSessionName);
const QRect switchR(x, y, hdR.width() - arrowHoverR.width(),
hdR.height() + s(VGapL));
const QRect switchR(x, y, hdR.width() - arrowHoverR.width(), arrowHoverR.height());
const bool switchActive = switchR.contains(mousePos);
painter->setPen(sessionNameTF.color());
painter->setFont(sessionNameTF.font(switchActive));
@@ -432,7 +432,7 @@ public:
m_activeSwitchToRect = switchR;
}
if (arrowVisible) {
if (arrowHoverR.adjusted(0, 0, 0, s(VGapL)).contains(mousePos)) {
if (arrowHoverR.adjusted(0, 0, 0, expanded ? 0 : s(VGapL)).contains(mousePos)) {
m_activeExpandRect = arrowHoverR;
} else {
painter->save();
@@ -447,9 +447,9 @@ public:
int yy = hdR.bottom();
if (expanded) {
const QFont projectNameFont = sessionProjetNameTF.font();
const QFont projectNameFont = sessionProjectNameTF.font();
const QFontMetrics projectNameFm(projectNameFont);
const int projectNameLineHeight = sessionProjetNameTF.lineHeight();
const int projectNameLineHeight = sessionProjectNameTF.lineHeight();
const QFont projectPathFont = projectPathTF.font();
const QFontMetrics projectPathFm(projectPathFont);
const int projectPathLineHeight = projectPathTF.lineHeight();
@@ -457,15 +457,15 @@ public:
const FilePaths projects = ProjectManager::projectsForSessionName(sessionName);
for (const FilePath &projectPath : projects) {
yy += s(VPaddingXs);
yy += s(VPaddingXxs);
{
painter->setFont(projectNameFont);
painter->setPen(sessionProjetNameTF.color());
painter->setPen(sessionProjectNameTF.color());
const QRect projectNameR(textX, yy, textWidth, projectNameLineHeight);
const QString projectNameElided =
projectNameFm.elidedText(projectPath.completeBaseName(), Qt::ElideMiddle,
textWidth);
painter->drawText(projectNameR, sessionProjetNameTF.drawTextFlags,
painter->drawText(projectNameR, sessionProjectNameTF.drawTextFlags,
projectNameElided);
yy += projectNameLineHeight;
yy += s(ExPaddingGapS);
@@ -483,7 +483,7 @@ public:
projectPathElided);
yy += projectPathLineHeight;
}
yy += s(VPaddingXs);
yy += s(VPaddingXxs);
}
yy += s(VGapXs);
@@ -551,11 +551,11 @@ public:
const QString sessionName = idx.data(Qt::DisplayRole).toString();
const FilePaths projects = ProjectManager::projectsForSessionName(sessionName);
const int projectEntryHeight =
s(VPaddingXs)
s(VPaddingXxs)
+ projectNameTF.lineHeight()
+ s(ExPaddingGapS)
+ projectPathTF.lineHeight()
+ s(VPaddingXs);
+ s(VPaddingXxs);
h += projects.size() * projectEntryHeight
+ s(VGapXs)
+ actionButtonHeight()
@@ -622,24 +622,24 @@ class ProjectDelegate : public BaseDelegate
public:
void paint(QPainter *painter, const QStyleOptionViewItem &option, const QModelIndex &idx) const final
{
// visible on withIcon() Extra margin right of project item
// | |
// +-------+-------+ +------+-----+
// | | | |
// visible on with Icon() Extra margin right of project item
// | |
// +--------+-------+ +------+-----+
// | | | |
//
// +------------+--------+--------+------+--------+-------------+------------+------------+
// | | | | | | (VPaddingXs)| | |
// | | | | | +-------------+ | |
// | | | | | |<projectName>| | |
// | | | | | +-------------+ | |
// |(HPaddingXs)|<number>|(HGapXs)|<icon>|(HGapXs)| (VGapXs) |(HPaddingXs)|(HPaddingXs)|
// | |(16x16) | | | +-------------+ | |
// | | | | | |<projectPath>| | |
// | | | | | +-------------+ | |
// | | | | | | (VPaddingXs)| | |
// +------------+--------+--------+------+--------+-------------+------------+------------+ --+
// | (VGapL) | +-- Gap between project items
// +--------------------------------------------------------------------------------------+ --+
// +------------+--------+---------+------+---------+-------------+------------+------------+
// | | | | | | (VPaddingXs)| | |
// | | | | | +-------------+ | |
// | | | | | |<projectName>| | |
// | | | | | +-------------+ | |
// |(HPaddingXs)|<number>|(HGapXxs)|<icon>|(HGapXxs)| (VGapXs) |(HPaddingXs)|(HPaddingXs)|
// | |(16x16) | | | +-------------+ | |
// | | | | | |<projectPath>| | |
// | | | | | +-------------+ | |
// | | | | | | (VPaddingXs)| | |
// +------------+--------+---------+------+---------+-------------+------------+------------+ --+
// | (VGapL) | +-- Gap between project items
// +----------------------------------------------------------------------------------------+ --+
const bool hovered = option.widget->isActiveWindow()
&& option.state & QStyle::State_MouseOver;
@@ -651,9 +651,9 @@ public:
const int x = bgR.x();
const int numberX = x + s(HPaddingXs);
const int iconX = numberX + shortcutNumberWidth + s(HGapXs);
const int iconX = numberX + shortcutNumberWidth + s(HGapXxs);
const int iconWidth = iconS.width();
const int textX = withIcon() ? iconX + iconWidth + s(HGapXs) : iconX;
const int textX = withIcon() ? iconX + iconWidth + s(HGapXxs) : iconX;
const int textWidth = bgR.width() - s(HPaddingXs) - textX;
const int y = bgR.y();

View File

@@ -193,7 +193,7 @@ public:
m_toolChainView->expandAll();
m_addButton = new QPushButton(Tr::tr("Add"), this);
auto addMenu = new QMenu;
auto addMenu = new QMenu(this);
for (ToolchainFactory *factory : std::as_const(m_factories)) {
QList<Utils::Id> languages = factory->supportedLanguages();
if (languages.isEmpty())

View File

@@ -35,7 +35,6 @@ void QmlDebuggingAspect::addToLayout(Layouting::LayoutItem &parent)
SelectionAspect::addToLayout(parent);
const auto warningLabel = createSubWidget<InfoLabel>(QString(), InfoLabel::Warning);
warningLabel->setElideMode(Qt::ElideNone);
warningLabel->setVisible(false);
parent.addRow({{}, warningLabel});
const auto changeHandler = [this, warningLabel] {
QString warningText;
@@ -51,7 +50,9 @@ void QmlDebuggingAspect::addToLayout(Layouting::LayoutItem &parent)
warningLabel->setText(warningText);
setVisible(supported);
const bool warningLabelsVisible = supported && !warningText.isEmpty();
if (warningLabel->parentWidget())
// avoid explicitly showing the widget when it doesn't have a parent, but always
// explicitly hide it when necessary
if (warningLabel->parentWidget() || !warningLabelsVisible)
warningLabel->setVisible(warningLabelsVisible);
};
connect(KitManager::instance(), &KitManager::kitsChanged, warningLabel, changeHandler);

View File

@@ -309,7 +309,7 @@ QtSettingsPageWidget::QtSettingsPageWidget()
{ProjectExplorer::Constants::msgAutoDetectedToolTip()});
m_manualItem = new StaticTreeItem(ProjectExplorer::Constants::msgManual());
m_model = new TreeModel<TreeItem, TreeItem, QtVersionItem>();
m_model = new TreeModel<TreeItem, TreeItem, QtVersionItem>(this);
m_model->setHeader({Tr::tr("Name"), Tr::tr("qmake Path")});
m_model->rootItem()->appendChild(m_autoItem);
m_model->rootItem()->appendChild(m_manualItem);

View File

@@ -24,7 +24,6 @@
#include <projectexplorer/projectexplorerconstants.h>
#include <utils/algorithm.h>
#include <utils/async.h>
#include <utils/devicefileaccess.h>
#include <utils/deviceshell.h>
#include <utils/environment.h>
@@ -1674,12 +1673,10 @@ void LinuxDevice::setDisconnected(bool disconnected)
d->setDisconnected(disconnected);
}
QFuture<bool> LinuxDevice::tryToConnect()
bool LinuxDevice::tryToConnect()
{
return Utils::asyncRun([this] {
QMutexLocker locker(&d->m_shellMutex);
return d->setupShell(sshParameters(), false);
});
QMutexLocker locker(&d->m_shellMutex);
return d->setupShell(sshParameters(), false);
}
namespace Internal {

View File

@@ -50,7 +50,7 @@ public:
bool isDisconnected() const;
void setDisconnected(bool disconnected);
QFuture<bool> tryToConnect();
bool tryToConnect();
protected:
LinuxDevice();

View File

@@ -6,6 +6,8 @@
#include "linuxdevice.h"
#include "remotelinuxtr.h"
#include <extensionsystem/pluginmanager.h>
#include <projectexplorer/devicesupport/deviceusedportsgatherer.h>
#include <projectexplorer/devicesupport/filetransfer.h>
#include <projectexplorer/projectexplorerconstants.h>
@@ -13,13 +15,12 @@
#include <solutions/tasking/tasktreerunner.h>
#include <utils/algorithm.h>
#include <utils/qtcprocess.h>
#include <utils/async.h>
#include <utils/processinterface.h>
#include <utils/qtcassert.h>
#include <utils/qtcprocess.h>
#include <utils/stringutils.h>
#include <QFutureWatcher>
using namespace ProjectExplorer;
using namespace Tasking;
using namespace Utils;
@@ -39,6 +40,7 @@ public:
QStringList commandsToTest() const;
GroupItem connectionTask() const;
GroupItem echoTask(const QString &contents) const;
GroupItem unameTask() const;
GroupItem gathererTask() const;
@@ -46,13 +48,9 @@ public:
const Storage<TransferStorage> &storage) const;
GroupItem transferTasks() const;
GroupItem commandTasks() const;
void runCommandTests();
bool isRunning() const { return m_connectionTest || m_taskTreeRunner.isRunning(); }
GenericLinuxDeviceTester *q = nullptr;
LinuxDevice::Ptr m_device;
QFutureWatcher<bool> *m_connectionTest = nullptr;
TaskTreeRunner m_taskTreeRunner;
QStringList m_extraCommands;
QList<GroupItem> m_extraTests;
@@ -98,6 +96,27 @@ QStringList GenericLinuxDeviceTesterPrivate::commandsToTest() const
return commands;
}
GroupItem GenericLinuxDeviceTesterPrivate::connectionTask() const
{
const auto onSetup = [this](Async<bool> &task) {
emit q->progressMessage(Tr::tr("Connecting to device..."));
task.setConcurrentCallData([device = m_device] { return device->tryToConnect(); });
task.setFutureSynchronizer(ExtensionSystem::PluginManager::futureSynchronizer());
};
const auto onDone = [this](const Async<bool> &task) {
const bool success = task.isResultAvailable() && task.result();
if (success) {
// TODO: For master: move the '\n' outside of Tr().
emit q->progressMessage(Tr::tr("Connected. Now doing extended checks.\n"));
} else {
emit q->errorMessage(
Tr::tr("Basic connectivity test failed, device is considered unusable.") + '\n');
}
return toDoneResult(success);
};
return AsyncTask<bool>(onSetup, onDone);
}
GroupItem GenericLinuxDeviceTesterPrivate::echoTask(const QString &contents) const
{
const auto onSetup = [this, contents](Process &process) {
@@ -283,20 +302,6 @@ GroupItem GenericLinuxDeviceTesterPrivate::commandTasks() const
return root;
}
void GenericLinuxDeviceTesterPrivate::runCommandTests()
{
const Group root {
echoTask("Hello"), // No quoting necessary
echoTask("Hello Remote World!"), // Checks quoting, too.
unameTask(),
gathererTask(),
transferTasks(),
m_extraTests,
commandTasks()
};
m_taskTreeRunner.start(root);
}
} // namespace Internal
using namespace Internal;
@@ -323,39 +328,27 @@ void GenericLinuxDeviceTester::setExtraTests(const QList<GroupItem> &extraTests)
void GenericLinuxDeviceTester::testDevice(const IDevice::Ptr &deviceConfiguration)
{
QTC_ASSERT(!d->isRunning(), return);
emit progressMessage(Tr::tr("Connecting to device..."));
QTC_ASSERT(!d->m_taskTreeRunner.isRunning(), return);
d->m_device = std::static_pointer_cast<LinuxDevice>(deviceConfiguration);
d->m_connectionTest = new QFutureWatcher<bool>(this);
connect(d->m_connectionTest, &QFutureWatcher<bool>::finished, this, [this] {
const bool success = d->m_connectionTest->result();
d->m_connectionTest->deleteLater();
d->m_connectionTest = nullptr;
if (success) {
emit progressMessage(Tr::tr("Connected. Now doing extended checks.\n"));
d->runCommandTests();
} else {
emit errorMessage(
Tr::tr("Basic connectivity test failed, device is considered unusable."));
emit finished(TestFailure);
}
});
d->m_connectionTest->setFuture(d->m_device->tryToConnect());
const Group root {
d->connectionTask(),
d->echoTask("Hello"), // No quoting necessary
d->echoTask("Hello Remote World!"), // Checks quoting, too.
d->unameTask(),
d->gathererTask(),
d->transferTasks(),
d->m_extraTests,
d->commandTasks()
};
d->m_taskTreeRunner.start(root);
}
void GenericLinuxDeviceTester::stopTest()
{
QTC_ASSERT(d->isRunning(), return);
if (d->m_connectionTest) {
d->m_connectionTest->disconnect();
d->m_connectionTest->cancel();
d->m_connectionTest = nullptr;
} else {
d->m_taskTreeRunner.reset();
}
QTC_ASSERT(d->m_taskTreeRunner.isRunning(), return);
d->m_taskTreeRunner.reset();
emit finished(TestFailure);
}

View File

@@ -136,9 +136,11 @@ public:
private:
void showDialogOrSettings()
{
if (!Internal::settings().toolsRegistered() &&
!Core::ICore::showOptionsDialog(Constants::TOOLSSETTINGSPAGE_ID)) {
return;
if (!Internal::settings().toolsRegistered()) {
// Show options if ffmpeg/ffprobe are neither autodetected nor manually set
Core::ICore::showOptionsDialog(Constants::TOOLSSETTINGSPAGE_ID);
if (!Internal::settings().toolsRegistered())
return; // User did not set ffmpeg/ffprobe
}
ScreenRecorderDialog::showDialog();

View File

@@ -1135,9 +1135,8 @@ VcsCommand *SubversionPluginPrivate::createInitialCheckoutCommand(const QString
args << SubversionClient::AddAuthOptions();
args << Subversion::Constants::NON_INTERACTIVE_OPTION << extraArgs << url << localName;
auto command = VcsBaseClient::createVcsCommand(baseDirectory,
subversionClient().processEnvironment(
baseDirectory));
auto command = VcsBaseClient::createVcsCommand(this, baseDirectory,
subversionClient().processEnvironment(baseDirectory));
command->addJob(args, -1);
return command;
}

View File

@@ -336,7 +336,7 @@ qint64 TerminalWidget::writeToPty(const QByteArray &data)
void TerminalWidget::resizePty(QSize newSize)
{
if (m_process && m_process->ptyData())
if (m_process && m_process->ptyData() && m_process->isRunning())
m_process->ptyData()->resize(newSize);
}

View File

@@ -6,7 +6,6 @@
#include "vcsbaseclientsettings.h"
#include "vcsbaseeditor.h"
#include "vcsbaseeditorconfig.h"
#include "vcsbaseplugin.h"
#include "vcsbasetr.h"
#include "vcscommand.h"
#include "vcsoutputwindow.h"
@@ -72,7 +71,8 @@ FilePath VcsBaseClientImpl::vcsBinary(const Utils::FilePath &forDirectory) const
VcsCommand *VcsBaseClientImpl::createCommand(const FilePath &workingDirectory,
VcsBaseEditorWidget *editor) const
{
auto cmd = createVcsCommand(workingDirectory, processEnvironment(workingDirectory));
auto cmd = createVcsCommand(const_cast<VcsBaseClientImpl *>(this),
workingDirectory, processEnvironment(workingDirectory));
if (editor) {
editor->setCommand(cmd);
connect(cmd, &VcsCommand::done, editor, [editor, cmd] {
@@ -214,6 +214,14 @@ VcsCommand *VcsBaseClientImpl::createVcsCommand(const FilePath &defaultWorkingDi
return new VcsCommand(defaultWorkingDir, environment);
}
VcsCommand *VcsBaseClientImpl::createVcsCommand(QObject *parent, const FilePath &defaultWorkingDir,
const Environment &environment)
{
auto command = new VcsCommand(defaultWorkingDir, environment);
command->setParent(parent);
return command;
}
VcsBaseEditorWidget *VcsBaseClientImpl::createVcsEditor(Id kind, QString title,
const FilePath &source, QTextCodec *codec,
const char *registerDynamicProperty,

View File

@@ -44,8 +44,11 @@ public:
virtual Utils::FilePath vcsBinary(const Utils::FilePath &forDirectory) const;
int vcsTimeoutS() const;
// TODO: For master: remove this overload.
static VcsCommand *createVcsCommand(const Utils::FilePath &defaultWorkingDir,
const Utils::Environment &environment);
static VcsCommand *createVcsCommand(QObject *parent, const Utils::FilePath &defaultWorkingDir,
const Utils::Environment &environment);
VcsBaseEditorWidget *createVcsEditor(Utils::Id kind, QString title,
const Utils::FilePath &source, QTextCodec *codec,

View File

@@ -65,6 +65,7 @@ class VCSBASE_EXPORT VcsCommand final : public QObject
Q_OBJECT
public:
// TODO: For master, make c'tor private and make it a friend to VcsBaseClientImpl.
VcsCommand(const Utils::FilePath &workingDirectory, const Utils::Environment &environment);
~VcsCommand() override;

Binary file not shown.

Before

Width:  |  Height:  |  Size: 175 B

After

Width:  |  Height:  |  Size: 172 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 225 B

After

Width:  |  Height:  |  Size: 212 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 192 B

After

Width:  |  Height:  |  Size: 165 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 255 B

After

Width:  |  Height:  |  Size: 187 B

Some files were not shown because too many files have changed in this diff Show More