Android Activity Transition Animation

What I am trying to achieve is : start a new activity with a transition animation for the exiting activity only. I would like to slide up the current activity, where the new activity will be behind the current one. Here is the slide up animation : R.layout.slide_up <set xmlns:android=””> <translate android:duration=”1000″ android:fromYDelta=”0%” android:toYDelta=”100%” /> […]

android monkey runner scripts

i am tryig to execute a sample python program through monkey runner command prompt and it is throwing an error Can’t open specified script file Usage: monkeyrunner [options] SCRIPT_FILE -s MonkeyServer IP Address. -p MonkeyServer TCP Port. -v MonkeyServer Logging level (ALL, FINEST, FINER, FINE, CONFIG, INFO, WARNING, SEVERE, OFF) Exception in thread “main” java.lang.NullPointerException […]

Scale text in a view to fit?

I don’t believe this exists, but wanted to double-check. I’d like to set a TextView’s text size such that it would fit within a given width, single line. Example: <LinearLayout layout_width=”100dip” layout_height=”50dip”> <TextView layout_width=”fill_parent” layout_height=”wrap_content” textSize=”fill” text=”fit me please!” /> </LinearLayout> Thanks

Ionic Android build: java.lang.IllegalStateException: buildToolsVersion is not specified

Since today, somehow my ionic project is not longer able to build for some reason. I already tried to remove the platform and add it again, but it didn’t work. I now almost spent three ours with upgrading, downgrading and reinstalling cordova and ionic but for some reason I always get the following error when […]

Phonegap (Android Build) – Intermediate Screen before Splash Screen

When I first launched my app, built using and then distributed to my Nexus 7 (running Jelly Bean 4.3), I see a black screen with a gray title bar at the top. Is this normal, or is there a setting I need to enable/disable? I can say that this build was a debug build […]

Change the line color used in listSeparatorTextViewStyle

I have the following code <TextView android:text=”@string/hello” style=”?android:attr/listSeparatorTextViewStyle” /> and I will get the following effect. However, I am not happy with the color line. I would like to have something like I would like it to have blue color line as in holo. I try the following custom style. <style name=”MyOwnListSeperatorTextViewStyle”> <item name=”android:background”>@android:drawable/list_section_divider_holo_light</item> <item […]

What are the steps to get notified by Bluetooth Low Energy (BLE) device?

I am working on a Bluetooth Low Energy (BLE) app. I have a BLE device (scale) which measures weight. I am able to connect with this device. But I am not getting how to read data (weight value) from it. I want to know if my app is connected to any BLE device, so what […]

What is the default font family in Android?

Starting in API 16, Jellybean Roboto was introduced as available font family to use. See whats “new” in Android 16 here. Specifying android:fontFamily=”sans-serif”(Roboto in API 16+) on a TextView the default fontFamily of the TextView? Is <TextView android:layout_width=”wrap_content” android:layout_height=”wrap_content” /> equivalent to <TextView android:layout_width=”wrap_content” android:layout_height=”wrap_content” android:fontFamily=”sans-serif” /> ? From Material design typography website: “Roboto and […]

Android how to use checkedtextview

the title speaks for itself. I am over several articles, topics and still haven’t figured out how to use checkedtextview. I want a listview with checkable items. In the following code i am using a listview and populating it with a string array. But how to change it to checkedtextview? delete.xml: <?xml version=”1.0″ encoding=”utf-8″?> <LinearLayout […]

Espresso how to test if Activity is finished?

I want to assert that my Acitivty that I am currently testing is finished when certain actions are performed. Unfortunately so far I am only to assert it by adding some sleep at the end of the test. Is there a better way ? import android.content.Context; import android.os.Build; import; import android.test.suitebuilder.annotation.LargeTest; import org.junit.Before; import […]

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