aboutsummaryrefslogtreecommitdiff
path: root/editor/code_editor.cpp
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--editor/code_editor.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/editor/code_editor.cpp b/editor/code_editor.cpp
index 70334c234..ed4d37c89 100644
--- a/editor/code_editor.cpp
+++ b/editor/code_editor.cpp
@@ -646,12 +646,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();
}