Merge remote-tracking branch 'origin/16.0' into qds/dev

Resolve conflict in src/plugins/coreplugin/systemsettings.cpp
(with current master version)

Change-Id: Ie8599e93f2b5eb5b1d61a10e674874b37a24ae2a
This commit is contained in:
Tim Jenssen
2025-04-24 12:29:36 +02:00
64 changed files with 63693 additions and 240 deletions

View File

@@ -7,7 +7,7 @@ on:
- 'doc/**'
env:
QT_VERSION: 6.8.2
QT_VERSION: 6.8.3
MACOS_DEPLOYMENT_TARGET: 11.0
CLANG_VERSION: 19.1.6
ELFUTILS_VERSION: 0.175

View File

@@ -136,6 +136,32 @@ if(CRASHPAD_BACKEND_URL AND (WIN32 OR APPLE)) # Linux is not supported for now
endif()
add_feature_info("Build with Crashpad" ${BUILD_WITH_CRASHPAD} "")
set(SENTRY_DSN "$ENV{QTC_SENTRY_DSN}" CACHE STRING "Data Source Name to use for sending Sentry events.")
set(SENTRY_PROJECT "" CACHE STRING "Project ID to use for sending Sentry events.")
set(BUILD_WITH_SENTRY OFF)
if(SENTRY_DSN AND SENTRY_PROJECT)
find_package(sentry QUIET)
if(TARGET sentry::sentry)
set(BUILD_WITH_SENTRY ON)
get_target_property(__sentry_configs sentry::sentry IMPORTED_CONFIGURATIONS)
get_target_property(__sentry_lib sentry::sentry IMPORTED_LOCATION_${__sentry_configs})
install(FILES ${__sentry_lib}
DESTINATION "${IDE_LIBRARY_ARCHIVE_PATH}"
COMPONENT Dependencies
EXCLUDE_FROM_ALL
)
if (TARGET sentry_crashpad::crashpad_handler)
get_target_property(SENTRY_CRASHPAD_PATH sentry_crashpad::crashpad_handler IMPORTED_LOCATION_${__sentry_configs})
install(PROGRAMS ${SENTRY_CRASHPAD_PATH}
DESTINATION "${IDE_LIBEXEC_PATH}"
COMPONENT Dependencies
EXCLUDE_FROM_ALL
)
endif()
endif()
endif()
add_feature_info("Build with Sentry" ${BUILD_WITH_SENTRY} "")
function (set_if_target var target)
if (TARGET "${target}")
set(_result ON)

View File

@@ -1,6 +1,6 @@
set(IDE_VERSION "16.0.1") # The IDE version.
set(IDE_VERSION "16.0.2") # The IDE version.
set(IDE_VERSION_COMPAT "16.0.0") # The IDE Compatibility version.
set(IDE_VERSION_DISPLAY "16.0.1") # The IDE display version.
set(IDE_VERSION_DISPLAY "16.0.2") # The IDE display version.
set(IDE_SETTINGSVARIANT "QtProject") # The IDE settings variation.
set(IDE_DISPLAY_NAME "Qt Creator") # The IDE display name.

View File

@@ -60,8 +60,40 @@ function(_extract_ts_data_from_targets outprefix)
set("${outprefix}_includes" "${_includes}" PARENT_SCOPE)
endfunction()
function(_create_lupdate_response_file response_file)
set(no_value_options "")
set(single_value_options "")
set(multi_value_options SOURCES INCLUDES)
cmake_parse_arguments(PARSE_ARGV 1 arg
"${no_value_options}" "${single_value_options}" "${multi_value_options}"
)
if(arg_UNPARSED_ARGUMENTS)
message(FATAL_ERROR "Unexpected arguments: ${arg_UNPARSED_ARGUMENTS}")
endif()
set(sources "${arg_SOURCES}")
list(SORT sources)
set(includes "${arg_INCLUDES}")
list(REMOVE_DUPLICATES sources)
list(REMOVE_DUPLICATES includes)
list(REMOVE_ITEM sources "")
list(REMOVE_ITEM includes "")
list(TRANSFORM includes PREPEND "-I")
string(REPLACE ";" "\n" sources_str "${sources}")
string(REPLACE ";" "\n" includes_str "${includes}")
file(WRITE "${response_file}" "${sources_str}\n${includes_str}")
endfunction()
function(_create_ts_custom_target name)
cmake_parse_arguments(_arg "EXCLUDE_FROM_ALL" "FILE_PREFIX;TS_TARGET_PREFIX" "SOURCES;INCLUDES" ${ARGN})
cmake_parse_arguments(_arg "" "FILE_PREFIX;LUPDATE_RESPONSE_FILE;TS_TARGET_PREFIX"
"DEPENDS;LANGUAGES" ${ARGN}
)
if (_arg_UNPARSED_ARGUMENTS)
message(FATAL_ERROR "Invalid parameters to _create_ts_custom_target: ${_arg_UNPARSED_ARGUMENTS}.")
endif()
@@ -70,77 +102,58 @@ function(_create_ts_custom_target name)
set(_arg_TS_TARGET_PREFIX "ts_")
endif()
set(ts_file "${CMAKE_CURRENT_SOURCE_DIR}/${_arg_FILE_PREFIX}_${name}.ts")
set(languages "${name}")
if(DEFINED _arg_LANGUAGES)
set(languages ${_arg_LANGUAGES})
endif()
set(_sources "${_arg_SOURCES}")
list(SORT _sources)
set(_includes "${_arg_INCLUDES}")
list(REMOVE_DUPLICATES _sources)
list(REMOVE_DUPLICATES _includes)
list(REMOVE_ITEM _sources "")
list(REMOVE_ITEM _includes "")
set(_prepended_includes)
foreach(include IN LISTS _includes)
list(APPEND _prepended_includes "-I${include}")
set(ts_files "")
foreach(language IN LISTS languages)
list(APPEND ts_files "${CMAKE_CURRENT_SOURCE_DIR}/${_arg_FILE_PREFIX}_${language}.ts")
endforeach()
set(_includes "${_prepended_includes}")
string(REPLACE ";" "\n" _sources_str "${_sources}")
string(REPLACE ";" "\n" _includes_str "${_includes}")
set(ts_file_list "${CMAKE_CURRENT_BINARY_DIR}/ts_${name}.lst")
file(WRITE "${ts_file_list}" "${_sources_str}\n${_includes_str}\n")
set(common_comment "Generate .ts file")
list(LENGTH languages languages_length)
if(languages_length GREATER 1)
string(APPEND common_comment "s")
endif()
string(APPEND common_comment " (${name})")
set(response_file ${_arg_LUPDATE_RESPONSE_FILE})
add_custom_target("${_arg_TS_TARGET_PREFIX}${name}"
COMMAND Qt::lupdate -locations relative -no-ui-lines "@${ts_file_list}" -ts ${ts_file}
COMMAND Qt::lupdate -locations relative -no-ui-lines "@${response_file}" -ts ${ts_files}
WORKING_DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}"
COMMENT "Generate .ts file (${name}), with obsolete translations and files and line numbers"
DEPENDS ${_sources}
COMMENT "${common_comment}, with obsolete translations and files and line numbers"
DEPENDS ${_arg_DEPENDS}
VERBATIM)
add_custom_target("${_arg_TS_TARGET_PREFIX}${name}_no_locations"
COMMAND Qt::lupdate -locations none -no-ui-lines "@${ts_file_list}" -ts ${ts_file}
COMMAND Qt::lupdate -locations none -no-ui-lines "@${response_file}" -ts ${ts_files}
WORKING_DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}"
COMMENT "Generate .ts file (${name}), with obsolete translations, without files and line numbers"
DEPENDS ${_sources}
COMMENT "${common_comment}, with obsolete translations, without files and line numbers"
DEPENDS ${_arg_DEPENDS}
VERBATIM)
# Uses lupdate + convert instead of just lupdate with '-locations none -no-obsolete'
# to keep the same sorting as the non-'cleaned' target and therefore keep the diff small
# get path for lconvert...
get_target_property(_lupdate_binary Qt::lupdate IMPORTED_LOCATION)
get_filename_component(_bin_dir ${_lupdate_binary} DIRECTORY)
set(lconvert_commands "")
foreach(ts_file IN LISTS ts_files)
list(APPEND lconvert_commands
COMMAND Qt::lconvert -locations none -no-ui-lines -no-obsolete ${ts_file} -o ${ts_file}
)
endforeach()
add_custom_target("${_arg_TS_TARGET_PREFIX}${name}_cleaned"
COMMAND Qt::lupdate -locations relative -no-ui-lines "@${ts_file_list}" -ts ${ts_file}
COMMAND ${_bin_dir}/lconvert -locations none -no-ui-lines -no-obsolete ${ts_file} -o ${ts_file}
COMMAND Qt::lupdate -locations relative -no-ui-lines "@${response_file}" -ts ${ts_files}
${lconvert_commands}
WORKING_DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}"
COMMENT "Generate .ts file (${name}), remove obsolete and vanished translations, and do not add files and line number"
DEPENDS ${_sources}
COMMENT "${common_comment}, remove obsolete and vanished translations, and do not add files and line number"
DEPENDS ${_arg_DEPENDS}
VERBATIM)
if (NOT _arg_EXCLUDE_FROM_ALL)
if (NOT TARGET ts_all_cleaned)
add_custom_target(ts_all_cleaned
COMMENT "Generate .ts files, remove obsolete and vanished translations, and do not add files and line numbers")
add_custom_target(ts_all
COMMENT "Generate .ts files, with obsolete translations and files and line numbers")
add_custom_target(ts_all_no_locations
COMMENT "Generate .ts files, with obsolete translations, without files and line numbers")
endif()
add_dependencies(ts_all_cleaned ${_arg_TS_TARGET_PREFIX}${name}_cleaned)
add_dependencies(ts_all ${_arg_TS_TARGET_PREFIX}${name})
add_dependencies(ts_all_no_locations ${_arg_TS_TARGET_PREFIX}${name}_no_locations)
endif()
endfunction()
function(add_translation_targets file_prefix)
if (NOT TARGET Qt::lrelease OR NOT TARGET Qt::lupdate)
if(NOT TARGET Qt::lrelease OR NOT TARGET Qt::lupdate OR NOT TARGET Qt::lconvert)
# No Qt translation tools were found: Skip this directory
message(WARNING "No Qt translation tools found, skipping translation targets. Add find_package(Qt6 COMPONENTS LinguistTools) to CMake to enable.")
return()
@@ -148,7 +161,7 @@ function(add_translation_targets file_prefix)
cmake_parse_arguments(_arg ""
"OUTPUT_DIRECTORY;INSTALL_DESTINATION;TS_TARGET_PREFIX;QM_TARGET_PREFIX;ALL_QM_TARGET"
"LANGUAGES;TARGETS;SOURCES;INCLUDES" ${ARGN})
"TS_LANGUAGES;QM_LANGUAGES;TARGETS;SOURCES;INCLUDES" ${ARGN})
if (_arg_UNPARSED_ARGUMENTS)
message(FATAL_ERROR "Invalid parameters to add_translation_targets: ${_arg_UNPARSED_ARGUMENTS}.")
endif()
@@ -175,10 +188,29 @@ function(add_translation_targets file_prefix)
_extract_ts_data_from_targets(_to_process "${_arg_TARGETS}")
_create_ts_custom_target(untranslated
FILE_PREFIX "${file_prefix}" TS_TARGET_PREFIX "${_arg_TS_TARGET_PREFIX}"
SOURCES ${_to_process_sources} ${_arg_SOURCES} INCLUDES ${_to_process_includes} ${_arg_INCLUDES}
EXCLUDE_FROM_ALL)
set(lupdate_response_file "${CMAKE_CURRENT_BINARY_DIR}/lupdate-args.lst")
_create_lupdate_response_file(${lupdate_response_file}
SOURCES ${_to_process_sources} ${_arg_SOURCES}
INCLUDES ${_to_process_includes} ${_arg_INCLUDES}
)
set(ts_languages untranslated ${_arg_TS_LANGUAGES})
foreach(language IN LISTS ts_languages)
_create_ts_custom_target(${language}
FILE_PREFIX "${file_prefix}" TS_TARGET_PREFIX "${_arg_TS_TARGET_PREFIX}"
LUPDATE_RESPONSE_FILE "${lupdate_response_file}"
DEPENDS ${_arg_SOURCES}
)
endforeach()
# Create ts_all* targets.
_create_ts_custom_target(all
LANGUAGES ${ts_languages}
FILE_PREFIX "${file_prefix}"
TS_TARGET_PREFIX "${_arg_TS_TARGET_PREFIX}"
LUPDATE_RESPONSE_FILE "${lupdate_response_file}"
DEPENDS ${_arg_SOURCES}
)
if (NOT TARGET "${_arg_ALL_QM_TARGET}")
add_custom_target("${_arg_ALL_QM_TARGET}" ALL COMMENT "Generate .qm-files")
@@ -186,13 +218,10 @@ function(add_translation_targets file_prefix)
file(MAKE_DIRECTORY ${_arg_OUTPUT_DIRECTORY})
foreach(l IN ITEMS ${_arg_LANGUAGES})
foreach(l IN LISTS _arg_QM_LANGUAGES)
set(_ts_file "${CMAKE_CURRENT_SOURCE_DIR}/${file_prefix}_${l}.ts")
set(_qm_file "${_arg_OUTPUT_DIRECTORY}/${file_prefix}_${l}.qm")
_create_ts_custom_target("${l}" FILE_PREFIX "${file_prefix}" TS_TARGET_PREFIX "${_arg_TS_TARGET_PREFIX}"
SOURCES ${_to_process_sources} ${_arg_SOURCES} INCLUDES ${_to_process_includes} ${_arg_INCLUDES})
add_custom_command(OUTPUT "${_qm_file}"
COMMAND Qt::lrelease "${_ts_file}" -qm "${_qm_file}"
MAIN_DEPENDENCY "${_ts_file}"

View File

@@ -7,7 +7,7 @@ instructions:
instructions:
- type: EnvironmentVariable
variableName: QTC_QT_BASE_URL
variableValue: "https://ci-files02-hki.ci.qt.io/packages/jenkins/qt/6.8.2/release_content/"
variableValue: "https://ci-files02-hki.ci.qt.io/packages/jenkins/qt/6.8.3/release_content/"
- type: EnvironmentVariable
variableName: MACOSX_DEPLOYMENT_TARGET
variableValue: 12.0

119
dist/changelog/changes-16.0.1.md vendored Normal file
View File

@@ -0,0 +1,119 @@
Qt Creator 16.0.1
=================
Qt Creator version 16.0.1 contains bug fixes.
It is a free upgrade for commercial license holders.
The most important changes are listed in this document. For a complete list of
changes, see the Git log for the Qt Creator sources that you can check out from
the public Git repository or view online at
<https://code.qt.io/cgit/qt-creator/qt-creator.git/log/?id=v16.0.0..v16.0.1>
Editing
-------
* Fixed that formatting code with the Beautifier plugin broke the text encoding
([QTCREATORBUG-32668](https://bugreports.qt.io/browse/QTCREATORBUG-32668))
* Fixed that jumping to a column that doesn't exist jumped to a different line
([QTCREATORBUG-32592](https://bugreports.qt.io/browse/QTCREATORBUG-32592))
### C++
* Fixed that autodetection of tab settings was turned on for the built-in
code styles
([QTCREATORBUG-32664](https://bugreports.qt.io/browse/QTCREATORBUG-32664))
### QML
* Fixed that `Follow Symbol Under Cursor` could open a copy in the build folder
([QTCREATORBUG-32652](https://bugreports.qt.io/browse/QTCREATORBUG-32652))
### Language Server Protocol
* Fixed the sorting in `Type Hierarchy`
Projects
--------
* Fixed a possible crash when renaming files
* Fixed a crash when canceling the download of SDKs
([QTCREATORBUG-32746](https://bugreports.qt.io/browse/QTCREATORBUG-32746))
### CMake
* Improved the detection of Ninja on macOS
([QTCREATORBUG-32331](https://bugreports.qt.io/browse/QTCREATORBUG-32331))
* Fixed a crash when adding files
([QTCREATORBUG-32745](https://bugreports.qt.io/browse/QTCREATORBUG-32745))
* Fixed `Package manager auto setup` for CMake older than 3.19
([QTCREATORBUG-32636](https://bugreports.qt.io/browse/QTCREATORBUG-32636))
Debugging
---------
* Fixed `Open Memory Editor Showing Stack Layout`
([QTCREATORBUG-32542](https://bugreports.qt.io/browse/QTCREATORBUG-32542))
### QML
Fixed that variable values in `Locals` view were not marked as changed
([QTCREATORBUG-29344](https://bugreports.qt.io/browse/QTCREATORBUG-29344))
* Fixed the re-enabling of breakpoints
([QTCREATORBUG-17294](https://bugreports.qt.io/browse/QTCREATORBUG-17294))
Analyzer
--------
### QML Profiler
* Fixed attaching to a running external application
([QTCREATORBUG-32617](https://bugreports.qt.io/browse/QTCREATORBUG-32617))
### Perf
* Fixed stopping profiling with the tool button
Terminal
--------
* Fixed issues with the `PATH` environment variable
([QTCREATORBUG-32647](https://bugreports.qt.io/browse/QTCREATORBUG-32647))
* Fixed `Enable mouse tracking`
Version Control Systems
-----------------------
### Git
* Guarded against crashes in `Branches` view
([QTCREATORBUG-32186](https://bugreports.qt.io/browse/QTCREATORBUG-32186))
Platforms
---------
### iOS
* Fixed running on iOS 17+ devices with Xcode 15.4
([QTCREATORBUG-32637](https://bugreports.qt.io/browse/QTCREATORBUG-32637))
Credits for these changes go to:
--------------------------------
Alessandro Portale
Andre Hartmann
Aurélien Brooke
Christian Kandeler
Christian Stenger
Cristian Adam
David Schulz
Eike Ziller
Jaroslaw Kobus
Jörg Bornemann
Krzysztof Chrusciel
Leena Miettinen
Lukasz Papierkowski
Marcus Tillmanns
Orgad Shaneh
Robert Löhning
Sami Shalayel
Thiago Macieira

View File

@@ -95,6 +95,8 @@ Analyzer
### Valgrind
### Perf
### Cppcheck
Terminal

Binary file not shown.

Before

Width:  |  Height:  |  Size: 45 KiB

View File

@@ -78,6 +78,8 @@
\li \c codellama:7b-code
\li \c deepseek-coder-v2:lite
\li \c starcoder2:7b
\li \c theqtcompany/codellama-7b-qml
\li \c theqtcompany/codellama-13b-qml
\endlist
\section2 Custom models
@@ -86,6 +88,7 @@
You can use the following custom models:
\list
\li \l {https://huggingface.co/QtGroup/CodeLlama-7B-QML}{codellama:7b-code-qml}
\li \l {https://huggingface.co/QtGroup/CodeLlama-13B-QML}{codellama:13b-code-qml}
\endlist
@@ -98,13 +101,17 @@
of your choice)
\li Meta Code Llama 13B (for Qt 5, running in a cloud deployment of your
choice)
\li Meta Code Llama 13 QML through Ollama (running locally on your
computer)
\li Meta Llama 3.3 70B QML (running in a cloud deployment of your choice)
\li Anthropic Claude 3.5 Sonnet (provided as subscription-based service
by Anthropic)
\li OpenAI GPT-4o (provided as subscription-based service by OpenAI)
\li Anthropic Claude 3.5 Sonnet (provided by Anthropic, remember that you
need to have a token-based billing payment method configured for your
Anthropic account: \l {https://console.anthropic.com/}{console.anthropic.com})
\li OpenAI GPT-4o (provided by OpenAI, remember that you need to have a
token-based billing payment method configured for your OpenAI account:
\l {https://platform.openai.com/}{platform.openai.com})
\li Meta Code Llama 13B QML through Ollama (running locally on your computer)
\li Meta Code Llama 7B QML through Ollama (running locally on your computer)
\li Meta Code Llama 7B through Ollama (running locally on your computer)
\li DeepSeek Coder V2 Lite through Ollama (running locally on your computer)
\li BigCode StarCoder2 through Ollama (running locally on your computer)
\endlist

View File

@@ -1,39 +0,0 @@
// Copyright (C) 2024 The Qt Company Ltd.
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GFDL-1.3-no-invariants-only
/*!
\page qt-design-viewer.html
\previouspage creator-how-tos.html
\ingroup creator-how-to-design
\title Preview UI prototypes in browsers
\image qt-design-viewer.png
Run Qt Quick UI Prototype projects in web browsers, such as Apple Safari,
Google Chrome, Microsoft Edge, and Mozilla Firefox, with \QDV.
The startup and compilation time depend on your browser and configuration.
Once started, the application performs the same as when running on the
desktop.
The .qmlproject configuration file defines the main QML file and the import
paths. Compress the project folder into a ZIP file that you upload to \QDV.
The loaded applications remain locally in your browser. No data is uploaded
into the cloud.
To preview an application in a web browser:
\list 1
\li In the browser, open \l{ https://designviewer.qt.io/}{\QDV}.
\li Drag your application package to \QDV, or select the load
icon to browse for your file.
\endlist
Your application is compiled and run on \QDV.
\sa {Create Qt Quick UI Prototypes}, {Design UIs}{How To: Design UIs},
{UI Design}
*/

View File

@@ -4,10 +4,10 @@ import qbs.FileInfo
import qbs.Utilities
Module {
property string qtcreator_display_version: '16.0.1'
property string qtcreator_display_version: '16.0.2'
property string ide_version_major: '16'
property string ide_version_minor: '0'
property string ide_version_release: '1'
property string ide_version_release: '2'
property string qtcreator_version: ide_version_major + '.' + ide_version_minor + '.'
+ ide_version_release

View File

@@ -1,4 +1,4 @@
set(languages cs da de en fr hr ja pl ru sl uk zh_CN zh_TW)
set(languages cs da de fr hr ja pl ru sl uk zh_CN zh_TW)
set(bad_languages hu) # Fix these before including them in languages!
find_package(Python3 COMPONENTS Interpreter)
@@ -45,7 +45,8 @@ else()
endif()
add_translation_targets(qtcreator
LANGUAGES ${languages}
TS_LANGUAGES ${languages}
QM_LANGUAGES ${languages} en
OUTPUT_DIRECTORY "${PROJECT_BINARY_DIR}/${IDE_DATA_PATH}/translations"
INSTALL_DESTINATION "${IDE_DATA_PATH}/translations"
TARGETS "${__QTC_LIBRARIES}" "${__QTC_PLUGINS}"

View File

@@ -59705,7 +59705,7 @@ Influence lindentation des lignes de continuation.
</message>
<message>
<source>Swap Views</source>
<translation>Afficher les vues</translation>
<translation>Intervertir les vues</translation>
</message>
<message>
<source>JSON Editor</source>
@@ -60490,7 +60490,7 @@ Les données de la trace sont perdues.</translation>
</message>
<message>
<source>The command &quot;%1&quot; terminated with exit code %2.</source>
<translation>La commande «&#xa0;%1&#xa0;» sest terminée avec le code de sortie %1.</translation>
<translation>La commande «&#xa0;%1&#xa0;» sest terminée avec le code de sortie %2.</translation>
</message>
<message>
<source>The command &quot;%1&quot; terminated abnormally.</source>

File diff suppressed because it is too large Load Diff

View File

@@ -157,6 +157,20 @@ if(BUILD_WITH_CRASHPAD)
)
endif()
extend_qtc_executable(qtcreator
CONDITION BUILD_WITH_SENTRY
DEFINES
SENTRY_DSN="${SENTRY_DSN}"
SENTRY_PROJECT="${SENTRY_PROJECT}"
ENABLE_SENTRY
DEPENDS sentry::sentry
)
extend_qtc_executable(qtcreator
CONDITION DEFINED SENTRY_CRASHPAD_PATH
DEFINES
SENTRY_CRASHPAD_PATH="${SENTRY_CRASHPAD_PATH}"
)
if ((NOT WIN32) AND (NOT APPLE))
# install logo
foreach(size 16 24 32 48 64 128 256 512)

View File

@@ -54,6 +54,12 @@
#include "client/settings.h"
#endif
#ifdef ENABLE_SENTRY
#include <sentry.h>
Q_LOGGING_CATEGORY(sentryLog, "qtc.sentry", QtWarningMsg)
#endif
using namespace ExtensionSystem;
using namespace Utils;
@@ -496,6 +502,35 @@ void startCrashpad(const AppInfo &appInfo, bool crashReportingEnabled)
}
#endif
#ifdef ENABLE_SENTRY
void configureSentry(const AppInfo &appInfo, bool crashReportingEnabled)
{
if (!crashReportingEnabled)
return;
sentry_options_t *options = sentry_options_new();
sentry_options_set_dsn(options, SENTRY_DSN);
#ifdef Q_OS_WIN
sentry_options_set_database_pathw(options, appInfo.crashReports.nativePath().toStdWString().c_str());
#else
sentry_options_set_database_path(options, appInfo.crashReports.nativePath().toUtf8().constData());
#endif
#ifdef SENTRY_CRASHPAD_PATH
if (const FilePath handlerpath = appInfo.libexec / "crashpad_handler"; handlerpath.exists()) {
sentry_options_set_handler_path(options, handlerpath.nativePath().toUtf8().constData());
} else if (const auto fallback = FilePath::fromString(SENTRY_CRASHPAD_PATH); fallback.exists()) {
sentry_options_set_handler_path(options, fallback.nativePath().toUtf8().constData());
} else {
qCWarning(sentryLog) << "Failed to find crashpad_handler for Sentry crash reports.";
}
#endif
const QString release = QString(SENTRY_PROJECT) + "@" + QCoreApplication::applicationVersion();
sentry_options_set_release(options, release.toUtf8().constData());
sentry_options_set_debug(options, sentryLog().isDebugEnabled() ? 1 : 0);
sentry_init(options);
}
#endif
class ShowInGuiHandler
{
public:
@@ -792,10 +827,15 @@ int main(int argc, char **argv)
CrashHandlerSetup setupCrashHandler(
Core::Constants::IDE_DISPLAY_NAME, CrashHandlerSetup::EnableRestart, info.libexec.path());
#ifdef ENABLE_CRASHPAD
// depends on AppInfo and QApplication being created
bool crashReportingEnabled = settings->value("CrashReportingEnabled", false).toBool();
const bool crashReportingEnabled = settings->value("CrashReportingEnabled", false).toBool();
#if defined(ENABLE_CRASHPAD)
startCrashpad(info, crashReportingEnabled);
#elif defined(ENABLE_SENTRY)
configureSentry(info, crashReportingEnabled);
#else
Q_UNUSED(crashReportingEnabled)
#endif
PluginManager pluginManager;
@@ -983,5 +1023,9 @@ int main(int argc, char **argv)
QApplication::setEffectEnabled(Qt::UI_AnimateMenu, false);
}
return restarter.restartOrExit(app.exec());
const int exitCode = restarter.restartOrExit(app.exec());
#ifdef ENABLE_SENTRY
sentry_close();
#endif
return exitCode;
}

View File

@@ -51,7 +51,7 @@ void NetworkQuery::start()
NetworkQuery::~NetworkQuery()
{
if (m_reply) {
disconnect(m_reply.get(), &QNetworkReply::finished, this, nullptr);
disconnect(m_reply.get(), nullptr, this, nullptr);
m_reply->abort();
}
}

View File

@@ -192,7 +192,6 @@ struct TerminalSurfacePrivate
vterm_state_set_palette_color(vts, i, &col);
}
vterm_screen_enable_reflow(m_vtermScreen, true);
vterm_screen_reset(m_vtermScreen, 1);
}

View File

@@ -278,6 +278,11 @@ void TerminalView::setPasswordMode(bool passwordMode)
}
}
void TerminalView::enableMouseTracking(bool enable)
{
d->m_allowMouseTracking = enable;
}
void TerminalView::setFont(const QFont &font)
{
QAbstractScrollArea::setFont(font);

View File

@@ -55,6 +55,8 @@ public:
void setFont(const QFont &font);
void enableMouseTracking(bool enable);
void copyToClipboard();
void pasteFromClipboard();
void copyLinkToClipboard();

View File

@@ -29,6 +29,8 @@
#include <QTextBlock>
#include <QTextBrowser>
#include <QTextDocument>
#include <QTextDocumentFragment>
#include <QTextDocumentWriter>
#include <QTextObjectInterface>
namespace Utils {
@@ -862,6 +864,31 @@ void MarkdownBrowser::mousePressEvent(QMouseEvent *event)
QTextBrowser::mousePressEvent(event);
}
QMimeData *MarkdownBrowser::createMimeDataFromSelection() const
{
// Basically a copy of QTextEditMimeData::setup, just replacing the object markers.
QMimeData *mimeData = new QMimeData;
QTextDocumentFragment fragment(textCursor());
static const auto removeObjectChar = [](QString &&text) {
return text.replace(QChar::ObjectReplacementCharacter, "");
};
mimeData->setData("text/html", removeObjectChar(fragment.toHtml()).toUtf8());
mimeData->setData("text/markdown", removeObjectChar(fragment.toMarkdown()).toUtf8());
{
QBuffer buffer;
QTextDocumentWriter writer(&buffer, "ODF");
if (writer.write(fragment)) {
buffer.close();
mimeData->setData("application/vnd.oasis.opendocument.text", buffer.data());
}
}
mimeData->setText(removeObjectChar(fragment.toPlainText()));
return mimeData;
}
} // namespace Utils
#include "markdownbrowser.moc"

View File

@@ -42,6 +42,8 @@ protected:
void changeEvent(QEvent *event) override;
void mousePressEvent(QMouseEvent *event) override;
QMimeData *createMimeDataFromSelection() const override;
private:
void handleAnchorClicked(const QUrl &link);
void postProcessDocument(bool firstTime);

View File

@@ -95,6 +95,7 @@ GroupItem downloadSdkRecipe()
progressDialog.reset(new QProgressDialog(Tr::tr("Downloading SDK Tools package..."),
Tr::tr("Cancel"), 0, 100, Core::ICore::dialogParent()));
progressDialog->setWindowModality(Qt::ApplicationModal);
progressDialog->setMinimumDuration(INT_MAX); // In order to suppress calls to processEvents() from setValue()
progressDialog->setWindowTitle(dialogTitle());
progressDialog->setFixedSize(progressDialog->sizeHint());
progressDialog->setAutoClose(false);

View File

@@ -504,7 +504,7 @@ static bool sdkManagerCommand(const QStringList &args, QString *output)
proc.setCommand({AndroidConfig::sdkManagerToolPath(), newArgs});
qCDebug(sdkManagerLog).noquote() << "Running SDK Manager command (sync):"
<< proc.commandLine().toUserOutput();
proc.runBlocking(60s, EventLoopMode::On);
proc.runBlocking(60s);
if (output)
*output = proc.allOutput();
return proc.result() == ProcessResult::FinishedWithSuccess;

View File

@@ -317,6 +317,7 @@ void AvdDialog::createAvd()
progressDialog.reset(new QProgressDialog(Core::ICore::dialogParent()));
progressDialog->setRange(0, 0);
progressDialog->setWindowModality(Qt::ApplicationModal);
progressDialog->setMinimumDuration(INT_MAX); // In order to suppress calls to processEvents() from setValue()
progressDialog->setWindowTitle("Create new AVD");
progressDialog->setLabelText(Tr::tr("Creating new AVD device..."));
progressDialog->setFixedSize(progressDialog->sizeHint());

View File

@@ -174,7 +174,7 @@ public:
m_error->setVisible(!text.isEmpty());
m_error->setText(text);
m_error->setType(type == Warning ? InfoLabel::Warning : InfoLabel::Error);
m_error->disconnect();
disconnect(m_error, &QLabel::linkActivated, this, nullptr);
if (linkAction)
connect(m_error, &QLabel::linkActivated, this, linkAction);
evaluateVisibility();

View File

@@ -697,6 +697,11 @@ bool CMakeBuildSystem::addSrcFiles(Node *context, const FilePaths &filePaths, Fi
<< "could not be found at" << targetDefinitionLine;
return false;
}
if (function->Arguments().size() == 0) {
qCCritical(cmakeBuildSystemLog) << "Function that defined the target" << targetName
<< "has zero arguments.";
return false;
}
const bool haveGlobbing = isGlobbingFunction(*cmakeListFile, *function);
n->setVisibleAfterAddFileAction(!haveGlobbing);

View File

@@ -708,8 +708,12 @@ bool CMakeGeneratorKitAspectFactory::isNinjaPresent(const Kit *k, const CMakeToo
return true;
if (Internal::settings(nullptr).ninjaPath().isEmpty()) {
auto findNinja = [](const Environment &env) -> bool {
return !env.searchInPath("ninja").isEmpty();
FilePaths extraDirs;
if (tool->filePath().osType() == OsTypeMac)
extraDirs << tool->filePath().parentDir();
auto findNinja = [extraDirs](const Environment &env) -> bool {
return !env.searchInPath("ninja", extraDirs).isEmpty();
};
if (!findNinja(tool->filePath().deviceEnvironment()))
return findNinja(k->buildEnvironment());

View File

@@ -322,8 +322,13 @@ extend_qtc_plugin(Core
)
extend_qtc_plugin(Core
CONDITION BUILD_WITH_CRASHPAD
DEFINES ENABLE_CRASHPAD
CONDITION BUILD_WITH_CRASHPAD OR BUILD_WITH_SENTRY
DEFINES ENABLE_CRASHREPORTING
)
extend_qtc_plugin(Core
CONDITION BUILD_WITH_CRASHPAD OR (BUILD_WITH_SENTRY AND SENTRY_CRASHPAD_PATH)
DEFINES CRASHREPORTING_USES_CRASHPAD
)
set(FONTS_BASE "${QtCreator_SOURCE_DIR}/src/share/3rdparty/studiofonts/")

View File

@@ -551,6 +551,7 @@ ActionManager::ActionManager(QObject *parent)
ActionManager::~ActionManager()
{
delete d;
d = nullptr;
}
/*!
@@ -734,6 +735,8 @@ QList<Command *> ActionManager::commands()
*/
void ActionManager::unregisterAction(QAction *action, Id id)
{
if (!d) // stray call during shutdown
return;
Command *cmd = d->m_idCmdMap.value(id, nullptr);
if (!cmd) {
qWarning() << "unregisterAction: id" << id.name()

View File

@@ -359,9 +359,13 @@ bool CorePlugin::initialize(const QStringList &arguments, QString *errorMessage)
Utils::PathChooser::setAboutToShowContextMenuHandler(&addToPathChooserContextMenu);
#ifdef ENABLE_CRASHPAD
connect(ICore::instance(), &ICore::coreOpened, this, &CorePlugin::warnAboutCrashReporing,
Qt::QueuedConnection);
#ifdef ENABLE_CRASHREPORTING
connect(
ICore::instance(),
&ICore::coreOpened,
this,
&CorePlugin::warnAboutCrashReporing,
Qt::QueuedConnection);
#endif
#ifdef WITH_TESTS
@@ -542,19 +546,33 @@ void CorePlugin::warnAboutCrashReporing()
// static
QString CorePlugin::msgCrashpadInformation()
{
return Tr::tr("%1 uses Google Crashpad for collecting crashes and sending them to Sentry "
"for processing. Crashpad may capture arbitrary contents from crashed process "
#if ENABLE_CRASHREPORTING
#if CRASHREPORTING_USES_CRASHPAD
const QString backend = "Google Crashpad";
const QString url
= "https://chromium.googlesource.com/crashpad/crashpad/+/master/doc/overview_design.md";
#else
const QString backend = "Google Breakpad";
const QString url
= "https://chromium.googlesource.com/breakpad/breakpad/+/HEAD/docs/client_design.md";
#endif
//: %1 = application name, %2 crash backend name (Google Crashpad or Google Breakpad)
return Tr::tr("%1 uses %2 for collecting crashes and sending them to Sentry "
"for processing. %2 may capture arbitrary contents from crashed process "
"memory, including user sensitive information, URLs, and whatever other content "
"users have trusted %1 with. The collected crash reports are however only used "
"for the sole purpose of fixing bugs.")
.arg(QGuiApplication::applicationDisplayName())
+ "<br><br>" + Tr::tr("More information:")
+ "<br><a href='https://chromium.googlesource.com/crashpad/crashpad/+/master/doc/"
"overview_design.md'>"
+ Tr::tr("Crashpad Overview")
.arg(QGuiApplication::applicationDisplayName(), backend)
+ "<br><br>" + Tr::tr("More information:") + "<br><a href='" + url
+ "'>"
//: %1 = crash backend name (Google Crashpad or Google Breakpad)
+ Tr::tr("%1 Overview").arg(backend)
+ "</a>"
"<br><a href='https://sentry.io/security/'>"
+ Tr::tr("%1 security policy").arg("Sentry.io") + "</a>";
#else
return {};
#endif
}
ExtensionSystem::IPlugin::ShutdownFlag CorePlugin::aboutToShutdown()

View File

@@ -12,7 +12,7 @@
#include "iversioncontrol.h" // sic!
#include "vcsmanager.h"
#ifdef ENABLE_CRASHPAD
#ifdef ENABLE_CRASHREPORTING
#include "coreplugin.h"
#endif
@@ -42,7 +42,7 @@ using namespace Layouting;
namespace Core::Internal {
#ifdef ENABLE_CRASHPAD
#ifdef CRASHREPORTING_USES_CRASHPAD
// TODO: move to somewhere in Utils
static QString formatSize(qint64 size)
{
@@ -57,7 +57,7 @@ static QString formatSize(qint64 size)
return i == 0 ? QString("%0 %1").arg(outputSize).arg(units[i]) // Bytes
: QString("%0 %1").arg(outputSize, 0, 'f', 2).arg(units[i]); // KB, MB, GB, TB
}
#endif // ENABLE_CRASHPAD
#endif // CRASHREPORTING_USES_CRASHPAD
SystemSettings &systemSettings()
{
@@ -147,15 +147,17 @@ SystemSettings::SystemSettings()
askBeforeExit.setLabelText(Tr::tr("Ask for confirmation before exiting"));
askBeforeExit.setLabelPlacement(BoolAspect::LabelPlacement::Compact);
#ifdef ENABLE_CRASHPAD
#ifdef ENABLE_CRASHREPORTING
enableCrashReporting.setSettingsKey("CrashReportingEnabled");
enableCrashReporting.setLabelPlacement(BoolAspect::LabelPlacement::Compact);
enableCrashReporting.setLabelText(Tr::tr("Enable crash reporting"));
enableCrashReporting.setToolTip(
Tr::tr("Allow crashes to be automatically reported. Collected reports are "
"used for the sole purpose of fixing bugs."));
#endif
"<p>"
+ Tr::tr("Allow crashes to be automatically reported. Collected reports are "
"used for the sole purpose of fixing bugs.")
+ "</p><p>"
+ Tr::tr("Crash reports are saved in \"%1\".").arg(appInfo().crashReports.toUserOutput()));
#endif // ENABLE_CRASHREPORTING
readSettings();
autoSaveInterval.setEnabler(&autoSaveModifiedFiles);
@@ -176,7 +178,7 @@ public:
, m_terminalOpenArgs(new QLineEdit)
, m_terminalExecuteArgs(new QLineEdit)
, m_environmentChangesLabel(new Utils::ElidingLabel)
#ifdef ENABLE_CRASHPAD
#ifdef CRASHREPORTING_USES_CRASHPAD
, m_crashReportsMenuButton(new QPushButton(Tr::tr("Manage"), this))
, m_crashReportsSizeText(new QLabel(this))
#endif
@@ -201,9 +203,12 @@ public:
resetFileBrowserButton->setToolTip(Tr::tr("Reset to default."));
auto helpExternalFileBrowserButton = new QToolButton;
helpExternalFileBrowserButton->setText(Tr::tr("?"));
#ifdef ENABLE_CRASHPAD
#ifdef ENABLE_CRASHREPORTING
auto helpCrashReportingButton = new QToolButton(this);
helpCrashReportingButton->setText(Tr::tr("?"));
connect(helpCrashReportingButton, &QAbstractButton::clicked, this, [this] {
showHelpDialog(Tr::tr("Crash Reporting"), CorePlugin::msgCrashpadInformation());
});
#endif
auto resetTerminalButton = new QPushButton(Tr::tr("Reset"));
resetTerminalButton->setToolTip(Tr::tr("Reset to default.", "Terminal"));
@@ -243,15 +248,16 @@ public:
grid.addRow({Tr::tr("Maximum number of entries in \"Recent Files\":"),
Row{s.maxRecentFiles, st}});
grid.addRow({s.askBeforeExit});
#ifdef ENABLE_CRASHPAD
const QString toolTip = Tr::tr("Crash reports are saved in \"%1\".")
.arg(appInfo().crashReports.toUserOutput());
m_crashReportsMenuButton->setToolTip(toolTip);
m_crashReportsSizeText->setToolTip(toolTip);
#ifdef ENABLE_CRASHREPORTING
Row crashDetails;
#ifdef CRASHREPORTING_USES_CRASHPAD
m_crashReportsMenuButton->setToolTip(s.enableCrashReporting.toolTip());
m_crashReportsSizeText->setToolTip(s.enableCrashReporting.toolTip());
auto crashReportsMenu = new QMenu(m_crashReportsMenuButton);
m_crashReportsMenuButton->setMenu(crashReportsMenu);
Row crashDetails
= Row{m_crashReportsMenuButton, m_crashReportsSizeText, helpCrashReportingButton, st};
crashDetails.addItems({m_crashReportsMenuButton, m_crashReportsSizeText});
#endif // CRASHREPORTING_USES_CRASHPAD
crashDetails.addItem(helpCrashReportingButton);
if (qtcEnvironmentVariableIsSet("QTC_SHOW_CRASHBUTTON")) {
auto crashButton = new QPushButton("CRASH!!!");
connect(crashButton, &QPushButton::clicked, [] {
@@ -261,6 +267,7 @@ public:
});
crashDetails.addItem(crashButton);
}
crashDetails.addItem(st);
grid.addRow({s.enableCrashReporting, crashDetails});
#endif
@@ -287,19 +294,19 @@ public:
m_externalFileBrowserEdit->setText(UnixUtils::fileBrowser(ICore::settings()));
}
#ifdef ENABLE_CRASHPAD
connect(helpCrashReportingButton, &QAbstractButton::clicked, this, [this] {
showHelpDialog(Tr::tr("Crash Reporting"), CorePlugin::msgCrashpadInformation());
});
const FilePath reportsPath = ICore::crashReportsPath()
/ QLatin1String(
HostOsInfo::isMacHost() ? "completed" : "reports");
#if defined(ENABLE_CRASHREPORTING) && defined(CRASHREPORTING_USES_CRASHPAD)
const FilePaths reportsPaths
= {ICore::crashReportsPath() / "completed",
ICore::crashReportsPath() / "reports",
ICore::crashReportsPath() / "attachments",
ICore::crashReportsPath() / "pending",
ICore::crashReportsPath() / "new"};
auto openLocationAction = new QAction(Tr::tr("Go to crash reports"));
connect(openLocationAction, &QAction::triggered, this, [this, reportsPath] {
if (!QDesktopServices::openUrl(reportsPath.toUrl())) {
qWarning() << "Failed to open path:" << reportsPath;
connect(openLocationAction, &QAction::triggered, this, [reportsPaths] {
const FilePath path = reportsPaths.first().parentDir();
if (!QDesktopServices::openUrl(path.toUrl())) {
qWarning() << "Failed to open path:" << path;
}
});
crashReportsMenu->addAction(openLocationAction);
@@ -307,12 +314,16 @@ public:
auto clearAction = new QAction(Tr::tr("Clear crash reports"));
crashReportsMenu->addAction(clearAction);
const auto updateClearCrashWidgets = [this, reportsPath] {
const auto updateClearCrashWidgets = [this, reportsPaths] {
qint64 size = 0;
const FilePaths crashFiles = reportsPath.dirEntries(QDir::Files);
for (const FilePath &file : crashFiles)
size += file.fileSize();
m_crashReportsMenuButton->setEnabled(!crashFiles.isEmpty());
FilePath::iterateDirectories(
reportsPaths,
[&size](const FilePath &item) {
size += item.fileSize();
return IterationPolicy::Continue;
},
FileFilter({}, QDir::Files, QDirIterator::Subdirectories));
m_crashReportsMenuButton->setEnabled(size > 0);
m_crashReportsSizeText->setText(formatSize(size));
};
updateClearCrashWidgets();
@@ -320,13 +331,17 @@ public:
clearAction,
&QAction::triggered,
this,
[updateClearCrashWidgets, reportsPath] {
const FilePaths &crashFiles = reportsPath.dirEntries(QDir::Files);
for (const FilePath &file : crashFiles)
file.removeFile();
[updateClearCrashWidgets, reportsPaths] {
FilePath::iterateDirectories(
reportsPaths,
[](const FilePath &item) {
item.removeRecursively();
return IterationPolicy::Continue;
},
FileFilter({}, QDir::Files | QDir::Dirs | QDir::NoDotAndDotDot));
updateClearCrashWidgets();
});
#endif
#endif // ENABLE_CRASHREPORTING && CRASHREPORTING_USES_CRASHPAD
if (HostOsInfo::isAnyUnixHost()) {
connect(resetTerminalButton,
@@ -405,7 +420,7 @@ private:
QLineEdit *m_terminalOpenArgs;
QLineEdit *m_terminalExecuteArgs;
Utils::ElidingLabel *m_environmentChangesLabel;
#ifdef ENABLE_CRASHPAD
#ifdef CRASHREPORTING_USES_CRASHPAD
QPushButton *m_crashReportsMenuButton;
QLabel *m_crashReportsSizeText;
#endif

View File

@@ -34,7 +34,7 @@ public:
Utils::SelectionAspect reloadSetting{this};
#ifdef ENABLE_CRASHPAD
#ifdef ENABLE_CRASHREPORTING
Utils::BoolAspect enableCrashReporting{this};
#endif

View File

@@ -22,6 +22,7 @@
#include <coreplugin/messagemanager.h>
#include <extensionsystem/iplugin.h>
#include <extensionsystem/pluginmanager.h>
#include <utils/algorithm.h>
#include <utils/fileutils.h>
@@ -74,6 +75,7 @@ class CodePasterPluginPrivate : public QObject
{
public:
CodePasterPluginPrivate();
~CodePasterPluginPrivate();
void post(PasteSource pasteSources);
void post(QString data, const QString &mimeType);
@@ -173,6 +175,13 @@ CodePasterPluginPrivate::CodePasterPluginPrivate()
.setText(Tr::tr("Fetch from URL..."))
.addToContainer(menu)
.addOnTriggered(this, &CodePasterPluginPrivate::fetchUrl);
ExtensionSystem::PluginManager::addObject(&m_service);
}
CodePasterPluginPrivate::~CodePasterPluginPrivate()
{
ExtensionSystem::PluginManager::removeObject(&m_service);
}
static inline void textFromCurrentEditor(QString *text, QString *mimeType)

View File

@@ -355,6 +355,7 @@ void KitDetectorPrivate::autoDetect()
RunDeviceTypeKitAspect::setDeviceTypeId(k, m_device->type());
RunDeviceKitAspect::setDevice(k, m_device);
BuildDeviceTypeKitAspect::setDeviceTypeId(k, m_device->type());
BuildDeviceKitAspect::setDevice(k, m_device);
const Toolchains toolchainCandidates = ToolchainManager::toolchains(

View File

@@ -697,6 +697,7 @@ void ExtensionManagerWidget::fetchAndInstallPlugin(const QUrl &url, const QStrin
Tr::tr("Downloading..."), Tr::tr("Cancel"), 0, 0, ICore::dialogParent()));
progressDialog->setWindowTitle(Tr::tr("Download Extension"));
progressDialog->setWindowModality(Qt::ApplicationModal);
progressDialog->setMinimumDuration(INT_MAX); // In order to suppress calls to processEvents() from setValue()
progressDialog->setFixedSize(progressDialog->sizeHint());
progressDialog->setAutoClose(false);
progressDialog->show(); // TODO: Should not be needed. Investigate possible QT_BUG

View File

@@ -69,42 +69,45 @@ bool BlameMark::addToolTipContent(QLayout *target) const
auto textLabel = new QLabel;
textLabel->setText(toolTip());
target->addWidget(textLabel);
QObject::connect(textLabel, &QLabel::linkActivated, textLabel, [this](const QString &link) {
qCInfo(log) << "Link activated with target:" << link;
const QString hash = (link == "blameParent") ? m_info.hash + "^" : m_info.hash;
QObject::connect(
textLabel, &QLabel::linkActivated, textLabel, [info = m_info](const QString &link) {
qCInfo(log) << "Link activated with target:" << link;
const QString hash = (link == "blameParent") ? info.hash + "^" : info.hash;
if (link.startsWith("blame") || link == "showFile") {
const VcsBasePluginState state = currentState();
QTC_ASSERT(state.hasTopLevel(), return);
const Utils::FilePath path = state.topLevel();
if (link.startsWith("blame") || link == "showFile") {
const VcsBasePluginState state = currentState();
QTC_ASSERT(state.hasTopLevel(), return);
const Utils::FilePath path = state.topLevel();
const QString originalFileName = m_info.originalFileName;
if (link.startsWith("blame")) {
qCInfo(log).nospace().noquote() << "Blaming: \"" << path << "/" << originalFileName
<< "\":" << m_info.originalLine << " @ " << hash;
gitClient().annotate(path, originalFileName, m_info.originalLine, hash);
const QString originalFileName = info.originalFileName;
if (link.startsWith("blame")) {
qCInfo(log).nospace().noquote()
<< "Blaming: \"" << path << "/" << originalFileName
<< "\":" << info.originalLine << " @ " << hash;
gitClient().annotate(path, originalFileName, info.originalLine, hash);
} else {
qCInfo(log).nospace().noquote()
<< "Showing file: \"" << path << "/" << originalFileName << "\" @ " << hash;
const auto fileName = Utils::FilePath::fromString(originalFileName);
gitClient().openShowEditor(path, hash, fileName);
}
} else if (link == "logLine") {
const VcsBasePluginState state = currentState();
QTC_ASSERT(state.hasFile(), return);
qCInfo(log).nospace().noquote()
<< "Showing log for: \"" << info.filePath << "\" line:" << info.line;
const QString lineArg
= QString("-L %1,%1:%2").arg(info.line).arg(state.relativeCurrentFile());
gitClient().log(state.currentFileTopLevel(), {}, true, {lineArg, "--no-patch"});
} else {
qCInfo(log).nospace().noquote() << "Showing file: \"" << path << "/"
<< originalFileName << "\" @ " << hash;
const auto fileName = Utils::FilePath::fromString(originalFileName);
gitClient().openShowEditor(path, hash, fileName);
qCInfo(log).nospace().noquote()
<< "Showing commit: " << hash << " for " << info.filePath;
gitClient().show(info.filePath, hash);
}
} else if (link == "logLine") {
const VcsBasePluginState state = currentState();
QTC_ASSERT(state.hasFile(), return);
qCInfo(log).nospace().noquote() << "Showing log for: \"" << m_info.filePath
<< "\" line:" << m_info.line;
const QString lineArg = QString("-L %1,%1:%2")
.arg(m_info.line).arg(state.relativeCurrentFile());
gitClient().log(state.currentFileTopLevel(), {}, true, {lineArg, "--no-patch"});
} else {
qCInfo(log).nospace().noquote() << "Showing commit: " << hash << " for " << m_info.filePath;
gitClient().show(m_info.filePath, hash);
}
});
});
return true;
}

View File

@@ -660,7 +660,8 @@ void LanguageClientManager::documentOpened(Core::IDocument *document)
clients.removeAll(clientForProject);
}
} else if (setting->m_startBehavior == BaseSettings::RequiresFile && clients.isEmpty()) {
clients << startClient(setting);
if (Client *client = startClient(setting); QTC_GUARD(client))
clients << client;
}
allClients << clients;
}

View File

@@ -618,6 +618,7 @@ Client *BaseSettings::createClient(ProjectExplorer::Project *project) const
BaseClientInterface *interface = createInterface(project);
QTC_ASSERT(interface, return nullptr);
auto *client = createClient(interface);
QTC_ASSERT(client, return nullptr);
if (client->name().isEmpty())
client->setName(Utils::globalMacroExpander()->expand(m_name));

View File

@@ -7,10 +7,11 @@
#include <utils/stringutils.h>
#include <QAction>
#include <QApplication>
#include <QClipboard>
#include <QCursor>
#include <QCompleter>
#include <QCursor>
#include <QDir>
#include <QFileDevice>
#include <QFontMetrics>
@@ -26,6 +27,40 @@ void setupQtModule()
sol::table qt(lua, sol::create);
const ScriptPluginSpec *pluginSpec = lua.get<ScriptPluginSpec *>("PluginSpec"sv);
qt.new_usertype<QAction>(
"QAction",
sol::no_constructor,
"checkable",
sol::property(&QAction::isCheckable, &QAction::setCheckable),
"checked",
sol::property(&QAction::isChecked, &QAction::setChecked),
"enabled",
sol::property(&QAction::isEnabled, &QAction::setEnabled),
"icon",
sol::property(
&QAction::icon,
[](QAction *action, IconFilePathOrString icon) {
action->setIcon(toIcon(icon)->icon());
}),
"text",
sol::property(&QAction::text, &QAction::setText),
"iconText",
sol::property(&QAction::iconText, &QAction::setIconText),
"toolTip",
sol::property(&QAction::toolTip, &QAction::setToolTip),
"statusTip",
sol::property(&QAction::statusTip, &QAction::setStatusTip),
"whatsThis",
sol::property(&QAction::whatsThis, &QAction::setWhatsThis),
"visible",
sol::property(&QAction::isVisible, &QAction::setVisible),
"iconVisibleInMenu",
sol::property(&QAction::isIconVisibleInMenu, &QAction::setIconVisibleInMenu),
"shortcutVisibleInContextMenu",
sol::property(
&QAction::isShortcutVisibleInContextMenu,
&QAction::setShortcutVisibleInContextMenu));
qt.new_usertype<QCompleter>(
"QCompleter",
"create",

View File

@@ -224,6 +224,15 @@ void setupTextEditorModule()
return BaseTextEditor::currentTextEditor();
};
result["openedEditors"] = [lua]() mutable -> sol::table {
QList<BaseTextEditor *> editors = BaseTextEditor::openedTextEditors();
sol::table result = lua.create_table();
for (auto& editor : editors) {
result.add(TextEditorPtr(editor));
}
return result;
};
result.new_usertype<MultiTextCursor>(
"MultiTextCursor",
sol::no_constructor,
@@ -238,18 +247,26 @@ void setupTextEditorModule()
"Position",
sol::no_constructor,
"line",
sol::property(&Position::line, &Position::line),
sol::property(
[](const Position &pos) { return pos.line; },
[](Position &pos, int line) { pos.line = line; }),
"column",
sol::property(&Position::column, &Position::column));
sol::property(
[](const Position &pos) { return pos.column; },
[](Position &pos, int column) { pos.column = column; }));
// In range can't use begin/end as "end" is a reserved word for LUA scripts
result.new_usertype<Range>(
"Range",
sol::no_constructor,
"from",
sol::property(&Range::begin, &Range::begin),
sol::property(
[](const Range &range) { return range.begin; },
[](Range &range, const Position &begin) { range.begin = begin; }),
"to",
sol::property(&Range::end, &Range::end));
sol::property(
[](const Range &range) { return range.end; },
[](Range &range, const Position &end) { range.end = end; }));
auto textCursorType = result.new_usertype<QTextCursor>(
"TextCursor",
@@ -419,6 +436,13 @@ void setupTextEditorModule()
QTC_ASSERT(textEditor, throw sol::error("TextEditor is not valid"));
textEditor->editorWidget()->insertExtraToolBarWidget(side, toWidget(widget));
},
"insertExtraToolBarAction",
[](const TextEditorPtr &textEditor,
TextEditorWidget::Side side,
QAction* action) {
QTC_ASSERT(textEditor, throw sol::error("TextEditor is not valid"));
textEditor->editorWidget()->insertExtraToolBarAction(side, action);
},
"setRefactorMarker",
[pluginSpec, activeMarkers](
const TextEditorPtr &textEditor,

View File

@@ -93,6 +93,10 @@ void setupUtilsModule()
utils.set_function("createUuid", []() { return QUuid::createUuid().toString(); });
utils.set_function("getNativeShortcut", [](QString shortcut) {
return QKeySequence::fromString(shortcut).toString(QKeySequence::NativeText);
});
sol::function wrap = async["wrap"].get<sol::function>();
utils["waitms"] = wrap(utils["waitms_cb"]);

View File

@@ -18,6 +18,11 @@ function utils.waitms_cb(ms, callback) end
---@return QString Arbitrary UUID string.
function utils.createUuid() end
---Converts a given shortcut string into its native representation for the current platform.
---@param shortcut string The shortcut string (e.g., "Ctrl+Shift+A").
---@return QString The native representation of the shortcut.
function utils.getNativeShortcut(shortcut) end
---@class Id
utils.Id = {}

View File

@@ -34,6 +34,7 @@ public:
virtual QString label() const = 0;
virtual QString cmakeVariableName() const = 0;
virtual QString environmentVariableName() const = 0;
virtual bool isOptional() const = 0;
virtual bool isAddToSystemPath() const = 0;
virtual QStringList versions() const = 0;

View File

@@ -41,6 +41,7 @@ McuPackage::McuPackage(const SettingsHandler::Ptr &settingsHandler,
const QStringList &versions,
const QString &downloadUrl,
const McuPackageVersionDetector *versionDetector,
const bool optional,
const bool addToSystemPath,
const Utils::PathChooser::Kind &valueType,
const bool allowNewerVersionKey)
@@ -53,6 +54,7 @@ McuPackage::McuPackage(const SettingsHandler::Ptr &settingsHandler,
, m_cmakeVariableName(cmakeVarName)
, m_environmentVariableName(envVarName)
, m_downloadUrl(downloadUrl)
, m_optional(optional)
, m_addToSystemPath(addToSystemPath)
, m_valueType(valueType)
{
@@ -93,6 +95,11 @@ QString McuPackage::environmentVariableName() const
return m_environmentVariableName;
}
bool McuPackage::isOptional() const
{
return m_optional;
}
bool McuPackage::isAddToSystemPath() const
{
return m_addToSystemPath;
@@ -190,25 +197,34 @@ McuPackage::Status McuPackage::status() const
return m_status;
}
bool McuPackage::isOptionalAndEmpty() const
{
return m_status == Status::EmptyPath && isOptional();
}
bool McuPackage::isValidStatus() const
{
return m_status == Status::ValidPackage || m_status == Status::ValidPackageMismatchedVersion
|| m_status == Status::ValidPackageVersionNotDetected;
|| m_status == Status::ValidPackageVersionNotDetected || isOptionalAndEmpty();
}
void McuPackage::updateStatusUi()
{
switch (m_status) {
case Status::ValidPackage:
if (isOptionalAndEmpty()) {
m_infoLabel->setType(InfoLabel::Ok);
break;
case Status::ValidPackageMismatchedVersion:
case Status::ValidPackageVersionNotDetected:
m_infoLabel->setType(InfoLabel::Warning);
break;
default:
m_infoLabel->setType(InfoLabel::NotOk);
break;
} else {
switch (m_status) {
case Status::ValidPackage:
m_infoLabel->setType(InfoLabel::Ok);
break;
case Status::ValidPackageMismatchedVersion:
case Status::ValidPackageVersionNotDetected:
m_infoLabel->setType(InfoLabel::Warning);
break;
default:
m_infoLabel->setType(InfoLabel::NotOk);
break;
}
}
m_infoLabel->setText(statusText());
}

View File

@@ -39,6 +39,7 @@ public:
const QString &downloadUrl = {},
const McuPackageVersionDetector *versionDetector = nullptr,
const bool addToPath = false,
const bool optional = false,
const Utils::PathChooser::Kind &valueType
= Utils::PathChooser::Kind::ExistingDirectory,
const bool allowNewerVersionKey = false);
@@ -50,6 +51,7 @@ public:
QString label() const override;
QString cmakeVariableName() const override;
QString environmentVariableName() const override;
bool isOptional() const override;
bool isAddToSystemPath() const override;
QStringList versions() const override;
@@ -77,6 +79,8 @@ private:
void updatePath();
void updateStatusUi();
bool isOptionalAndEmpty() const;
SettingsHandler::Ptr settingsHandler;
Utils::PathChooser *m_fileChooser = nullptr;
@@ -95,6 +99,7 @@ private:
const QString m_cmakeVariableName;
const QString m_environmentVariableName;
const QString m_downloadUrl;
const bool m_optional;
const bool m_addToSystemPath;
const Utils::PathChooser::Kind m_valueType;

View File

@@ -55,8 +55,10 @@ private:
QMap<McuPackagePtr, QWidget *> m_packageWidgets;
QMap<McuTargetPtr, QWidget *> m_mcuTargetPacketWidgets;
QFormLayout *m_packagesLayout = nullptr;
QFormLayout *m_optionalPackagesLayout = nullptr;
QGroupBox *m_qtForMCUsSdkGroupBox = nullptr;
QGroupBox *m_packagesGroupBox = nullptr;
QGroupBox *m_optionalPackagesGroupBox = nullptr;
QGroupBox *m_mcuTargetsGroupBox = nullptr;
QComboBox *m_mcuTargetsComboBox = nullptr;
QGroupBox *m_kitCreationGroupBox = nullptr;
@@ -122,6 +124,14 @@ McuSupportOptionsWidget::McuSupportOptionsWidget(McuSupportOptions &options,
m_packagesGroupBox->setLayout(m_packagesLayout);
}
{
m_optionalPackagesGroupBox = new QGroupBox(Tr::tr("Optional"));
m_optionalPackagesGroupBox->setFlat(true);
mainLayout->addWidget(m_optionalPackagesGroupBox);
m_optionalPackagesLayout = new QFormLayout;
m_optionalPackagesGroupBox->setLayout(m_optionalPackagesLayout);
}
{
m_mcuTargetsInfoLabel = new Utils::InfoLabel;
mainLayout->addWidget(m_mcuTargetsInfoLabel);
@@ -187,6 +197,10 @@ void McuSupportOptionsWidget::updateStatus()
const bool ready = valid && mcuTarget;
m_mcuTargetsGroupBox->setVisible(ready);
m_packagesGroupBox->setVisible(ready && !mcuTarget->packages().isEmpty());
m_optionalPackagesGroupBox->setVisible(
ready && std::ranges::any_of(mcuTarget->packages(), [](McuPackagePtr p) {
return p->isOptional();
}));
m_kitCreationGroupBox->setVisible(ready);
m_mcuTargetsInfoLabel->setVisible(valid && m_options.sdkRepository.mcuTargets.isEmpty());
if (m_mcuTargetsInfoLabel->isVisible()) {
@@ -266,6 +280,10 @@ void McuSupportOptionsWidget::showMcuTargetPackages()
m_packagesLayout->removeRow(0);
}
while (m_optionalPackagesLayout->rowCount() > 0) {
m_optionalPackagesLayout->removeRow(0);
}
std::set<McuPackagePtr, McuPackageSort> packages;
for (const auto &package : mcuTarget->packages()) {
@@ -285,7 +303,10 @@ void McuSupportOptionsWidget::showMcuTargetPackages()
package->setPath(macroExpander->expand(package->defaultPath()));
}
});
m_packagesLayout->addRow(package->label(), packageWidget);
if (package->isOptional())
m_optionalPackagesLayout->addRow(package->label(), packageWidget);
else
m_packagesLayout->addRow(package->label(), packageWidget);
packageWidget->show();
}

View File

@@ -61,6 +61,7 @@ McuPackagePtr createQtForMCUsPackage(const SettingsHandler::Ptr &settingsHandler
{}, // versions
{}, // downloadUrl
nullptr, // versionDetector
false, // optional
false, // addToPath
Utils::PathChooser::Kind::ExistingDirectory, // valueType
true)}; // useNewestVersionKey
@@ -706,6 +707,7 @@ static PackageDescription parsePackage(const QJsonObject &cmakeEntry)
detectionPaths,
versions,
parseVersionDetection(cmakeEntry),
cmakeEntry["optional"].toBool(),
cmakeEntry["addToSystemPath"].toBool(),
parseLineEditType(cmakeEntry["type"])};
}

View File

@@ -33,6 +33,7 @@ struct PackageDescription
Utils::FilePaths detectionPaths;
QStringList versions;
VersionDetection versionDetection;
bool optional;
bool shouldAddToSystemPath;
Utils::PathChooser::Kind type;
}; //struct PackageDescription

View File

@@ -137,6 +137,7 @@ McuPackagePtr McuTargetFactory::createPackage(const PackageDescription &pkgDesc)
pkgDesc.versions,
{},
createVersionDetection(pkgDesc.versionDetection),
pkgDesc.optional,
pkgDesc.shouldAddToSystemPath,
pkgDesc.type}};
}

View File

@@ -29,6 +29,7 @@ public:
MOCK_METHOD(bool, isValidStatus, (), (const));
MOCK_METHOD(QString, cmakeVariableName, (), (const));
MOCK_METHOD(QString, environmentVariableName, (), (const));
MOCK_METHOD(bool, isOptional, (), (const));
MOCK_METHOD(bool, isAddToSystemPath, (), (const));
MOCK_METHOD(bool, writeToSettings, (), (const));
MOCK_METHOD(void, readFromSettings, ());

View File

@@ -196,6 +196,7 @@ const PackageDescription
{},
VersionDetection{},
false,
false,
Utils::PathChooser::Kind::ExistingDirectory};
const McuTargetDescription::Platform platformDescription{id,
@@ -851,6 +852,7 @@ void McuSupportTest::test_useFallbackPathForToolchainWhenPathFromSettingsIsNotAv
{},
VersionDetection{},
false,
false,
Utils::PathChooser::Kind::ExistingDirectory};
McuTargetDescription::Toolchain toolchainDescription{armGcc, {}, compilerDescription, {}};
@@ -875,6 +877,7 @@ void McuSupportTest::test_usePathFromSettingsForToolchainPath()
{},
VersionDetection{},
false,
false,
Utils::PathChooser::Kind::ExistingDirectory};
McuTargetDescription::Toolchain toolchainDescription{armGcc, {}, compilerDescription, {}};

View File

@@ -139,7 +139,7 @@ public:
perfParserWorker->addStartDependency(perfRecordWorker);
perfParserWorker->addStopDependency(perfRecordWorker);
perfRecordWorker->addStopDependency(perfParserWorker);
QObject::connect(perfRecordWorker, &RunWorker::stopped, runControl, &RunControl::initiateStop);
PerfProfilerTool::instance()->onWorkerCreation(runControl);
auto tool = PerfProfilerTool::instance();

View File

@@ -318,6 +318,7 @@ GroupItem WindowsSettingsWidget::downloadNugetRecipe()
Tr::tr("Cancel"), 0, 100,
Core::ICore::dialogParent()));
progressDialog->setWindowModality(Qt::ApplicationModal);
progressDialog->setMinimumDuration(INT_MAX); // In order to suppress calls to processEvents() from setValue()
progressDialog->setWindowTitle(Tr::tr("Downloading"));
progressDialog->setFixedSize(progressDialog->sizeHint());
progressDialog->setAutoClose(false);

View File

@@ -38,7 +38,6 @@ QmlProfilerRunner::QmlProfilerRunner(RunControl *runControl)
: RunWorker(runControl)
{
setId("QmlProfilerRunner");
runControl->requestQmlChannel();
runControl->setIcon(ProjectExplorer::Icons::ANALYZER_START_SMALL_TOOLBAR);
}
@@ -152,6 +151,7 @@ RunWorker *createLocalQmlProfilerWorker(RunControl *runControl)
worker->setId("LocalQmlProfilerSupport");
auto profiler = new QmlProfilerRunner(runControl);
runControl->requestQmlChannel();
worker->addStopDependency(profiler);
// We need to open the local server before the application tries to connect.

View File

@@ -555,7 +555,9 @@ ProjectExplorer::RunControl *QmlProfilerTool::attachToWaitingApplication()
d->m_viewContainer->perspective()->select();
auto runControl = new RunControl(ProjectExplorer::Constants::QML_PROFILER_RUN_MODE);
runControl->copyDataFromRunConfiguration(activeRunConfigForActiveProject());
if (RunConfiguration *runConfig = activeRunConfigForActiveProject())
runControl->copyDataFromRunConfiguration(runConfig);
runControl->setQmlChannel(serverUrl);
// The object as such is needed, the RunWorker becomes part of the RunControl at construction time,
// similar to how QObject children are owned by their parents
[[maybe_unused]] auto profiler = new QmlProfilerRunner(runControl);

View File

@@ -66,6 +66,7 @@ TerminalWidget::TerminalWidget(QWidget *parent, const OpenTerminalParameters &op
surfaceChanged();
setAllowBlinkingCursor(settings().allowBlinkingCursor());
enableMouseTracking(settings().enableMouseTracking());
connect(&settings(), &AspectContainer::applied, this, [this] {
// Setup colors first, as setupFont will redraw the screen.
@@ -73,6 +74,7 @@ TerminalWidget::TerminalWidget(QWidget *parent, const OpenTerminalParameters &op
setupFont();
configBlinkTimer();
setAllowBlinkingCursor(settings().allowBlinkingCursor());
enableMouseTracking(settings().enableMouseTracking());
});
}
@@ -127,8 +129,6 @@ void TerminalWidget::setupPty()
env.setFallback("COMMAND_MODE", "unix2003");
env.setFallback("INIT_CWD", QCoreApplication::applicationDirPath());
// For git bash on Windows
env.prependOrSetPath(shellCommand.executable().parentDir());
if (env.hasKey("CLINK_NOAUTORUN"))
env.unset("CLINK_NOAUTORUN");

View File

@@ -77,6 +77,7 @@ static FormatOutput format(const FormatInput &input)
options.replaceInStrings(QLatin1String("%file"), sourceFile.filePath().toUrlishString());
Process process;
process.setCommand({executable, options});
process.setUtf8StdOutCodec();
process.runBlocking(5s);
if (process.result() != ProcessResult::FinishedWithSuccess) {
return Utils::make_unexpected(Tr::tr("Failed to format: %1.")
@@ -102,6 +103,7 @@ static FormatOutput format(const FormatInput &input)
options.replaceInStrings("%file", input.filePath.toUrlishString());
process.setCommand({executable, options});
process.setWriteData(input.sourceData.toUtf8());
process.setUtf8StdOutCodec();
process.start();
if (!process.waitForFinished(5s)) {
return Utils::make_unexpected(Tr::tr("Cannot call %1 or some other error occurred. "

View File

@@ -3497,7 +3497,9 @@ void TextEditorWidget::gotoLine(int line, int column, bool centerLine, bool anim
const QTextBlock &block = document()->findBlockByNumber(blockNumber);
if (block.isValid()) {
QTextCursor cursor(block);
if (column > 0) {
if (column >= block.length()) {
cursor.movePosition(QTextCursor::EndOfBlock);
} else if (column > 0) {
cursor.movePosition(QTextCursor::Right, QTextCursor::MoveAnchor, column);
} else {
int pos = cursor.position();
@@ -9897,6 +9899,23 @@ QAction * TextEditorWidget::insertExtraToolBarWidget(TextEditorWidget::Side side
}
}
void TextEditorWidget::insertExtraToolBarAction(TextEditorWidget::Side side, QAction *action)
{
if (side == Left) {
auto findLeftMostAction = [this](QAction *action) {
if (d->m_toolbarOutlineAction && action == d->m_toolbarOutlineAction)
return false;
return d->m_toolBar->widgetForAction(action) != nullptr;
};
QAction *before = Utils::findOr(d->m_toolBar->actions(),
d->m_fileEncodingLabelAction,
findLeftMostAction);
d->m_toolBar->insertAction(before, action);
} else {
d->m_toolBar->insertAction(d->m_fileLineEndingAction, action);
}
}
void TextEditorWidget::setToolbarOutline(QWidget *widget)
{
if (d->m_toolbarOutlineAction) {
@@ -10357,6 +10376,11 @@ BaseTextEditor *BaseTextEditor::currentTextEditor()
return qobject_cast<BaseTextEditor *>(EditorManager::currentEditor());
}
QList<BaseTextEditor *> BaseTextEditor::openedTextEditors()
{
return qobject_container_cast<BaseTextEditor *>(DocumentModel::editorsForOpenedDocuments());
}
QVector<BaseTextEditor *> BaseTextEditor::textEditorsForDocument(TextDocument *textDocument)
{
QVector<BaseTextEditor *> ret;

View File

@@ -127,6 +127,7 @@ public:
virtual void finalizeInitialization() {}
static BaseTextEditor *currentTextEditor();
static QList<BaseTextEditor *> openedTextEditors();
static QVector<BaseTextEditor *> textEditorsForDocument(TextDocument *textDocument);
TextEditorWidget *editorWidget() const;
@@ -351,6 +352,7 @@ public:
enum Side { Left, Right };
QAction *insertExtraToolBarWidget(Side side, QWidget *widget);
void insertExtraToolBarAction(Side side, QAction *action);
void setToolbarOutline(QWidget* widget);
const QWidget *toolbarOutlineWidget();

View File

@@ -126,7 +126,7 @@ def displayHintForHighlighterDefinition(fileName, patterns, added):
if hasSuffix(fileName, patterns):
return not added
test.warning("Got an unexpected suffix.", "Filename: %s, Patterns: %s"
% (fileName, str(patterns + lPatterns)))
% (fileName, str(patterns)))
return False
def main():

View File

@@ -62,12 +62,20 @@ def main():
"consider raising the timeout.")
else:
snooze(1)
type(cppwindow, testData.field(record, "operator"))
operator = testData.field(record, "operator")
type(cppwindow, operator)
genericProposalWidget = __getGenericProposalListView__(1500)
# the clang code model does not change the . to -> before applying a proposal
# so, verify list of proposals roughly
if useClang:
expectProposal = testData.field(record, "clangProposal") == 'True'
if expectProposal and (genericProposalWidget is None):
test.warning("Expected proposal widget was not displayed as expected. "
"Trying again...")
for _ in operator:
type(cppwindow, "<Backspace>")
type(cppwindow, operator)
genericProposalWidget = __getGenericProposalListView__(500)
test.compare(genericProposalWidget is not None, expectProposal,
'Verifying whether proposal widget is displayed as expected.')

View File

@@ -13,12 +13,12 @@
"<QPointer>" "QPointer<QCoreApplication> pa; QPointer<QCoreApplication> &poi = pa;" "poi" "." "poi." "True" "mixed"
"<QPointer>" "QPointer<QCoreApplication> poi[5];" "poi[2]" "." "poi[2]." "True" "mixed"
"<QPointer>" "QPointer<QCoreApplication> *poi[5];" "poi[2]" "." "poi[2]->" "True" "all"
"<memory>" "std::auto_ptr<QCoreApplication> sap;" "sap" "." "sap." "True" "mixed"
"<memory>" "std::auto_ptr<QCoreApplication> *sap;" "sap" "." "sap->" "True" "all"
"<memory>" "std::auto_ptr<QCoreApplication> &sap;" "sap" "." "sap." "True" "mixed"
"<memory>" "std::auto_ptr<QCoreApplication> sapqa; std::auto_ptr<QCoreApplication> &sap = sapqa;" "sap" "." "sap." "True" "mixed"
"<memory>" "std::auto_ptr<QCoreApplication> sap[10];" "sap[2]" "." "sap[2]." "True" "mixed"
"<memory>" "std::auto_ptr<QCoreApplication> *sap[10];" "sap[2]" "." "sap[2]->" "True" "all"
"<memory>" "std::unique_ptr<QCoreApplication> sap;" "sap" "." "sap." "True" "mixed"
"<memory>" "std::unique_ptr<QCoreApplication> *sap;" "sap" "." "sap->" "True" "all"
"<memory>" "std::unique_ptr<QCoreApplication> &sap;" "sap" "." "sap." "True" "mixed"
"<memory>" "std::unique_ptr<QCoreApplication> sapqa; std::unique_ptr<QCoreApplication> &sap = sapqa;" "sap" "." "sap." "True" "mixed"
"<memory>" "std::unique_ptr<QCoreApplication> sap[10];" "sap[2]" "." "sap[2]." "True" "mixed"
"<memory>" "std::unique_ptr<QCoreApplication> *sap[10];" "sap[2]" "." "sap[2]->" "True" "all"
"<QVector>" "QVector<QCoreApplication> vec;" "vec" "." "vec." "True" "none"
"<QVector>" "QVector<QCoreApplication *> vec;" "vec" "." "vec." "True" "none"
"<QVector>" "QVector<QCoreApplication> *vec;" "vec" "." "vec->" "True" "all"
1 include declaration usage operator expected clangProposal correction
13 <QPointer> QPointer<QCoreApplication> pa; QPointer<QCoreApplication> &poi = pa; poi . poi. True mixed
14 <QPointer> QPointer<QCoreApplication> poi[5]; poi[2] . poi[2]. True mixed
15 <QPointer> QPointer<QCoreApplication> *poi[5]; poi[2] . poi[2]-> True all
16 <memory> std::auto_ptr<QCoreApplication> sap; std::unique_ptr<QCoreApplication> sap; sap . sap. True mixed
17 <memory> std::auto_ptr<QCoreApplication> *sap; std::unique_ptr<QCoreApplication> *sap; sap . sap-> True all
18 <memory> std::auto_ptr<QCoreApplication> &sap; std::unique_ptr<QCoreApplication> &sap; sap . sap. True mixed
19 <memory> std::auto_ptr<QCoreApplication> sapqa; std::auto_ptr<QCoreApplication> &sap = sapqa; std::unique_ptr<QCoreApplication> sapqa; std::unique_ptr<QCoreApplication> &sap = sapqa; sap . sap. True mixed
20 <memory> std::auto_ptr<QCoreApplication> sap[10]; std::unique_ptr<QCoreApplication> sap[10]; sap[2] . sap[2]. True mixed
21 <memory> std::auto_ptr<QCoreApplication> *sap[10]; std::unique_ptr<QCoreApplication> *sap[10]; sap[2] . sap[2]-> True all
22 <QVector> QVector<QCoreApplication> vec; vec . vec. True none
23 <QVector> QVector<QCoreApplication *> vec; vec . vec. True none
24 <QVector> QVector<QCoreApplication> *vec; vec . vec-> True all