* @brief Resets the editor to the default painter template. */
| 447 | * @brief Resets the editor to the default painter template. |
| 448 | */ |
| 449 | void DataModel::PainterCodeEditor::reload(bool guiTrigger) |
| 450 | { |
| 451 | Q_UNUSED(guiTrigger) |
| 452 | m_widget.setPlainText(defaultTemplate()); |
| 453 | m_widget.document()->clearUndoRedoStacks(); |
| 454 | m_widget.document()->setModified(false); |
| 455 | Q_EMIT modifiedChanged(); |
| 456 | } |
| 457 | |
| 458 | /** |
| 459 | * @brief Returns the bundled default-template source. |
nothing calls this directly
no test coverage detected