diff --git a/RedPandaIDE/debugger/debugger.cpp b/RedPandaIDE/debugger/debugger.cpp index 8e5297f1..7a33ae22 100644 --- a/RedPandaIDE/debugger/debugger.cpp +++ b/RedPandaIDE/debugger/debugger.cpp @@ -35,6 +35,7 @@ #include #include "widgets/signalmessagedialog.h" #include +#include Debugger::Debugger(QObject *parent) : QObject(parent), mForceUTF8(false), @@ -2461,7 +2462,7 @@ MemoryModel::MemoryModel(int dataPerLine, QObject *parent): void MemoryModel::updateMemory(const QStringList &value) { int maxDataPerLine=-1; - QRegExp delimiter("(\\s+)"); + QRegularExpression delimiter("(\\s+)"); QList newModel; for (int i=0;i #include #include -#include #include #include #include diff --git a/RedPandaIDE/settings.cpp b/RedPandaIDE/settings.cpp index f83e8c10..766ce300 100644 --- a/RedPandaIDE/settings.cpp +++ b/RedPandaIDE/settings.cpp @@ -28,7 +28,6 @@ #include #include #include -#include #include #include #include @@ -6443,19 +6442,23 @@ void Settings::UI::doLoad() mProblemOrder = intValue("problem_order",6); //dialogs - mCPUDialogWidth = intValue("cpu_dialog_width",977*qApp->desktop()->width()/1920); - mCPUDialogHeight = intValue("cpu_dialog_height",622*qApp->desktop()->height()/1080); - mCPUDialogSplitterPos = intValue("cpu_dialog_splitter",500*qApp->desktop()->width()/1920); - mSettingsDialogWidth = intValue("settings_dialog_width",977*qApp->desktop()->width()/1920); - mSettingsDialogHeight = intValue("settings_dialog_height",622*qApp->desktop()->height()/1080); - mSettingsDialogSplitterPos = intValue("settings_dialog_splitter",300*qApp->desktop()->width()/1920); + QRect geometry = qApp->primaryScreen()->geometry(); + int width = geometry.width(); + int height = geometry.height(); - mNewProjectDialogWidth = intValue("new_project_dialog_width", 900*qApp->desktop()->width()/1920); - mNewProjectDialogHeight = intValue("new_project_dialog_height", 600*qApp->desktop()->height()/1080); - mNewClassDialogWidth = intValue("new_class_dialog_width", 642*qApp->desktop()->width()/1920); - mNewClassDialogHeight = intValue("new_class_dialog_height", 300*qApp->desktop()->height()/1080); - mNewHeaderDialogWidth = intValue("new_header_dialog_width", 642*qApp->desktop()->width()/1920); - mNewHeaderDialogHeight = intValue("new_header_dialog_height", 300*qApp->desktop()->height()/1080); + mCPUDialogWidth = intValue("cpu_dialog_width", 977 * width / 1920); + mCPUDialogHeight = intValue("cpu_dialog_height", 622 * height / 1080); + mCPUDialogSplitterPos = intValue("cpu_dialog_splitter", 500 * width / 1920); + mSettingsDialogWidth = intValue("settings_dialog_width", 977 * width / 1920); + mSettingsDialogHeight = intValue("settings_dialog_height", 622 * height / 1080); + mSettingsDialogSplitterPos = intValue("settings_dialog_splitter", 300 * width / 1920); + + mNewProjectDialogWidth = intValue("new_project_dialog_width", 900 * width / 1920); + mNewProjectDialogHeight = intValue("new_project_dialog_height", 600 * height / 1080); + mNewClassDialogWidth = intValue("new_class_dialog_width", 642 * width / 1920); + mNewClassDialogHeight = intValue("new_class_dialog_height", 300 * height / 1080); + mNewHeaderDialogWidth = intValue("new_header_dialog_width", 642 * width / 1920); + mNewHeaderDialogHeight = intValue("new_header_dialog_height", 300 * height / 1080); } #ifdef ENABLE_VCS diff --git a/RedPandaIDE/settingsdialog/settingsdialog.cpp b/RedPandaIDE/settingsdialog/settingsdialog.cpp index c071e1e9..e05e3f13 100644 --- a/RedPandaIDE/settingsdialog/settingsdialog.cpp +++ b/RedPandaIDE/settingsdialog/settingsdialog.cpp @@ -63,7 +63,6 @@ #include #include #include -#include SettingsDialog::SettingsDialog(QWidget *parent) : QDialog(parent), diff --git a/RedPandaIDE/widgets/codecompletionpopup.cpp b/RedPandaIDE/widgets/codecompletionpopup.cpp index 87ac8dc5..4e032b13 100644 --- a/RedPandaIDE/widgets/codecompletionpopup.cpp +++ b/RedPandaIDE/widgets/codecompletionpopup.cpp @@ -44,7 +44,7 @@ CodeCompletionPopup::CodeCompletionPopup(QWidget *parent) : mListView->setItemDelegate(mDelegate); setLayout(new QVBoxLayout()); layout()->addWidget(mListView); - layout()->setMargin(0); + layout()->setContentsMargins(0, 0, 0, 0); mListView->setFocus(); mShowKeywords=true; diff --git a/RedPandaIDE/widgets/cpudialog.cpp b/RedPandaIDE/widgets/cpudialog.cpp index 42ada22c..dea654cd 100644 --- a/RedPandaIDE/widgets/cpudialog.cpp +++ b/RedPandaIDE/widgets/cpudialog.cpp @@ -14,7 +14,6 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . */ -#include #include #include "cpudialog.h" #include "ui_cpudialog.h" diff --git a/RedPandaIDE/widgets/headercompletionpopup.cpp b/RedPandaIDE/widgets/headercompletionpopup.cpp index b5fcf81b..b0af1455 100644 --- a/RedPandaIDE/widgets/headercompletionpopup.cpp +++ b/RedPandaIDE/widgets/headercompletionpopup.cpp @@ -39,7 +39,7 @@ HeaderCompletionPopup::HeaderCompletionPopup(QWidget* parent):QWidget(parent) mListView->setItemDelegate(mDelegate); setLayout(new QVBoxLayout()); layout()->addWidget(mListView); - layout()->setMargin(0); + layout()->setContentsMargins(0, 0, 0, 0); mListView->setFocus(); diff --git a/libs/qsynedit/qsynedit/qsynedit.cpp b/libs/qsynedit/qsynedit/qsynedit.cpp index ad1fcabc..fec184af 100644 --- a/libs/qsynedit/qsynedit/qsynedit.cpp +++ b/libs/qsynedit/qsynedit/qsynedit.cpp @@ -38,7 +38,6 @@ #include #include #include -#include #include #include diff --git a/libs/qsynedit/qsynedit/searcher/regexsearcher.cpp b/libs/qsynedit/qsynedit/searcher/regexsearcher.cpp index b75dd2a6..8c4604fd 100644 --- a/libs/qsynedit/qsynedit/searcher/regexsearcher.cpp +++ b/libs/qsynedit/qsynedit/searcher/regexsearcher.cpp @@ -16,7 +16,7 @@ */ #include "regexsearcher.h" -#include +#include namespace QSynedit {