75 lines
2.2 KiB
Text
75 lines
2.2 KiB
Text
|
[gd_scene load_steps=2 format=3 uid="uid://cimp70l7c0y2p"]
|
||
|
|
||
|
[ext_resource type="Script" path="res://regex.gd" id="1"]
|
||
|
|
||
|
[node name="Regex" type="VBoxContainer"]
|
||
|
anchors_preset = 15
|
||
|
anchor_right = 1.0
|
||
|
anchor_bottom = 1.0
|
||
|
offset_left = 14.0
|
||
|
offset_top = 20.0
|
||
|
offset_right = -14.0
|
||
|
offset_bottom = -20.0
|
||
|
grow_horizontal = 2
|
||
|
grow_vertical = 2
|
||
|
theme_override_constants/separation = 10
|
||
|
script = ExtResource("1")
|
||
|
|
||
|
[node name="Help" type="RichTextLabel" parent="."]
|
||
|
modulate = Color(1, 1, 1, 0.752941)
|
||
|
custom_minimum_size = Vector2(0, 50)
|
||
|
layout_mode = 2
|
||
|
bbcode_enabled = true
|
||
|
text = "Regular expressions (RegEx) can be used for advanced text matching.
|
||
|
You can use [url=https://regexr.com]RegExr[/url] to test regular expressions online and compare results."
|
||
|
|
||
|
[node name="HBoxContainer" type="HBoxContainer" parent="."]
|
||
|
layout_mode = 2
|
||
|
theme_override_constants/separation = 10
|
||
|
|
||
|
[node name="Label" type="Label" parent="HBoxContainer"]
|
||
|
layout_mode = 2
|
||
|
size_flags_horizontal = 3
|
||
|
size_flags_vertical = 5
|
||
|
size_flags_stretch_ratio = 0.08
|
||
|
text = "RegEx"
|
||
|
horizontal_alignment = 2
|
||
|
|
||
|
[node name="Expression" type="LineEdit" parent="HBoxContainer"]
|
||
|
unique_name_in_owner = true
|
||
|
layout_mode = 2
|
||
|
size_flags_horizontal = 3
|
||
|
text = "\"((?:\\\\.|[^\"])*)\""
|
||
|
placeholder_text = "Regular expression to match against"
|
||
|
|
||
|
[node name="HBoxContainer2" type="HBoxContainer" parent="."]
|
||
|
layout_mode = 2
|
||
|
theme_override_constants/separation = 10
|
||
|
|
||
|
[node name="Label" type="Label" parent="HBoxContainer2"]
|
||
|
layout_mode = 2
|
||
|
size_flags_horizontal = 3
|
||
|
size_flags_vertical = 5
|
||
|
size_flags_stretch_ratio = 0.08
|
||
|
text = "Text"
|
||
|
horizontal_alignment = 2
|
||
|
|
||
|
[node name="Text" type="TextEdit" parent="HBoxContainer2"]
|
||
|
unique_name_in_owner = true
|
||
|
custom_minimum_size = Vector2(0, 200)
|
||
|
layout_mode = 2
|
||
|
size_flags_horizontal = 3
|
||
|
placeholder_text = "Text to search in"
|
||
|
|
||
|
[node name="ScrollContainer" type="ScrollContainer" parent="."]
|
||
|
layout_mode = 2
|
||
|
size_flags_vertical = 3
|
||
|
|
||
|
[node name="List" type="VBoxContainer" parent="ScrollContainer"]
|
||
|
unique_name_in_owner = true
|
||
|
layout_mode = 2
|
||
|
|
||
|
[connection signal="meta_clicked" from="Help" to="." method="_on_help_meta_clicked"]
|
||
|
[connection signal="text_changed" from="HBoxContainer/Expression" to="." method="update_expression"]
|
||
|
[connection signal="text_changed" from="HBoxContainer2/Text" to="." method="update_text"]
|