GithubHelp home page GithubHelp logo

penglitu / chatkeyboard-master Goto Github PK

View Code? Open in Web Editor NEW

This project forked from yangchaojiang/chatkeyboard-master

1.0 0.0 0.0 364 KB

一个功能强大且易于使用的键盘库包括表情、录音、自定义多媒体键盘

License: BSD 3-Clause "New" or "Revised" License

Java 100.00%

chatkeyboard-master's Introduction

ChatKeyboard

A powerful and easy using keyboard lib includes emoticons, audio recording, multi media keyboard, etc.

###Import

use import dependency in gradle

dependencies {
compile 'ycjiang:keyboard:1.0.1'
}
Maven
dependency>
  <groupId>ycjiang</groupId>
  <artifactId>videolibrary</artifactId>
  <version>1.0.4</version>
  <type>pom</type>
</dependency>

dependency

 compile 'com.android.support:appcompat-v7:23.2.0'

###How to use

1, Use ChatKeyboardLayout make your layout contains keyboard. 用Framgment extends KeyboardFragment

FragmentTransaction sss = getSupportFragmentManager().beginTransaction();
    KeyboardFragment    keyboardFragment = new KeyboardFragment();
        sss.add(R.id.sssssssss, keyboardFragment);
        sss.commit();
        keyboardFragment.setKeyBoardLister(this);

perhaps

<com.yang.keyboard.ChatKeyboardLayout
        android:id="@+id/kv_bar"
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        app:sendBtnBg="@drawable/send_button_bg">
        ...your layout
</com.yang.keyboard.ChatKeyboardLayout>

Notice: ChatKeyboardLayout can only include one child. 2, custom your emoticon and stick keyboard

if ( !ChatKeyboardLayout.isEmoticonInitSuccess(this) ) {
	List<EmoticonEntity> entities = new ArrayList<>();
	entities.add(new EmoticonEntity("emoticons/xhs", EmoticonBase.Scheme.ASSETS));
	entities.add(new EmoticonEntity("emoticons/tusiji", EmoticonBase.Scheme.ASSETS));
	ChatKeyboardLayout.initEmoticonsDB(this, true, entities);
}

Notice: Add the code above before the ChatKeyboardLayout used, better in onCreate of Application

other usage please refer to the demo code

Thanks for xhsEmoticonsKeyboard powered by w446108264. Thanks to Chris for ideas email [email protected]

chatkeyboard-master's People

Contributors

yangchaojiang avatar

Stargazers

 avatar

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.