- enhancement: Info contents from stderr are logged into "Tools Output" panel, add problem case name info to the log.
This commit is contained in:
parent
40777386a9
commit
477f7f1d7d
1
NEWS.md
1
NEWS.md
|
@ -91,6 +91,7 @@ Red Panda C++ Version 2.27
|
|||
|
||||
- enhancement: Auto define macro "_DEBUG" for "Debug" compiler set(like visual studio).
|
||||
- enhancement: Suggest macro names after "#ifdef"/"#ifndef".
|
||||
- enhancement: Info contents from stderr are logged into "Tools Output" panel, add problem case name info to the log.
|
||||
|
||||
Red Panda C++ Version 2.26
|
||||
- enhancement: Code suggestion for embedded std::vectors.
|
||||
|
|
|
@ -84,7 +84,7 @@ void OJProblemCasesRunner::runCase(int index,POJProblemCase problemCase)
|
|||
env.insert("PATH",path);
|
||||
process.setProcessEnvironment(env);
|
||||
if (pSettings->executor().redirectStderrToToolLog()) {
|
||||
emit logStderrOutput("\n");
|
||||
emit logStderrOutput("\n"+tr("--- stderr from %1 ---").arg(problemCase->name)+"\n");
|
||||
} else {
|
||||
process.setProcessChannelMode(QProcess::MergedChannels);
|
||||
process.setReadChannel(QProcess::StandardOutput);
|
||||
|
|
|
@ -49,6 +49,9 @@ public:
|
|||
|
||||
void setMemoryLimit(size_t limit);
|
||||
|
||||
bool includeOutputFromStderr() const;
|
||||
void setIncludeOutputFromStderr(bool newIncludeOutputFromStderr);
|
||||
|
||||
signals:
|
||||
void caseStarted(const QString &caseId, int current, int total);
|
||||
void caseFinished(const QString &caseId, int current, int total);
|
||||
|
@ -68,6 +71,7 @@ private:
|
|||
int mOutputRefreshTime;
|
||||
int mExecTimeout;
|
||||
size_t mMemoryLimit;
|
||||
bool mIncludeOutputFromStderr;
|
||||
};
|
||||
|
||||
#endif // OJPROBLEMCASESRUNNER_H
|
||||
|
|
|
@ -1382,7 +1382,7 @@
|
|||
<location filename="../editor.cpp" line="+384"/>
|
||||
<location line="+70"/>
|
||||
<location line="+29"/>
|
||||
<location line="+1088"/>
|
||||
<location line="+1093"/>
|
||||
<location line="+5"/>
|
||||
<location line="+21"/>
|
||||
<location line="+5"/>
|
||||
|
@ -1390,7 +1390,7 @@
|
|||
<translation>Erro</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location line="-1182"/>
|
||||
<location line="-1187"/>
|
||||
<source>Save As</source>
|
||||
<translation>Salvar como</translation>
|
||||
</message>
|
||||
|
@ -1400,7 +1400,7 @@
|
|||
<translation>Arquivo %1 já aberto!</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location line="+1117"/>
|
||||
<location line="+1122"/>
|
||||
<source>The text to be copied exceeds count limit!</source>
|
||||
<translation>O texto a ser copiado excede o limite do contador!</translation>
|
||||
</message>
|
||||
|
@ -1432,7 +1432,7 @@
|
|||
<translation>Ctrl+clik para mais informações</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location line="+919"/>
|
||||
<location line="+920"/>
|
||||
<source>astyle not found</source>
|
||||
<translation>astyle não encontrado</translation>
|
||||
</message>
|
||||
|
@ -1457,13 +1457,13 @@
|
|||
<translation>Apenas leitura</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location line="-5368"/>
|
||||
<location line="-5374"/>
|
||||
<location line="+434"/>
|
||||
<source>Error Load File</source>
|
||||
<translation type="unfinished">Erro ao carregar arquivo</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location line="+1578"/>
|
||||
<location line="+1583"/>
|
||||
<source>hex: %1</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
|
@ -2907,18 +2907,18 @@
|
|||
</message>
|
||||
<message>
|
||||
<location line="+42"/>
|
||||
<location line="+94"/>
|
||||
<location line="+96"/>
|
||||
<source>Can't delete the old executable file "%1".
|
||||
</source>
|
||||
<translation>Impossível remover o antigo arquivo executável "%1".</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location line="-63"/>
|
||||
<location line="-65"/>
|
||||
<source>Can't find the compiler for file %1</source>
|
||||
<translation>Impossível encontrar o compilador para o arquivo %1</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location line="+41"/>
|
||||
<location line="+43"/>
|
||||
<source>The Compiler '%1' doesn't exists!</source>
|
||||
<translation>O compilador '%1' é inexistente!</translation>
|
||||
</message>
|
||||
|
@ -2942,7 +2942,7 @@
|
|||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<location line="-122"/>
|
||||
<location line="-124"/>
|
||||
<source>Checking single file...</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
|
@ -2952,7 +2952,7 @@
|
|||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<location line="+68"/>
|
||||
<location line="+70"/>
|
||||
<source>Command: %1</source>
|
||||
<translation type="unfinished">Comando: %1</translation>
|
||||
</message>
|
||||
|
@ -7345,7 +7345,12 @@
|
|||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<location line="+3"/>
|
||||
<location line="-91"/>
|
||||
<source>--- stderr from %1 ---</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<location line="+94"/>
|
||||
<source>Memory limit exceeded!</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
|
@ -7674,7 +7679,7 @@
|
|||
<translation>- Arquivo de recursos: %1</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location line="+343"/>
|
||||
<location line="+345"/>
|
||||
<source>Compiling project changes...</source>
|
||||
<translation>Compilando alterações em projeto ...</translation>
|
||||
</message>
|
||||
|
@ -8374,7 +8379,7 @@
|
|||
<location filename="../autolinkmanager.cpp" line="+54"/>
|
||||
<location line="+16"/>
|
||||
<location line="+19"/>
|
||||
<location filename="../settings.cpp" line="+4045"/>
|
||||
<location filename="../settings.cpp" line="+4051"/>
|
||||
<location filename="../widgets/ojproblemsetmodel.cpp" line="-401"/>
|
||||
<location line="+61"/>
|
||||
<source>Can't open file '%1' for read.</source>
|
||||
|
@ -9676,7 +9681,7 @@
|
|||
<translation type="unfinished">Impossível abrir '%1' para gravar!</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location line="+214"/>
|
||||
<location line="+212"/>
|
||||
<source>Compiling project changes...</source>
|
||||
<translation type="unfinished">Compilando alterações em projeto ...</translation>
|
||||
</message>
|
||||
|
|
|
@ -1596,7 +1596,7 @@ p, li { white-space: pre-wrap; }
|
|||
<location filename="../editor.cpp" line="+384"/>
|
||||
<location line="+70"/>
|
||||
<location line="+29"/>
|
||||
<location line="+1088"/>
|
||||
<location line="+1093"/>
|
||||
<location line="+5"/>
|
||||
<location line="+21"/>
|
||||
<location line="+5"/>
|
||||
|
@ -1608,7 +1608,7 @@ p, li { white-space: pre-wrap; }
|
|||
<translation type="vanished">无法写入文件"%1"</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location line="-1475"/>
|
||||
<location line="-1480"/>
|
||||
<location line="+434"/>
|
||||
<source>Error Load File</source>
|
||||
<translation>载入文件错误</translation>
|
||||
|
@ -1648,7 +1648,7 @@ p, li { white-space: pre-wrap; }
|
|||
<translation>文件%1已经被打开!</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location line="+1117"/>
|
||||
<location line="+1122"/>
|
||||
<source>The text to be copied exceeds count limit!</source>
|
||||
<translation>要复制的内容超过了行数限制!</translation>
|
||||
</message>
|
||||
|
@ -1694,7 +1694,7 @@ p, li { white-space: pre-wrap; }
|
|||
<translation type="vanished">未找到符号'%1'!</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location line="+919"/>
|
||||
<location line="+920"/>
|
||||
<source>astyle not found</source>
|
||||
<translation>找不到astyle程序</translation>
|
||||
</message>
|
||||
|
@ -3222,13 +3222,13 @@ p, li { white-space: pre-wrap; }
|
|||
</message>
|
||||
<message>
|
||||
<location line="+42"/>
|
||||
<location line="+94"/>
|
||||
<location line="+96"/>
|
||||
<source>Can't delete the old executable file "%1".
|
||||
</source>
|
||||
<translation>无法删除旧的可执行文件"%1".</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location line="-81"/>
|
||||
<location line="-83"/>
|
||||
<source>GNU Assembler</source>
|
||||
<translation>GNU汇编</translation>
|
||||
</message>
|
||||
|
@ -3239,7 +3239,7 @@ p, li { white-space: pre-wrap; }
|
|||
<translation>找不到适合文件%1的编译器</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location line="+41"/>
|
||||
<location line="+43"/>
|
||||
<source>The Compiler '%1' doesn't exists!</source>
|
||||
<translation>编译器程序"%1"不存在!</translation>
|
||||
</message>
|
||||
|
@ -7930,7 +7930,12 @@ p, li { white-space: pre-wrap; }
|
|||
<translation type="vanished">案例运行超时</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../compiler/ojproblemcasesrunner.cpp" line="+178"/>
|
||||
<location filename="../compiler/ojproblemcasesrunner.cpp" line="+87"/>
|
||||
<source>--- stderr from %1 ---</source>
|
||||
<translation type="unfinished">--- 来自“%1”的stderr ---</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location line="+91"/>
|
||||
<source>Time limit exceeded!</source>
|
||||
<translation>运行时间超限!</translation>
|
||||
</message>
|
||||
|
@ -8312,7 +8317,7 @@ p, li { white-space: pre-wrap; }
|
|||
<translation>- 资源文件: %1</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location line="+343"/>
|
||||
<location line="+345"/>
|
||||
<source>Compiling project changes...</source>
|
||||
<translation>正在编译项目修改...</translation>
|
||||
</message>
|
||||
|
@ -9234,7 +9239,7 @@ p, li { white-space: pre-wrap; }
|
|||
<translation>生成调试信息(-g3)</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../settings.cpp" line="+3443"/>
|
||||
<location filename="../settings.cpp" line="+3449"/>
|
||||
<source>Would you like Red Panda C++ to search for compilers in PATH?</source>
|
||||
<translation>您同意小熊猫C++在PATH路径中寻找gcc编译器吗?</translation>
|
||||
</message>
|
||||
|
@ -10421,7 +10426,7 @@ p, li { white-space: pre-wrap; }
|
|||
<translation>无法写入文件'%1'!</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location line="+214"/>
|
||||
<location line="+212"/>
|
||||
<source>Compiling project changes...</source>
|
||||
<translation>正在编译项目修改...</translation>
|
||||
</message>
|
||||
|
|
|
@ -1227,7 +1227,7 @@
|
|||
<location filename="../editor.cpp" line="+384"/>
|
||||
<location line="+70"/>
|
||||
<location line="+29"/>
|
||||
<location line="+1088"/>
|
||||
<location line="+1093"/>
|
||||
<location line="+5"/>
|
||||
<location line="+21"/>
|
||||
<location line="+5"/>
|
||||
|
@ -1235,7 +1235,7 @@
|
|||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<location line="-1182"/>
|
||||
<location line="-1187"/>
|
||||
<source>Save As</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
|
@ -1245,7 +1245,7 @@
|
|||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<location line="+1117"/>
|
||||
<location line="+1122"/>
|
||||
<source>The text to be copied exceeds count limit!</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
|
@ -1277,7 +1277,7 @@
|
|||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<location line="+919"/>
|
||||
<location line="+920"/>
|
||||
<source>astyle not found</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
|
@ -1302,13 +1302,13 @@
|
|||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<location line="-5368"/>
|
||||
<location line="-5374"/>
|
||||
<location line="+434"/>
|
||||
<source>Error Load File</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<location line="+1578"/>
|
||||
<location line="+1583"/>
|
||||
<source>hex: %1</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
|
@ -2716,18 +2716,18 @@
|
|||
</message>
|
||||
<message>
|
||||
<location line="+42"/>
|
||||
<location line="+94"/>
|
||||
<location line="+96"/>
|
||||
<source>Can't delete the old executable file "%1".
|
||||
</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<location line="-63"/>
|
||||
<location line="-65"/>
|
||||
<source>Can't find the compiler for file %1</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<location line="+41"/>
|
||||
<location line="+43"/>
|
||||
<source>The Compiler '%1' doesn't exists!</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
|
@ -2747,7 +2747,7 @@
|
|||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<location line="-122"/>
|
||||
<location line="-124"/>
|
||||
<source>Checking single file...</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
|
@ -2757,7 +2757,7 @@
|
|||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<location line="+68"/>
|
||||
<location line="+70"/>
|
||||
<source>Command: %1</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
|
@ -7030,7 +7030,12 @@
|
|||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<location line="+3"/>
|
||||
<location line="-91"/>
|
||||
<source>--- stderr from %1 ---</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<location line="+94"/>
|
||||
<source>Memory limit exceeded!</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
|
@ -7335,7 +7340,7 @@
|
|||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<location line="+343"/>
|
||||
<location line="+345"/>
|
||||
<source>Compiling project changes...</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
|
@ -8002,7 +8007,7 @@
|
|||
<location filename="../autolinkmanager.cpp" line="+54"/>
|
||||
<location line="+16"/>
|
||||
<location line="+19"/>
|
||||
<location filename="../settings.cpp" line="+4045"/>
|
||||
<location filename="../settings.cpp" line="+4051"/>
|
||||
<location filename="../widgets/ojproblemsetmodel.cpp" line="-401"/>
|
||||
<location line="+61"/>
|
||||
<source>Can't open file '%1' for read.</source>
|
||||
|
@ -9077,7 +9082,7 @@
|
|||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<location line="+214"/>
|
||||
<location line="+212"/>
|
||||
<source>Compiling project changes...</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
|
|
Loading…
Reference in New Issue