theming, changed tooltip from RichText to Label

This commit is contained in:
2023-02-15 00:29:35 +01:00
parent 8ec360bb42
commit 5943b7e4db
4 changed files with 46 additions and 27 deletions

View File

@@ -1,6 +1,38 @@
[gd_resource type="Theme" load_steps=2 format=2]
[gd_resource type="Theme" load_steps=5 format=2]
[ext_resource path="res://gymkhana/addons/escoria-ui-return-monkey-island/fonts/caslonantique.tres" type="DynamicFont" id=1]
[sub_resource type="StyleBoxFlat" id=1]
content_margin_left = 28.0
content_margin_right = 3.0
content_margin_top = 6.0
content_margin_bottom = 3.0
bg_color = Color( 0, 0, 0, 0.462745 )
corner_radius_top_left = 5
corner_radius_top_right = 5
corner_radius_bottom_right = 5
corner_radius_bottom_left = 5
[sub_resource type="StyleBoxFlat" id=2]
bg_color = Color( 0, 0, 0, 0.509804 )
corner_radius_top_left = 5
corner_radius_top_right = 5
corner_radius_bottom_right = 5
corner_radius_bottom_left = 5
[sub_resource type="StyleBoxFlat" id=3]
bg_color = Color( 0, 0, 0, 0.388235 )
corner_radius_top_left = 5
corner_radius_top_right = 5
corner_radius_bottom_right = 5
corner_radius_bottom_left = 5
[resource]
default_font = ExtResource( 1 )
Label/colors/font_color = Color( 1, 1, 1, 1 )
Label/colors/font_color_shadow = Color( 0, 0, 0, 0 )
Label/colors/font_outline_modulate = Color( 1, 0, 0, 1 )
Label/colors/label_box_bg = Color( 0, 0, 0, 0.745098 )
Label/styles/normal = SubResource( 1 )
RichTextLabel/styles/focus = SubResource( 2 )
RichTextLabel/styles/normal = SubResource( 3 )

View File

@@ -8,20 +8,13 @@
z_index = 500
script = ExtResource( 3 )
[node name="label" type="RichTextLabel" parent="."]
margin_left = 21.0
margin_top = -10.0
margin_right = 235.0
margin_bottom = 41.0
[node name="label" type="Label" parent="."]
margin_left = -1.0
margin_top = -16.0
margin_right = 83.0
margin_bottom = 14.0
theme = ExtResource( 2 )
bbcode_enabled = true
bbcode_text = "[color=#ffffff] Prueba
[/color]"
text = " Prueba
"
__meta__ = {
"_editor_description_": ""
}
text = "Prueba"
[node name="MouseLeft" type="Sprite" parent="."]
position = Vector2( 13, -2 )

View File

@@ -8,20 +8,13 @@
z_index = 500
script = ExtResource( 3 )
[node name="label" type="RichTextLabel" parent="."]
margin_left = 21.0
margin_top = -10.0
margin_right = 235.0
margin_bottom = 41.0
[node name="label" type="Label" parent="."]
margin_left = -1.0
margin_top = -16.0
margin_right = 83.0
margin_bottom = 14.0
theme = ExtResource( 2 )
bbcode_enabled = true
bbcode_text = "[color=#ffffff] Prueba
[/color]"
text = " Prueba
"
__meta__ = {
"_editor_description_": ""
}
text = "Prueba"
[node name="MouseRight" type="Sprite" parent="."]
position = Vector2( 11.5, -1 )

View File

@@ -12,6 +12,7 @@ func _ready():
func set_text(text: String) -> void:
$label.text = text
# Called every frame. 'delta' is the elapsed time since the previous frame.
#func _process(delta):