Compare commits
2 Commits
v171901013
...
v171901014
Author | SHA1 | Date | |
---|---|---|---|
69da932ab5 | |||
592fb6328a |
@ -127,7 +127,13 @@ class ArticleFragment : Fragment() {
|
|||||||
font = prefs.getString("reader_font", "")
|
font = prefs.getString("reader_font", "")
|
||||||
if (font.isNotEmpty()) {
|
if (font.isNotEmpty()) {
|
||||||
resId = context!!.resources.getIdentifier(font, "font", context!!.packageName)
|
resId = context!!.resources.getIdentifier(font, "font", context!!.packageName)
|
||||||
typeface = ResourcesCompat.getFont(context!!, resId)!!
|
typeface = try {
|
||||||
|
ResourcesCompat.getFont(context!!, resId)!!
|
||||||
|
} catch (e: java.lang.Exception) {
|
||||||
|
ACRA.getErrorReporter().maybeHandleSilentException(Throwable("Font loading issue: ${e.message}"), context!!)
|
||||||
|
// Just to be sure
|
||||||
|
null
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
refreshAlignment()
|
refreshAlignment()
|
||||||
|
Reference in New Issue
Block a user