chrisjenx / Calligraphy

Custom fonts in Android the easy way...
Apache License 2.0
8.59k stars 1.1k forks source link

Compilation error while using 'implementation' instead of deprecated 'compile' in gradle settings #448

Closed sandeepbol closed 6 years ago

sandeepbol commented 6 years ago

When I use implementation 'uk.co.chrisjenx:calligraphy:2.3.0' in app's gradle file, I get compilation error that says

error: cannot find symbol class CalligraphyContextWrapper

It works fine when I use compile 'uk.co.chrisjenx:calligraphy:2.3.0' but I get a warning that compile is deprecated and will be removed in future.

sandeepbol commented 6 years ago

The issue is fixed. The problem was that I was putting

implementation 'uk.co.chrisjenx:calligraphy:2.3.0' in the module gradle file which is added as dependency of the app and not in app's gradle file. I put the line in app's gradle file and the code compiled fine.