From 0e1decad6575a4aa2168435444fb18ef601acc2b Mon Sep 17 00:00:00 2001 From: Roy Qu Date: Tue, 27 Jun 2023 11:50:43 +0800 Subject: [PATCH] check windows version and decide if the debug info in the executable files is utf8 encoded. --- NEWS.md | 1 + RedPandaIDE/debugger.cpp | 45 +- RedPandaIDE/debugger.h | 4 + RedPandaIDE/mainwindow.cpp | 3 +- RedPandaIDE/translations/RedPandaIDE_pt_BR.ts | 6 +- RedPandaIDE/translations/RedPandaIDE_zh_CN.ts | 1202 +++++++++-------- RedPandaIDE/translations/RedPandaIDE_zh_TW.ts | 8 +- RedPandaIDE/widgets/cpudialog.ui | 64 +- .../windows/installer-scripts/config.nsh.in | 2 +- 9 files changed, 693 insertions(+), 642 deletions(-) diff --git a/NEWS.md b/NEWS.md index b01a5cc9..e114f181 100644 --- a/NEWS.md +++ b/NEWS.md @@ -12,6 +12,7 @@ Red Panda C++ Version 2.23 - enhancement: improve parsing for multiple vars defined in one line - enhancement: improve parsing result for function parameters like 'Node (&node)[10]' - fix: Can't copy by ctrl+dray&drop to current selection's begin/end + - enhancement: Support debug executable files generated by mingw-w64 gcc 13.1 and filepath contains non-ascii chars. Red Panda C++ Version 2.22 diff --git a/RedPandaIDE/debugger.cpp b/RedPandaIDE/debugger.cpp index f1157fbd..512dc918 100644 --- a/RedPandaIDE/debugger.cpp +++ b/RedPandaIDE/debugger.cpp @@ -85,6 +85,27 @@ bool Debugger::start(int compilerSetIndex, const QString& inferior, const QStrin return false; } setForceUTF8(CompilerInfoManager::forceUTF8InDebugger(compilerSet->compilerType())); + setDebugInfosUsingUTF8(false); +#ifdef Q_OS_WIN + + bool isOk; + int productVersion = QSysInfo::productVersion().toInt(&isOk); +// qDebug()<mainVersion()>=13 && compilerSet->compilerType()==CompilerType::GCC + && productVersion>=10) + setDebugInfosUsingUTF8(true); +#endif if (compilerSet->debugger().endsWith(LLDB_MI_PROGRAM)) setDebuggerType(DebuggerType::LLDB_MI); else @@ -560,6 +581,16 @@ void Debugger::fetchVarChildren(const QString &varName) } } +bool Debugger::debugInfosUsingUTF8() const +{ + return mDebugInfosUsingUTF8; +} + +void Debugger::setDebugInfosUsingUTF8(bool newDebugInfosUsingUTF8) +{ + mDebugInfosUsingUTF8 = newDebugInfosUsingUTF8; +} + DebuggerType Debugger::debuggerType() const { return mDebuggerType; @@ -1356,6 +1387,13 @@ void DebugReader::runNextCmd() //clang compatibility if (mDebugger->forceUTF8()) { params = pCmd->params.toUtf8(); + } else if (mDebugger->debugInfosUsingUTF8() && + (pCmd->command=="-break-insert" + || pCmd->command=="-var-create" + || pCmd->command=="-data-read-memory" + || pCmd->command=="-data-evaluate-expression" + )) { + params = pCmd->params.toUtf8(); } if (pCmd->command == "-var-create") { //hack for variable creation,to easy remember var expression @@ -1493,7 +1531,7 @@ void DebugReader::handleBreakpoint(const GDBMIResultParser::ParseObject& breakpo { QString filename; // gdb use system encoding for file path - if (mDebugger->forceUTF8()) + if (mDebugger->forceUTF8() || mDebugger->debugInfosUsingUTF8()) filename = breakpoint["fullname"].utf8PathValue(); else filename = breakpoint["fullname"].pathValue(); @@ -1511,7 +1549,8 @@ void DebugReader::handleFrame(const GDBMIResultParser::ParseValue &frame) if (!ok) mCurrentAddress=0; mCurrentLine = frameObj["line"].intValue(); - if (mDebugger->forceUTF8()) + if (mDebugger->forceUTF8() + || mDebugger->debugInfosUsingUTF8()) mCurrentFile = frameObj["fullname"].utf8PathValue(); else mCurrentFile = frameObj["fullname"].pathValue(); @@ -1526,7 +1565,7 @@ void DebugReader::handleStack(const QList & stack GDBMIResultParser::ParseObject frameObject = frameValue.object(); PTrace trace = std::make_shared(); trace->funcname = frameObject["func"].value(); - if (mDebugger->forceUTF8()) + if (mDebugger->forceUTF8() || mDebugger->debugInfosUsingUTF8()) trace->filename = frameObject["fullname"].utf8PathValue(); else trace->filename = frameObject["fullname"].pathValue(); diff --git a/RedPandaIDE/debugger.h b/RedPandaIDE/debugger.h index a2922a67..5ef53bdf 100644 --- a/RedPandaIDE/debugger.h +++ b/RedPandaIDE/debugger.h @@ -372,6 +372,9 @@ public: DebuggerType debuggerType() const; void setDebuggerType(DebuggerType newDebuggerType); + bool debugInfosUsingUTF8() const; + void setDebugInfosUsingUTF8(bool newDebugInfosUsingUTF8); + signals: void evalValueReady(const QString& s); void memoryExamineReady(const QStringList& s); @@ -414,6 +417,7 @@ private: DebugReader *mReader; DebugTarget *mTarget; bool mForceUTF8; + bool mDebugInfosUsingUTF8; DebuggerType mDebuggerType; int mLeftPageIndexBackup; qint64 mLastLoadtime; diff --git a/RedPandaIDE/mainwindow.cpp b/RedPandaIDE/mainwindow.cpp index 850d3c52..99db5398 100644 --- a/RedPandaIDE/mainwindow.cpp +++ b/RedPandaIDE/mainwindow.cpp @@ -2417,7 +2417,7 @@ void MainWindow::debug() mDebugger->sendCommand("-gdb-set", "confirm off"); mDebugger->sendCommand("-gdb-set", "print repeats 0"); // don't repeat elements mDebugger->sendCommand("-gdb-set", QString("print elements %1").arg(pSettings->debugger().arrayElements())); // limit array elements to 500 - mDebugger->sendCommand("-environment-cd", QString("\"%1\"").arg(extractFileDir(filePath))); // restore working directory + //mDebugger->sendCommand("-environment-cd", QString("\"%1\"").arg(extractFileDir(filePath))); // restore working directory if (pSettings->debugger().useGDBServer()) { mDebugger->sendCommand("-target-select",QString("remote localhost:%1").arg(pSettings->debugger().GDBServerPort())); if (!debugInferiorhasBreakpoint() || !debugEnabled) { @@ -9942,4 +9942,3 @@ void MainWindow::on_actionClose_Others_triggered() } mClosing = false; } - diff --git a/RedPandaIDE/translations/RedPandaIDE_pt_BR.ts b/RedPandaIDE/translations/RedPandaIDE_pt_BR.ts index 5f73a442..9015e310 100644 --- a/RedPandaIDE/translations/RedPandaIDE_pt_BR.ts +++ b/RedPandaIDE/translations/RedPandaIDE_pt_BR.ts @@ -183,7 +183,7 @@ Disassemble - Disassemble + Disassemble Step over one machine instruction @@ -205,6 +205,10 @@ Blend Mode Modo mesclado + + Callstack + + CharsetInfoManager diff --git a/RedPandaIDE/translations/RedPandaIDE_zh_CN.ts b/RedPandaIDE/translations/RedPandaIDE_zh_CN.ts index 2acf8556..024f42cb 100644 --- a/RedPandaIDE/translations/RedPandaIDE_zh_CN.ts +++ b/RedPandaIDE/translations/RedPandaIDE_zh_CN.ts @@ -193,17 +193,17 @@ p, li { white-space: pre-wrap; } BacktraceModel - + Function 函数 - + Filename 文件名 - + Line @@ -249,17 +249,17 @@ p, li { white-space: pre-wrap; } BreakpointModel - + Filename 文件名 - + Line - + Condition 条件 @@ -288,22 +288,26 @@ p, li { white-space: pre-wrap; } CPU信息 - Disassemble - 反汇编 + 反汇编 - - + + Step over one machine instruction 单步执行一条机器指令 - - + + Step into one machine instruction 单步进入一条机器指令 + + + Callstack + 调用栈 + AT&&T @@ -1341,12 +1345,12 @@ Are you really want to continue? 调试器路径"%1"中包含非ASCII字符(如,中文字符) - + This prevents it from executing. 这会导致调试器无法启动。 - + Debugger not exists 找不到调试器 @@ -1355,57 +1359,57 @@ Are you really want to continue? 找不到调试器程序"%1" - + Can''t find debugger (gdb) in : "%1" 找不到gdb程序“%1” - + Please check the "program" page of compiler settings. 请检查编译器设置中的“程序”页。 - + GDB Server path error gdb server路径错误 - + GDB Server's path "%1" contains non-ascii characters. gdb server的路径"%1"包含中文或者全角字符 - + GDB Server not exists 找不到gdb server - + Can''t find gdb server in : "%1" 无法在"%1"找到gdb server - + Execute to evaluate 执行以求值 - + Save file '%1' failed. 保存文件'%1'失败。 - + Can't open file '%1' for write. 无法写入文件'%1'. - + Error in json file '%1':%2 : %3 JSON文件'%1':%2中存在错误:%3 - + Can't open file '%1' for read. 无法读取文件'%1'. @@ -1414,22 +1418,22 @@ Are you really want to continue? 不在当前语境中 - + Compile 编译 - + Source file is more recent than executable. 源文件比程序文件新。 - + Recompile? 重新编译? - + Signal "%1" Received: 收到信号"%1": @@ -1539,9 +1543,9 @@ Are you really want to continue? 打印文档 - - - + + + Ctrl+click for more info Ctrl+单击以获取更多信息 @@ -1550,27 +1554,27 @@ Are you really want to continue? 未找到符号'%1'! - + astyle not found 找不到astyle程序 - + Can't find astyle in "%1". 找不到astyle程序"%1". - + Break point condition 断点条件 - + Enter the condition of the breakpoint: 输入当前断点的生效条件: - + Readonly 只读 @@ -4326,11 +4330,11 @@ Are you really want to continue? - - - - - + + + + + Issues 编译器 @@ -4404,7 +4408,7 @@ Are you really want to continue? - + Debug Console 调试主控台 @@ -4584,7 +4588,7 @@ Are you really want to continue? Undo - 恢复 + 撤销 @@ -4613,9 +4617,9 @@ Are you really want to continue? - - - + + + Copy 复制 @@ -4626,7 +4630,7 @@ Are you really want to continue? - + Paste 粘贴 @@ -4637,8 +4641,8 @@ Are you really want to continue? - - + + Select All 选择全部 @@ -4762,38 +4766,38 @@ Are you really want to continue? - - + + New Problem Set 新建试题集 - + Add Problem 添加试题 - + Remove Problem 删除试题 - - + + Save Problem Set 保存试题集 - - + + Load Problem Set 载入试题集 @@ -4841,7 +4845,7 @@ Are you really want to continue? - + Remove Problem Case Remove Problem Set 删除试题集 @@ -4849,21 +4853,21 @@ Are you really want to continue? - + Open Anwser Source File 打开答案源代码文件 - + Run All Cases Run Current Case 运行所有案例 - + Problem Cases Validation Options 测试案例验证选项 @@ -4923,15 +4927,15 @@ Are you really want to continue? - - + + Import FPS Problem Set 导入FPS试题集 - - + + Export FPS Problem Set 导出FPS试题集 @@ -5183,7 +5187,7 @@ Are you really want to continue? - + Clear all breakpoints 删除所有断点 @@ -5537,7 +5541,7 @@ Are you really want to continue? 保存为模板... - + New File 新建文件 @@ -5578,7 +5582,7 @@ Are you really want to continue? - + Rename Symbol 重命名符号 @@ -5599,13 +5603,13 @@ Are you really want to continue? - + Export As RTF 导出为RTF - + Export As HTML 导出为HTML @@ -5874,7 +5878,7 @@ Are you really want to continue? 运行参数... - + File Encoding 文件编码 @@ -5950,7 +5954,7 @@ Are you really want to continue? 确认 - + Source file is not compiled. 源文件尚未编译。 @@ -5967,39 +5971,39 @@ Are you really want to continue? 重新编译? - - - - + + + + Wrong Compiler Settings 错误的编译器设置 - - - - + + + + Compiler is set not to generate executable. 编译器被设置为不生成可执行文件。 - - + + We need the executabe to run problem case. 我们需要可执行文件来运行试题案例。 - + No compiler set 无编译器设置 - + No compiler set is configured. 没有配置编译器设置。 - + Can't start debugging. 无法启动调试器 @@ -6020,33 +6024,33 @@ Are you really want to continue? 项目尚未构建。是否构建? - + Host applcation missing 宿主程序不存在 - + DLL project needs a host application to run. 动态链接库(DLL)需要一个宿主程序来运行。 - + But it's missing. 但它不存在。 - + Host application not exists 宿主程序不存在 - + Host application file '%1' doesn't exist. 宿主程序'%1'不存在。 - - + + Please correct this before start debugging 请在调试前改正设置。 @@ -6055,8 +6059,8 @@ Are you really want to continue? 重新编译? - + Save last open info error 保存上次打开信息失败 @@ -6065,37 +6069,37 @@ Are you really want to continue? 无法删除旧上次打开信息文件'%1' - + Can't save last open info file '%1' 无法保存上次打开信息文件'%1' - - + + Load last open info error 载入上次打开信息失败 - - + + Can't load last open info file '%1' 无法载入上次打开信息文件'%1' - + Open Source File 打开源代码文件 - - - + + + Correct compile settings for debug 纠正调试用编译设置 - - + + The generated executable won't have debug symbol infos, and can't be debugged. 生成的可执行文件中会缺少调试符号信息,因此无法编译。 @@ -6104,81 +6108,81 @@ Are you really want to continue? 如果你正在使用Release版的编译器设置集,请在工具栏中将其改为Debug版本。 - - - + + + Or you can manually change the following settings in the options dialog's compiler set page: 您也可以手动在选项对话框的编译器设置页中修正下列选项: - - - + + + - Turned on the "Generate debug info (-g3)" option. - 打开“生成调试信息(-g3)"选项. - - - + + + - Turned off the "Strip executable (-s)" option. - 关闭"剥除附加信息(-s)"选项. - - - + + + - Turned off the "Optimization level (-O)" option or set it to "Debug (-Og)". - 关闭"优化级别(-O)选项,或将其设置为"调试(-Og)"级别. - - - - + + + + You should recompile after change the compiler set or it's settings. 在更换编译器设置集或修改其设置后,需要重新编译. - - - + + + Do you want to mannually change the compiler set settings now? 您现在就要手动修改编译器设置集的设置吗? - - + + Batch Set Cases 批量设置案例 - + Show detail debug logs 显示详细调试器日志 - + Copy all 全部复制 - + Go to Line 跳转到行 - + Line - + Template Exists 模板已存在 - + Template %1 already exists. Do you want to overwrite? 模板%1已存在。是否覆盖? @@ -6186,9 +6190,9 @@ Are you really want to continue? - - - + + + Clear 清除 @@ -6204,7 +6208,7 @@ Are you really want to continue? - + Problem Set %1 试题集%1 @@ -6233,56 +6237,56 @@ Are you really want to continue? 项目已经被修改过,是否需要重新构建? - + Auto Save Error 自动保存出错 - + Auto save "%1" to "%2" failed:%3 自动保存"%1"到"%2"失败:%3 - + Properties... 试题属性... - + Set Problem Set Name 设置试题集名称 - + Problem Set Name: 试题集名称: - + Remove 删除 - + Remove All Bookmarks 删除全部书签 - + Modify Description 修改描述 - - - + + + Bookmark Description 书签描述 - - - + + + Description: 描述: @@ -6291,65 +6295,65 @@ Are you really want to continue? 在调试主控台中显示调试器输出 - + Remove this search 清除这次搜索 - + Clear all searches 删除所有搜索 - + Breakpoint condition... 断点条件... - + Break point condition 断点条件 - + Enter the condition of the breakpoint: 输入当前断点的生效条件: - + Remove All Breakpoints Remove all breakpoints 删除所有断点 - + Remove Breakpoint 删除当前断点 - + Rename File 重命名文件 - - + + Add Folder 添加文件夹 - - + + New folder 新文件夹 - + Folder name: 文件夹: - + Rename Folder 重命名 @@ -6362,17 +6366,17 @@ Are you really want to continue? 要现在去修改设置吗? - + Rename Problem Set 修改试题集名称 - + Can't open last open information file '%1' for write! 无法写入配置文件'%1'。 - + Rename Problem 修改试题名称 @@ -6402,12 +6406,12 @@ Are you really want to continue? 是否现在去改正? - + Missing Project Files 项目文件缺失 - + The following files is missing, can't build the project: 下列项目文件缺失,无法构建项目: @@ -6424,186 +6428,186 @@ Are you really want to continue? 请取消该设置,重新编译然后重新启动调试。 - + Goto Url 跳转到试题网址 - + Add Problem Case 添加试题案例 - + Run Current Case 运行当前案例 - + Remove Folder 删除文件夹 - + Switch to normal view 切换为普通视图 - + Switch to custom view 切换为自定义视图 - + Sort By Type 按类型排序 - + Sort alphabetically 按名称排序 - + Show inherited members 显示继承的成员 - + Goto declaration 跳转到声明处 - + Goto definition 跳转到定义处 - + In current file 仅当前文件 - + In current project 整个项目 - - + + New Folder 新建文件夹 - + Rename 重命名 - - - - + + + + Delete 删除 - + Open in Editor 在编辑器中打开 - + Open in External Program 使用外部程序打开 - + Open in Terminal 在终端中打开 - + Open in Windows Explorer - 在Windows浏览器中打开 + 在文件资源管理器中打开 - + Character sets 字符集 - + Convert to %1 转换为%1编码 - + Newline 换行符 - + %1 files autosaved 已自动保存%1个文件 - + Set answer to... 设置答案源代码... - + select other file... 选择其他文件... - + Select Answer Source File 选择答案源代码文件 - + Watchpoint hitted 变量断点被触发 - + Value of "%1" has changed: "%1"的值发生了变化: - + New value: %1 新值: %1 - + Project folder removed. 项目文件夹被删除 - + Folder for project '%1' was removed. 项目"%1"的文件夹已被外部程序删除. - + It will be closed. 项目将被关闭. - + Save settings failed! 保存设置失败 - + Watchpoint variable name 被监控的变量 - + Stop execution when the following variable is modified (it must be visible from the currect scope): 当下面的变量被修改时暂停执行(该变量必须可以从当前程序处访问): @@ -6612,17 +6616,17 @@ Are you really want to continue? 中止 - + FPS Problem Set Files (*.fps;*.xml) FPS试题集文件(*.fps;*.xml) - + FPS Problem Set Files (*.fps) FPS试题集文件(*.fps) - + Export Error 导出时出错 @@ -6632,7 +6636,7 @@ Are you really want to continue? C/C++源代码文件 (*.c *.cpp *.cc *.cxx) - + New Folder %1 新建文件夹%1 @@ -6645,12 +6649,12 @@ Are you really want to continue? 无标题%1 - + Do you really want to delete %1? 你真的要删除%1吗? - + Do you really want to delete %1 files? 你真的要删除%1个文件吗? @@ -6663,7 +6667,7 @@ Are you really want to continue? 变量"%1"有改动: - + Old value: %1 旧值: %1 @@ -6672,65 +6676,65 @@ Are you really want to continue? 新值: %1 - + Save project 保存项目 - + The project '%1' has modifications. 项目'%1'有改动。 - - + + Do you want to save it? 需要保存吗? - - + + File Changed 文件已发生变化 - - - + + + New Project File? 新建项目文件? - - - + + + Do you want to add the new file to the project? 您是否要将新建的文件加入项目? - - - - - + + + + + Save Error 保存失败 - + Change Project Compiler Set 改变项目编译器配置集 - + Change the project's compiler set will lose all custom compiler set options. 改变项目的编译器配置集会导致所有的自定义编译器选项被重置。 - - + + Do you really want to do that? 你真的想要那么做吗? @@ -6740,12 +6744,12 @@ Are you really want to continue? 批量设置案例 - + Choose input files 选择输入数据文件 - + Input data files (*.in) 输入数据文件 (*.in) @@ -6754,78 +6758,78 @@ Are you really want to continue? 无标题%1 - + Modify Watch 修改监视表达式 - + Watch Expression 监视表达式 - + Do you really want to clear all breakpoints in this file? 您真的要清除该文件的所有断点吗? - + New project 新建项目 - + Close %1 and start new project? 关闭'%1'以打开新项目? - + Folder not exist 文件夹不存在 - + Folder '%1' doesn't exist. Create it now? 文件夹'%1'不存在。是否创建? - + Can't create folder 无法创建文件夹 - + Failed to create folder '%1'. 创建文件夹'%1'失败。 - + Save new project as - + Folder %1 is not empty. 文件夹%1不是空的。 - + Do you really want to delete it? 你真的要删除它吗? - + Change working folder 改变工作文件夹 - + File '%1' is not in the current working folder. File '%1' is not in the current working folder 文件'%1'不在当前工作文件夹中。 - + Do you want to change working folder to '%1'? 是否将工作文件夹改设为'%1'? @@ -6834,28 +6838,28 @@ Are you really want to continue? 正在删除试题... - + Can't Commit 无法提交 - + Git needs user info to commit. Git需要用信息进行提交。 - + Choose Input Data File 选择输入数据文件 - - + + All files (*.*) 所有文件 (*.*) - + Choose Expected Output Data File Choose Expected Input Data File 选择期望输出文件 @@ -6867,59 +6871,59 @@ Are you really want to continue? - + Choose Working Folder 选择工作文件夹 - - + + Header Exists 头文件已存在 - - + + Header file "%1" already exists! 头文件"%1"已存在! - + Source Exists 源文件已存在! - + Source file "%1" already exists! 源文件"%1"已存在! - + Can't commit! 无法提交! - + The following files are in conflicting: 下列文件处于冲突状态,请解决后重新添加和提交: - + Commit Message 提交信息 - + Commit Message: 提交信息: - + Commit Failed 提交失败 - + Commit message shouldn't be empty! 提交信息不能为空! @@ -6928,22 +6932,22 @@ Are you really want to continue? 小熊猫Dev-C++项目文件 (*.dev) - + New project fail 新建项目失败 - + Can't assign project template 无法使用模板创建项目 - + Remove file 删除文件 - + Remove the file from disk? 同时从硬盘上删除文件? @@ -6952,27 +6956,27 @@ Are you really want to continue? 无标题 - + New Project File Name 新的项目文件名 - + File Name: 文件名: - + File Already Exists! 文件已存在! - + File '%1' already exists! 文件'%1'已经存在! - + Add to project 添加到项目 @@ -6989,12 +6993,12 @@ Are you really want to continue? 请在工具栏中选择Debug编译器配置集,或者在“编译器配置集”设置的“编译/链接选项”页中<b>启用</b>“生成调试信息(-g3)”、<b>禁用</b>“剥除附件信息(-3)”。 - + C/C++ Source Files (*.c *.cpp *.cc *.cxx) C/C++源代码文件 (*.c *.cpp *.cc *.cxx) - + This operation will remove all cases for the current problem. 本操作会删除此试题的所有案例。 @@ -7003,7 +7007,7 @@ Are you really want to continue? 调试失败 - + The executable doesn't have symbol table, and can't be debugged. 可执行文件中没有符号表信息,无法调试。 @@ -7028,88 +7032,88 @@ Are you really want to continue? 您也可以删除所有断点,打开“CPU信息窗口”,然后调试汇编代码。 - + Failed to generate the executable. 未能生成可执行文件。 - + Please check detail info in "Tools Output" panel. 请查看“工具输出”面板中的详细信息。 - + Red Panda C++ project file (*.dev) 小熊猫C++项目文件(*.dev) - + Rename Error 重命名出错 - + Symbol '%1' is defined in system header. 符号'%1'在系统头文件中定义,无法修改。 - + New Name 新名称 - - - - + + + + Replace Error 替换出错 - + Can't open file '%1' for replace! 无法打开文件'%1'进行替换! - + Contents has changed since last search! 内容和上次查找时不一致。 - + Rich Text Format Files (*.rtf) RTF格式文件 (*.rtf) - + HTML Files (*.html) HTML文件 (*.html) - + The current problem set is not empty. 当前的试题集不是空的。 - + Problem %1 试题%1 - - + + Problem Set Files (*.pbs) 试题集文件 (*.pbs) - - + + Load Error 载入失败 - - + + Problem Case %1 试题案例%1 @@ -7120,14 +7124,14 @@ Are you really want to continue? - - - - - - - - + + + + + + + + Error 错误 @@ -7152,8 +7156,8 @@ Are you really want to continue? 编译生成的可执行文件中没有符号表,无法被调试。 - - + + Version Control 版本控制 @@ -7162,87 +7166,87 @@ Are you really want to continue? 请在工具栏中选用Debug编译器配置集,或者在选项对话框的编辑器配置集页中勾选“生成调试信息(-g3)"选项。 - + File '%1' was changed. 磁盘文件'%1'已被修改。 - + Reload its content from disk? 是否重新读取它的内容? - + File '%1' was removed. 磁盘文件'%1'已被删除。 - + Keep it open? 是否保持它在小熊猫C++中打开的编辑窗口? - + Open 打开 - - + + Compile Failed 编译失败 - + Run Failed 运行失败 - - - - + + + + Confirm Convertion 确认转换 - - - + + + If you are using the Release compiler set, please use choose the Debug version from toolbar. 如果你正在使用Release版的编译器设置集,请在工具栏中将其改为Debug版本。 - - - - + + + + The editing file will be saved using %1 encoding. <br />This operation can't be reverted. <br />Are you sure to continue? 当前编辑器中的文件将会使用%1编码保存。<br />这项操作无法被撤回。<br />你确定要继续吗? - + New Watch Expression 新监视表达式 - + Enter Watch Expression (it is recommended to use 'this->' for class members): 输入监视表达式 - + Parsing file %1 of %2: "%3" (%1/%2)正在解析文件"%3" - - + + Done parsing %1 files in %2 seconds 完成%1个文件的解析,用时%2秒 - + (%1 files per second) (每秒%1个文件) @@ -7250,17 +7254,17 @@ Are you really want to continue? MemoryModel - + addr: %1 地址: %1 - + dec: %1 十进制: %1 - + oct: %1 八进制: %1 @@ -7269,12 +7273,12 @@ Are you really want to continue? 16进制: %1 - + bin: %1 二进制: %1 - + ascii: '%1' ASCII字符: '%1' @@ -8583,13 +8587,13 @@ Are you really want to continue? QObject - + Save 保存 - + Save changes to %1? 将修改保存到"%1"? @@ -9279,12 +9283,12 @@ Are you really want to continue? 无标题 - + constructor 构造函数 - + destructor 析构函数 @@ -9339,63 +9343,9 @@ Are you really want to continue? RegisterModel - - - - - - - - - - - - - - - - - - - - - - - - - - 64-bit - 64位 - - - Accumulator - 累加器 - - - - - - - - - - - - - - - - - - - General purpose - 通用 - - - Instruction Pointer - 指令 - - + + + @@ -9410,13 +9360,47 @@ Are you really want to continue? - - - - 32-bit - 32位 + + + + + + + + + 64-bit + 64位 + Accumulator + 累加器 + + + + + + + + + + + + + + + + + + + General purpose + 通用 + + + Instruction Pointer + 指令 + + + @@ -9433,11 +9417,11 @@ Are you really want to continue? - - lower 16 bits of %1 - %1的低16位 + 32-bit + 32位 + @@ -9454,24 +9438,44 @@ Are you really want to continue? - lower 8 bits of %1 - %1的低8位 + lower 16 bits of %1 + %1的低16位 - 8 high bits of lower 16 bits of %1 - %1的低16位数据中的高8位 - - + + + + + + + lower 8 bits of %1 + %1的低8位 + + + + + + + 8 high bits of lower 16 bits of %1 + %1的低16位数据中的高8位 + + + + + + + + 16-bit 16位 @@ -9484,160 +9488,6 @@ Are you really want to continue? 媒体 - - - - - - - - - - - - - - - - 128-bit - 128位 - - - - Floating-point control - 浮点运算控制 - - - - - Accumulator for operands and results data - 操作数和结果的累加器 - - - - - Pointer to data in the DS segment - 指向DS段中数据的指针 - - - - - Counter for string and loop operations - 字符串和循环操作计数器 - - - - - I/O pointer - I/O指针 - - - - - Source index for string operations; Pointer to data in the segment pointed to by the DS register - 字符串操作来源下标;指向DS段中数据的指针 - - - - - Destination index for string operations; Pointer to data (or destination) in the segment pointed to by the ES register - 字符串操作目的下标;指向ES段中数据(或目标)的指针 - - - - - Stack pointer (in the SS segment) - 栈指针(在SS段中) - - - - - Pointer to data on the stack (in the SS segment) - 指向(SS段中)栈内数据的指针 - - - - - Instruction pointer - 指令指针 - - - - - Flags - 标志 - - - - Code segment selector - 代码段选择器 - - - - Data segment selector - 数据段选择器 - - - - - - Extra data segment selector - 额外的数据段选择器 - - - - Stack segment selector - 栈段选择器 - - - - - - - - - - - Floating-point data - 浮点运算数据 - - - - Floating-point status - 浮点运算状态 - - - - Floating-point tag word - 浮点运算标签word - - - - Floating-point operation - 浮点运算操作 - - - - Floating-point last instruction segment - 浮点运算上次指令段 - - - - Floating-point last instruction offset - 浮点运算上次指令位移 - - - - Floating-point last operand segment - 浮点运算上次操作数段 - - - - Floating-point last operand offset - 浮点运算上次操作数位移 - - - @@ -9652,21 +9502,175 @@ Are you really want to continue? + + 128-bit + 128位 + + + + Floating-point control + 浮点运算控制 + + + + + Accumulator for operands and results data + 操作数和结果的累加器 + + + + + Pointer to data in the DS segment + 指向DS段中数据的指针 + + + + + Counter for string and loop operations + 字符串和循环操作计数器 + + + + + I/O pointer + I/O指针 + + + + + Source index for string operations; Pointer to data in the segment pointed to by the DS register + 字符串操作来源下标;指向DS段中数据的指针 + + + + + Destination index for string operations; Pointer to data (or destination) in the segment pointed to by the ES register + 字符串操作目的下标;指向ES段中数据(或目标)的指针 + + + + + Stack pointer (in the SS segment) + 栈指针(在SS段中) + + + + + Pointer to data on the stack (in the SS segment) + 指向(SS段中)栈内数据的指针 + + + + + Instruction pointer + 指令指针 + + + + + Flags + 标志 + + + + Code segment selector + 代码段选择器 + + + + Data segment selector + 数据段选择器 + + + + + + Extra data segment selector + 额外的数据段选择器 + + + + Stack segment selector + 栈段选择器 + + + + + + + + + + + Floating-point data + 浮点运算数据 + + + + Floating-point status + 浮点运算状态 + + + + Floating-point tag word + 浮点运算标签word + + + + Floating-point operation + 浮点运算操作 + + + + Floating-point last instruction segment + 浮点运算上次指令段 + + + + Floating-point last instruction offset + 浮点运算上次指令位移 + + + + Floating-point last operand segment + 浮点运算上次操作数段 + + + + Floating-point last operand offset + 浮点运算上次操作数位移 + + + + + + + + + + + + + + + + + 256-bit 256位 - + SSE status and control SSE状态和控制 - + Register 寄存器 - + Value @@ -10327,18 +10331,18 @@ Are you really want to continue? 性能 - - - - + + + + Compiler Set 编译器配置集 - - + + Compiler @@ -10350,7 +10354,7 @@ Are you really want to continue? 自动链接 - + @@ -10426,15 +10430,15 @@ Are you really want to continue? 杂项 - - + + Program Runner 程序运行 - + Problem Set 试题集 @@ -10493,8 +10497,8 @@ Are you really want to continue? 项目选项 - - + + @@ -10974,14 +10978,14 @@ Are you really want to continue? JSON文件'%1':%2中存在错误:%3 - - + + Execute to evaluate 执行以求值 - - + + Not Valid 在当前作用域中无效 @@ -10990,17 +10994,17 @@ Are you really want to continue? 无法读取文件'%1'. - + Expression 表达式 - + Type 类型 - + Value diff --git a/RedPandaIDE/translations/RedPandaIDE_zh_TW.ts b/RedPandaIDE/translations/RedPandaIDE_zh_TW.ts index ef610e65..8a691785 100644 --- a/RedPandaIDE/translations/RedPandaIDE_zh_TW.ts +++ b/RedPandaIDE/translations/RedPandaIDE_zh_TW.ts @@ -161,10 +161,6 @@ CPU Info - - Disassemble - - Step over one machine instruction @@ -185,6 +181,10 @@ Blend Mode + + Callstack + + ChooseThemeDialog diff --git a/RedPandaIDE/widgets/cpudialog.ui b/RedPandaIDE/widgets/cpudialog.ui index 27bfa6f0..34e1980b 100644 --- a/RedPandaIDE/widgets/cpudialog.ui +++ b/RedPandaIDE/widgets/cpudialog.ui @@ -66,10 +66,41 @@ 0 + + + + Step over one machine instruction + + + Step over one machine instruction + + + + :/icons/images/newlook24/052-next.png:/icons/images/newlook24/052-next.png + + + Qt::ToolButtonIconOnly + + + + + + + Step into one machine instruction + + + Step into one machine instruction + + + + :/icons/images/newlook24/040-goto.png:/icons/images/newlook24/040-goto.png + + + - Disassemble + Callstack @@ -120,37 +151,6 @@ 0 - - - - Step over one machine instruction - - - Step over one machine instruction - - - - :/icons/images/newlook24/052-next.png:/icons/images/newlook24/052-next.png - - - Qt::ToolButtonIconOnly - - - - - - - Step into one machine instruction - - - Step into one machine instruction - - - - :/icons/images/newlook24/040-goto.png:/icons/images/newlook24/040-goto.png - - - diff --git a/platform/windows/installer-scripts/config.nsh.in b/platform/windows/installer-scripts/config.nsh.in index ec053f88..b4ed0b2b 100644 --- a/platform/windows/installer-scripts/config.nsh.in +++ b/platform/windows/installer-scripts/config.nsh.in @@ -1,6 +1,6 @@ #################################################################### # Startup -!define COMPILERNAME \"MinGW-w64 X86_64 GCC 11.4\" +!define COMPILERNAME \"MinGW-w64 X86_64 GCC 13.1\" !define DEVCPP_VERSION \"$${APP_VERSION}\"