diff --git a/assets/chrome.png b/assets/chrome.png index d865869a4..a46acfcfe 100644 Binary files a/assets/chrome.png and b/assets/chrome.png differ diff --git a/src/com/shatteredpixel/shatteredpixeldungeon/Chrome.java b/src/com/shatteredpixel/shatteredpixeldungeon/Chrome.java index 0452fc400..4bdb06a85 100644 --- a/src/com/shatteredpixel/shatteredpixeldungeon/Chrome.java +++ b/src/com/shatteredpixel/shatteredpixeldungeon/Chrome.java @@ -52,11 +52,11 @@ public class Chrome { case SCROLL: return new NinePatch( Asset, 32, 32, 32, 32, 5, 11, 5, 11 ); case TAB_SET: - return new NinePatch( Asset, 64, 0, 20, 20, 6, 6, 6, 6 ); + return new NinePatch( Asset, 64, 0, 20, 20, 6 ); case TAB_SELECTED: - return new NinePatch( Asset, 64, 22, 10, 14, 4, 7, 4, 6 ); + return new NinePatch( Asset, 65, 22, 8, 13, 3, 7, 3, 5 ); case TAB_UNSELECTED: - return new NinePatch( Asset, 74, 22, 10, 14, 4, 7, 4, 6 ); + return new NinePatch( Asset, 75, 22, 8, 13, 3, 7, 3, 5 ); default: return null; } diff --git a/src/com/shatteredpixel/shatteredpixeldungeon/windows/WndTabbed.java b/src/com/shatteredpixel/shatteredpixeldungeon/windows/WndTabbed.java index 81056b4d0..30f43a2d9 100644 --- a/src/com/shatteredpixel/shatteredpixeldungeon/windows/WndTabbed.java +++ b/src/com/shatteredpixel/shatteredpixeldungeon/windows/WndTabbed.java @@ -41,7 +41,7 @@ public class WndTabbed extends Window { protected Tab add( Tab tab ) { tab.setPos( tabs.size() == 0 ? - -chrome.marginLeft() : + -chrome.marginLeft() + 1 : tabs.get( tabs.size() - 1 ).right(), height ); tab.select( false ); super.add( tab ); @@ -102,7 +102,8 @@ public class WndTabbed extends Window { } public void layoutTabs(){ - int fullWidth = width+chrome.marginHor(); + //subract two as there's extra horizontal space for those nobs on the top. + int fullWidth = width+chrome.marginHor()-2; int numTabs = tabs.size(); if (numTabs == 0) @@ -116,7 +117,7 @@ public class WndTabbed extends Window { int spacing = -1; while (spacing == -1) { - for (int i = 0; i <= 5; i++){ + for (int i = 0; i <= 3; i++){ if ((fullWidth - i*(spaces)) % numTabs == 0) { spacing = i; break; @@ -130,7 +131,7 @@ public class WndTabbed extends Window { for (int i = 0; i < tabs.size(); i++){ tabs.get(i).setSize(tabWidth, tabHeight()); tabs.get(i).setPos( i == 0 ? - -chrome.marginLeft() : + -chrome.marginLeft() + 1 : tabs.get( i - 1 ).right() + spacing, height ); }