You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-12-06 17:25:19 +00:00
Add new monospace related hint strings
- Add hint string `monospace` for `PROPERTY_HINT_{NONE,PASSWORD,PLACEHOLDER_TEXT}` to set the `LineEdit` font monospaced.
- Add hint string `monospace` for `PROPERTY_HINT_MULTILINE_TEXT` to set the `TextEdit` font monospaced.
- Add hint string `no_wrap` for `PROPERTY_HINT_MULTILINE_TEXT` to make the `TextEdit` not wrap lines automatically.
Also:
- Fix issue with `EditorPropertyMultilineText` not updating font properly.
- Add `EditorPropertyMultilineText` tweak flags.
- Add support with GDScript `@export_multiline`.
This commit is contained in:
@@ -2837,6 +2837,8 @@
|
||||
</constant>
|
||||
<constant name="PROPERTY_HINT_MULTILINE_TEXT" value="18" enum="PropertyHint">
|
||||
Hints that a [String] property is text with line breaks. Editing it will show a text input field where line breaks can be typed.
|
||||
The hint string can be set to [code]"monospace"[/code] to force the input field to use a monospaced font.
|
||||
If the hint string [code]"no_wrap"[/code] is set, the input field will not wrap lines at boundaries, instead resorting to making the area scrollable.
|
||||
</constant>
|
||||
<constant name="PROPERTY_HINT_EXPRESSION" value="19" enum="PropertyHint">
|
||||
Hints that a [String] property is an [Expression].
|
||||
|
||||
@@ -263,7 +263,7 @@ void EditorExportPlatformAppleEmbedded::get_export_options(List<ExportOption> *r
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "application/short_version", PROPERTY_HINT_PLACEHOLDER_TEXT, "Leave empty to use project version"), ""));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "application/version", PROPERTY_HINT_PLACEHOLDER_TEXT, "Leave empty to use project version"), ""));
|
||||
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "application/additional_plist_content", PROPERTY_HINT_MULTILINE_TEXT), ""));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "application/additional_plist_content", PROPERTY_HINT_MULTILINE_TEXT, "monospace,no_wrap"), ""));
|
||||
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::INT, "application/icon_interpolation", PROPERTY_HINT_ENUM, "Nearest neighbor,Bilinear,Cubic,Trilinear,Lanczos"), 4));
|
||||
|
||||
@@ -302,7 +302,7 @@ void EditorExportPlatformAppleEmbedded::get_export_options(List<ExportOption> *r
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::BOOL, "entitlements/increased_memory_limit"), false));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::BOOL, "entitlements/game_center"), false));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "entitlements/push_notifications", PROPERTY_HINT_ENUM, "Disabled,Production,Development"), "Disabled"));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "entitlements/additional", PROPERTY_HINT_MULTILINE_TEXT), ""));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "entitlements/additional", PROPERTY_HINT_MULTILINE_TEXT, "monospace,no_wrap"), ""));
|
||||
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::BOOL, "capabilities/access_wifi"), false));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::BOOL, "capabilities/performance_gaming_tier"), false));
|
||||
|
||||
@@ -55,6 +55,7 @@
|
||||
#include "scene/3d/gpu_particles_3d.h"
|
||||
#include "scene/gui/color_picker.h"
|
||||
#include "scene/gui/grid_container.h"
|
||||
#include "scene/gui/text_edit.h"
|
||||
#include "scene/main/window.h"
|
||||
#include "scene/resources/font.h"
|
||||
#include "scene/resources/mesh.h"
|
||||
@@ -157,10 +158,34 @@ EditorPropertyVariant::EditorPropertyVariant() {
|
||||
|
||||
///////////////////// TEXT /////////////////////////
|
||||
|
||||
void EditorPropertyText::_notification(int p_what) {
|
||||
switch (p_what) {
|
||||
case NOTIFICATION_THEME_CHANGED: {
|
||||
_update_theme();
|
||||
} break;
|
||||
}
|
||||
}
|
||||
|
||||
void EditorPropertyText::_set_read_only(bool p_read_only) {
|
||||
text->set_editable(!p_read_only);
|
||||
}
|
||||
|
||||
void EditorPropertyText::_update_theme() {
|
||||
Ref<Font> font;
|
||||
int font_size;
|
||||
|
||||
if (monospaced) {
|
||||
font = get_theme_font(SNAME("source"), EditorStringName(EditorFonts));
|
||||
font_size = get_theme_font_size(SNAME("source_size"), EditorStringName(EditorFonts));
|
||||
} else {
|
||||
font = get_theme_font(SceneStringName(font), SNAME("LineEdit"));
|
||||
font_size = get_theme_font_size(SceneStringName(font_size), SNAME("LineEdit"));
|
||||
}
|
||||
|
||||
text->add_theme_font_override(SceneStringName(font), font);
|
||||
text->add_theme_font_size_override(SceneStringName(font_size), font_size);
|
||||
}
|
||||
|
||||
void EditorPropertyText::_text_submitted(const String &p_string) {
|
||||
if (updating) {
|
||||
return;
|
||||
@@ -227,6 +252,14 @@ void EditorPropertyText::set_placeholder(const String &p_string) {
|
||||
text->set_placeholder(p_string);
|
||||
}
|
||||
|
||||
void EditorPropertyText::set_monospaced(bool p_monospaced) {
|
||||
if (p_monospaced == monospaced) {
|
||||
return;
|
||||
}
|
||||
monospaced = p_monospaced;
|
||||
_update_theme();
|
||||
}
|
||||
|
||||
EditorPropertyText::EditorPropertyText() {
|
||||
HBoxContainer *hb = memnew(HBoxContainer);
|
||||
add_child(hb);
|
||||
@@ -265,11 +298,11 @@ void EditorPropertyMultilineText::_open_big_text() {
|
||||
big_text = memnew(TextEdit);
|
||||
if (expression) {
|
||||
big_text->set_syntax_highlighter(text->get_syntax_highlighter());
|
||||
big_text->add_theme_font_override(SceneStringName(font), get_theme_font(SNAME("expression"), EditorStringName(EditorFonts)));
|
||||
big_text->add_theme_font_size_override(SceneStringName(font_size), get_theme_font_size(SNAME("expression_size"), EditorStringName(EditorFonts)));
|
||||
}
|
||||
big_text->connect(SceneStringName(text_changed), callable_mp(this, &EditorPropertyMultilineText::_big_text_changed));
|
||||
big_text->set_line_wrapping_mode(TextEdit::LineWrappingMode::LINE_WRAPPING_BOUNDARY);
|
||||
big_text->set_line_wrapping_mode(wrap_lines
|
||||
? TextEdit::LineWrappingMode::LINE_WRAPPING_BOUNDARY
|
||||
: TextEdit::LineWrappingMode::LINE_WRAPPING_NONE);
|
||||
big_text_dialog = memnew(AcceptDialog);
|
||||
big_text_dialog->add_child(big_text);
|
||||
big_text_dialog->set_title(TTR("Edit Text:"));
|
||||
@@ -279,6 +312,8 @@ void EditorPropertyMultilineText::_open_big_text() {
|
||||
big_text_dialog->popup_centered_clamped(Size2(1000, 900) * EDSCALE, 0.8);
|
||||
big_text->set_text(text->get_text());
|
||||
big_text->grab_focus();
|
||||
|
||||
_update_theme();
|
||||
}
|
||||
|
||||
void EditorPropertyMultilineText::update_property() {
|
||||
@@ -292,9 +327,7 @@ void EditorPropertyMultilineText::update_property() {
|
||||
}
|
||||
}
|
||||
|
||||
void EditorPropertyMultilineText::_notification(int p_what) {
|
||||
switch (p_what) {
|
||||
case NOTIFICATION_THEME_CHANGED: {
|
||||
void EditorPropertyMultilineText::_update_theme() {
|
||||
Ref<Texture2D> df = get_editor_theme_icon(SNAME("DistractionFree"));
|
||||
open_big_text->set_button_icon(df);
|
||||
|
||||
@@ -303,23 +336,66 @@ void EditorPropertyMultilineText::_notification(int p_what) {
|
||||
if (expression) {
|
||||
font = get_theme_font(SNAME("expression"), EditorStringName(EditorFonts));
|
||||
font_size = get_theme_font_size(SNAME("expression_size"), EditorStringName(EditorFonts));
|
||||
|
||||
text->add_theme_font_override(SceneStringName(font), font);
|
||||
text->add_theme_font_size_override(SceneStringName(font_size), font_size);
|
||||
if (big_text) {
|
||||
big_text->add_theme_font_override(SceneStringName(font), font);
|
||||
big_text->add_theme_font_size_override(SceneStringName(font_size), font_size);
|
||||
}
|
||||
} else {
|
||||
// Non expression.
|
||||
if (monospaced) {
|
||||
font = get_theme_font(SNAME("source"), EditorStringName(EditorFonts));
|
||||
font_size = get_theme_font_size(SNAME("source_size"), EditorStringName(EditorFonts));
|
||||
} else {
|
||||
font = get_theme_font(SceneStringName(font), SNAME("TextEdit"));
|
||||
font_size = get_theme_font_size(SceneStringName(font_size), SNAME("TextEdit"));
|
||||
}
|
||||
}
|
||||
text->add_theme_font_override(SceneStringName(font), font);
|
||||
text->add_theme_font_size_override(SceneStringName(font_size), font_size);
|
||||
text->set_line_wrapping_mode(wrap_lines
|
||||
? TextEdit::LineWrappingMode::LINE_WRAPPING_BOUNDARY
|
||||
: TextEdit::LineWrappingMode::LINE_WRAPPING_NONE);
|
||||
if (big_text) {
|
||||
big_text->add_theme_font_override(SceneStringName(font), font);
|
||||
big_text->add_theme_font_size_override(SceneStringName(font_size), font_size);
|
||||
big_text->set_line_wrapping_mode(wrap_lines
|
||||
? TextEdit::LineWrappingMode::LINE_WRAPPING_BOUNDARY
|
||||
: TextEdit::LineWrappingMode::LINE_WRAPPING_NONE);
|
||||
}
|
||||
|
||||
text->set_custom_minimum_size(Vector2(0, font->get_height(font_size) * 6));
|
||||
}
|
||||
|
||||
void EditorPropertyMultilineText::_notification(int p_what) {
|
||||
switch (p_what) {
|
||||
case NOTIFICATION_THEME_CHANGED: {
|
||||
_update_theme();
|
||||
} break;
|
||||
}
|
||||
}
|
||||
|
||||
EditorPropertyMultilineText::EditorPropertyMultilineText(bool p_expression) {
|
||||
void EditorPropertyMultilineText::EditorPropertyMultilineText::set_monospaced(bool p_monospaced) {
|
||||
if (p_monospaced == monospaced) {
|
||||
return;
|
||||
}
|
||||
monospaced = p_monospaced;
|
||||
_update_theme();
|
||||
}
|
||||
|
||||
bool EditorPropertyMultilineText::EditorPropertyMultilineText::get_monospaced() {
|
||||
return monospaced;
|
||||
}
|
||||
|
||||
void EditorPropertyMultilineText::EditorPropertyMultilineText::set_wrap_lines(bool p_wrap_lines) {
|
||||
if (p_wrap_lines == wrap_lines) {
|
||||
return;
|
||||
}
|
||||
wrap_lines = p_wrap_lines;
|
||||
_update_theme();
|
||||
}
|
||||
|
||||
bool EditorPropertyMultilineText::EditorPropertyMultilineText::get_wrap_lines() {
|
||||
return wrap_lines;
|
||||
}
|
||||
|
||||
EditorPropertyMultilineText::EditorPropertyMultilineText(bool p_expression) :
|
||||
expression(p_expression) {
|
||||
HBoxContainer *hb = memnew(HBoxContainer);
|
||||
hb->add_theme_constant_override("separation", 0);
|
||||
add_child(hb);
|
||||
@@ -337,8 +413,8 @@ EditorPropertyMultilineText::EditorPropertyMultilineText(bool p_expression) {
|
||||
hb->add_child(open_big_text);
|
||||
big_text_dialog = nullptr;
|
||||
big_text = nullptr;
|
||||
if (p_expression) {
|
||||
expression = true;
|
||||
|
||||
if (expression) {
|
||||
Ref<EditorStandardSyntaxHighlighter> highlighter;
|
||||
highlighter.instantiate();
|
||||
text->set_syntax_highlighter(highlighter);
|
||||
@@ -3889,7 +3965,14 @@ EditorProperty *EditorInspectorDefaultPlugin::get_editor_for_property(Object *p_
|
||||
} else if (p_hint == PROPERTY_HINT_INPUT_NAME) {
|
||||
return get_input_action_editor(p_hint_text, false);
|
||||
} else if (p_hint == PROPERTY_HINT_MULTILINE_TEXT) {
|
||||
EditorPropertyMultilineText *editor = memnew(EditorPropertyMultilineText);
|
||||
Vector<String> options = p_hint_text.split(",", false);
|
||||
EditorPropertyMultilineText *editor = memnew(EditorPropertyMultilineText(false));
|
||||
if (options.has("monospace")) {
|
||||
editor->set_monospaced(true);
|
||||
}
|
||||
if (options.has("no_wrap")) {
|
||||
editor->set_wrap_lines(false);
|
||||
}
|
||||
return editor;
|
||||
} else if (p_hint == PROPERTY_HINT_EXPRESSION) {
|
||||
EditorPropertyMultilineText *editor = memnew(EditorPropertyMultilineText(true));
|
||||
@@ -3916,6 +3999,12 @@ EditorProperty *EditorInspectorDefaultPlugin::get_editor_for_property(Object *p_
|
||||
return editor;
|
||||
} else {
|
||||
EditorPropertyText *editor = memnew(EditorPropertyText);
|
||||
|
||||
Vector<String> hints = p_hint_text.split(",");
|
||||
if (hints.has("monospace")) {
|
||||
editor->set_monospaced(true);
|
||||
}
|
||||
|
||||
if (p_hint == PROPERTY_HINT_PLACEHOLDER_TEXT) {
|
||||
editor->set_placeholder(p_hint_text);
|
||||
} else if (p_hint == PROPERTY_HINT_PASSWORD) {
|
||||
|
||||
@@ -95,12 +95,16 @@ class EditorPropertyText : public EditorProperty {
|
||||
GDCLASS(EditorPropertyText, EditorProperty);
|
||||
LineEdit *text = nullptr;
|
||||
|
||||
bool monospaced = false;
|
||||
bool updating = false;
|
||||
bool string_name = false;
|
||||
void _text_changed(const String &p_string);
|
||||
void _text_submitted(const String &p_string);
|
||||
void _update_theme();
|
||||
|
||||
protected:
|
||||
void _notification(int p_what);
|
||||
|
||||
virtual void _set_read_only(bool p_read_only) override;
|
||||
|
||||
public:
|
||||
@@ -108,21 +112,27 @@ public:
|
||||
virtual void update_property() override;
|
||||
void set_placeholder(const String &p_string);
|
||||
void set_secret(bool p_enabled);
|
||||
void set_monospaced(bool p_monospaced);
|
||||
EditorPropertyText();
|
||||
};
|
||||
|
||||
class EditorPropertyMultilineText : public EditorProperty {
|
||||
GDCLASS(EditorPropertyMultilineText, EditorProperty);
|
||||
|
||||
TextEdit *text = nullptr;
|
||||
|
||||
AcceptDialog *big_text_dialog = nullptr;
|
||||
TextEdit *big_text = nullptr;
|
||||
Button *open_big_text = nullptr;
|
||||
|
||||
bool expression = false;
|
||||
bool monospaced = false;
|
||||
bool wrap_lines = true;
|
||||
|
||||
void _big_text_changed();
|
||||
void _text_changed();
|
||||
void _open_big_text();
|
||||
bool expression = false;
|
||||
void _update_theme();
|
||||
|
||||
protected:
|
||||
virtual void _set_read_only(bool p_read_only) override;
|
||||
@@ -130,6 +140,13 @@ protected:
|
||||
|
||||
public:
|
||||
virtual void update_property() override;
|
||||
|
||||
void set_monospaced(bool p_monospaced);
|
||||
bool get_monospaced();
|
||||
|
||||
void set_wrap_lines(bool p_wrap_lines);
|
||||
bool get_wrap_lines();
|
||||
|
||||
EditorPropertyMultilineText(bool p_expression = false);
|
||||
};
|
||||
|
||||
|
||||
@@ -281,7 +281,7 @@ void register_editor_types() {
|
||||
#endif
|
||||
|
||||
// For correct doc generation.
|
||||
GLOBAL_DEF("editor/run/main_run_args", "");
|
||||
GLOBAL_DEF(PropertyInfo(Variant::STRING, "editor/run/main_run_args", PROPERTY_HINT_NONE, "monospace"), "");
|
||||
|
||||
GLOBAL_DEF(PropertyInfo(Variant::STRING, "editor/script/templates_search_path", PROPERTY_HINT_DIR), "res://script_templates");
|
||||
|
||||
|
||||
@@ -621,14 +621,16 @@
|
||||
[/codeblock]
|
||||
</description>
|
||||
</annotation>
|
||||
<annotation name="@export_multiline">
|
||||
<annotation name="@export_multiline" qualifiers="vararg">
|
||||
<return type="void" />
|
||||
<param index="0" name="hint" type="String" default="""" />
|
||||
<description>
|
||||
Export a [String], [Array][lb][String][rb], [PackedStringArray], [Dictionary] or [Array][lb][Dictionary][rb] property with a large [TextEdit] widget instead of a [LineEdit]. This adds support for multiline content and makes it easier to edit large amount of text stored in the property.
|
||||
See also [constant PROPERTY_HINT_MULTILINE_TEXT].
|
||||
[codeblock]
|
||||
@export_multiline var character_biography
|
||||
@export_multiline var npc_dialogs: Array[String]
|
||||
@export_multiline("monospace", "no_wrap") var favorite_ascii_art: String
|
||||
[/codeblock]
|
||||
</description>
|
||||
</annotation>
|
||||
|
||||
@@ -160,7 +160,7 @@ GDScriptParser::GDScriptParser() {
|
||||
register_annotation(MethodInfo("@export_dir"), AnnotationInfo::VARIABLE, &GDScriptParser::export_annotations<PROPERTY_HINT_DIR, Variant::STRING>);
|
||||
register_annotation(MethodInfo("@export_global_file", PropertyInfo(Variant::STRING, "filter")), AnnotationInfo::VARIABLE, &GDScriptParser::export_annotations<PROPERTY_HINT_GLOBAL_FILE, Variant::STRING>, varray(""), true);
|
||||
register_annotation(MethodInfo("@export_global_dir"), AnnotationInfo::VARIABLE, &GDScriptParser::export_annotations<PROPERTY_HINT_GLOBAL_DIR, Variant::STRING>);
|
||||
register_annotation(MethodInfo("@export_multiline"), AnnotationInfo::VARIABLE, &GDScriptParser::export_annotations<PROPERTY_HINT_MULTILINE_TEXT, Variant::STRING>);
|
||||
register_annotation(MethodInfo("@export_multiline", PropertyInfo(Variant::STRING, "hint")), AnnotationInfo::VARIABLE, &GDScriptParser::export_annotations<PROPERTY_HINT_MULTILINE_TEXT, Variant::STRING>, varray(""), true);
|
||||
register_annotation(MethodInfo("@export_placeholder", PropertyInfo(Variant::STRING, "placeholder")), AnnotationInfo::VARIABLE, &GDScriptParser::export_annotations<PROPERTY_HINT_PLACEHOLDER_TEXT, Variant::STRING>);
|
||||
register_annotation(MethodInfo("@export_range", PropertyInfo(Variant::FLOAT, "min"), PropertyInfo(Variant::FLOAT, "max"), PropertyInfo(Variant::FLOAT, "step"), PropertyInfo(Variant::STRING, "extra_hints")), AnnotationInfo::VARIABLE, &GDScriptParser::export_annotations<PROPERTY_HINT_RANGE, Variant::FLOAT>, varray(1.0, ""), true);
|
||||
register_annotation(MethodInfo("@export_exp_easing", PropertyInfo(Variant::STRING, "hints")), AnnotationInfo::VARIABLE, &GDScriptParser::export_annotations<PROPERTY_HINT_EXP_EASING, Variant::FLOAT>, varray(""), true);
|
||||
|
||||
@@ -2184,11 +2184,11 @@ void EditorExportPlatformAndroid::get_export_options(List<ExportOption> *r_optio
|
||||
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::BOOL, "user_data_backup/allow"), false));
|
||||
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "command_line/extra_args"), ""));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "command_line/extra_args", PROPERTY_HINT_NONE, "monospace"), ""));
|
||||
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::BOOL, "apk_expansion/enable"), false, false, true));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "apk_expansion/SALT"), ""));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "apk_expansion/public_key", PROPERTY_HINT_MULTILINE_TEXT), "", false, true));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "apk_expansion/public_key", PROPERTY_HINT_MULTILINE_TEXT, "monospace,no_wrap"), "", false, true));
|
||||
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::PACKED_STRING_ARRAY, "permissions/custom_permissions"), PackedStringArray()));
|
||||
|
||||
|
||||
@@ -200,10 +200,10 @@ void EditorExportPlatformLinuxBSD::get_export_options(List<ExportOption> *r_opti
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "ssh_remote_deploy/host"), "user@host_ip"));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "ssh_remote_deploy/port"), "22"));
|
||||
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "ssh_remote_deploy/extra_args_ssh", PROPERTY_HINT_MULTILINE_TEXT), ""));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "ssh_remote_deploy/extra_args_scp", PROPERTY_HINT_MULTILINE_TEXT), ""));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "ssh_remote_deploy/run_script", PROPERTY_HINT_MULTILINE_TEXT), run_script));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "ssh_remote_deploy/cleanup_script", PROPERTY_HINT_MULTILINE_TEXT), cleanup_script));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "ssh_remote_deploy/extra_args_ssh", PROPERTY_HINT_MULTILINE_TEXT, "monospace,no_wrap"), ""));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "ssh_remote_deploy/extra_args_scp", PROPERTY_HINT_MULTILINE_TEXT, "monospace,no_wrap"), ""));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "ssh_remote_deploy/run_script", PROPERTY_HINT_MULTILINE_TEXT, "monospace,no_wrap"), run_script));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "ssh_remote_deploy/cleanup_script", PROPERTY_HINT_MULTILINE_TEXT, "monospace,no_wrap"), cleanup_script));
|
||||
}
|
||||
|
||||
bool EditorExportPlatformLinuxBSD::is_elf(const String &p_path) const {
|
||||
|
||||
@@ -490,7 +490,7 @@ void EditorExportPlatformMacOS::get_export_options(List<ExportOption> *r_options
|
||||
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::BOOL, "shader_baker/enabled"), false));
|
||||
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "application/additional_plist_content", PROPERTY_HINT_MULTILINE_TEXT), ""));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "application/additional_plist_content", PROPERTY_HINT_MULTILINE_TEXT, "monospace,no_wrap"), ""));
|
||||
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "xcode/platform_build"), "14C18"));
|
||||
// TODO(sgc): Need to set appropriate version when using Metal
|
||||
@@ -539,7 +539,7 @@ void EditorExportPlatformMacOS::get_export_options(List<ExportOption> *r_options
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::INT, "codesign/entitlements/app_sandbox/files_movies", PROPERTY_HINT_ENUM, "No,Read-only,Read-write"), 0));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::INT, "codesign/entitlements/app_sandbox/files_user_selected", PROPERTY_HINT_ENUM, "No,Read-only,Read-write"), 0));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::ARRAY, "codesign/entitlements/app_sandbox/helper_executables", PROPERTY_HINT_ARRAY_TYPE, itos(Variant::STRING) + "/" + itos(PROPERTY_HINT_GLOBAL_FILE) + ":"), Array()));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "codesign/entitlements/additional", PROPERTY_HINT_MULTILINE_TEXT), ""));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "codesign/entitlements/additional", PROPERTY_HINT_MULTILINE_TEXT, "monospace,no_wrap"), ""));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::PACKED_STRING_ARRAY, "codesign/custom_options"), PackedStringArray()));
|
||||
|
||||
#ifdef MACOS_ENABLED
|
||||
@@ -609,10 +609,10 @@ void EditorExportPlatformMacOS::get_export_options(List<ExportOption> *r_options
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "ssh_remote_deploy/host"), "user@host_ip"));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "ssh_remote_deploy/port"), "22"));
|
||||
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "ssh_remote_deploy/extra_args_ssh", PROPERTY_HINT_MULTILINE_TEXT), ""));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "ssh_remote_deploy/extra_args_scp", PROPERTY_HINT_MULTILINE_TEXT), ""));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "ssh_remote_deploy/run_script", PROPERTY_HINT_MULTILINE_TEXT), run_script));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "ssh_remote_deploy/cleanup_script", PROPERTY_HINT_MULTILINE_TEXT), cleanup_script));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "ssh_remote_deploy/extra_args_ssh", PROPERTY_HINT_MULTILINE_TEXT, "monospace,no_wrap"), ""));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "ssh_remote_deploy/extra_args_scp", PROPERTY_HINT_MULTILINE_TEXT, "monospace,no_wrap"), ""));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "ssh_remote_deploy/run_script", PROPERTY_HINT_MULTILINE_TEXT, "monospace,no_wrap"), run_script));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "ssh_remote_deploy/cleanup_script", PROPERTY_HINT_MULTILINE_TEXT, "monospace,no_wrap"), cleanup_script));
|
||||
}
|
||||
|
||||
void _rgba8_to_packbits_encode(int p_ch, int p_size, Vector<uint8_t> &p_source, Vector<uint8_t> &p_dest) {
|
||||
|
||||
@@ -375,7 +375,7 @@ void EditorExportPlatformWeb::get_export_options(List<ExportOption> *r_options)
|
||||
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::BOOL, "html/export_icon"), true));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "html/custom_html_shell", PROPERTY_HINT_FILE, "*.html"), ""));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "html/head_include", PROPERTY_HINT_MULTILINE_TEXT), ""));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "html/head_include", PROPERTY_HINT_MULTILINE_TEXT, "monospace,no_wrap"), ""));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::INT, "html/canvas_resize_policy", PROPERTY_HINT_ENUM, "None,Project,Adaptive"), 2));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::BOOL, "html/focus_canvas_on_start"), true));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::BOOL, "html/experimental_virtual_keyboard"), false));
|
||||
|
||||
@@ -499,10 +499,10 @@ void EditorExportPlatformWindows::get_export_options(List<ExportOption> *r_optio
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "ssh_remote_deploy/host"), "user@host_ip"));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "ssh_remote_deploy/port"), "22"));
|
||||
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "ssh_remote_deploy/extra_args_ssh", PROPERTY_HINT_MULTILINE_TEXT), ""));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "ssh_remote_deploy/extra_args_scp", PROPERTY_HINT_MULTILINE_TEXT), ""));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "ssh_remote_deploy/run_script", PROPERTY_HINT_MULTILINE_TEXT), run_script));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "ssh_remote_deploy/cleanup_script", PROPERTY_HINT_MULTILINE_TEXT), cleanup_script));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "ssh_remote_deploy/extra_args_ssh", PROPERTY_HINT_MULTILINE_TEXT, "monospace,no_wrap"), ""));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "ssh_remote_deploy/extra_args_scp", PROPERTY_HINT_MULTILINE_TEXT, "monospace,no_wrap"), ""));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "ssh_remote_deploy/run_script", PROPERTY_HINT_MULTILINE_TEXT, "monospace,no_wrap"), run_script));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "ssh_remote_deploy/cleanup_script", PROPERTY_HINT_MULTILINE_TEXT, "monospace,no_wrap"), cleanup_script));
|
||||
}
|
||||
|
||||
Error EditorExportPlatformWindows::_add_data(const Ref<EditorExportPreset> &p_preset, const String &p_path, bool p_console_icon) {
|
||||
|
||||
Reference in New Issue
Block a user