Presencode/Console.tscn

98 lines
3.5 KiB
Text
Raw Normal View History

[gd_scene load_steps=10 format=3 uid="uid://btyi16dkvbly1"]
[ext_resource type="Script" path="res://src/console.gd" id="1_viv5y"]
[ext_resource type="FontFile" uid="uid://b325yyejgxcyt" path="res://assets/fonts/FiraCode/Regular.ttf" id="2_ebuk0"]
[ext_resource type="FontFile" uid="uid://bbo5ifp3raaog" path="res://assets/fonts/FiraCode/Bold.ttf" id="3_102to"]
[ext_resource type="FontFile" uid="uid://yvdh4nvjqmbk" path="res://assets/fonts/FiraCode/Medium.ttf" id="4_jqfsc"]
[sub_resource type="StyleBoxEmpty" id="StyleBoxEmpty_u40jo"]
[sub_resource type="StyleBoxEmpty" id="StyleBoxEmpty_wj4aw"]
[sub_resource type="StyleBoxEmpty" id="StyleBoxEmpty_ime8b"]
[sub_resource type="StyleBoxEmpty" id="StyleBoxEmpty_hjtld"]
[sub_resource type="StyleBoxEmpty" id="StyleBoxEmpty_xa0gg"]
[node name="Console" type="ColorRect"]
offset_right = 767.0
offset_bottom = 426.0
script = ExtResource("1_viv5y")
[node name="Bar" type="ColorRect" parent="."]
layout_mode = 0
offset_left = 2.5
offset_top = 2.5
offset_right = 764.5
offset_bottom = 27.5
color = Color(0.839216, 0.0196078, 0.196078, 1)
[node name="X1" type="Line2D" parent="Bar"]
points = PackedVector2Array(760, 2, 739, 23)
width = 2.0
[node name="X2" type="Line2D" parent="Bar"]
points = PackedVector2Array(760, 23, 739, 2)
width = 2.0
[node name="CloseButton" type="Button" parent="Bar"]
layout_mode = 0
offset_left = 737.0
offset_right = 762.0
offset_bottom = 25.0
theme_override_styles/normal = SubResource("StyleBoxEmpty_u40jo")
theme_override_styles/hover = SubResource("StyleBoxEmpty_wj4aw")
theme_override_styles/pressed = SubResource("StyleBoxEmpty_ime8b")
theme_override_styles/disabled = SubResource("StyleBoxEmpty_hjtld")
theme_override_styles/focus = SubResource("StyleBoxEmpty_xa0gg")
[node name="DragButton" type="Button" parent="Bar"]
layout_mode = 0
offset_right = 737.0
offset_bottom = 25.0
theme_override_styles/normal = SubResource("StyleBoxEmpty_u40jo")
theme_override_styles/hover = SubResource("StyleBoxEmpty_wj4aw")
theme_override_styles/pressed = SubResource("StyleBoxEmpty_ime8b")
theme_override_styles/disabled = SubResource("StyleBoxEmpty_hjtld")
theme_override_styles/focus = SubResource("StyleBoxEmpty_xa0gg")
[node name="Shell" type="ColorRect" parent="."]
layout_mode = 0
offset_left = 2.5
offset_top = 27.5
offset_right = 764.5
offset_bottom = 423.5
color = Color(0, 0, 0, 1)
[node name="Output" type="RichTextLabel" parent="Shell"]
layout_mode = 0
offset_right = 762.0
offset_bottom = 361.0
theme_override_fonts/normal_font = ExtResource("2_ebuk0")
theme_override_fonts/bold_font = ExtResource("3_102to")
theme_override_fonts/italics_font = ExtResource("2_ebuk0")
theme_override_fonts/bold_italics_font = ExtResource("3_102to")
theme_override_fonts/mono_font = ExtResource("2_ebuk0")
theme_override_font_sizes/normal_font_size = 18
theme_override_font_sizes/bold_font_size = 18
theme_override_font_sizes/italics_font_size = 18
theme_override_font_sizes/bold_italics_font_size = 18
theme_override_font_sizes/mono_font_size = 18
bbcode_enabled = true
scroll_following = true
[node name="Input" type="TextEdit" parent="Shell"]
layout_mode = 0
offset_top = 361.0
offset_right = 762.0
offset_bottom = 396.0
theme_override_colors/background_color = Color(0, 0, 0, 1)
theme_override_colors/font_color = Color(1, 1, 1, 1)
theme_override_fonts/font = ExtResource("4_jqfsc")
theme_override_font_sizes/font_size = 18
placeholder_text = "Enter a command here"
Partial source code rewrite - [src/*] Update comments - [src/*] Improve code quality - [export_presets.cfg] All exports use a console wrapper now - [src/console.gd] Add highlighting for "arbitrary" command - [src/console.gd] Add special message if nothing has been typed in - [src/misc.gd, src/console.gd] Move BooleanState, get_last() (now called get_shortened_array), get_boolean(), get_int() and get_int_direct() into misc - [src/console_info.gd] Remove useless _init() function - [src/console_info.gd] Make get_error_string() function more compact - [Loader.tscn, src/loader.gd] Remove window size support and slow initialization functionality - [src/loader.gd] Remove warning on startup (will be reimplemented at some point, most likely graphically) - [src/loader.gd] Replaced append_log() function with a lambda - [src/loader.gd] Implement argument parser with configuration support - [src/loader.gd] Add Presencode version information as constants and format_version() function - [src/misc.gd] Reorganize functions - [src/pmana.gd] Add checks to avoid slide change collisions - [src/pmana.gd] Replace logger.warn() calls to "await logger.error()" calls - [src/pmana.gd, src/misc.gd, src/console.gd] Remove pmana.shutdown() function in favour of misc.shutdown() which now does the same - [src/preader.gd] Fix resource loading issues for presentation directories - [src/preader.gd] Move resource loading workaround into seperate function _read_resource_workaround() - [src/processor.gd, src/console.gd, src/loader.gd, src/pmana.gd, src/ui_engine.gd] Move all _process() functions into seperate file - [src/processor.gd, src/console.gd, src/loader.gd, src/pmana.gd, src/ui_engine.gd, src/ui/welcome.gd] Move everything dragging related (except variables) into processor.gd - [ui/Welcome.tscn, src/ui/welcome.gd] Add support for presentation directories - [src/ui/welcome.gd] Update splash text
2024-01-19 20:45:37 +01:00
[connection signal="pressed" from="Bar/CloseButton" to="." method="toggle_console"]
[connection signal="text_changed" from="Shell/Input" to="." method="input_changed"]