Mainmenu: Improve button alignment
authorezhh <owlecho@live.com>
Fri, 17 Nov 2017 21:45:39 +0000 (21:45 +0000)
committerparamat <mat.gregory@virginmedia.com>
Sun, 19 Nov 2017 00:24:40 +0000 (00:24 +0000)
builtin/mainmenu/tab_local.lua
builtin/mainmenu/tab_mods.lua
builtin/mainmenu/tab_online.lua
builtin/mainmenu/tab_settings.lua

index 3e62078ce1eea55e158a43b5076d7014b84bcfba..6759893cefa60ab3af52448d789d32a021b69263 100644 (file)
@@ -93,9 +93,9 @@ local function get_formspec(tabview, name, tabdata)
                                )
 
        retval = retval ..
-                       "button[4,4.15;2.6,0.5;world_delete;".. fgettext("Delete") .. "]" ..
-                       "button[6.5,4.15;2.8,0.5;world_create;".. fgettext("New") .. "]" ..
-                       "button[9.2,4.15;2.55,0.5;world_configure;".. fgettext("Configure") .. "]" ..
+                       "button[4,3.95;2.6,1;world_delete;".. fgettext("Delete") .. "]" ..
+                       "button[6.5,3.95.15;2.8,1;world_create;".. fgettext("New") .. "]" ..
+                       "button[9.2,3.95;2.5,1;world_configure;".. fgettext("Configure") .. "]" ..
                        "label[4,-0.25;".. fgettext("Select World:") .. "]"..
                        "checkbox[0.25,0.25;cb_creative_mode;".. fgettext("Creative Mode") .. ";" ..
                        dump(core.settings:get_bool("creative_mode")) .. "]"..
@@ -109,7 +109,7 @@ local function get_formspec(tabview, name, tabdata)
 
        if core.settings:get_bool("enable_server") then
                retval = retval ..
-                               "button[8.5,5;3.25,0.5;play;".. fgettext("Host Game") .. "]" ..
+                               "button[8.5,4.8;3.2,1;play;".. fgettext("Host Game") .. "]" ..
                                "checkbox[0.25,1.6;cb_server_announce;" .. fgettext("Announce Server") .. ";" ..
                                dump(core.settings:get_bool("server_announce")) .. "]" ..
                                "label[0.25,2.2;" .. fgettext("Name/Password") .. "]" ..
@@ -131,7 +131,7 @@ local function get_formspec(tabview, name, tabdata)
                end
        else
                retval = retval ..
-                               "button[8.5,5;3.25,0.5;play;".. fgettext("Play Game") .. "]"
+                               "button[8.5,4.8;3.2,1;play;".. fgettext("Play Game") .. "]"
        end
 
        return retval
index ccd92fb138518e0f02bbd21bd13b2364d207e8f1..60e21ee27dc18f2b6a3a7c1e460e9c813aca3403 100644 (file)
@@ -84,9 +84,9 @@ local function get_formspec(tabview, name, tabdata)
 
                if selected_mod.is_modpack then
                        retval = retval .. ";0]" ..
-                               "button[10,4.85;2,0.5;btn_mod_mgr_rename_modpack;" ..
+                               "button[9.9,4.65;2,1;btn_mod_mgr_rename_modpack;" ..
                                fgettext("Rename") .. "]"
-                       retval = retval .. "button[5.5,4.85;4.5,0.5;btn_mod_mgr_delete_mod;"
+                       retval = retval .. "button[5.5,4.65;4.5,1;btn_mod_mgr_delete_mod;"
                                .. fgettext("Uninstall Selected Modpack") .. "]"
                else
                        --show dependencies
@@ -109,7 +109,7 @@ local function get_formspec(tabview, name, tabdata)
 
                        retval = retval .. ";0]"
 
-                       retval = retval .. "button[5.5,4.85;4.5,0.5;btn_mod_mgr_delete_mod;"
+                       retval = retval .. "button[5.5,4.65;4.5,1;btn_mod_mgr_delete_mod;"
                                .. fgettext("Uninstall Selected Mod") .. "]"
                end
        end
index b387d9556dc2d8f6fe130cc07d843239c33f15ec..d1c9bcc989513dba3c9acb19bc6a0116ea57c30f 100644 (file)
@@ -33,8 +33,8 @@ local function get_formspec(tabview, name, tabdata)
 
        local retval =
                -- Search
-               "field[0.15,0.35;6.05,0.27;te_search;;"..core.formspec_escape(tabdata.search_for).."]"..
-               "button[5.8,0.1;2,0.1;btn_mp_search;" .. fgettext("Search") .. "]" ..
+               "field[0.15,0.075;6.05,1;te_search;;"..core.formspec_escape(tabdata.search_for).."]"..
+               "button[5.8,-0.25;2,1;btn_mp_search;" .. fgettext("Search") .. "]" ..
 
                -- Address / Port
                "label[7.75,-0.25;" .. fgettext("Address / Port") .. "]" ..
@@ -53,11 +53,11 @@ local function get_formspec(tabview, name, tabdata)
                "box[7.73,2.25;4.25,2.6;#999999]"..
 
                -- Connect
-               "button[10.1,5.15;2,0.5;btn_mp_connect;" .. fgettext("Connect") .. "]"
+               "button[9.88,4.9;2.3,1;btn_mp_connect;" .. fgettext("Connect") .. "]"
 
        if tabdata.fav_selected and fav_selected then
                if gamedata.fav then
-                       retval = retval .. "button[7.75,5.15;2.3,0.5;btn_delete_favorite;" ..
+                       retval = retval .. "button[7.73,4.9;2.3,1;btn_delete_favorite;" ..
                                fgettext("Del. Favorite") .. "]"
                end
                if fav_selected.description then
index 281dde3d0f8ce3c486595d0e2ac9000bcded4922..f260490270ff040b088d366cc3683749ceb234fe 100644 (file)
@@ -209,16 +209,16 @@ local function formspec(tabview, name, tabdata)
 
        if PLATFORM == "Android" then
                tab_string = tab_string ..
-                       "button[8,4.75;4.1,1;btn_reset_singleplayer;"
+                       "button[8,4.75;3.95,1;btn_reset_singleplayer;"
                        .. fgettext("Reset singleplayer world") .. "]"
        else
                tab_string = tab_string ..
-                       "button[8,4.75;4,1;btn_change_keys;"
+                       "button[8,4.75;3.95,1;btn_change_keys;"
                        .. fgettext("Change Keys") .. "]"
        end
 
        tab_string = tab_string ..
-               "button[0,4.75;4,1;btn_advanced_settings;"
+               "button[0,4.75;3.95,1;btn_advanced_settings;"
                .. fgettext("Advanced Settings") .. "]"