Skip to content

Commit

Permalink
- change: position caret to (1,1) when create a new file using editor…
Browse files Browse the repository at this point in the history
…'s new file template
  • Loading branch information
royqh1979 committed Jun 23, 2022
1 parent b2585f5 commit 5557d9c
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions NEWS.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ Red Panda C++ Version 1.1.2
- fix: select all shouldn't set file's modified flag
- enhancement: add (return)type info for functions/varaibles/typedefs in the class browser panel
- enhancement: autolink add "force utf8" property (mainly for raylib)
- change: position caret to (1,1) when create a new file using editor's new file template

Red Panda C++ Version 1.1.1
- enhancement: adjust the appearance of problem case's input/output/expected control
Expand Down
1 change: 1 addition & 0 deletions RedPandaIDE/editor.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -165,6 +165,7 @@ Editor::Editor(QWidget *parent, const QString& filename,
QString fileTemplate = pMainWindow->codeSnippetManager()->newFileTemplate();
if (!fileTemplate.isEmpty()) {
insertCodeSnippet(fileTemplate);
setCaretPosition(1,1);
mCanAutoSave = true;
}
}
Expand Down

0 comments on commit 5557d9c

Please sign in to comment.