Merge pull request #76596 from Calinou/editor-settings-allow-negative-line-spacing

Allow negative line spacing for the script editor in Editor Settings
This commit is contained in:
Thaddeus Crews 2026-02-19 20:29:17 -06:00
commit 230e6bfc3b
No known key found for this signature in database
GPG key ID: 8C6E5FEB5FC03CCC
2 changed files with 2 additions and 2 deletions

View file

@ -1442,7 +1442,7 @@
If [code]true[/code], draws tab characters as chevrons.
</member>
<member name="text_editor/appearance/whitespace/line_spacing" type="int" setter="" getter="">
The space to add between lines (in pixels). Greater line spacing can help improve readability at the cost of displaying fewer lines on screen.
The space to add between lines (in pixels). Greater line spacing can help improve readability at the cost of displaying fewer lines on screen. Negative values allow for even more compact text, but may look broken with certain fonts.
</member>
<member name="text_editor/behavior/documentation/enable_tooltips" type="bool" setter="" getter="">
If [code]true[/code], documentation tooltips will appear when hovering over a symbol.

View file

@ -788,7 +788,7 @@ void EditorSettings::_load_defaults(Ref<ConfigFile> p_extra_config) {
// Appearance: Whitespace
_initial_set("text_editor/appearance/whitespace/draw_tabs", true, true);
_initial_set("text_editor/appearance/whitespace/draw_spaces", false, true);
EDITOR_SETTING(Variant::INT, PROPERTY_HINT_RANGE, "text_editor/appearance/whitespace/line_spacing", 4, "0,50,1")
EDITOR_SETTING(Variant::INT, PROPERTY_HINT_RANGE, "text_editor/appearance/whitespace/line_spacing", 4, "-10,50,1")
// Behavior
// Behavior: General