Tag: android-coordinatorlayout

Using windowTranslucentStatus with hidden Toolbar

I’m trying to incorporate windowTranslucentStatus and AppBarLayout with Toolbar flagged with app:layout_scrollFlags=”scroll|enterAlways” Testing simultaneously on APIs 18, 19 and 22 (from the left). Problem is on the highest API, where toolbar is partialy visible under the statusbar. I tried many many combinations of styles but this is the closest I got. In styles I use: […]

Animating logo along with collapsing toolbar within CoordinatorLayout

I want to implement collapsible toolbar with a logo in the following manner: Flexible Space with overlapping content, like shown here (have this already); Parallaxed pattern in this space that gets scrimmed with solid color (have this too) A horizontally-centered logo, which must appear right above the content but float upwards as toolbar collapses: In […]

Issue with CoordinatorLayout and ImageView that adjusts width while scrolling

I’m attempting to put an ImageView in a CollapsingToolbarLayout in which it takes up the full screen on load and as you scroll the content, the 16×9 resolution image width resizes until the image takes up the full width of the screen. At that point, I’d like the image to parallax with a app:layout_collapseParallaxMultiplier of […]

ImageView inside CollapsingToolbarLayout not visible in certain devices

I am using CollapsingToolbarLayout with two images inside, one for the background and one as an upper logo. The idea is to make them both parallax. This thing works fine in Android 5 in physical devices, but not in devices (or emulators) with lower versions. Kind of strange. This is my layout: <android.support.design.widget.CoordinatorLayout xmlns:android=”http://schemas.android.com/apk/res/android” xmlns:app=”http://schemas.android.com/apk/res-auto” […]

CoordinatorLayout/AppBarLayout ExpandableListView being rendered off screen

Yet more problem in using CoordinatorLayout and AppBarLayout. I’m trying to achieve the basic functionality of having the Toolbar scroll off screen when scrolling down and coming back on screen when scrolling up. However, my current set up is showing a problem: Not only is the Toolbar not scrolling off, the ListView seems to be […]

How to create AppBarLayout which overlaps content of CoordinatorLayout

When using a CoordinatorLayout with AppBarLayout on some activities I need the content to be under the AppBarLayout, i.e. the Toolbar is using some transparent color and overlays the content. By default CoordinatorLayout + AppBarLayout arrange things so that toolbar and scrolling content are next to eachother, without any overlapping. Android developer guides have the […]

Strange behaviour of the CoordinatorLayout in conjunction with ViewPager

I have the following main page layout in my app: <?xml version=”1.0″ encoding=”utf-8″?> <android.support.design.widget.CoordinatorLayout 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.v4.view.ViewPager android:id=”@+id/mainPager” android:layout_width=”match_parent” android:layout_height=”wrap_content” app:layout_behavior=”@string/app_bar_scrolling_view_behavior”> </android.support.v4.view.ViewPager> <android.support.design.widget.AppBarLayout android:layout_width=”match_parent” android:layout_height=”wrap_content” > <android.support.v7.widget.Toolbar xmlns:android=”http://schemas.android.com/apk/res/android” android:id=”@+id/actionToolbar” android:layout_height=”wrap_content” android:layout_width=”match_parent” android:minHeight=”?attr/actionBarSize” android:theme=”@style/ThemeOverlay.AppCompat.Dark.ActionBar” app:title=”@string/app_name” app:popupTheme=”@style/ThemeOverlay.AppCompat.Light” android:background=”?attr/colorPrimary” app:layout_scrollFlags=”scroll|enterAlways”> </android.support.v7.widget.Toolbar> <android.support.design.widget.TabLayout android:id=”@+id/tabLayout” android:layout_width=”match_parent” android:layout_height=”wrap_content” android:theme=”@style/ThemeOverlay.AppCompat.Dark.ActionBar” app:layout_scrollFlags=”scroll|enterAlways”> </android.support.design.widget.TabLayout> </android.support.design.widget.AppBarLayout> </android.support.design.widget.CoordinatorLayout> The scrollable content is the ViewPager. […]

adjustResize does not work with CoordinatorLayout

I have the following layout in my android app but I have a problem with windowSoftInputMode=”adjustResize” in the activity: The LinearLayout named “container” contains multiple EditTexts but when one of them has focus and the keyboard appears, the Activity does not resize and the EditText is hidden behind the keyboard. I think this has something […]

Scrolling with Collapsing Toolbar and Tabs

I’m trying to make a layout with a CollapsingToolbarLayout which has scroll|exitUntilCollapsed flag, and a TabLayout which has scroll|enterAlways scrollFlag property. Basically I want my toolbar to be pinned and show and hide the tabs while scrolling. I’ve modified the cheesesquare app from https://github.com/chrisbanes/cheesesquare. Here is my layout xml; <?xml version=”1.0″ encoding=”utf-8″?> <android.support.design.widget.CoordinatorLayout xmlns:android=”http://schemas.android.com/apk/res/android” xmlns:app=”http://schemas.android.com/apk/res-auto” […]

CoordinatorLayout custom behavior with AppBarLayout

I am trying to achieve a similar behavior to that of Telegram, on the settings page, that is, there is a CircleImage that when scrolling up goes to the left of the Topbar title, and when scrolling down goes to the middle of the expanded AppBarLayout. I was basing my work on this example: https://github.com/saulmm/CoordinatorBehaviorExample […]

Android Babe is a Google Android Fan, All about Android Phones, Android Wear, Android Dev and Android Games Apps and so on.