Package 

Class InlineCodeSpan

  • All Implemented Interfaces:
    android.os.Parcelable , android.text.ParcelableSpan , android.text.style.UpdateAppearance , android.text.style.UpdateLayout , io.element.android.wysiwyg.view.spans.PlainAtRoomMentionDisplaySpan

    
    public final class InlineCodeSpan
    extends TypefaceSpan implements PlainAtRoomMentionDisplaySpan
                        

    Inline code (some code in Markdown, <code> in HTML) Span that applies a monospaced font style.

    Note that this span does not apply a background style; it simply tells the TextView where to apply an inline background.

    To display this span, either:

    See io.element.android.wysiwyg.inlinebg.SpanBackgroundRenderer, based on the official Google sample:

    • https://medium.com/androiddevelopers/drawing-a-rounded-corner-background-on-text-5a610a95af5

    • https://github.com/googlearchive/android-text/tree/996fdb65bbfbb786c3ca4e4e40b30509067201fc/RoundedBackground-Kotlin

    • Constructor Summary

      Constructors 
      Constructor Description
      InlineCodeSpan(Float relativeSizeProportion)
    • Method Summary

      Modifier and Type Method Description
      Unit updateMeasureState(TextPaint paint)
      Unit updateDrawState(TextPaint ds)
      • Methods inherited from class io.element.android.wysiwyg.view.spans.InlineCodeSpan

        describeContents, getFamily, getSpanTypeId, getTypeface, toString, writeToParcel
      • Methods inherited from class android.text.style.TypefaceSpan

        getUnderlying
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait