mirror of
https://github.com/hobbesjaap/wellbeingapp.git
synced 2024-12-22 08:39:52 +00:00
UI improvements
This commit is contained in:
parent
9e5500dea9
commit
352d9d7555
@ -18,6 +18,7 @@ func _ready():
|
||||
|
||||
# Set starting state visibility
|
||||
ui_control.show_start_menu()
|
||||
node_variables.first_time_label.visible = false
|
||||
|
||||
# define variables from ini file
|
||||
node_variables.user_name.text = user_values.user_first_name
|
||||
|
@ -2,14 +2,14 @@ extends Node
|
||||
|
||||
|
||||
onready var main_screen = get_node("/root/main_screen")
|
||||
onready var start_menu = get_node("/root/main_screen/UI/top_container/menus_container/start_menu")
|
||||
onready var user_menu = get_node("/root/main_screen/UI/top_container/menus_container/user_details")
|
||||
onready var daily_prompts = get_node("/root/main_screen/UI/top_container/menus_container/daily_prompts")
|
||||
onready var start_menu = get_node("/root/main_screen/UI/top_container/start_menu")
|
||||
onready var user_menu = get_node("/root/main_screen/UI/top_container/user_details")
|
||||
onready var daily_prompts = get_node("/root/main_screen/UI/top_container/daily_prompts")
|
||||
|
||||
|
||||
onready var user_name = get_node("/root/main_screen/UI/top_container/menus_container/user_details/textbox_user_name")
|
||||
onready var first_time_label = get_node("/root/main_screen/UI/top_container/menus_container/user_details/label_first_time")
|
||||
onready var welcome_label = get_node("/root/main_screen/UI/top_container/menus_container/start_menu/welcome_title")
|
||||
onready var user_name = get_node("/root/main_screen/UI/top_container/user_details/user_menu/textbox_user_name")
|
||||
onready var first_time_label = get_node("/root/main_screen/UI/top_container/user_details/user_menu/label_first_time")
|
||||
onready var welcome_label = get_node("/root/main_screen/UI/top_container/start_menu/welcome_title")
|
||||
|
||||
|
||||
func _ready():
|
||||
|
@ -8,79 +8,14 @@
|
||||
[node name="start_menu" type="CanvasLayer"]
|
||||
script = ExtResource( 1 )
|
||||
|
||||
[node name="MarginContainer" type="MarginContainer" parent="."]
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
margin_left = 5.0
|
||||
margin_top = 53.0
|
||||
margin_right = -943.0
|
||||
margin_bottom = -540.0
|
||||
|
||||
[node name="GridContainer" type="GridContainer" parent="MarginContainer"]
|
||||
margin_right = 332.0
|
||||
margin_bottom = 127.0
|
||||
columns = 2
|
||||
|
||||
[node name="button_daily_action" type="Button" parent="MarginContainer/GridContainer"]
|
||||
margin_right = 222.0
|
||||
margin_bottom = 37.0
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
text = "Daily Action"
|
||||
|
||||
[node name="button_open_github" type="Button" parent="MarginContainer/GridContainer"]
|
||||
margin_left = 230.0
|
||||
margin_right = 332.0
|
||||
margin_bottom = 37.0
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
text = "GitHub"
|
||||
script = ExtResource( 4 )
|
||||
|
||||
[node name="button_email_feedback" type="Button" parent="MarginContainer/GridContainer"]
|
||||
margin_top = 45.0
|
||||
margin_right = 222.0
|
||||
margin_bottom = 82.0
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
text = "Feedback"
|
||||
script = ExtResource( 3 )
|
||||
|
||||
[node name="button_name" type="Button" parent="MarginContainer/GridContainer"]
|
||||
margin_left = 230.0
|
||||
margin_top = 45.0
|
||||
margin_right = 332.0
|
||||
margin_bottom = 82.0
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
text = "Name"
|
||||
script = ExtResource( 2 )
|
||||
|
||||
[node name="button_update_check" type="Button" parent="MarginContainer/GridContainer"]
|
||||
margin_top = 90.0
|
||||
margin_right = 222.0
|
||||
margin_bottom = 127.0
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
text = "Check for Updates"
|
||||
|
||||
[node name="button_journal" type="Button" parent="MarginContainer/GridContainer"]
|
||||
margin_left = 230.0
|
||||
margin_top = 90.0
|
||||
margin_right = 332.0
|
||||
margin_bottom = 127.0
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
text = "Journal"
|
||||
|
||||
[node name="welcome_title" type="Label" parent="."]
|
||||
unique_name_in_owner = true
|
||||
anchor_left = 0.5
|
||||
anchor_right = 0.5
|
||||
margin_left = -185.0
|
||||
margin_top = 11.0
|
||||
margin_top = 7.0
|
||||
margin_right = 185.0
|
||||
margin_bottom = 42.0
|
||||
margin_bottom = 38.0
|
||||
text = "All your base are belong to us"
|
||||
|
||||
[node name="HTTPRequest" type="HTTPRequest" parent="."]
|
||||
@ -89,13 +24,73 @@ text = "All your base are belong to us"
|
||||
anchor_top = 1.0
|
||||
anchor_bottom = 1.0
|
||||
margin_left = 5.0
|
||||
margin_top = -29.0
|
||||
margin_top = -31.0
|
||||
margin_right = 1280.0
|
||||
margin_bottom = 1.0
|
||||
margin_bottom = -1.0
|
||||
text = "Version"
|
||||
|
||||
[connection signal="pressed" from="MarginContainer/GridContainer/button_open_github" to="MarginContainer/GridContainer/button_open_github" method="_on_button_open_github_pressed"]
|
||||
[connection signal="pressed" from="MarginContainer/GridContainer/button_email_feedback" to="MarginContainer/GridContainer/button_email_feedback" method="_on_button_email_feedback_pressed"]
|
||||
[connection signal="pressed" from="MarginContainer/GridContainer/button_name" to="MarginContainer/GridContainer/button_name" method="_on_button_name_pressed"]
|
||||
[connection signal="pressed" from="MarginContainer/GridContainer/button_update_check" to="." method="_on_button_update_check_pressed"]
|
||||
[node name="GridContainer" type="GridContainer" parent="."]
|
||||
margin_left = 10.0
|
||||
margin_top = 55.0
|
||||
margin_right = 1270.0
|
||||
margin_bottom = 665.0
|
||||
columns = 2
|
||||
|
||||
[node name="button_daily_action" type="Button" parent="GridContainer"]
|
||||
margin_right = 626.0
|
||||
margin_bottom = 198.0
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
text = "Daily Action"
|
||||
|
||||
[node name="button_open_github" type="Button" parent="GridContainer"]
|
||||
margin_left = 634.0
|
||||
margin_right = 1260.0
|
||||
margin_bottom = 198.0
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
text = "GitHub"
|
||||
script = ExtResource( 4 )
|
||||
|
||||
[node name="button_email_feedback" type="Button" parent="GridContainer"]
|
||||
margin_top = 206.0
|
||||
margin_right = 626.0
|
||||
margin_bottom = 404.0
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
text = "Feedback"
|
||||
script = ExtResource( 3 )
|
||||
|
||||
[node name="button_name" type="Button" parent="GridContainer"]
|
||||
margin_left = 634.0
|
||||
margin_top = 206.0
|
||||
margin_right = 1260.0
|
||||
margin_bottom = 404.0
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
text = "Name"
|
||||
script = ExtResource( 2 )
|
||||
|
||||
[node name="button_update_check" type="Button" parent="GridContainer"]
|
||||
margin_top = 412.0
|
||||
margin_right = 626.0
|
||||
margin_bottom = 610.0
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
text = "Check for Updates"
|
||||
|
||||
[node name="button_journal" type="Button" parent="GridContainer"]
|
||||
visible = false
|
||||
margin_left = 230.0
|
||||
margin_top = 90.0
|
||||
margin_right = 332.0
|
||||
margin_bottom = 127.0
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
text = "Journal"
|
||||
|
||||
[connection signal="request_completed" from="HTTPRequest" to="." method="_on_HTTPRequest_request_completed"]
|
||||
[connection signal="pressed" from="GridContainer/button_open_github" to="GridContainer/button_open_github" method="_on_button_open_github_pressed"]
|
||||
[connection signal="pressed" from="GridContainer/button_email_feedback" to="GridContainer/button_email_feedback" method="_on_button_email_feedback_pressed"]
|
||||
[connection signal="pressed" from="GridContainer/button_name" to="GridContainer/button_name" method="_on_button_name_pressed"]
|
||||
[connection signal="pressed" from="GridContainer/button_update_check" to="." method="_on_button_update_check_pressed"]
|
||||
|
@ -24,25 +24,22 @@ color = Color( 0.94902, 0.937255, 0.85098, 1 )
|
||||
|
||||
[node name="top_bar" type="Panel" parent="UI"]
|
||||
margin_right = 1280.0
|
||||
margin_bottom = 50.0
|
||||
rect_min_size = Vector2( 0, 50 )
|
||||
margin_bottom = 40.0
|
||||
rect_min_size = Vector2( 0, 40 )
|
||||
custom_styles/panel = SubResource( 1 )
|
||||
|
||||
[node name="top_container" type="VBoxContainer" parent="UI"]
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
margin_top = 52.0
|
||||
margin_bottom = -41.0
|
||||
margin_top = 42.0
|
||||
margin_bottom = -48.0
|
||||
|
||||
[node name="menus_container" type="VBoxContainer" parent="UI/top_container"]
|
||||
margin_right = 1280.0
|
||||
[node name="start_menu" parent="UI/top_container" instance=ExtResource( 3 )]
|
||||
|
||||
[node name="start_menu" parent="UI/top_container/menus_container" instance=ExtResource( 3 )]
|
||||
|
||||
[node name="user_details" parent="UI/top_container/menus_container" instance=ExtResource( 2 )]
|
||||
[node name="user_details" parent="UI/top_container" instance=ExtResource( 2 )]
|
||||
visible = false
|
||||
|
||||
[node name="daily_prompts" parent="UI/top_container/menus_container" instance=ExtResource( 4 )]
|
||||
[node name="daily_prompts" parent="UI/top_container" instance=ExtResource( 4 )]
|
||||
visible = false
|
||||
|
||||
[node name="bottom_bar" type="Panel" parent="UI"]
|
||||
|
@ -4,38 +4,39 @@
|
||||
|
||||
[node name="user_details" type="CanvasLayer"]
|
||||
|
||||
[node name="button_user_save" type="Button" parent="."]
|
||||
margin_left = 540.0
|
||||
margin_top = 280.0
|
||||
margin_right = 615.0
|
||||
margin_bottom = 317.0
|
||||
text = "OK"
|
||||
script = ExtResource( 1 )
|
||||
[node name="user_menu" type="VBoxContainer" parent="."]
|
||||
margin_left = 10.0
|
||||
margin_top = 55.0
|
||||
margin_right = 1270.0
|
||||
margin_bottom = 665.0
|
||||
rect_min_size = Vector2( 1260, 610 )
|
||||
|
||||
[node name="textbox_user_name" type="LineEdit" parent="."]
|
||||
[node name="label_first_time" type="Label" parent="user_menu"]
|
||||
unique_name_in_owner = true
|
||||
margin_left = 244.0
|
||||
margin_top = 205.0
|
||||
margin_right = 794.0
|
||||
margin_bottom = 250.0
|
||||
margin_right = 1260.0
|
||||
margin_bottom = 25.0
|
||||
text = "First time user: Please fill in your FIRST NAME only below."
|
||||
|
||||
[node name="textbox_user_name" type="LineEdit" parent="user_menu"]
|
||||
unique_name_in_owner = true
|
||||
margin_top = 33.0
|
||||
margin_right = 1260.0
|
||||
margin_bottom = 78.0
|
||||
caret_blink = true
|
||||
caret_blink_speed = 0.5
|
||||
|
||||
[node name="button_birth_day" type="MenuButton" parent="."]
|
||||
margin_left = 311.0
|
||||
margin_top = 367.0
|
||||
margin_right = 376.0
|
||||
margin_bottom = 404.0
|
||||
[node name="button_user_save" type="Button" parent="user_menu"]
|
||||
margin_top = 86.0
|
||||
margin_right = 1260.0
|
||||
margin_bottom = 123.0
|
||||
text = "OK"
|
||||
script = ExtResource( 1 )
|
||||
|
||||
[node name="button_birth_day" type="MenuButton" parent="user_menu"]
|
||||
margin_top = 131.0
|
||||
margin_right = 1260.0
|
||||
margin_bottom = 168.0
|
||||
focus_mode = 2
|
||||
text = "Day"
|
||||
|
||||
[node name="label_first_time" type="Label" parent="."]
|
||||
unique_name_in_owner = true
|
||||
visible = false
|
||||
margin_left = 211.0
|
||||
margin_top = 168.0
|
||||
margin_right = 832.0
|
||||
margin_bottom = 193.0
|
||||
text = "First time user: Please fill in your FIRST NAME only below."
|
||||
|
||||
[connection signal="pressed" from="button_user_save" to="button_user_save" method="_on_button_user_save_pressed"]
|
||||
[connection signal="pressed" from="user_menu/button_user_save" to="user_menu/button_user_save" method="_on_button_user_save_pressed"]
|
||||
|
Loading…
Reference in New Issue
Block a user