Reputation: 723
Caused by: android.view.InflateException: Binary XML file line #17 in com.acadamis.vidyaspoorthiteacher:layout/abc_screen_toolbar: Binary XML file line #17 in com.acadamis.vidyaspoorthiteacher:layout/abc_screen_toolbar: Error inflating class androidx.appcompat.widget.ActionBarOverlayLayout
Caused by: android.view.InflateException: Binary XML file line #17 in com.acadamis.vidyaspoorthiteacher:layout/abc_screen_toolbar: Error inflating class androidx.appcompat.widget.ActionBarOverlayLayout
AndroidRuntime: at androidx.appcompat.app.AppCompatActivity.setContentView(AppCompatActivity.java:161)
** It's working up to API 28, but not for API 29
Upvotes: 0
Views: 2328
Reputation: 31
This problem happens when using calligraphy library.
implementation 'uk.co.chrisjenx:calligraphy:2.3.0'
Solution:
Replace new calligraphy library
implementation 'io.github.inflationx:calligraphy3:3.1.1'
implementation 'io.github.inflationx:viewpump:2.0.3'
Change the calligraphy initial code
ViewPump.init(ViewPump.builder()
.addInterceptor(new CalligraphyInterceptor(
new CalligraphyConfig.Builder()
.setDefaultFontPath("1.ttf")
.setFontAttrId(R.attr.fontPath)
.build()))
.build());
And change wrapper
super.attachBaseContext(ViewPumpContextWrapper.wrap(newBase));
Upvotes: 3