diff options
author | Gilles Roudière <gilles.roudiere@gmail.com> | 2018-05-07 15:06:02 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-05-07 15:06:02 +0200 |
commit | 801657f64e4566d8c9bd86f2f2e70f31637b327f (patch) | |
tree | 43a20c17fbeb9ea86501354f39bcd149a139d332 /editor | |
parent | fb4e9526e80efa2188e0651c2be80fafec01f589 (diff) | |
parent | eeb05344267580a25bc59d3c363537ade363f82e (diff) |
Merge pull request #18628 from raphael10241024/patch
fix : code editor's text size should change at least one each time when you try to change it using shortcuts
Diffstat (limited to 'editor')
-rw-r--r-- | editor/code_editor.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/editor/code_editor.cpp b/editor/code_editor.cpp index 19bcb28fa5..24e86770bf 100644 --- a/editor/code_editor.cpp +++ b/editor/code_editor.cpp @@ -650,12 +650,12 @@ void CodeTextEditor::_text_editor_gui_input(const Ref<InputEvent> &p_event) { } void CodeTextEditor::_zoom_in() { - font_resize_val += EDSCALE; + font_resize_val += MAX(EDSCALE, 1.0f); _zoom_changed(); } void CodeTextEditor::_zoom_out() { - font_resize_val -= EDSCALE; + font_resize_val -= MAX(EDSCALE, 1.0f); _zoom_changed(); } |