Code Monkey home page Code Monkey logo

android-floatinglabel-widgets's Introduction

Maven Central

Android Floating Label Widgets

A set of input widgets with a hint label that floats when input is not empty.

Demo

A demo of the widget is worth a thousand words. You can download it for free on Google Play.

Demo on Google Play

We also have a small video showing it (just click the image below)

demo video

Included widgets

  • Simple EditText
  • AutoComplete TextView
  • Item picker (pick an item from a list in a dialog)
  • Instant picker (pick a date or a time from a dialog)
  • Item chooser (pick an item from another activity)

Usage

See the Wiki pages for the documentation, changelog, samples, etc.

About Vincent & MarvinLabs

I am a freelance developer located in Biarritz, France. You can have a look at my website to get to know me a little better. If you want to follow me, here are some links:

MarvinLabs is my digital studio specialised in native mobile applications and web sites. You can browse our website to get to know us a little better. If you want to get updates about our work, you can also:

Change log

See the wiki

android-floatinglabel-widgets's People

Contributors

joosun avatar vpratfr avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

android-floatinglabel-widgets's Issues

Gradle support

It would be great if you could add the Library easily by adding the following line to the build.gradle file:
compile 'com.marvinlabs:android-floatinglabel-widgets:1.5.0+'

Currently it's throwing an error:
Error:Module version com.marvinlabs:android-floatinglabel-widgets:1.5.0 depends on libraries but is not a library itself

support for RTL Language

when trying to use the widget with hebrew string in app:flw_labelText, the hint is positioned with an offset to the right
(causing the text to be trunced)
also, when the widget is in focus, the label position is also with offset

layout file in this example:

<LinearLayout
    android:layout_width="fill_parent"
    android:layout_height="wrap_content"
    android:orientation="vertical">
    <FloatingLabelEditText
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:drawablePadding="10dp"
        app:flw_labelText="טקסט בעברית" />
    <FloatingLabelEditText
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        app:flw_labelText="טקסט פשוט שאמור להיות מימין" />
</LinearLayout>

see screenshot:
device-2015-06-28-080320

import to android studio

Error:The modules 'android-floatinglabel-widgets-master', 'android-floatinglabel-widgets' point to same directory in the file system.
Each module has to have a unique path.
Error:(15, 0) No service of type Factory available in ProjectScopeServices.
Open File

can you help me ?

Compatibility with Saaripaar Validation Library

Has anyone found a way to make this widget compatible with the Sarippar Android validation library?
https://github.com/ragunathjawahar/android-saripaar

floating labels widgets looks really nice but it does not seem to be compatible with EditText which is what it is replacing.

I was just wandering if anyone has had this issue before. As I would like to keep using floating labels library. But sadly the convenience of saripaar outweighs the looks of Floating label

Gradle Sync Error

Error:Failed to find: com.marvinlabs:android-floatinglabel-widgets:1.0.+
Getting this error after Sync.

Specify hint size when textview not empty

Currently it is not possible to set the size of the text hint when the textview already contains text. It shrinks to a predetermined size, but the size of this text should also be customizable.

Apache 2.0 License?

I'm looking to integrate your floating label library (which looks great btw) into an app for a client and was wondering if you'd be willing to put your source under the Apache 2.0 license. Since the source is unlicensed I'm not able to use it in its current state. Here's a link to the license: http://www.apache.org/licenses/LICENSE-2.0.html

If you don't want to license it I understand, but this is pretty much the standard license for open source Android projects anyway. Thanks!

NPE with FloatingLabelAutoCompleteTextView and AppCompat 22.1.1 on API 21+

When using this library with AppCompat there is a null pointer exception which occurs
when running on API 21+. The FloatingLabelAutoCompleteTextView's AutoCompleteTextView input is
injected as an AppCompatAutoCompleteTextView by the app compat library. When

inputWidget.setDropDownBackgroundResource(popupBackground)

is called, AppCompatAutoCompleteTextView tries to get the drawable from it's internal TintManager. The TintManager is not initialized when running on 21+ because of the TintManager.SHOULD_BE_USED is false on 21+. (See TintManager.java) (I haven't found the source for AppCompatAutoCompleteTextView online anywhere to link.)

My workaround for now is to change

inputWidget.setDropDownBackgroundResource(popupBackground); //FloatingLabelAutoCompleteTextView.java:90

to

inputWidget.setDropDownBackgroundDrawable(getContext().getDrawable(popupBackground)); //FloatingLabelAutoCompleteTextView.java:90

I want to verify that this is an AppCompat issue and not a FloatingLabelWidget issue and see if anyone has a better workaround.

Text misaligned with text cursor

screenshot_2014-10-22-17-49-44
As you can see the text is aligned with the bottom of the cursor, whereas it should be aligned with the center of the cursor. Not sure if I'm being clear enough :/.

Disable/Enable widgets programmatically

I have two ItemPickers on my layout, and I need insert items in picker2 after the user select a item in picker1. When the picker1 was not selected yet, I'd like to disable picker2.

I've tried myPicker2.setEnabled(false), myPicker2.setActived(false) and myPicker2.setClickable(false) but nothing works. The problem is, when picker2 is empty and is clicked, the app crash:

java.lang.RuntimeException: StringPickerDialogFragment needs some items to pick from

I wouldn't like to insert a empty item on picker2. Is there a way to disable ItemPickers instead?

Is it possible to disable drawableRight for pickers?

Is it possible to programmatically disable drawableLeft for pickers? This is because there is no possibility to adjust heights of Fl...EditText and FL..Picker which are placed in one row (horizontal Linearlayout) because of drawableRight...

Gradle error: Library is not a library itself

I added the following line to the build.gradle of my app module:

compile 'com.marvinlabs:android-floatinglabel-widgets:1.5.0'

When I sync the project with Gradle the following error is shown:

Module version com.marvinlabs:android-floatinglabel-widgets:1.5.0 depends on libraries but is not a library itself

Bug with multiline pickers

First click "Multiple item picker" select all items, then click ok.
second click "Multiple item picker" and unselect all items, then click ok.
the Multiple item picker position is uncorrect, so i want to fix it. thank you for the library again.

See pull request #1

Limited to minSdkVersion 15

I added version 1.5.0 of the library to an application project which defines minSdkVersion 9. When I compile the project the following error occurs:

Error:Execution failed for task ':app:processDebugManifest'.
Manifest merger failed : uses-sdk:minSdkVersion 9 cannot be smaller than version 15 declared in library /home/user/projects/MyApp/app/build/intermediates/exploded-aar/com.marvinlabs/android-floatinglabel-widgets/1.5.0/AndroidManifest.xml

What is the reason you declared minSdkVersion 15?
Can you backport the library?


Further, can you please explicitly state the minSdkVersion in the README.md so people do not spent time trying to integrate it when they target a lower SDK version?

Date picker month is -1

Hi,
I'm using floating labels for picking a date. But I'm trying to get rid of fragments by using flow and mortar libraries so I'm using my own dialog. Today I got next error: org.threeten.bp.DateTimeException: Invalid value for MonthOfYear (valid values 1 - 12): -1
date is (2'nd Jenuary 2015).
Looks really strange that January is -1.

Style contains key with bad entry

I am trying to run my app using the library.

My project's min-sdk is API 15.
I dont see the label in any of the widgets. Instead see this error in the logcat

  E/ResourceType Style contains key with bad entry: 0x01010479

I beleive this has something to do with the AppTheme. My theme is Theme.AppCompat.Light.DarkActionBar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.