diff --git a/TheGameExtreme/view/HomePage.xaml.cs b/TheGameExtreme/view/HomePage.xaml.cs index c9dc2e3..6e0677a 100644 --- a/TheGameExtreme/view/HomePage.xaml.cs +++ b/TheGameExtreme/view/HomePage.xaml.cs @@ -1,7 +1,6 @@ using System; using Xamarin.Forms; using TheGameExtreme.IO; -using Android.Views; namespace TheGameExtreme.view { diff --git a/TheGameExtreme/view/MainPage.xaml.cs b/TheGameExtreme/view/MainPage.xaml.cs index 07f36aa..2d3d754 100644 --- a/TheGameExtreme/view/MainPage.xaml.cs +++ b/TheGameExtreme/view/MainPage.xaml.cs @@ -196,10 +196,11 @@ namespace TheGameExtreme.view stackCollection.Clear(); SKPaint textPaint = new SKPaint(); - SKPoint position = new SKPoint((float)((DeviceDisplay.MainDisplayInfo.Width - 20) / (viewmodel.getListOrderedStacks().Count * 2)) + 10f, (float)((DeviceDisplay.MainDisplayInfo.Height * 0.1) + (DeviceDisplay.MainDisplayInfo.Height * 0.9) * 0.01 + 2 * (0.05f * (float)DeviceDisplay.MainDisplayInfo.Width * textPaint.TextSize / textPaint.MeasureText("001")))); float inflateWidth = 0.024f * (float)(DeviceDisplay.MainDisplayInfo.Width - 20); + SKPoint position = new SKPoint((float)((DeviceDisplay.MainDisplayInfo.Width - 20 - inflateWidth) / (viewmodel.getListOrderedStacks().Count * 2)) + 10f, (float)((DeviceDisplay.MainDisplayInfo.Height * 0.1) + (DeviceDisplay.MainDisplayInfo.Height * 0.9) * 0.01 + 2 * (0.05f * (float)DeviceDisplay.MainDisplayInfo.Width * textPaint.TextSize / textPaint.MeasureText("001")))); + position.X -= inflateWidth; for (int i = 0; i < viewmodel.getListOrderedStacks().Count; i++) @@ -226,7 +227,7 @@ namespace TheGameExtreme.view InitialPoint = position }); - position.X += (float)((DeviceDisplay.MainDisplayInfo.Width - 20) / viewmodel.getListOrderedStacks().Count) + textWidth * 0.5f; + position.X += (float)((DeviceDisplay.MainDisplayInfo.Width - 20 - inflateWidth) / viewmodel.getListOrderedStacks().Count) + textWidth * 0.5f; } } @@ -237,10 +238,11 @@ namespace TheGameExtreme.view private void InflateHand() { SKPaint textPaint = new SKPaint(); - SKPoint position = new SKPoint((float)((DeviceDisplay.MainDisplayInfo.Width - 20) / (viewmodel.CurrentHand.Count * 2)) + 10f, (float)((DeviceDisplay.MainDisplayInfo.Height * 0.9) - (DeviceDisplay.MainDisplayInfo.Height * 0.9) * 0.1 - 2 * (0.05f * (float)(DeviceDisplay.MainDisplayInfo.Width - 20) * textPaint.TextSize / textPaint.MeasureText("001")))); float inflateWidth = 0.024f * (float)(DeviceDisplay.MainDisplayInfo.Width - 20); + SKPoint position = new SKPoint((float)((DeviceDisplay.MainDisplayInfo.Width - 20 - inflateWidth) / (viewmodel.CurrentHand.Count * 2)) + 10f, (float)((DeviceDisplay.MainDisplayInfo.Height * 0.9) - (DeviceDisplay.MainDisplayInfo.Height * 0.9) * 0.1 - 2 * (0.05f * (float)(DeviceDisplay.MainDisplayInfo.Width - 20) * textPaint.TextSize / textPaint.MeasureText("001")))); + position.X -= inflateWidth; for (int i = 0; i < viewmodel.CurrentHand.Count; i++) @@ -267,7 +269,7 @@ namespace TheGameExtreme.view InitialPoint = position }); - position.X += (float)((DeviceDisplay.MainDisplayInfo.Width - 20) / viewmodel.CurrentHand.Count) + textWidth * 0.5f; + position.X += (float)((DeviceDisplay.MainDisplayInfo.Width - 20 - inflateWidth) / viewmodel.CurrentHand.Count) + textWidth * 0.5f; } } diff --git a/TheGameExtreme/view/RulesGame.xaml b/TheGameExtreme/view/RulesGame.xaml index 5481ff9..92395e5 100644 --- a/TheGameExtreme/view/RulesGame.xaml +++ b/TheGameExtreme/view/RulesGame.xaml @@ -1,12 +1,13 @@  - + @@ -55,14 +56,11 @@ + Grid.ColumnSpan="3" + Margin="20,0,20,0">