WeatherInformation Android: current and specific
authorgu.martinm@gmail.com <gu.martinm@gmail.com>
Mon, 8 Sep 2014 13:25:24 +0000 (15:25 +0200)
committergu.martinm@gmail.com <gu.martinm@gmail.com>
Mon, 8 Sep 2014 13:25:24 +0000 (15:25 +0200)
Layouts, final improvements.

Android/WeatherInformation/res/layout/weather_current_fragment.xml
Android/WeatherInformation/res/layout/weather_specific_fragment.xml

index e6a42cd..9e2b192 100644 (file)
@@ -99,7 +99,8 @@
                        android:layout_width="0dp"
                        android:layout_weight="1"
                                android:layout_height="wrap_content"
-                       android:layout_gravity="top|start"
+                       android:gravity="center"
+                       android:layout_gravity="center"
                        android:orientation="horizontal" >
                                <!-- Feels like -->
                                <TextView
                <LinearLayout
                        android:layout_width="0dp"
                        android:layout_height="wrap_content"
-                       android:layout_gravity="top|end"
+                       android:gravity="center"
+                               android:layout_gravity="center"
                        android:layout_weight="1"
                        android:orientation="horizontal" >
                        <!-- Snow -->
                                android:layout_width="0dp"
                                android:layout_weight="1"
                                        android:layout_height="wrap_content"
-                               android:layout_gravity="top|start"
+                               android:gravity="center"
+                               android:layout_gravity="center"
                                android:orientation="horizontal" >
                                <!-- Humidity -->
                                <TextView
                <LinearLayout
                        android:layout_width="0dp"
                        android:layout_height="wrap_content"
-                       android:layout_gravity="top|end"
+                       android:gravity="center"
+                               android:layout_gravity="center"
                        android:layout_weight="1"
                        android:orientation="horizontal" >
                        <!-- Rain -->
                                android:layout_width="0dp"
                                android:layout_weight="1"
                                        android:layout_height="wrap_content"
-                               android:layout_gravity="top|center"
+                               android:gravity="center"
+                               android:layout_gravity="center"
                                android:orientation="horizontal" >
                                <!-- Wind -->
                                <TextView
                                android:layout_width="wrap_content"
                                android:layout_height="wrap_content"
                                android:text="WIND"
-                               android:layout_gravity="top|center"
+                               android:layout_gravity="start"
                                android:gravity="start"
                                android:textAlignment="textStart"
                                android:textColor="@color/weather_time_of_day_color_title"
                                android:layout_width="wrap_content"
                                android:layout_height="wrap_content"
                                        android:text="6.36"
-                               android:layout_gravity="top|center"
+                               android:layout_gravity="start"
                                android:gravity="start"
                                android:textAlignment="textStart"
                                android:layout_marginTop="5dp"
                                android:layout_width="wrap_content"
                                android:layout_height="wrap_content"
                                android:text=" m/s"
-                               android:layout_gravity="top|center"
+                               android:layout_gravity="start"
                                android:gravity="start"
                                android:textAlignment="textStart"
                                android:layout_marginTop="5dp"
                 <LinearLayout
                        android:layout_width="0dp"
                        android:layout_height="wrap_content"
-                       android:layout_gravity="top|center"
+                       android:gravity="center"
+                               android:layout_gravity="center"
                        android:layout_weight="1"
                        android:orientation="horizontal" >
                        <!-- Clouds -->
                                android:layout_width="wrap_content"
                                android:layout_height="wrap_content"
                                android:text="CLOUDS"
-                               android:layout_gravity="top|center"
+                               android:layout_gravity="end"
                                android:gravity="end"
                                android:textAlignment="textEnd"
                                android:textColor="@color/weather_time_of_day_color_title"
                                android:layout_width="wrap_content"
                                android:layout_height="wrap_content"
                                android:text="6.36"
-                               android:layout_gravity="top|center"
+                               android:layout_gravity="end"
                                android:layout_marginTop="5dp"
                                android:layout_marginBottom="5dp"
                                android:gravity="end"
                                android:layout_width="wrap_content"
                                android:layout_height="wrap_content"
                                android:text="%"
-                               android:layout_gravity="top|center"
+                               android:layout_gravity="end"
                                android:gravity="end"
                                android:textAlignment="textEnd"
                                android:layout_marginTop="5dp"
                        android:layout_width="wrap_content"
                        android:layout_height="wrap_content"
                        android:text="PRESSURE"
-                       android:layout_gravity="start"
-                       android:gravity="start"
-                       android:textAlignment="textStart"
+                       android:layout_gravity="center"
+                       android:gravity="center"
+                       android:textAlignment="center"
                        android:textColor="@color/weather_time_of_day_color_title"
                        android:layout_margin="5dp"
                        android:textAppearance="?android:attr/textAppearanceMedium"
                        android:layout_width="wrap_content"
                        android:layout_height="wrap_content"
                        android:text="1036.05"
-                       android:layout_gravity="start"
-                       android:gravity="start"
-                       android:textAlignment="textStart"
+                       android:layout_gravity="center"
+                       android:gravity="center"
+                       android:textAlignment="center"
                        android:layout_marginTop="5dp"
                        android:layout_marginBottom="5dp"
                        android:textAppearance="?android:attr/textAppearanceSmall"
                        android:layout_width="wrap_content"
                        android:layout_height="wrap_content"
                        android:text=" hpa"
-                               android:layout_gravity="start"
-                       android:gravity="start"
-                       android:textAlignment="textStart"
+                               android:layout_gravity="center"
+                       android:gravity="center"
+                       android:textAlignment="center"
                        android:layout_marginTop="5dp"
                        android:layout_marginBottom="5dp"
                        android:layout_marginEnd="5dp"
                        android:layout_width="wrap_content"
                        android:layout_height="wrap_content"
                        android:text="SUN RISE"
-                       android:layout_gravity="start"
-                       android:gravity="start"
-                       android:textAlignment="textStart"
+                       android:layout_gravity="center"
+                       android:gravity="center"
+                       android:textAlignment="center"
                        android:textColor="@color/weather_time_of_day_color_title"
                        android:layout_margin="5dp"
                        android:textAppearance="?android:attr/textAppearanceMedium"
                        android:layout_width="wrap_content"
                        android:layout_height="wrap_content"
                        android:text="2014.04.20 10:29:33"
-                       android:layout_gravity="start"
-                       android:gravity="start"
-                       android:textAlignment="textStart"
+                       android:layout_gravity="center"
+                       android:gravity="center"
+                       android:textAlignment="center"
                        android:layout_marginTop="5dp"
                        android:layout_marginBottom="5dp"
                        android:textAppearance="?android:attr/textAppearanceSmall"
                        android:layout_width="wrap_content"
                        android:layout_height="wrap_content"
                        android:text="SUN SET"
-                       android:layout_gravity="start"
-                       android:gravity="start"
-                       android:textAlignment="textStart"
+                       android:layout_gravity="center"
+                       android:gravity="center"
+                       android:textAlignment="center"
                        android:textColor="@color/weather_time_of_day_color_title"
                        android:layout_margin="5dp"
                        android:textAppearance="?android:attr/textAppearanceMedium"
                        android:layout_width="wrap_content"
                        android:layout_height="wrap_content"
                        android:text="2014.04.20 10:29:33"
-                       android:layout_gravity="start"
-                       android:gravity="start"
-                       android:textAlignment="textStart"
+                       android:layout_gravity="center"
+                       android:gravity="center"
+                       android:textAlignment="center"
                        android:layout_marginTop="5dp"
                        android:layout_marginBottom="5dp"
                        android:textAppearance="?android:attr/textAppearanceSmall"
index f4ef531..bf2102d 100644 (file)
@@ -99,7 +99,8 @@
                        android:layout_width="0dp"
                        android:layout_weight="1"
                                android:layout_height="wrap_content"
-                       android:layout_gravity="top|start"
+                       android:gravity="center"
+                       android:layout_gravity="center"
                        android:orientation="horizontal" >
                        <!-- Humidity -->
                        <TextView
            <LinearLayout
                android:layout_width="0dp"
                android:layout_height="wrap_content"
-               android:layout_gravity="top|end"
+               android:gravity="center"
+                       android:layout_gravity="center"
                android:layout_weight="1"
                android:orientation="horizontal" >
                 <!-- Rain -->
                        android:layout_width="0dp"
                        android:layout_weight="1"
                                android:layout_height="wrap_content"
-                       android:layout_gravity="top|start"
+                       android:gravity="center"
+                       android:layout_gravity="center"
                        android:orientation="horizontal" >
                        
                        <!-- Wind -->
            <LinearLayout
                android:layout_width="0dp"
                android:layout_height="wrap_content"
-               android:layout_gravity="top|end"
+               android:gravity="center"
+                       android:layout_gravity="center"
                android:layout_weight="1"
                android:orientation="horizontal" >                      
                 <!-- Clouds -->
                        android:layout_width="wrap_content"
                        android:layout_height="wrap_content"
                        android:text="PRESSURE"
-                       android:layout_gravity="start"
-                       android:gravity="start"
-                       android:textAlignment="textStart"
+                       android:layout_gravity="center"
+                       android:gravity="center"
+                       android:textAlignment="center"
                        android:textColor="@color/weather_time_of_day_color_title"
                        android:layout_margin="5dp"
                        android:textAppearance="?android:attr/textAppearanceMedium"
                        android:layout_width="wrap_content"
                        android:layout_height="wrap_content"
                        android:text="1036.05"
-                       android:layout_gravity="start"
-                       android:gravity="start"
-                       android:textAlignment="textStart"
+                       android:layout_gravity="center"
+                       android:gravity="center"
+                       android:textAlignment="center"
                        android:layout_marginTop="5dp"
                        android:layout_marginBottom="5dp"
                        android:textAppearance="?android:attr/textAppearanceSmall"
                        android:layout_width="wrap_content"
                        android:layout_height="wrap_content"
                        android:text=" hpa"
-                               android:layout_gravity="start"
-                       android:gravity="start"
-                       android:textAlignment="textStart"
+                               android:layout_gravity="center"
+                       android:gravity="center"
+                       android:textAlignment="center"
                        android:layout_marginTop="5dp"
                        android:layout_marginBottom="5dp"
                        android:layout_marginEnd="5dp"
             android:layout_height="wrap_content"
             android:layout_gravity="bottom|start"
             android:fadingEdge="none"
-            android:padding="25dp"
             android:scrollbars="horizontal|none" >
                        
                <LinearLayout