1
0
Fork 0
mirror of https://github.com/Orama-Interactive/Pixelorama.git synced 2025-01-18 17:19:50 +00:00

3 themes available under Preferences, changed theme organization

Dark theme (default), gray theme, Godot's theme
This commit is contained in:
OverloadedOrama 2019-12-20 05:22:03 +02:00
parent 71d4a58a8c
commit abee0653d6
9 changed files with 28 additions and 20 deletions

View file

@ -1,8 +1,8 @@
[gd_scene load_steps=81 format=2]
[ext_resource path="res://Themes & Styles/Main Theme/Original Theme.tres" type="Theme" id=1]
[ext_resource path="res://Themes & Styles/Dark Theme/Dark Theme.tres" type="Theme" id=1]
[ext_resource path="res://Scripts/Main.gd" type="Script" id=2]
[ext_resource path="res://Themes & Styles/Main Theme/OriginalTopMenuStyle.tres" type="StyleBox" id=3]
[ext_resource path="res://Themes & Styles/Dark Theme/DarkTopMenuStyle.tres" type="StyleBox" id=3]
[ext_resource path="res://Assets/Graphics/Tools/RectSelect.png" type="Texture" id=4]
[ext_resource path="res://Assets/Graphics/Tools/ColorPicker.png" type="Texture" id=5]
[ext_resource path="res://Assets/Graphics/Tools/Pencil_l.png" type="Texture" id=6]
@ -1478,8 +1478,8 @@ resizable = true
mode = 0
access = 2
filters = PoolStringArray( "*.pxo ; Pixelorama Project" )
current_dir = "C:/Users/User/Desktop/Github/Pixelorama"
current_path = "C:/Users/User/Desktop/Github/Pixelorama/"
current_dir = "C:/Users/Overloaded/Dropbox/Orama Founding Members/εταιρικα αρχεια/Godot Projects/Pixelorama"
current_path = "C:/Users/Overloaded/Dropbox/Orama Founding Members/εταιρικα αρχεια/Godot Projects/Pixelorama/"
[node name="SaveSprite" type="FileDialog" parent="."]
anchor_left = 0.5
@ -1494,8 +1494,8 @@ window_title = "Save Sprite as .pxo"
resizable = true
access = 2
filters = PoolStringArray( "*.pxo ; Pixelorama Project" )
current_dir = "C:/Users/User/Desktop/Github/Pixelorama"
current_path = "C:/Users/User/Desktop/Github/Pixelorama/"
current_dir = "C:/Users/Overloaded/Dropbox/Orama Founding Members/εταιρικα αρχεια/Godot Projects/Pixelorama"
current_path = "C:/Users/Overloaded/Dropbox/Orama Founding Members/εταιρικα αρχεια/Godot Projects/Pixelorama/"
[node name="ImportSprites" type="FileDialog" parent="."]
margin_right = 515.0
@ -1505,8 +1505,8 @@ resizable = true
mode = 1
access = 2
filters = PoolStringArray( "*.bmp ; BMP Image", "*.hdr ; Radiance HDR Image", "*.jpg,*.jpeg ; JPEG Image", "*.png ; PNG Image", "*.svg ; SVG Image", "*.tga ; TGA Image", "*.webp ; WebP Image" )
current_dir = "C:/Users/User/Desktop/Github/Pixelorama"
current_path = "C:/Users/User/Desktop/Github/Pixelorama/"
current_dir = "C:/Users/Overloaded/Dropbox/Orama Founding Members/εταιρικα αρχεια/Godot Projects/Pixelorama"
current_path = "C:/Users/Overloaded/Dropbox/Orama Founding Members/εταιρικα αρχεια/Godot Projects/Pixelorama/"
[node name="ExportSprites" type="FileDialog" parent="."]
anchor_left = 0.5
@ -1521,8 +1521,8 @@ window_title = "Export Sprite"
resizable = true
access = 2
filters = PoolStringArray( "*.png ; PNG Image" )
current_dir = "C:/Users/User/Desktop/Github/Pixelorama"
current_path = "C:/Users/User/Desktop/Github/Pixelorama/"
current_dir = "C:/Users/Overloaded/Dropbox/Orama Founding Members/εταιρικα αρχεια/Godot Projects/Pixelorama"
current_path = "C:/Users/Overloaded/Dropbox/Orama Founding Members/εταιρικα αρχεια/Godot Projects/Pixelorama/"
[node name="ScaleImage" type="ConfirmationDialog" parent="."]
editor/display_folded = true
@ -1677,8 +1677,8 @@ visible = false
[node name="NewPaletteDialog" parent="." instance=ExtResource( 60 )]
[node name="PaletteImportFileDialog" parent="." instance=ExtResource( 61 )]
current_dir = "C:/Users/User/Desktop/Github/Pixelorama"
current_path = "C:/Users/User/Desktop/Github/Pixelorama/"
current_dir = "C:/Users/Overloaded/Dropbox/Orama Founding Members/εταιρικα αρχεια/Godot Projects/Pixelorama"
current_path = "C:/Users/Overloaded/Dropbox/Orama Founding Members/εταιρικα αρχεια/Godot Projects/Pixelorama/"
[node name="AnimationTimer" type="Timer" parent="."]

View file

@ -1,9 +1,13 @@
[gd_scene load_steps=3 format=2]
[ext_resource path="res://Themes & Styles/Main Theme/Main Theme.tres" type="Theme" id=1]
[ext_resource path="res://Themes & Styles/Godot's Theme/Godot's Theme.tres" type="Theme" id=1]
[ext_resource path="res://Scripts/NotificationLabel.gd" type="Script" id=2]
[node name="NotificationLabel" type="Label"]
margin_right = 116.0
margin_bottom = 14.0

View file

@ -48,8 +48,8 @@ margin_top = 24.0
margin_right = 218.0
margin_bottom = 44.0
text = "Dark Theme"
items = [ "Main Theme", null, false, 0, null, "Dark Theme", null, false, 1, null ]
selected = 1
items = [ "Dark Theme", null, false, 0, null, "Gray Theme", null, false, 1, null, "Godot's Theme", null, false, 2, null ]
selected = 0
[node name="GridOptionsLabel" type="Label" parent="VBoxContainer"]
margin_top = 48.0

View file

@ -17,14 +17,18 @@ func _on_ThemeOption_item_selected(ID : int) -> void:
var main_theme
var top_menu_style
var ruler_style
if ID == 0: #Main Theme
main_theme = preload("res://Themes & Styles/Main Theme/Main Theme.tres")
top_menu_style = preload("res://Themes & Styles/Main Theme/TopMenuStyle.tres")
ruler_style = preload("res://Themes & Styles/Main Theme/RulerStyle.tres")
elif ID == 1: #Dark Theme
if ID == 0: #Dark Theme
main_theme = preload("res://Themes & Styles/Dark Theme/Dark Theme.tres")
top_menu_style = preload("res://Themes & Styles/Dark Theme/DarkTopMenuStyle.tres")
ruler_style = preload("res://Themes & Styles/Dark Theme/DarkRulerStyle.tres")
elif ID == 1: #Gray Theme
main_theme = preload("res://Themes & Styles/Gray Theme/Gray Theme.tres")
top_menu_style = preload("res://Themes & Styles/Gray Theme/GrayTopMenuStyle.tres")
ruler_style = preload("res://Themes & Styles/Dark Theme/DarkRulerStyle.tres")
elif ID == 2: #Godot's Theme
main_theme = preload("res://Themes & Styles/Godot\'s Theme/Godot\'s Theme.tres")
top_menu_style = preload("res://Themes & Styles/Godot\'s Theme/TopMenuStyle.tres")
ruler_style = preload("res://Themes & Styles/Godot\'s Theme/RulerStyle.tres")
Global.control.theme = main_theme
Global.top_menu_container.add_stylebox_override("panel", top_menu_style)