Skip to content

Async drawable doesn't show up if it's the only thing in the text view #189

@Kaned1as

Description

@Kaned1as
  • Markwon version: 4.2.1-SNAPSHOT + GlidePlugin

Async drawable doesn't show up if it's the only thing in the text view.

In the source code of the ReplacementSpan there's this suspicious javadoc

   /**
     * Returns the width of the span. Extending classes can set the height of the span by updating
     * attributes of {@link android.graphics.Paint.FontMetricsInt}. If the span covers the whole
     * text, and the height is not set,
     * {@link #draw(Canvas, CharSequence, int, int, float, int, int, int, Paint)} will not be
     * called for the span.
     */
     public abstract int getSize(...)

And AsyncDrawable.initWithKnownDimensions(...) is only called if AsyncDrawableSpan.draw(...) of the parent span was called.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions