Commit 1117fae5 authored by Konstantin Tskhovrebov's avatar Konstantin Tskhovrebov 🤖

changed Calligraphy -> Android Support fonts

parent c063b63b
......@@ -96,8 +96,6 @@ dependencies {
implementation 'ru.noties:markwon:1.0.3'
//Bottom navigation bar
implementation 'com.aurelhubert:ahbottomnavigation:2.1.0'
//Custom fonts
implementation 'uk.co.chrisjenx:calligraphy:2.3.0'
//Lottie
implementation 'com.airbnb.android:lottie:2.1.0'
//Date
......
......@@ -14,7 +14,6 @@ import toothpick.Toothpick
import toothpick.configuration.Configuration
import toothpick.registries.FactoryRegistryLocator
import toothpick.registries.MemberInjectorRegistryLocator
import uk.co.chrisjenx.calligraphy.CalligraphyConfig
/**
* @author Konstantin Tskhovrebov (aka terrakok) on 26.03.17.
......@@ -27,7 +26,6 @@ class App : Application() {
initLogger()
initToothpick()
initAppScope()
initCalligraphy()
initMarkwon()
initThreetenABP()
}
......@@ -58,13 +56,6 @@ class App : Application() {
serverScope.installModules(ServerModule(authHolder.serverPath))
}
private fun initCalligraphy() {
CalligraphyConfig.initDefault(CalligraphyConfig.Builder()
.setDefaultFontPath(getString(R.string.font_main_regular))
.setFontAttrId(R.attr.fontPath)
.build())
}
private fun initMarkwon() {
val theme = SpannableTheme.builderWithDefaults(this)
.codeTextColor(Color.parseColor("#C0341D"))
......
package ru.terrakok.gitlabclient.ui.global
import android.content.Context
import android.os.Bundle
import com.arellomobile.mvp.MvpAppCompatActivity
import ru.terrakok.cicerone.Navigator
import ru.terrakok.cicerone.NavigatorHolder
import uk.co.chrisjenx.calligraphy.CalligraphyContextWrapper
import javax.inject.Inject
/**
......@@ -17,10 +15,6 @@ abstract class BaseActivity : MvpAppCompatActivity() {
protected abstract val layoutRes: Int
protected abstract val navigator: Navigator
override fun attachBaseContext(newBase: Context?) {
super.attachBaseContext(CalligraphyContextWrapper.wrap(newBase))
}
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
setContentView(layoutRes)
......
......@@ -60,7 +60,7 @@
</LinearLayout>
<TextView
fontPath="@string/font_main_medium"
app:fontFamily="@font/roboto_medium"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:padding="16sp"
......@@ -93,7 +93,7 @@
android:textSize="16sp"/>
<TextView
fontPath="@string/font_main_medium"
app:fontFamily="@font/roboto_medium"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:padding="16sp"
......
......@@ -21,7 +21,7 @@
<TextView
android:id="@+id/titleTextView"
fontPath="@string/font_main_medium"
app:fontFamily="@font/roboto_medium"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_marginEnd="16dp"
......
......@@ -22,13 +22,13 @@
<TextView
android:id="@+id/titleTextView"
fontPath="@string/font_main_medium"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_marginEnd="16dp"
android:layout_marginStart="16dp"
android:textColor="@color/primary_text"
android:textSize="18sp"
app:fontFamily="@font/roboto_medium"
app:layout_constraintLeft_toRightOf="@id/avatarImageView"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toTopOf="@id/avatarImageView"
......
......@@ -44,7 +44,7 @@
android:maxLines="1"
android:textColor="@color/white"
android:textSize="14sp"
fontPath="@string/font_main_medium"
app:fontFamily="@font/roboto_medium"
app:layout_constraintHorizontal_bias="0.0"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
......@@ -102,7 +102,7 @@
android:text="@string/activity_item"
android:textColor="@color/primary_text"
android:textSize="14sp"
fontPath="@string/font_main_medium" />
app:fontFamily="@font/roboto_medium" />
<TextView
android:id="@+id/projectsMI"
......@@ -116,7 +116,7 @@
android:text="@string/projects_item"
android:textColor="@color/primary_text"
android:textSize="14sp"
fontPath="@string/font_main_medium" />
app:fontFamily="@font/roboto_medium" />
<View
android:layout_width="match_parent"
......@@ -137,7 +137,7 @@
android:text="@string/about_item"
android:textColor="@color/primary_text"
android:textSize="14sp"
fontPath="@string/font_main_medium" />
app:fontFamily="@font/roboto_medium" />
</LinearLayout>
</android.support.constraint.ConstraintLayout>
</ScrollView>
\ No newline at end of file
......@@ -51,7 +51,7 @@
<TextView
android:id="@+id/titleTextView"
fontPath="@string/font_main_medium"
app:fontFamily="@font/roboto_medium"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_marginEnd="16dp"
......
......@@ -38,7 +38,7 @@
<TextView
android:id="@+id/usernameTextView"
fontPath="@string/font_main_medium"
app:fontFamily="@font/roboto_medium"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_marginEnd="16dp"
......
......@@ -47,7 +47,7 @@
<TextView
android:id="@+id/issueIdTextView"
fontPath="@string/font_main_medium"
app:fontFamily="@font/roboto_medium"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="16dp"
......@@ -60,7 +60,7 @@
<TextView
android:id="@+id/issueMessagesCountTextView"
fontPath="@string/font_main_medium"
app:fontFamily="@font/roboto_medium"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginEnd="16dp"
......
......@@ -48,7 +48,7 @@
<TextView
android:id="@+id/mergeRequestIdTextView"
fontPath="@string/font_main_medium"
app:fontFamily="@font/roboto_medium"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="16dp"
......@@ -61,7 +61,7 @@
<TextView
android:id="@+id/mergeRequestOpenedAtByAuthorTextView"
fontPath="@string/font_main_medium"
app:fontFamily="@font/roboto_medium"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="4dp"
......@@ -74,7 +74,7 @@
<TextView
android:id="@+id/mergeRequestMessagesCountTextView"
fontPath="@string/font_main_medium"
app:fontFamily="@font/roboto_medium"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginEnd="16dp"
......
......@@ -152,8 +152,4 @@
<string name="menu_project_info">Info</string>
<string name="menu_project_issue">Issues</string>
<string name="menu_project_merge_request">Merge Requests</string>
<!--Calligraphy Config-->
<string name="font_main_regular">fonts/Roboto-Regular.ttf</string>
<string name="font_main_medium">fonts/Roboto-Medium.ttf</string>
</resources>
......@@ -10,6 +10,7 @@
<item name="android:textColorSecondary">@color/secondary_text</item>
<item name="android:windowBackground">@color/white</item>
<item name="fontFamily">@font/roboto_regular</item>
</style>
<style name="AppTheme.Splash">
......@@ -18,7 +19,7 @@
<style name="ToolbarTheme" parent="ThemeOverlay.AppCompat.Dark.ActionBar">
<item name="colorAccent">@color/white</item>
<item name="fontPath">@string/font_main_medium</item>
<item name="fontFamily">@font/roboto_medium</item>
</style>
<style name="PopupToolbarTheme" parent="ThemeOverlay.AppCompat.Light">
......@@ -40,13 +41,13 @@
<style name="TextHeadline" parent="TextAppearance.AppCompat.Headline">
<item name="android:textColor">@color/primary_text</item>
<item name="fontPath">@string/font_main_medium</item>
<item name="fontFamily">@font/roboto_medium</item>
</style>
<style name="TextTitle" parent="TextAppearance.AppCompat.Title">
<item name="android:textColor">@color/primary_text</item>
<item name="android:textSize">16sp</item>
<item name="fontPath">@string/font_main_medium</item>
<item name="fontFamily">@font/roboto_medium</item>
</style>
<style name="TextBody" parent="TextAppearance.AppCompat.Body1">
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment