146 Commits

Author SHA1 Message Date
Danil Alexeev
db9b8ff003
CodeEditor: Make possible to select and copy error text 2025-06-12 22:06:09 +02:00
kobewi
c32a031908 Improve auto-translation of Script Editor 2025-06-04 14:41:15 +02:00
Thaddeus Crews
f6a56c112f
Merge pull request #106500 from Frozenfire92/global-find-in-files
Make FindInFiles globally accessible
2025-05-26 11:24:20 -05:00
Joel Kuntz
2cf64cc971 Make FindInFiles globally accessible
- Make ScriptEditor expose open_find_in_files_dialog to allow opening from anywhere
- Add FindInFiles to EditorNode as a keyboard shortcut, command, and menu option
- Change all find_in_files commands to be editor/find_in_files
2025-05-23 19:19:16 -03:00
Jorge Korgut Junior
77e6d92357 Fix highlighting warning and error issues related to Godot editor.
Fix Issue #104413 : Add a limit of 20 lines of warning highlight otherwise paint the background of the first line only.
Fix Issue #106278 : Extract the logic from clearing and setting background lines from _update_errors() and _update_warnings() to _update_background_text().
Fix Issue #83979 : Added signal for folding/unfolding lines (fold_lines_updated).
Feature: Highlight the folded line using signals connected to _update_background_text() to keep the editor visuals up to date. The background is set in the following priority order: Error, Warning, then Highlight background.
2025-05-20 10:03:39 +02:00
Hugo Locurcio
e8eeccebcb
Unify Scripts Panel naming for the script and shader editors
Both use the same shortcut and action, so it makes sense to call it
a Files panel as opposed to a Scripts panel.
2025-04-09 01:17:36 +02:00
Yufeng Ying
4f4031a675 Replace size() == 0 with is_empty(). 2025-04-02 19:18:43 +08:00
Thaddeus Crews
6fdf91cc2f
Merge pull request #101616 from KoBeWi/how_was_it_even_functional
Rework script external modification tracking
2025-01-26 11:49:20 -06:00
kobewi
b761ff662e Rework script external modification tracking 2025-01-16 01:03:26 +01:00
Adam Scott
33e16435f5
Replace some problematic uses of String::num to String::num_int64 2025-01-15 12:51:51 -05:00
Pāvels Nadtočajevs
b252867145 [macOS/Windows] Add Emoji & Symbols context menu item to LineEdit/TextEdit to show system character picker. 2025-01-10 09:25:34 +02:00
Thaddeus Crews
98c5267ce5
Merge pull request #91388 from kitbdev/fix-goto-line
Make Goto line a Popup and column input
2024-12-23 11:15:12 -06:00
Yufeng Ying
f241c1fda0 Remove unused header in editor.
Co-authored-by: A Thousand Ships <96648715+AThousandShips@users.noreply.github.com>
2024-12-24 00:40:38 +08:00
kit
f41cd8ad52 Make Goto line a Popup and allow column input 2024-10-31 10:11:46 -04:00
A Thousand Ships
194bdde947
Cleanup of raw nullptr checks with Ref
Using `is_valid/null` over checks with `nullptr` or `ERR_FAIL_NULL` etc.
2024-08-31 15:01:09 +02:00
kobewi
b4c92dbd0e Refactor toggling script list 2024-08-28 17:00:51 +02:00
kit
06b17a4d2f Fix goto line issues in code editor 2024-07-31 10:34:10 -04:00
A Thousand Ships
755a0efbb6
[Scene] Add SceneStringNames::id_pressed 2024-05-30 22:54:04 +02:00
Rémi Verschelde
838eb5a0fd
Merge pull request #87099 from bitwise-aiden/ba-add-trim-newlines
Implement `trim_final_newlines` setting and functionality
2024-05-30 11:47:28 +02:00
kobewi
e065d7132a Remove duplicate shortcut definitions 2024-05-21 23:28:49 +02:00
kobewi
413c11357d Use Core/Scene stringnames consistently 2024-05-13 23:41:07 +02:00
Aiden Storey
b4c1634b52 Implement trim_final_newlines functionality 2024-05-02 22:57:34 -04:00
kit
773a473807 Overhaul multiple caret editing in TextEdit.
Use a multicaret edit to delay merging overlapping carets until the end.
2024-04-26 14:26:10 -04:00
kit
154f727c7a Overhaul TextEdit selection.
The caret is now a part of the selection.
2024-04-26 14:24:10 -04:00
Muller-Castro
1638c1b28f Add const lvalue ref to editor/* container parameters 2024-02-26 15:28:15 -03:00
kobewi
aeec3c1309 Add methods to add submenus without using names 2024-02-22 15:13:53 +01:00
Zi Ye
9281c441f6 Improved text editor status bar and zooming UX. 2024-02-21 17:33:16 -06:00
kit
a6af442b05 Apply TextEdit IME on most actions 2024-01-29 15:07:19 -05:00
A Thousand Ships
15369fdb1d
Remove unnecessary this-> expressions 2024-01-29 09:59:18 +01:00
Adam Scott
12c84836b7
Make the text editor consistent with the script editor 2024-01-23 11:27:00 -05:00
kobewi
0e8f90f4c8 Update deferred calls to use Callables 2024-01-09 16:11:47 +01:00
Yuri Sizov
b04b546092 Fix node names of submenu items across the editor
Also removes some programmer remarks and fixes some docs.
2023-11-08 14:42:42 +01:00
PucklaMotzer09
d2e651f403 Add Duplicate Lines shortcut to CodeTextEditor
This keyboard shortcut has been made with inspiration from the VS Code keyboard shortcut editor.action.copyLinesDownAction. It duplicates all selected lines and inserts them below no matter where the caret is within the line.
2023-09-25 23:41:31 +02:00
lawnjelly
b69c8b4791 Single Compilation Unit build.
Adds support for simple SCU build (DEV_ENABLED only).
This speeds up compilation by compiling multiple cpp files within a single translation unit.
2023-06-06 15:36:51 +01:00
Paulb23
0b3fba45c6 Move convert_indent into CodeEdit 2023-05-07 13:08:37 +01:00
kobewi
ff310f0969 Add shortcut for quick-toggling word wrap 2023-04-19 23:46:22 +02:00
kobewi
5906d6de8e Fix line folding with multiple carets 2023-02-21 21:28:26 +01:00
Paulb23
a197d6ef4e Support editing JSON in ScriptEditor 2023-01-28 16:06:13 +00:00
kobewi
59ea36b87c Remove set_drag_forwarding_compat() 2023-01-14 15:16:51 +01:00
Juan Linietsky
e6a4debede Change set_drag_forwarding() to use callables.
* This solution is much cleaner than the one in 3.x thanks to the use of callables.
* Works without issues in any language (no need to worry about camel or snake case).
* Editor code uses a compatibility function (too much work to redo).

Fixes #59899
2023-01-10 14:09:24 +01:00
Rémi Verschelde
d95794ec8a
One Copyright Update to rule them all
As many open source projects have started doing it, we're removing the
current year from the copyright notice, so that we don't need to bump
it every year.

It seems like only the first year of publication is technically
relevant for copyright notices, and even that seems to be something
that many companies stopped listing altogether (in a version controlled
codebase, the commits are a much better source of date of publication
than a hardcoded copyright statement).

We also now list Godot Engine contributors first as we're collectively
the current maintainers of the project, and we clarify that the
"exclusive" copyright of the co-founders covers the timespan before
opensourcing (their further contributions are included as part of Godot
Engine contributors).

Also fixed "cf." Frenchism - it's meant as "refer to / see".
2023-01-05 13:25:55 +01:00
VolTer
94416e41c5 Fix various fringe issues with multi-carets and selections 2022-12-07 20:54:48 +01:00
trollodel
c90d0bd84f Use forward-declarations in big editor classes 2022-11-29 09:59:43 +01:00
Rémi Verschelde
5947f22be9
Merge pull request #67578 from KoBeWi/GEDITOR
Unify usage of GLOBAL/EDITOR_GET
2022-10-31 13:15:58 +01:00
Eric M
d499071e5b Set the shortcut context for the edit/search/goto menus to the ScriptEditor so that shortcuts continue to work when FindReplaceBar is focused. 2022-10-25 19:52:42 +10:00
kobewi
e48c5daddf Unify usage of GLOBAL/EDITOR_GET 2022-10-18 19:01:48 +02:00
Rémi Verschelde
f5903215d0 Merge pull request #61902 from Paulb23/multi-caret
Add Multi-caret support to TextEdit
2022-10-06 08:56:34 +02:00
Paulb23
0cbe176ce6 Add multi caret support to Editor 2022-10-05 17:19:26 +01:00
Rémi Verschelde
121e1df55b Merge pull request #66300 from KoBeWi/📝🧭
Split script navigation state and edit state
2022-10-05 08:30:49 +02:00
Rindbee
72a7d874b4 Fix the flickering of the line gutter icon when saving 2022-10-03 19:19:28 +08:00