bruvzg
f19cd44346
Unify TextServer built-in module and GDExtension code.
2022-03-17 08:15:29 +02:00
kobewi
2057ea2883
Remove duplicate editor settings definitions
2022-03-06 22:05:49 +01:00
Hugo Locurcio
a06f82ca4d
Add optional constructor arguments to more Control nodes
...
This can be used to make editor code more compact.
However, as of writing, these constructor arguments cannot be used
from the scripting API.
This was already provided for Label and CheckBox, but it was missing
for other Control nodes where it made sense to provide a default value.
2022-03-04 09:48:41 +01:00
Hugo Locurcio
816d332e51
Fix LineEdit and TextEdit carets disappearing at theme scales below 1.0
...
This fixes carets disappearing in the editor when the Editor Scale
setting is set below 100%.
2022-03-03 00:15:48 +01:00
Rémi Verschelde
0f5455230c
Use `switch` consistently in `_notification` (`scene` folder)
2022-02-15 18:44:55 +01:00
bruvzg
29199579f7
Add sub-pixel glyph positioning support.
2022-02-12 19:55:52 +02:00
Paulb23
1cd1df5dc3
Move placeholder color to theme item
2022-01-30 17:56:23 +00:00
bruvzg
40c56ed410
Improve locale detection.
...
Use separate language, script and country lists.
Add locale selection dialog and property hint.
2022-01-18 14:30:00 +02:00
Rémi Verschelde
f6792eacf5
Merge pull request #54956 from Calinou/lineedit-textedit-add-caret-width-theme-item
...
Add a theme constant to change LineEdit and TextEdit's caret width
2022-01-13 09:21:01 +01:00
bruvzg
c89c515ccf
[TextServer] Improve ligature cursor handling.
...
Fix mid-grapheme hit test.
Fix OpenType features property handling, add default features override option.
Enable mid-grapheme cursor by default.
2022-01-09 19:03:48 +02:00
Hugo Locurcio
f6443beade
Add a theme constant to change LineEdit and TextEdit's caret width
...
This can be useful to improve caret visibility, especially at
larger font sizes. This can also be used for accessibility purposes.
2022-01-07 20:51:22 +01:00
Rémi Verschelde
fe52458154
Update copyright statements to 2022
...
Happy new year to the wonderful Godot community!
2022-01-03 21:27:34 +01:00
Nathan Franke
49403cbfa0
Replace String comparisons with "", String() to is_empty()
...
Also:
- Adds two stress tests to test_string.h
- Changes to .empty() on std::strings
2021-12-09 04:48:38 -06:00
Nathan Franke
41a20171eb
align to horizontal_alignment, valign to vertical_alignment, related
2021-12-09 01:38:46 -06:00
Rémi Verschelde
75ac048e4b
Merge pull request #55662 from KoBeWi/update_minimum_size_changed_to_update_minimum_size
2021-12-06 18:28:46 +01:00
jmb462
81efebb3a1
Fix bad popups offset in editor with single window off
...
Co-authored-by: Gil Arasa Verge <gilarasaverge@gmail.com>
Co-authored-by: Tomasz Chabora <kobewi4e@gmail.com>
2021-12-06 14:29:48 +01:00
kobewi
ea7cc1dea9
Rename minimum_size_changed() method
2021-12-06 14:02:34 +01:00
ConteZero
0699941f07
Add drag and drop to TextEdit
2021-12-02 22:00:07 +01:00
Rémi Verschelde
76aa1d0a43
Merge pull request #55151 from Chaosus/control_reset_size
2021-11-22 16:22:57 +01:00
Yuri Roubinsky
eabf8f5edf
Added `reset_size` method to `Control` and `Window` classes
2021-11-22 16:55:21 +03:00
ConteZero
2b1787b446
Fix drag and drop on LineEdit
2021-11-15 17:10:56 +01:00
Aaron Franke
3c0fdcc8ac
Use "enum class" for input enums
2021-11-12 15:37:54 -06:00
Rémi Verschelde
2beaae4b6f
String: Remove `erase` method, bindings can't mutate String
2021-11-11 11:23:32 +01:00
Rémi Verschelde
d9a74fd07f
Merge pull request #54372 from bruvzg/text_edit_ui
2021-11-09 00:13:25 +01:00
Hugo Locurcio
c012fbc8b2
Rename `PROPERTY_USAGE_NOEDITOR` to `PROPERTY_USAGE_NO_EDITOR`
...
This is consistent with other constants that include `NO`,
such as `PROPERTY_HINT_COLOR_NO_ALPHA`.
2021-11-03 23:06:17 +01:00
bruvzg
3f33e1d7d6
Add functions for getting name and font style from dynamic and bitmap fonts.
...
Add font selection toolbar editor plugin.
2021-10-31 12:40:58 +02:00
Rémi Verschelde
21529c90f8
Merge pull request #54166 from ConteZero/unique_selection
2021-10-27 20:50:54 +02:00
ConteZero
fbee4efa5f
Add option to make selection unique
2021-10-27 19:45:52 +02:00
Rémi Verschelde
b2ab5cb504
Merge pull request #54045 from ConteZero/primary_clipboard_linux_fix_warning
2021-10-23 19:13:34 +02:00
ConteZero
8c48b4a7e0
Fix primary clipboard warning
2021-10-23 15:50:01 +02:00
Hugo Locurcio
abbc8facc6
Use TitleCase for CTL dialog menu options
...
This is more consistent with other actions exposed in the dialog.
2021-10-21 17:47:39 +02:00
ConteZero
838c9d37b4
Added primary clipboard for Linux
2021-10-18 14:01:06 +02:00
bruvzg
19a0982d60
Fix inline IME input not working in the empty LineEdit with the placeholder.
2021-10-11 08:21:34 +03:00
Yuri Sizov
bdbb7b3999
Remove EDSCALE dependency from /scene/gui
2021-10-04 15:25:08 +03:00
bruvzg
0c0b5c84b0
Implement TextServer GDExtension interface, remove TextServer GDNative interface.
2021-10-01 15:13:29 +03:00
Rémi Verschelde
6c0f44ca7e
Merge pull request #53000 from Chaosus/lineedit_expose_selection_methods
2021-09-29 10:31:37 +02:00
jmb462
3f0fe0b8a3
Fix LineEdit and TextEdit double-click and triple-click selection
2021-09-26 19:56:48 +02:00
Yuri Roubinsky
4e0552a4ff
Add selection getter methods to `LineEdit`
2021-09-24 11:30:58 +03:00
Silc 'Tokage' Renew
facf8f1883
Apply set_read_only() to child classes of EditorProperty elements
2021-09-05 18:22:17 +09:00
kobewi
a913ae8d56
Add support for internal nodes
2021-08-28 02:07:23 +02:00
bruvzg
4c3f7d1290
Makes FontData importable resource.
...
Adds multi-channel SDF font texture generation and rendering support.
Adds per-font oversampling support.
Adds FontData import plugins (for dynamic fonts, BMFonts and monospaced image fonts), font texture cache pre-generation and loading.
Adds BMFont binary format and outline support.
2021-08-27 15:43:18 +03:00
reduz
5cecdfa8af
Entirely removes BIND_VMETHOD in favor of GDVIRTUAL
...
* `_gui_input`, `_input`, `_unhandled_input` and `_unhandled_key_input` are now regular C++ virutal functions.
* Everything else converted to GDVIRTUAL
* BIND_VMETHOD is gone, always use the new syntax from now on.
Creating `_gui_input` method and using the binder to register events will no longer work, simply override the virtual function now.
2021-08-23 08:10:13 -03:00
Haoyu Qiu
16c2d4ef22
Improve Undo/Redo menu items
...
* Make Undo/Redo menu items disabled when clicking it does nothing.
* Context menu of `TextEdit`
* Context menu of `LineEdit`
* Editor's Scene menu
* Script editor's Edit menu and context menu (for Script and Text)
* Make editor undo/redo log messages translatable.
* Mark `UndoRedo`'s `has_{un,re}do()` methods as `const`.
* Expose `TextEdit`'s `has_{un,re}do()` to scripts since `{un,re}do()` are already available.
2021-08-17 21:11:10 +08:00
Paulb23
bcfc591f86
Reorganise text editor settings
2021-08-16 17:18:49 +01:00
Michael Alexsander
94a64d557e
Add `auto_translate` toggle for automatic translation
2021-07-29 18:30:34 -03:00
Rémi Verschelde
a0bc2f359d
Merge pull request #50588 from bruvzg/menu_gen
...
Optimize LineEdit and TextEdit menu item generation.
2021-07-19 22:56:53 +02:00
bruvzg
1ac7a126f1
Optimize LineEdit and TextEdit menu item generation.
2021-07-19 08:19:09 +03:00
reduz
6631f66c2a
Optimize StringName usage
...
* Added a new macro SNAME() that constructs and caches a local stringname.
* Subsequent usages use the cached version.
* Since these use a global static variable, a second refcounter of static usages need to be kept for cleanup time.
* Replaced all theme usages by this new macro.
* Replace all signal emission usages by this new macro.
* Replace all call_deferred usages by this new macro.
This is part of ongoing work to optimize GUI and the editor.
2021-07-18 21:20:02 -03:00
reduz
a3fb76cd45
Create many types of popups on demand
...
* LineEdit popups created on demand.
* TextEdit popups created on demand.
* SpinSlider popups created on demand.
* ResourcePicker popups created on demand.
Improves editor responsiveness.
2021-07-17 10:57:14 -03:00
Rémi Verschelde
9a1ce8e6c3
LineEdit: Respect `max_length` by truncating text to append
...
When appending text (either via `set_text()` or by pasting from clipboard),
if the input would make the `LineEdit` exceed its configured `max_length`,
the input text is truncated to fit. The discard part is passed as a parameter
in the `text_change_rejected` signal.
Fixes #33321 .
Fixes #41278 .
Also cleaned up unimplemented `max_chars` property in `TextEdit`.
Co-authored-by: Tony-Goat <70238376+Tony-Goat@users.noreply.github.com>
2021-07-06 18:03:03 +02:00