Kotlin Android About-Us Page Options

0
User Management System
Learn Kotlin, Retrofit, MVVM and MySQL using this all-in-one app. It is designed to be beginner friendly.

In web development, for sites like this one of ours, having an about us page is almost a must. Users can read about your services, what you are offering and maybe your email address. Google, the search engine can also use it to learn about your business. In android development, having one is also important. Users of the app can learn more about you as a person, or your business and maybe where to contact you.

It's thus imperative we look at some options for you to include an about us page in your app. Obviously you can roll out one for yourself, using a dedicated activity or fragment, or even a full screen dialog. Another option is to use existing libraries in github. These have already been designed and do provide you with simple builder methods that you can use to set properties like name, title, email, links etc.

Alien Planets Firebase(2 Projects - Kotlin/Java)
Put away books. Learn faster using these specially designed student projects. Kotlin, Java, MVVM etc.

Let's look at some of the best libraries in this regard.

  • First Solution
  • Example

Android About Page

Create an awesome About Page for your Android App in 2 minutes

Android About Page Cover

This library allows to generate beautiful About Pages with less effort, it's fully customizable and supports opening specific intent

View aboutPage = new AboutPage(this)
  .isRTL(false)
  .setImage(R.drawable.dummy_image)
  .addItem(versionElement)
  .addItem(adsElement)
  .addGroup("Connect with us")
  .addEmail("elmehdi.sakout@gmail.com")
  .addWebsite("http://medyo.github.io/")
  .addFacebook("the.medy")
  .addTwitter("medyo80")
  .addYoutube("UCdPQtdWIsg7_pi4mrRu46vA")
  .addPlayStore("com.ideashower.readitlater.pro")
  .addGitHub("medyo")
  .addInstagram("medyo80")
  .create();

Setup

Available on Jcenter, Maven and JitPack

compile 'com.github.medyo:android-about-page:1.2.1'

Usage

1. Add Description

setDescription(String)

2. Add Image

setImage(Int)

3. Add predefined Social network

The library has already some predefined social networks like :

  • Facebook
  • Twitter
  • Instagram
  • Youtube
  • PlayStore
addFacebook(String PageID)
addTwitter(String AccountID)
addYoutube(String AccountID)
addPlayStore(String PackageName)
addInstagram(String AccountID)
addGitHub(String AccountID)

4. Add Custom Element

For example app version :

Element versionElement = new Element();
versionElement.setTitle("Version 6.2");
addItem(versionElement)

5. Available attributes for Element Class

Function Description
setTitle(String) Set title of the element
setIconTint(Int) Set color of the element
setIconDrawable(Int) Set icon of the element
setValue(String) Set Element value like Facebook ID
setIntent(Intent) Set an intent to be called on onClickListener
setGravity(Gravity) Set a Gravity for the element
setOnClickListener(View.OnClickListener) If intent isn't suitable for you need, implement your custom behaviour by overriding the click listener

Sample Project

medyo/android-about-page/app/

Translations

The library does supports the following languages :

Please make a Pull request to add a new language.

ProGuard

Nothing to include

License

The MIT License (MIT)
Copyright (c) 2016 Mehdi Sakout

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

package mehdi.sakout.aboutpage.sample;

import android.content.res.Configuration;
import android.os.Bundle;
import android.support.v7.app.AppCompatActivity;
import android.support.v7.app.AppCompatDelegate;
import android.view.Gravity;
import android.view.View;
import android.widget.Toast;

import java.util.Calendar;

import mehdi.sakout.aboutpage.AboutPage;
import mehdi.sakout.aboutpage.Element;

public class MainActivity extends AppCompatActivity {

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        simulateDayNight(/* DAY */ 0);
        Element adsElement = new Element();
        adsElement.setTitle("Advertise with us");

        View aboutPage = new AboutPage(this)
                .isRTL(false)
                .setImage(R.drawable.dummy_image)
                .addItem(new Element().setTitle("Version 6.2"))
                .addItem(adsElement)
                .addGroup("Connect with us")
                .addEmail("elmehdi.sakout@gmail.com")
                .addWebsite("http://medyo.github.io/")
                .addFacebook("the.medy")
                .addTwitter("medyo80")
                .addYoutube("UCdPQtdWIsg7_pi4mrRu46vA")
                .addPlayStore("com.ideashower.readitlater.pro")
                .addInstagram("medyo80")
                .addGitHub("medyo")
                .addItem(getCopyRightsElement())
                .create();

        setContentView(aboutPage);
    }


    Element getCopyRightsElement() {
        Element copyRightsElement = new Element();
        final String copyrights = String.format(getString(R.string.copy_right), Calendar.getInstance().get(Calendar.YEAR));
        copyRightsElement.setTitle(copyrights);
        copyRightsElement.setIconDrawable(R.drawable.about_icon_copy_right);
        copyRightsElement.setIconTint(mehdi.sakout.aboutpage.R.color.about_item_icon_color);
        copyRightsElement.setIconNightTint(android.R.color.white);
        copyRightsElement.setGravity(Gravity.CENTER);
        copyRightsElement.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                Toast.makeText(MainActivity.this, copyrights, Toast.LENGTH_SHORT).show();
            }
        });
        return copyRightsElement;
    }

    void simulateDayNight(int currentSetting) {
        final int DAY = 0;
        final int NIGHT = 1;
        final int FOLLOW_SYSTEM = 3;

        int currentNightMode = getResources().getConfiguration().uiMode
                & Configuration.UI_MODE_NIGHT_MASK;
        if (currentSetting == DAY && currentNightMode != Configuration.UI_MODE_NIGHT_NO) {
            AppCompatDelegate.setDefaultNightMode(
                    AppCompatDelegate.MODE_NIGHT_NO);
        } else if (currentSetting == NIGHT && currentNightMode != Configuration.UI_MODE_NIGHT_YES) {
            AppCompatDelegate.setDefaultNightMode(
                    AppCompatDelegate.MODE_NIGHT_YES);
        } else if (currentSetting == FOLLOW_SYSTEM) {
            AppCompatDelegate.setDefaultNightMode(
                    AppCompatDelegate.MODE_NIGHT_FOLLOW_SYSTEM);
        }
    }
}

  • Second Solution

EasyAbout

A fully material-designed about fragment for your application.


Releases:

Current release: 1.0.6.

You can see all the library releases here.


Demo:

You can download the sample apk here.

Default Default Dark Colored
Sample App
Sample App
Sample App

Usage:

Adding the depencency

Add this to your root build.gradle file:

allprojects {
    repositories {
        ...
        maven { url 'https://jitpack.io' }
    }
}

Now add the dependency to your app build.gradle file:

implementation 'com.github.marcoscgdev:EasyAbout:1.0.6'

Create the fragment

Your about fragment must extend from EasyAboutFragment

public class AboutFragment extends EasyAboutFragment {

    @Override
    protected void configureFragment(Context context, View rootView, Bundle savedInstanceState) {
        // add cards here
    }
}

Create a card

Note: all parameters are optional

AboutCard aboutCard = new AboutCard.Builder(context)
        .setTitle("Card title") // It can also be passed as a string resource
        .setTitleColorRes(R.color.colorAccent) // You can also use setTitleColor(int color);
        .addItem(personAboutItem)
        .addItem(normalAboutItem)
        .build();

Create a item

Note: all parameters are optional and common for all item types

Header item

Header item

HeaderAboutItem headerAboutItem = new HeaderAboutItem.Builder(context)
        .setTitle(R.string.app_name) // It can also be passed as a string value
        .setSubtitle(BuildConfig.VERSION_NAME) // It can also be passed as a string resource
        .setIcon(R.mipmap.ic_launcher) // It can also be passed as a drawable
        .build();

Normal item

Normal item

NormalAboutItem normalAboutItem = new NormalAboutItem.Builder(context)
        .setTitle("Item title") // It can also be passed as a string resource
        .setSubtitle("Item subtitle") // It can also be passed as a string resource
        .setIcon(R.drawable.ic_info_outline_black_24dp) // It can also be passed as a drawable
        .setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View view) {
                // Your click action here
            }
        })
        .setOnLongClickListener(new View.OnLongClickListener() {
            @Override
            public boolean onLongClick(View view) {
                // Your long click action here
                return false;
            }
        })
        .build();

Person item

Person item

PersonAboutItem personAboutItem = new PersonAboutItem.Builder(context)
        .setTitle("Your name here") // It can also be passed as a string resource
        .setSubtitle("Your info here") // It can also be passed as a string resource
        .setIcon(R.drawable.user) // It can also be passed as a drawable
        .build();

Add cards to the fragment

You can add cards with the addCard(AboutCard aboutCard); method (inside the configureFragment function of the fragment)

AboutCard aboutCard = new AboutCard.Builder(context)
        .setTitle("Card title") // It can also be passed as a string resource
        .setTitleColorRes(R.color.colorAccent) // You can also use setTitleColor(int color);
        .addItem(personAboutItem)
        .addItem(normalAboutItem)
        .build();

addCard(aboutCard);
addCard(anotherCard);
addCard(contactCard);

Sample fragment

public class AboutFragment extends EasyAboutFragment {

    @Override
    protected void configureFragment(final Context context, View rootView, Bundle savedInstanceState) {
        addCard(new AboutCard.Builder(context)
                .addItem(AboutItemBuilder.generateAppTitleItem(context)
                        .setSubtitle("by @MarcosCGdev."))
                .addItem(AboutItemBuilder.generateAppVersionItem(context, true)
                        .setIcon(R.drawable.ic_info_outline_black_24dp))
                .addItem(new NormalAboutItem.Builder(context)
                        .setTitle("Licenses")
                        .setIcon(R.drawable.ic_description_black_24dp)
                        .setOnClickListener(new View.OnClickListener() {
                            @Override
                            public void onClick(View view) {
                                DemoUtils.showLicensesDialog(context);
                            }
                        })
                        .build())
                .build());

        addCard(new AboutCard.Builder(context)
                .setTitle("Support")
                .addItem(AboutItemBuilder.generatePlayStoreItem(context)
                        .setTitle("Rate application")
                        .setIcon(R.drawable.ic_star_black_24dp))
                .addItem(AboutItemBuilder.generateLinkItem(context, "https://github.com/marcoscgdev/EasyAbout/issues/new")
                        .setTitle("Report bugs")
                        .setIcon(R.drawable.ic_bug_report_black_24dp))
                .addItem(new NormalAboutItem.Builder(context)
                        .setTitle("Clickable item")
                        .setSubtitle("This item has onClick and onLongClick listener.")
                        .setOnClickListener(new View.OnClickListener() {
                            @Override
                            public void onClick(View view) {
                                Toast.makeText(context, "onClick", Toast.LENGTH_SHORT).show();
                            }
                        })
                        .setOnLongClickListener(new View.OnLongClickListener() {
                            @Override
                            public boolean onLongClick(View view) {
                                Toast.makeText(context, "onLongClick", Toast.LENGTH_SHORT).show();
                                return false;
                            }
                        })
                        .setIcon(R.drawable.ic_mouse_black_24dp)
                        .build())
                .build());
    }
}

Customize card color

Simply add this to your app theme. Replace @color/colorPrimary with your desired color.

<item name="aboutCardBackground">@color/colorPrimary</item>

See the sample project to clarify any queries you may have.


License

MIT License

Copyright (c) 2018 Marcos Calvo García

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

 

  • Third Solution

AboutUsActivity - Library

  • About Us Activity for Android Application About screen.
  • Simple and Easy to Use

Demo App - Click here

Screen Shot

More Screen Shot

How To Use

  1. Add the JitPack repository to your build file. Add it in your root build.gradle at the end of repositories
    allprojects {
        repositories {
            ...
            maven { url 'https://jitpack.io' }
        }
    }
  1. Add the dependency
    dependencies {
            implementation 'com.gitlab.manimaran:aboutusactivity:v1.0'
    }
  1. Inside Click Listener
    // Base
    int appTheme = R.style.AppTheme;
    String aboutUsActivityTitle = "About Us";

    // App Details
    int appLogo = R.drawable.ic_app_logo;
    String appName = getString(R.string.app_name);
    String appAbout = "About App Info. About Activity for simple and easy way to show about us.";
    String appVersion = "Version : " + BuildConfig.VERSION_NAME;
    String appPlayStoreLink =  "https://play.google.com/store/apps/details?id=com.jskaleel.fte";

    // License details
    String licenseName = "GPL v3";
    String licenseUrl = "https://www.gnu.org/licenses/gpl-3.0.txt";

    // Share Details
    String shareMsgText = "About Us Activity you can see : \nhttps://gitlab.com/manimaran/aboutusactivity";
    String shareIntentTitle = "Choose app to share...";

    // Powered By
    int poweredByIcon = R.drawable.ic_power_by; // If No need image set 0
    String poweredByTitle = "Powered By";
    String poweredByName = "Coopon";
    String poweredByAbout = "Coopon Sci Tech LLP";
    String poweredByLink = "http://cooponscitech.in/";

    // Initiated By
    int initiatedByIcon = R.drawable.ic_initiator; // If No need image set 0
    String initiatedByTitle = "Initiated By";
    String initiatedByName = "Initiator";
    String initiatedByAbout = "About details of Initiator";
    String initiatedByLink = "http://initiator.in/";

    // Others
    String sourceCodeLink = "https://gitlab.com/manimaran/aboutusactivity";
    int jsonResOfThirdPartyLibrary = R.raw.third_party_library;
    int jsonResOfCredits = R.raw.credits;
    String contactMail = "manimaran@cooponscitech.in";

    /**
     *  All the values are set in about activity builder
     *  If we don't need any views just ignore in build.
     */
    new AboutActivityBuilder.Builder(MainActivity.this)
            .setAppTheme(appTheme)
            .setTitle(aboutUsActivityTitle)
            .setAppLogo(appLogo)
            .setAppName(appName)
            .setAppAbout(appAbout)
            .setAppVersion(appVersion)
            .setLicense(licenseName, licenseUrl)
            .setShare(shareMsgText, shareIntentTitle)
            .setRateUs(appPlayStoreLink)
            .setPoweredBy(poweredByIcon, poweredByTitle, poweredByName, poweredByAbout, poweredByLink)
            .setInitiatedBy(initiatedByIcon, initiatedByTitle, initiatedByName, initiatedByAbout, initiatedByLink)
            .setSeeSourceCode(sourceCodeLink)
            .setThirdPartyLibrary(jsonResOfThirdPartyLibrary)
            .setCredits(jsonResOfCredits)
            .setContactUs(contactMail)
            .showAboutActivity();

Note

Syntax : R.raw.credits - structure like

{
  "credits": [
    {
      "name": "Manimaran",
      "about": "Reason/About",
      "url": "http://manimaran96.wordpress.com/"
    },
    {
      "name": "XYZ",
      "about": "Reason/About",
      "url": "http://xyz.com/"
    }
  ]
}

Syntax : R.raw.third_party_library

{
  "third_party_library": [
    {
      "name": "androidx.appcompat:appcompat:1.0.2",
      "url": "http://developer.android.com/tools/extras/support-library.html",
      "license": "The Apache Software License, Version 2.0",
      "license_url": "http://www.apache.org/licenses/LICENSE-2.0.txt"
    },
    {
      "name": "androidx.constraintlayout:constraintlayout:1.1.3",
      "url": "http://developer.android.com/tools/extras/support-library.html",
      "license": "The Apache Software License, Version 2.0",
      "license_url": "http://www.apache.org/licenses/LICENSE-2.0.txt"
    }
  ]
}

Thanks To

 

  • Fourth Solution

Nordan Simply Page

platform API License

Dependency

Add this to your module's build.gradle file:

dependencies {
    ...
    implementation 'com.github.Dan629pl:nordan-simply-page-android:1.2.5'
}

Nordan Simply Pages

About Us Page Style

        ...
    ConstraintLayout simplyPage = new NordanSimplyPage(this)
                  .addImageItem(R.drawable.nordan_logo)
                  .addDescriptionItem(R.string.lorem_ipsum)
                  .addSeparator()
                  .addGroup("Contact", R.color.gray_font_color)
                  .addPhone("123456789", "Call to me")
                  .addEmail("email address", "Write me an email")
                  .addSms("123456789", "Send message to me", "Sms message")
                  .addGroup("Check my socials", R.color.gray_font_color)
                  .addFacebook("facebookId")
                  .addInstagram("instagramId")
                  .addGithub("githubId")
                  .addGooglePlayStore("com.google.android.googlequicksearchbox")
                  .addYoutube("channelId")
                  .addWebsite("https://www.google.com", "Website")
                  .addSkype("profileId")
                  .addLinkedIn("daniel-owczarczyk-8b89a6150")
                  .addTwitter("profileId")
                  .addGroup(R.mipmap.ic_launcher_round, "Other groups (with left side image)")
                  .addMinimalItem(BaseElement.builder().title("Minimal item (only text view)").build())
                  .addEmptyItem()
                  .addMinimalItem(
                          BaseElement.builder()
                                  .title("Version " + BuildConfig.VERSION_NAME)
                                  .gravity(Gravity.CENTER)
                                  .build())
                  .addCopyRightsItem()
                  .create();
          setContentView(simplyPage);
            ...

Screenshots

Settings Page Style

                    ...
      View settingPage = new NordanSimplyPage(this)
                .addImageItem(R.drawable.nordan_logo, 300, 75)
                .addGroup(getString(R.string.account_group), R.drawable.account_icon, R.color.gray_font_color)
                .addAccountItem(createAccountElement())
                .addItem(createAccountConfirmedElement())
                .addMinimalItem(createSignOutElement())
                .addEmptyItem(30)
                .addGroup(R.drawable.settings_app_icon, "Application")
                .addSwitchItem(createThemeSwitcherElement())
                .addItem(createTimeRefreshElement())
                .addSingleRadioChoiceItem(createSingleChoiceElement())
                .addCheckBoxItem(createCheckBoxElement())
                .addCheckBoxItem(createCheckBoxExtendableElement())
                .addSeekBarItem(createSeekBarElement())
                .addEditTextItem(createEditTextElement())
                .addEmptyItem(200)
                .create();
        setContentView(settingPage);
                     ...

Screenshots

Donation

If this library help you reduce time to develop, you can buy me a coffee! 🙂

Buy Me A Coffee

License


Copyright 2020 Daniel Owczarczyk

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

 http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

 

 

 

Android MySQL Retrofit2 Multipart CRUD,Search,Pagination rating

When I was a 2nd year Software Engineering student, I buillt a now defunct online tool called Camposha(from Campus Share) using my then favorite language C#(ASP.NET) to compete OLX in my country(Kenya). The idea was to target campus students in Kenya. I got a few hundred signups but competing OLX proved too daunting. I decided to focus on my studies, learning other languages like Java,Python,Kotlin etc while meanwhile publishing tutorials at my YouTube Channel ProgrammingWizards TV which led to this site(camposha.info). Say hello or post me a suggestion: oclemmi@gmail.com . Follow me below; Github , and on my channel: ProgrammingWizards TV

We will be happy to hear your thoughts

Leave a reply

twelve + = sixteen

Reset Password
Compare items
  • Total (0)
Compare
0
Shopping cart