Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 10 additions & 2 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,21 @@ buildscript {
jcenter()
}
dependencies {
classpath 'com.android.tools.build:gradle:2.1.2'
classpath 'com.android.tools.build:gradle:2.3.3'
classpath 'com.jfrog.bintray.gradle:gradle-bintray-plugin:1.7'
classpath 'com.github.dcendents:android-maven-gradle-plugin:1.3'
classpath 'com.github.dcendents:android-maven-gradle-plugin:1.4.1'

// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
}
}

allprojects {
repositories {
jcenter()
maven {
url "https://maven.google.com"
}
}
}

4 changes: 2 additions & 2 deletions gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#Tue Jul 05 11:53:35 ICT 2016
#Sat Sep 09 15:10:31 KST 2017
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-2.10-all.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-3.3-all.zip
8 changes: 4 additions & 4 deletions sample/build.gradle
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
apply plugin: 'com.android.application'

android {
compileSdkVersion 22
buildToolsVersion "21.1.2"
compileSdkVersion 26
buildToolsVersion "26.0.1"

defaultConfig {
applicationId "com.tsengvn.typekitsample"
minSdkVersion 10
minSdkVersion 14
targetSdkVersion 22
versionCode 1
versionName "1.0"
Expand All @@ -28,6 +28,6 @@ android {

dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
compile 'com.android.support:appcompat-v7:22.1.1'
compile 'com.android.support:appcompat-v7:26.0.1'
compile project(path: ':typekit')
}
6 changes: 3 additions & 3 deletions sample/src/main/res/layout/activity_sample.xml
Original file line number Diff line number Diff line change
Expand Up @@ -50,15 +50,15 @@
android:text="soopafre"
android:textColor="@android:color/black"
android:textSize="18sp"
app:font="custom1"/>
app:fontType="custom1"/>

<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Break It Down"
android:textColor="@android:color/black"
android:textSize="18sp"
app:font="custom2"/>
app:fontType="custom2"/>

<TextView
android:layout_width="wrap_content"
Expand All @@ -73,5 +73,5 @@
android:text="Waltograph Disney"
android:textColor="@android:color/black"
android:textSize="30sp"
app:font="disney"/>
app:fontType="disney"/>
</LinearLayout>
8 changes: 4 additions & 4 deletions typekit/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -35,20 +35,20 @@ buildscript {
}

dependencies {
classpath 'com.android.tools.build:gradle:2.1.2'
classpath 'com.android.tools.build:gradle:2.3.3'
}
}

android {
signingConfigs {
}
compileSdkVersion 22
buildToolsVersion "21.1.2"
buildToolsVersion "26.0.1"
defaultConfig {
minSdkVersion 10
targetSdkVersion 22
versionCode 2
versionName "1.0.1"
versionCode 3
versionName "1.0.2"
}
buildTypes {
release {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ private void applyFontForTextView(Context context, AttributeSet attrs, TextView
Typekit typekit = Typekit.getInstance();

TypedArray array = context.obtainStyledAttributes(attrs, R.styleable.Typekit);
String fontKey = (array != null) ? array.getString(R.styleable.Typekit_font) : null;
String fontKey = (array != null) ? array.getString(R.styleable.Typekit_fontType) : null;

if (!TextUtils.isEmpty(fontKey)) {
textView.setTypeface(typekit.get(fontKey));
Expand Down
2 changes: 1 addition & 1 deletion typekit/src/main/res/values/attrs.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<declare-styleable name="Typekit">
<attr name="font" format="string"/>
<attr name="fontType" format="string"/>
</declare-styleable>
</resources>