noties / Markwon

Android markdown library (no WebView)
https://noties.io/Markwon/
Apache License 2.0
2.76k stars 313 forks source link

How can i change code block text color and background color? #457

Closed emrememil closed 1 year ago

emrememil commented 1 year ago

I want to change text color & background color of code block. How can i change it?

emrememil commented 1 year ago

I found a code;

            .usePlugin(object : AbstractMarkwonPlugin() {
                override fun configureTheme(builder: MarkwonTheme.Builder) {
                    super.configureTheme(builder)

                    builder.codeBackgroundColor(context.getColor(R.color.transparent))
                    builder.codeTextColor(Color.RED)
                }
            })