Markwon: list bullet size / style?

475 Views Asked by At

I'm trying to use the Markwon markdown library. https://noties.io/Markwon/

On my screen, list bullets are rendering too large.

enter image description here

(And also not centered).

I'm wondering if there's a way to style the bullets?

1

There are 1 best solutions below

0
Jeffrey Blattman On BEST ANSWER

Answer was provided by Mike M. in comments.

It looks like you can specify a bullet width through a custom MarkwonTheme. The MarkwonTheme.Builder there has a bulletWidth(int) method that takes a measure in pixels.

final Markwon markwon = Markwon.builder(getContext())
    .usePlugin(new AbstractMarkwonPlugin() {
      @Override
      public void configureTheme(@NonNull MarkwonTheme.Builder builder) {
        builder.bulletWidth(6); // pixels
      }
    })
    .build();

This is for Markwon 4.4.0.