Giter Club home page Giter Club logo

appintroduction's Introduction

App Introduction

App Introduction is a library that helps to create introduction menu for users.

Only thing that you need to do is giving the id of the element to show (if you want to point an element) and write the message. You can choose pointing type like vertical or horizontal. Then the rest is done by library.

The messages that you add to same AppIntroduction object are stored and showed to the user one by one. When user sees messages of an Activity once, they will not be shown again. You can select one of the 20 themes. You can create listeners for doing some actions before and after each step, so you can have full control on steps. Also you can create a listener to know when user dismisses the AppIntroduction.

Features included

  • Showing the message in the middle.
  • Showing the message with horizontal pointer.
  • Showing the message with vertical pointer.
  • Remembering past (not showing messages if already shown).
  • Changing theme (Selecting one of the colors in http://flatuicolors.com).
  • Creating listeners for before/after events for each step.
  • Creating listeners for user dismiss.

Screenshots

Message in the middle.Message with vertical pointer.Message with horizontal pointer.Message with vertical pointer again.

Theme Screenshots

Orange.Wet Asphalt.Turquoise.Asbestos.Wisteria.Pomegranate

Colors

colors

Usage

For using this library in Android Studio (IntelliJ IDEA) you need to activate including assets from dependencies.

  • Open project structure (Right Click on Project -> 'Open Module Settings')
  • Select 'Facets' from left menu
  • Select 'Compiler' tab at right
  • Activate 'Include assets from dependencies into APK' beneath 'Resources Packaging'
AppIntroduction appIntroduction = new AppIntroduction(this);

// remembering past. not showing again if already shown before
appIntroduction.rememberPast(true);

// changing theme. selecting one of the colors
appIntroduction.setTheme(AppIntroduction.TURQUOISE);



// adding message into middle
appIntroduction.addStep(new Step(getResources().getString(R.string.uc_main_1)));

// adding message with vertical pointer
appIntroduction.addStep(new Step(R.id.search,
                getResources().getString(R.string.uc_main_3), AppIntroduction.SIDE_VERTICAL));
                
// adding message with horizontal pointer
appIntroduction.addStep(new Step(R.id.next,
                getResources().getString(R.string.uc_shuffle_3), AppIntroduction.SIDE_HORIZONTAL));           
                


// constructing AppIntroduction for listening dismiss of the user
appIntroduction = new AppIntroduction(this) {
    @Override
    public void onDismiss() {
        super.onDismiss();
        // handle user's dismiss
    }
};              



// listeners for steps. you can do some changes before or after a step
appIntroduction.addStep(new Step(R.id.second_language,
        getResources().getString(R.string.uc_shuffle_11), AppIntroduction.SIDE_VERTICAL, new StepActionListener() {
    @Override
    public void beforeMessageShown() {
        // do something before showing message
    }

    @Override
    public void afterMessageShown() {
        // do something after showing message
    }
}));

// starting introduction. you CANNOT call this in onCreate method of activity.
// because the content view of activity won't be ready in onCreate
appIntroduction.start();

// starting introduction. you can call this in onCreate method in activity.
// it will wait for 0.5 seconds for content view to be ready.
appIntroduction.startWithDelay();

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.