Android DatePicker style messed up -
i'm developping android app , @ point needed use datepicker. i'm using bit of code here. datepickerfragment pops has style messed :
this layout of activity :
<linearlayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:tools="http://schemas.android.com/tools" android:layout_width="match_parent" android:layout_height="match_parent" android:paddingleft="@dimen/activity_horizontal_margin" android:paddingright="@dimen/activity_horizontal_margin" android:paddingtop="@dimen/activity_vertical_margin" android:paddingbottom="@dimen/activity_vertical_margin" tools:context="narthe.compteur_km.exportactivity" android:background="#ff1a2530" android:gravity="center" android:orientation="vertical"> <textview android:id="@+id/showmydate" android:layout_width="fill_parent" android:layout_height="wrap_content"/> <button android:id="@+id/mydatepickerbutton" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="@string/pick_date" android:onclick="showdatepickerdialog" /> <button style="@style/customeditbutton" android:layout_width="fill_parent" android:layout_height="wrap_content" android:text="@string/exporter" android:id="@+id/exportbutton" android:layout_margintop="20dp" android:textstyle="bold" android:textsize="25sp" /> </linearlayout>
so doing wrong ? there style of mine overriding native style ? (tried remove "style="@style/customeditbutton" line in second button same result)
i realised had defined global background color whole app in styles.xml follow :
<style name="apptheme" parent="theme.appcompat.light.darkactionbar"> <item name="android:background">#ff1a2530</item> </style>
so removed , got right style date picker.
Comments
Post a Comment