android-support-library

ToolBar disappears when setting elevation for AppBarLayout

↘锁芯ラ 提交于 2019-12-06 17:35:28
My ToolBar disappears when setting elevation for AppBarLayout . Here's the layout. <android.support.design.widget.AppBarLayout android:id="@+id/appbar" android:layout_width="match_parent" android:layout_height="@dimen/appbar_height" app:elevation="0dp" android:background="@color/transparent"> <android.support.v7.widget.Toolbar style="@style/ToolBarStyle" android:id="@+id/toolbar" android:layout_width="match_parent" android:layout_height="wrap_content" app:elevation="0dp" android:background="@drawable/backgorund_toolbar_tranluscent" android:minHeight="@dimen/abc_action_bar_default_height

BACK-PORTING can use PdfDocument (API 19) in jellybean API 16? [closed]

情到浓时终转凉″ 提交于 2019-12-06 16:29:12
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed 6 months ago . I'm compiling using Android 4.4.2 (API19) but running on Android 4.1.1 API 16 . Is there an Android support library,or something, so I can use PdfDocument.java (API 19) in Jellybean API 16 ? code: import android.graphics.pdf.PdfDocument; import android.graphics.pdf.PdfDocument.Page; import android.graphics.pdf

BottomNavigationView hides when scrolling up instead of down

我与影子孤独终老i 提交于 2019-12-06 13:26:05
The new BottomNavigationView from support library v25.0.0 is supposed to hide when scrolling down, in order to see all the items from a list. However, in my testing scenario, the view hides when scrolling up. Any ideas what can cause this reverse behavior? The inner_fragment is set up as a Fragment inserted inside the activity_main_framelayout_content Framelayout. XML layouts below: main_activity.xml: <android.support.design.widget.CoordinatorLayout android:id="@+id/activity_main_coordinatorlayout" android:layout_width="match_parent" android:layout_height="match_parent"> <android.support

Android: how to the design app for Smartphone AND Tablet?

只愿长相守 提交于 2019-12-06 12:29:57
I know there are already quite a lot of blog entries , how to's , questions out there that cover backward compatibility of Android 3.0 apps. However, after reading them all I'm just more confused than before. :( What I have is a Smartphone app that supports min. SDK version 8 (2.2). I now want this one to stay the same on Smartphones, but also provide a fancy version on Honeycomb Tablets with Action Bar and Fragments and so on. I know there is the compatibility pack, but all I read about it was about Fragments. What's with the Action Bar and the holographic Theme? I did get this pretty nice

How to align message textview to the center in snackbar?

我与影子孤独终老i 提交于 2019-12-06 11:58:23
How to align message textview to the center Horizontally in snackbar in android? Below is a sample, for making the Snackbar Text center horizontal Snackbar snackbar = Snackbar.make(findViewById(R.id.coordinatorLayout), "Hello", Snackbar.LENGTH_SHORT); snackbar.show(); View view = snackbar.getView(); TextView txtv = (TextView) view.findViewById(android.support.design.R.id.snackbar_text); txtv.setGravity(Gravity.CENTER_HORIZONTAL); Try to set both textAlignment and Gravity to the Gravity.CENTER_HORIZONTAL snackTextView.setGravity(Gravity.CENTER_HORIZONTAL); snackTextView.setTextAlignment(Gravity

Set the spacing between title and v7 drawer toggle

孤街醉人 提交于 2019-12-06 11:50:00
问题 I'm now using ActionBarDrawerToggle of the v7 support library. But the drawer icon is directly at the title font as I have disabled showHomeEnabled. How can I set more free space between the title and the toggle? Thanks 回答1: In fact, this is sadly not really realizable. The simplest thing to do is to use ActionBarCompat or if you're just caring about that on 5.0+, Theme.Material. It looks much better then and obviously, Google kinda wants us to use ActionBarCompat as there are some issues

android-support-multidex.jar not working in eclipse

≯℡__Kan透↙ 提交于 2019-12-06 11:15:54
问题 Recently I faced 65K method limitation issue in my android project. Then I started to implement multidex in that projects. When I try to add this support library in eclipse, the issue not resolved. Still it showing the 65K limitation. But when its working fine in Gradle+Android studio. How can i achieve this in eclipse? Because I don't want to switch to Android studio now. Here is the steps I have followed, 1) Added the android-support-multidex.jar into build path, 2) overrided, the below

Multiple dex files define Landroid/support/v7/app/ActionBar$DisplayOptions

只谈情不闲聊 提交于 2019-12-06 10:45:58
My Project shows no errors. Though when I run the application it says please fix the error before running your application. When I looked at Console tab it says [2015-07-10 19:50:26 - Dex Loader] Unable to execute dex: Multiple dex files define Landroid/support/v7/app/ActionBar$DisplayOptions; [2015-07-10 19:50:26 - NavigationDrawer] Conversion to Dalvik format failed: Unable to execute dex: Multiple dex files define Landroid/support/v7/app/ActionBar$DisplayOptions; I tried searching for the solution but haven't got any. this is what I have for my support libraries. Please Help. I got stuck

java.lang.NoSuchMethodError: No static method isCtrlPressed(Landroid/view/KeyEvent;)Z in class Landroid/support/v4/view/KeyEventCompatHoneycomb;

青春壹個敷衍的年華 提交于 2019-12-06 10:29:15
I got this type of error while executing App. My code is work in support library 24.2.0 (Android studio in Linux operating system) and when I run this code in windows operating system I got some error, for that solution I upgrade my support library to 25.0.0 and it resolve but now below mentioned error generated. compileSdkVersion = 25 buildToolsVersion = '25.0.0' supportLibraryVersion = '25.0.0' targetSdkVersion = 25 E/UncaughtException: java.lang.NoSuchMethodError: No static method isCtrlPressed(Landroid/view/KeyEvent;)Z in class Landroid/support/v4/view/KeyEventCompatHoneycomb; or its super

android.support.v4.app.Fragment: undefined method getChildFragmentManager()

别来无恙 提交于 2019-12-06 09:17:42
问题 I'm using ActionBarSherlock and ViewPageIndicator and I tried to implement nested fragments, but the method getChildFragmentManager() is undefined in my android.support.v4.app.Fragments . There are no other errors and ABS and VPI work as expected. I'm not using the Support Library v13, I'm on the latest versions and I've cleaned my projects. A normal android.app.Fragment does not complain about getChildFragmentManager() . I also tried rearranging the support library dependencies (android