androiddesignsupport

Custom TextSize of BottomNavigationView support android

天大地大妈咪最大 提交于 2019-11-27 00:26:57
问题 I am trying to change the textSize of BottomNavigationView from android support library 25.0.0 <android.support.design.widget.BottomNavigationView android:id="@+id/bottom_navigation_view" android:layout_width="match_parent" android:layout_height="wrap_content" android:layout_alignParentBottom="true" android:background="@color/colorPrimaryDark" android:foregroundTint="@color/colorAccent" app:itemIconTint="@android:color/white" app:itemTextColor="@android:color/white" app:layout_anchor="@id/lyt

Add views below toolbar in CoordinatorLayout

对着背影说爱祢 提交于 2019-11-26 23:25:24
I have the following layout: <android.support.design.widget.CoordinatorLayout android:id="@+id/main_content" xmlns:android="http://schemas.android.com/apk/res/android" xmlns:app="http://schemas.android.com/apk/res-auto" android:layout_width="match_parent" android:layout_height="match_parent"> <android.support.design.widget.AppBarLayout android:id="@+id/appBar" android:layout_width="match_parent" android:layout_height="wrap_content" android:theme="@style/ThemeOverlay.AppCompat.ActionBar"> <android.support.v7.widget.Toolbar android:id="@+id/toolbar" android:layout_width="match_parent" android

Remove BottomNavigationView labels

こ雲淡風輕ζ 提交于 2019-11-26 22:18:31
Google released new support library v25 with BottomNavigationView is there any way to remove items labels ? I hope I am not too late to the party here. But as of Design Support Library 28.0.0-alpha1 you can use the property app:labelVisibilityMode="unlabeled" you can use other values "auto", "labeled" and "selected" as well. ittianyu Would you want to this style ? If so, I recommend you try BottomNavigationViewEx . Unfortunately this first version of BottomNavigationView came with a lot of limitations. And for now you can't remove the titles just using the support design API. So to solve this

NavigationView menu items with counter on the right

只谈情不闲聊 提交于 2019-11-26 21:39:09
The new NavigationView in the new Design Support Library works really great. They use " menu-items " to display the options. But how can I display a counter to the right of the menu item? Like in this picture: Or like in the GMail app. Starting from version 23 of appcompat-v7 NavigationView supports action views, so it is quite easy to implement counter yourself. Create counter layout, i.e. menu_counter.xml : <?xml version="1.0" encoding="utf-8"?> <TextView xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="wrap_content" android:layout_height="match_parent"

Android design library CoordinatorLayout, AppBarLayout and DrawerLayout

最后都变了- 提交于 2019-11-26 21:13:16
问题 I'm using the Android design library on API 22. I would like to: have a Toolbar and a DrawerLayout inside which there is a RecyclerView have the DrawerLayout be below the Toolbar; for example, when the toolbar is visible, the drawer's main content should be below it, and the (left) drawer should also be below it so that when it is expanded, the toolbar is still visible have Toolbar be scrolled off the screen when the recycler view is scrolled down Is this even possible? I have problems to

Floating Action Button not showing fully inside a fragment

血红的双手。 提交于 2019-11-26 18:58:09
问题 I am using FAB button along with RecyclerView in a Fragment. This Fragment is an instance of a TabViewPager. I am having a issue with the FAB button. I have placed the RecyclerView and the fab button inside a FrameLayout, where the FAB buttton is positioned bottom right. Now the problem that I am facing is the FAB button is not fully visible. Its half of the portion is hidden as shown in the screenshot below. Can any one help me to solve this issue. Thanks in advance. Note: The FAB is

In android how to set navigation drawer header image and name programmatically in class file?

谁都会走 提交于 2019-11-26 18:52:19
问题 In android studio 1.4.1, I have created new Navigation Drawer Project which is default.My issue is in this project there is nav_header_main.xml file which is for navigation header image and name. I want this image and name should be set programmatically in my main class activity. How to do this, I tried lot but the app crashes. nav_header_main.xml <?xml version="1.0" encoding="utf-8"?> <LinearLayout android:layout_width="match_parent" android:id="@+id/headerView" android:layout_height="@dimen

android:textAllCaps=“false” not working for TabLayout design Support

南楼画角 提交于 2019-11-26 17:31:46
问题 I have set android:textAllCaps="false" in my android.support.design.widget.TabLayout thought it is showing the Tab Title in All caps only. How can I remove all caps? 回答1: UPDATE FOR DESIGN LIBRARY 23.2.0+ The original answer doesn't work with design library 23.2.0 or later. Thanks for @fahmad6 pointed out in comment, in case someone missed that comment, I'll put it here. You need to set both textAllCaps and android:textAllCaps to false to disable all capitalize setting. <style name=

Getting exception : java.lang.NoClassDefFoundError: android.support.v7.app.AppCompatDelegateImplV14

牧云@^-^@ 提交于 2019-11-26 17:16:25
问题 I updated Android Studio and the android design library recently since then I am getting an exception java.lang.NoClassDefFoundError: android.support.v7.app.AppCompatDelegateImplV14 . Not sure what is the problem, I tried almost everything, its working in lollipop 5.1 device(nexus 4) but it does not work in Android 4.4 device and 4.02 device. It was working before the updation in all versions. I tried all solutions mentioned in stackoverflow but nothing worked for me. Also tried removing the

Can't use srcCompat for ImageViews in android

徘徊边缘 提交于 2019-11-26 16:04:39
问题 I'm using the Design Support Library 23.2. I've added these lines in my build.gradle as my Gradle Plugin is version 1.5 defaultConfig { applicationId "com.abc.xyz" minSdkVersion 16 targetSdkVersion 23 versionCode 1 versionName "1.0" generatedDensities = [] } aaptOptions { additionalParameters "--no-version-vectors" } } as it's specified in here But I can't use the srcCompat attribute for my imageview. <ImageView android:layout_width="wrap_content" android:layout_height="wrap_content" android