- fix: Can't undo & save after copy by drag with mouse.
This commit is contained in:
parent
3b56bab68b
commit
e9247f6476
1
NEWS.md
1
NEWS.md
|
@ -18,6 +18,7 @@ Red Panda C++ Version 2.17
|
||||||
- enhancement: Shift+Down in the last line will expand selection to the end of the line.
|
- enhancement: Shift+Down in the last line will expand selection to the end of the line.
|
||||||
- enhancement: If no selection, Ctrl+C (Copy) auto selects the current line and put the cursor to the beginning.
|
- enhancement: If no selection, Ctrl+C (Copy) auto selects the current line and put the cursor to the beginning.
|
||||||
- fix: Chinese characters in the source code is not correctly displayed in the CPU info window.
|
- fix: Chinese characters in the source code is not correctly displayed in the CPU info window.
|
||||||
|
- fix: Can't undo & save after copy by drag with mouse.
|
||||||
|
|
||||||
|
|
||||||
Red Panda C++ Version 2.16
|
Red Panda C++ Version 2.16
|
||||||
|
|
|
@ -129,7 +129,7 @@ SOURCES += \
|
||||||
settingsdialog/executorproblemsetwidget.cpp \
|
settingsdialog/executorproblemsetwidget.cpp \
|
||||||
settingsdialog/formattergeneralwidget.cpp \
|
settingsdialog/formattergeneralwidget.cpp \
|
||||||
settingsdialog/languageasmgenerationwidget.cpp \
|
settingsdialog/languageasmgenerationwidget.cpp \
|
||||||
settingsdialog/languagecformatwidget.cpp \
|
# settingsdialog/languagecformatwidget.cpp \
|
||||||
settingsdialog/projectcompileparamaterswidget.cpp \
|
settingsdialog/projectcompileparamaterswidget.cpp \
|
||||||
settingsdialog/projectcompilerwidget.cpp \
|
settingsdialog/projectcompilerwidget.cpp \
|
||||||
settingsdialog/projectdirectorieswidget.cpp \
|
settingsdialog/projectdirectorieswidget.cpp \
|
||||||
|
@ -265,7 +265,7 @@ HEADERS += \
|
||||||
settingsdialog/executorproblemsetwidget.h \
|
settingsdialog/executorproblemsetwidget.h \
|
||||||
settingsdialog/formattergeneralwidget.h \
|
settingsdialog/formattergeneralwidget.h \
|
||||||
settingsdialog/languageasmgenerationwidget.h \
|
settingsdialog/languageasmgenerationwidget.h \
|
||||||
settingsdialog/languagecformatwidget.h \
|
# settingsdialog/languagecformatwidget.h \
|
||||||
settingsdialog/projectcompileparamaterswidget.h \
|
settingsdialog/projectcompileparamaterswidget.h \
|
||||||
settingsdialog/projectcompilerwidget.h \
|
settingsdialog/projectcompilerwidget.h \
|
||||||
settingsdialog/projectdirectorieswidget.h \
|
settingsdialog/projectdirectorieswidget.h \
|
||||||
|
@ -373,7 +373,7 @@ FORMS += \
|
||||||
settingsdialog/executorproblemsetwidget.ui \
|
settingsdialog/executorproblemsetwidget.ui \
|
||||||
settingsdialog/formattergeneralwidget.ui \
|
settingsdialog/formattergeneralwidget.ui \
|
||||||
settingsdialog/languageasmgenerationwidget.ui \
|
settingsdialog/languageasmgenerationwidget.ui \
|
||||||
settingsdialog/languagecformatwidget.ui \
|
# settingsdialog/languagecformatwidget.ui \
|
||||||
settingsdialog/projectcompileparamaterswidget.ui \
|
settingsdialog/projectcompileparamaterswidget.ui \
|
||||||
settingsdialog/projectcompilerwidget.ui \
|
settingsdialog/projectcompilerwidget.ui \
|
||||||
settingsdialog/projectdirectorieswidget.ui \
|
settingsdialog/projectdirectorieswidget.ui \
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
#include "cppformatter.h"
|
#include "cppformatter.h"
|
||||||
#include "../qsynedit.h"
|
#include "../qsynedit.h"
|
||||||
#include "../syntaxer/cpp.h"
|
#include "../syntaxer/cpp.h"
|
||||||
|
#include <QDebug>
|
||||||
|
|
||||||
namespace QSynedit {
|
namespace QSynedit {
|
||||||
CppFormatter::CppFormatter()
|
CppFormatter::CppFormatter()
|
||||||
|
@ -53,15 +53,13 @@ namespace QSynedit {
|
||||||
|
|
||||||
&& lineText.endsWith(':')
|
&& lineText.endsWith(':')
|
||||||
&& (
|
&& (
|
||||||
(getBoolOption("IndentClassMemberVisibilityKeywords",true)
|
( (
|
||||||
&& (
|
|
||||||
firstToken == "public" || firstToken == "private"
|
firstToken == "public" || firstToken == "private"
|
||||||
|| firstToken == "protected"
|
|| firstToken == "protected"
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
||
|
||
|
||||||
(getBoolOption("IndentSwitchCases",true)
|
( (
|
||||||
&& (
|
|
||||||
firstToken == "case"
|
firstToken == "case"
|
||||||
|| firstToken == "default"
|
|| firstToken == "default"
|
||||||
)
|
)
|
||||||
|
@ -135,7 +133,5 @@ namespace QSynedit {
|
||||||
|
|
||||||
void CppFormatter::doInitOptions()
|
void CppFormatter::doInitOptions()
|
||||||
{
|
{
|
||||||
mOptions.insert("IndentClassMemberVisibilityKeywords",true);
|
|
||||||
mOptions.insert("IndentSwitchCases",true);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -6388,9 +6388,8 @@ void QSynEdit::dropEvent(QDropEvent *event)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
endEditing();
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
endEditing();
|
||||||
event->acceptProposedAction();
|
event->acceptProposedAction();
|
||||||
mDropped = true;
|
mDropped = true;
|
||||||
setTopLine(topLine);
|
setTopLine(topLine);
|
||||||
|
|
Loading…
Reference in New Issue