Package icyllis.modernui.text.style

# Class SubscriptSpan

java.lang.Object
icyllis.modernui.text.style.CharacterStyle
icyllis.modernui.text.style.MetricAffectingSpan
icyllis.modernui.text.style.SubscriptSpan

All Implemented Interfaces:
  `ParcelableSpan`, `UpdateAppearance`, `UpdateLayout`, `Parcelable`

public class SubscriptSpan extends MetricAffectingSpan implements ParcelableSpan
The span that moves the position of the text baseline lower.

Unlike Android, this Span also affects the relative text size.

- ## Nested Class Summary

  ## Nested classes/interfaces inherited from interface icyllis.modernui.util.Parcelable

  `Parcelable.ClassLoaderCreator<T>, Parcelable.Creator<T>, Parcelable.WriteFlags`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `SubscriptSpan()`
  Creates a `SubscriptSpan`.
  `SubscriptSpan(Parcel src)`
  Creates a `SubscriptSpan` from a parcel.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `protected void`
  `applyBaselineShift(TextPaint textPaint)`
  `int`
  `getSpanTypeId()`
  Return a special type identifier for this span class.
  `String`
  `toString()`
  `void`
  `updateMeasureState(TextPaint textPaint)`
  Classes that extend MetricAffectingSpan implement this method to update the text formatting in a way that can change the width or height of characters.
  `void`
  `writeToParcel(Parcel dest, int flags)`
  The subclass implements the method to flatten its contents by calling the methods of `Parcel` for its primitive values.

  ### Methods inherited from class icyllis.modernui.text.style.MetricAffectingSpan

  `getUnderlying, updateDrawState`

  ### Methods inherited from class icyllis.modernui.text.style.CharacterStyle

  `wrap`

  ### Methods inherited from class java.lang.Object

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

- ## Constructor Details

  - ### SubscriptSpan

    public SubscriptSpan()
    Creates a `SubscriptSpan`.

  - ### SubscriptSpan

    public SubscriptSpan(@NonNull Parcel src)
    Creates a `SubscriptSpan` from a parcel.

- ## Method Details

  - ### getSpanTypeId

    public int getSpanTypeId()
    Description copied from interface: `ParcelableSpan`
    Return a special type identifier for this span class.
    Specified by:
      `getSpanTypeId` in interface `ParcelableSpan`

  - ### writeToParcel

    public void writeToParcel(@NonNull Parcel dest, int flags)
    Description copied from interface: `Parcelable`
    The subclass implements the method to flatten its contents by calling the methods of `Parcel` for its primitive values.
    Specified by:
      `writeToParcel` in interface `Parcelable`
    Parameters:
      `dest` - the parcel to write the object's data to
      `flags` - the flags about how the object should be written

  - ### updateMeasureState

    public void updateMeasureState(@NonNull TextPaint textPaint)
    Description copied from class: `MetricAffectingSpan`
    Classes that extend MetricAffectingSpan implement this method to update the text formatting in a way that can change the width or height of characters.
    Specified by:
      `updateMeasureState` in class `MetricAffectingSpan`
    Parameters:
      `textPaint` - the paint used for measuring the text

  - ### applyBaselineShift

    protected void applyBaselineShift(@NonNull TextPaint textPaint)

  - ### toString

    public String toString()
    Overrides:
      `toString` in class `Object`