GithubHelp home page GithubHelp logo

custom Button about easylogin HOT 1 CLOSED

maksim88 avatar maksim88 commented on July 25, 2024
custom Button

from easylogin.

Comments (1)

maksim88 avatar maksim88 commented on July 25, 2024

Hey,

there is no straightforward way to customize the texts. I found that it is possible to edit the login / logout button text on facebook by changing the com_facebook_login_text and com_facebook_logout_text properties.
So you can edit them the following way:

    <com.facebook.login.widget.LoginButton
        android:id="@+id/facebook_login_button"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_gravity="center_horizontal"
        android:layout_marginTop="30dp"
        app:com_facebook_login_text="Custom login Text"
        app:com_facebook_logout_text="Custom logout Text"
        android:layout_marginBottom="30dp" />

the app namespace is bound to http://schemas.android.com/apk/res-auto in this case.
As this is not a supported attribute the behaviour might break for the facebook button.

The gPlus button can be easily customizable. You can just create your own Button and then set it with setSignInButton() (I changed the dxpected type in the library for that, so this will be possible in the 0.5 release)

The text for the Twitter button can also be easily customizable with setText() on the button.

But beware that you will have to supply your own translations for all the texts if you use one of those approaches above.

from easylogin.

Related Issues (9)

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.