Update(blocks): python新增plot_cla图形块,多语言将在稳定后进行

This commit is contained in:
王立帮
2024-09-17 19:43:20 +08:00
parent b9c1be61a0
commit 07ce56952a
5 changed files with 682 additions and 77 deletions

View File

@@ -175,6 +175,9 @@ class PythonShell {
if (code.indexOf('import turtle') !== -1) {
code += '\nturtle.done()\n';
}
if (code.indexOf('import matplotlib.pyplot') !== -1) {
code += '\nplt.clf()\n';
}
this.#statusBarsManager_.changeTo('output');
this.#statusBarsManager_.show();
this.#statusBarTerminal_.setValue(`${Msg.Lang['shell.running']}...\n`);