diff --git a/README.md b/README.md index aceb49a..dce4335 100644 --- a/README.md +++ b/README.md @@ -9,6 +9,11 @@ Gappein Sticker SDK is just android SDK where you can convert your text as Stick - You can use it with your XML View - And yes, it can be used in your view file. +### To install it in your project, + +```groovy +implementation 'com.gappein:sticker:1.0.0' +``` ### To use it in View (Activity/Fragment) diff --git a/app/build.gradle b/app/build.gradle index 52dc704..dda2236 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -34,6 +34,6 @@ dependencies { androidTestImplementation 'androidx.test.ext:junit:1.1.2' androidTestImplementation 'androidx.test.espresso:espresso-core:3.3.0' -// implementation project(":sticker") - implementation 'com.gappein:sticker:1.0.0-alpha2' + implementation project(":sticker") +// implementation 'com.gappein:sticker:1.0.0-alpha1' } \ No newline at end of file diff --git a/app/src/main/java/com/gappein/sample/MainActivity.kt b/app/src/main/java/com/gappein/sample/MainActivity.kt index 7c7130f..09e9373 100644 --- a/app/src/main/java/com/gappein/sample/MainActivity.kt +++ b/app/src/main/java/com/gappein/sample/MainActivity.kt @@ -4,12 +4,15 @@ import android.os.Bundle import android.text.Editable import android.text.TextWatcher import androidx.appcompat.app.AppCompatActivity +import com.gappein.ui.StickerView +import com.gappein.util.generateSticker import kotlinx.android.synthetic.main.activity_main.* class MainActivity : AppCompatActivity() { override fun onCreate(savedInstanceState: Bundle?) { super.onCreate(savedInstanceState) setContentView(R.layout.activity_main) + val stickerView = StickerView(this) editTextInput.addTextChangedListener(object : TextWatcher { diff --git a/app/src/main/res/layout/activity_main.xml b/app/src/main/res/layout/activity_main.xml index 4fab6a7..d4092e9 100644 --- a/app/src/main/res/layout/activity_main.xml +++ b/app/src/main/res/layout/activity_main.xml @@ -17,7 +17,7 @@ app:layout_constraintRight_toRightOf="parent" app:layout_constraintTop_toTopOf="parent" /> - ResourcesCompat.getFont(this.context, R.font.bumper) + 1 -> ResourcesCompat.getFont(this.context, R.font.beibeh) + 2 -> ResourcesCompat.getFont(this.context, R.font.countryside) + 3 -> ResourcesCompat.getFont(this.context, R.font.jennie) + else -> ResourcesCompat.getFont(this.context, R.font.bumper) + } +} \ No newline at end of file diff --git a/sticker/src/main/res/font/beibeh.ttf b/sticker/src/main/res/font/beibeh.ttf new file mode 100644 index 0000000..8052d33 Binary files /dev/null and b/sticker/src/main/res/font/beibeh.ttf differ diff --git a/sticker/src/main/res/font/countryside.ttf b/sticker/src/main/res/font/countryside.ttf new file mode 100644 index 0000000..a9d3af7 Binary files /dev/null and b/sticker/src/main/res/font/countryside.ttf differ diff --git a/sticker/src/main/res/font/jennie.otf b/sticker/src/main/res/font/jennie.otf new file mode 100644 index 0000000..a7ec614 Binary files /dev/null and b/sticker/src/main/res/font/jennie.otf differ