Package org.robolectric.shadows
Class ShadowNativePaint
java.lang.Object
org.robolectric.shadows.ShadowNativePaint
@Implements(minSdk=26, value=android.graphics.Paint.class, looseSignatures=true, shadowPicker=Picker.class, isInAndroidSdk=false) public class ShadowNativePaint extends Object
Shadow for
Paint
that is backed by native code-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
ShadowNativePaint.Picker
Shadow picker forPaint
. -
Constructor Summary
Constructors Constructor Description ShadowNativePaint()
-
Method Summary
Modifier and Type Method Description protected static float
nAscent(long paintPtr)
protected static float
nAscent(long paintPtr, long typefacePtr)
protected static int
nBreakText(long nObject, char[] text, int index, int count, float maxWidth, int bidiFlags, float[] measuredWidth)
protected static int
nBreakText(long nObject, long typefacePtr, char[] text, int index, int count, float maxWidth, int bidiFlags, float[] measuredWidth)
protected static int
nBreakText(long nObject, long typefacePtr, String text, boolean measureForwards, float maxWidth, int bidiFlags, float[] measuredWidth)
protected static int
nBreakText(long nObject, String text, boolean measureForwards, float maxWidth, int bidiFlags, float[] measuredWidth)
protected static float
nDescent(long paintPtr)
protected static float
nDescent(long paintPtr, long typefacePtr)
protected static boolean
nEqualsForTextMeasurement(long leftPaintPtr, long rightPaintPtr)
protected static int
nGetAlpha(long paintPtr)
protected static void
nGetCharArrayBounds(long nativePaint, char[] text, int index, int count, int bidiFlags, Rect bounds)
protected static void
nGetCharArrayBounds(long nativePaint, long typefacePtr, char[] text, int index, int count, int bidiFlags, Rect bounds)
protected static int
nGetColor(long paintPtr)
protected static int
nGetEndHyphenEdit(long paintPtr)
protected static boolean
nGetFillPath(long paintPtr, long src, long dst)
protected static int
nGetFlags(long paintPtr)
protected static float
nGetFontMetrics(long paintPtr, long typefacePtr, Paint.FontMetrics metrics)
protected static float
nGetFontMetrics(long paintPtr, Paint.FontMetrics metrics)
protected static int
nGetFontMetricsInt(long paintPtr, long typefacePtr, Paint.FontMetricsInt fmi)
protected static int
nGetFontMetricsInt(long paintPtr, Paint.FontMetricsInt fmi)
protected static void
nGetFontMetricsIntForText(long paintPtr, char[] text, int start, int count, int ctxStart, int ctxCount, boolean isRtl, Paint.FontMetricsInt outMetrics)
protected static void
nGetFontMetricsIntForText(long paintPtr, String text, int start, int count, int ctxStart, int ctxCount, boolean isRtl, Paint.FontMetricsInt outMetrics)
protected static int
nGetHinting(long paintPtr)
protected static int
nGetHyphenEdit(long paintPtr)
protected static float
nGetLetterSpacing(long paintPtr)
protected static long
nGetNativeFinalizer()
protected static int
nGetOffsetForAdvance(long paintPtr, char[] text, int start, int end, int contextStart, int contextEnd, boolean isRtl, float advance)
protected static int
nGetOffsetForAdvance(long paintPtr, long typefacePtr, char[] text, int start, int end, int contextStart, int contextEnd, boolean isRtl, float advance)
protected static float
nGetRunAdvance(long paintPtr, char[] text, int start, int end, int contextStart, int contextEnd, boolean isRtl, int offset)
protected static float
nGetRunAdvance(long paintPtr, long typefacePtr, char[] text, int start, int end, int contextStart, int contextEnd, boolean isRtl, int offset)
protected static float
nGetRunCharacterAdvance(long paintPtr, char[] text, int start, int end, int contextStart, int contextEnd, boolean isRtl, int offset, float[] advances, int advancesIndex)
protected static int
nGetStartHyphenEdit(long paintPtr)
protected static float
nGetStrikeThruPosition(long paintPtr)
protected static float
nGetStrikeThruThickness(long paintPtr)
protected static void
nGetStringBounds(long nativePaint, long typefacePtr, String text, int start, int end, int bidiFlags, Rect bounds)
protected static void
nGetStringBounds(long nativePaint, String text, int start, int end, int bidiFlags, Rect bounds)
protected static int
nGetStrokeCap(long paintPtr)
protected static int
nGetStrokeJoin(long paintPtr)
protected static float
nGetStrokeMiter(long paintPtr)
protected static float
nGetStrokeWidth(long paintPtr)
protected static int
nGetStyle(long paintPtr)
protected static float
nGetTextAdvances(long paintPtr, char[] text, int index, int count, int contextIndex, int contextCount, int bidiFlags, float[] advances, int advancesIndex)
protected static float
nGetTextAdvances(long paintPtr, long typefacePtr, char[] text, int index, int count, int contextIndex, int contextCount, int bidiFlags, float[] advances, int advancesIndex)
protected static float
nGetTextAdvances(long paintPtr, long typefacePtr, String text, int index, int count, int contextIndex, int contextCount, int bidiFlags, float[] advances, int advancesIndex)
protected static float
nGetTextAdvances(long paintPtr, String text, int start, int end, int contextStart, int contextEnd, int bidiFlags, float[] advances, int advancesIndex)
protected static int
nGetTextAlign(long paintPtr)
protected static void
nGetTextPath(long paintPtr, int bidiFlags, char[] text, int index, int count, float x, float y, long path)
protected static void
nGetTextPath(long paintPtr, int bidiFlags, String text, int start, int end, float x, float y, long path)
protected static void
nGetTextPath(long paintPtr, long typefacePtr, int bidiFlags, char[] text, int index, int count, float x, float y, long path)
protected static void
nGetTextPath(long paintPtr, long typefacePtr, int bidiFlags, String text, int start, int end, float x, float y, long path)
protected int
nGetTextRunCursor(long paintPtr, char[] text, int contextStart, int contextLength, int dir, int offset, int cursorOpt)
protected int
nGetTextRunCursor(long paintPtr, long typefacePtr, char[] text, int contextStart, int contextLength, int dir, int offset, int cursorOpt)
protected int
nGetTextRunCursor(long paintPtr, long typefacePtr, String text, int contextStart, int contextEnd, int dir, int offset, int cursorOpt)
protected int
nGetTextRunCursor(long paintPtr, String text, int contextStart, int contextEnd, int dir, int offset, int cursorOpt)
protected static float
nGetTextScaleX(long paintPtr)
protected static float
nGetTextSize(long paintPtr)
protected static float
nGetTextSkewX(long paintPtr)
protected static float
nGetUnderlinePosition(long paintPtr)
protected static float
nGetUnderlineThickness(long paintPtr)
protected static float
nGetWordSpacing(long paintPtr)
protected static boolean
nHasGlyph(long paintPtr, int bidiFlags, String string)
protected static boolean
nHasGlyph(long paintPtr, long typefacePtr, int bidiFlags, String string)
protected static boolean
nHasShadowLayer(long paintPtr)
protected static long
nInit()
protected static long
nInitWithPaint(long paint)
protected static boolean
nIsElegantTextHeight(long paintPtr)
protected static void
nReset(long paintPtr)
protected static void
nSet(long paintPtrDest, long paintPtrSrc)
protected static void
nSetAlpha(long paintPtr, int a)
protected static void
nSetAntiAlias(long paintPtr, boolean aa)
protected static void
nSetColor(long paintPtr, int color)
protected static void
nSetColor(long paintPtr, long colorSpaceHandle, long color)
protected static long
nSetColorFilter(long paintPtr, long filter)
protected static void
nSetDither(long paintPtr, boolean dither)
protected static void
nSetElegantTextHeight(long paintPtr, boolean elegant)
protected static void
nSetEndHyphenEdit(long paintPtr, int hyphen)
protected static void
nSetFakeBoldText(long paintPtr, boolean fakeBoldText)
protected static void
nSetFilterBitmap(long paintPtr, boolean filter)
protected static void
nSetFlags(long paintPtr, int flags)
protected static void
nSetFontFeatureSettings(long paintPtr, String settings)
protected static void
nSetHinting(long paintPtr, int mode)
protected static void
nSetHyphenEdit(long paintPtr, int hyphen)
protected static void
nSetLetterSpacing(long paintPtr, float letterSpacing)
protected static void
nSetLinearText(long paintPtr, boolean linearText)
protected static long
nSetMaskFilter(long paintPtr, long maskfilter)
protected static long
nSetPathEffect(long paintPtr, long effect)
protected static long
nSetShader(long paintPtr, long shader)
protected static void
nSetShadowLayer(long paintPtr, float radius, float dx, float dy, int color)
protected static void
nSetShadowLayer(long paintPtr, float radius, float dx, float dy, long colorSpaceHandle, long shadowColor)
protected static void
nSetStartHyphenEdit(long paintPtr, int hyphen)
protected static void
nSetStrikeThruText(long paintPtr, boolean strikeThruText)
protected static void
nSetStrokeCap(long paintPtr, int cap)
protected static void
nSetStrokeJoin(long paintPtr, int join)
protected static void
nSetStrokeMiter(long paintPtr, float miter)
protected static void
nSetStrokeWidth(long paintPtr, float width)
protected static void
nSetStyle(long paintPtr, int style)
protected static void
nSetSubpixelText(long paintPtr, boolean subpixelText)
protected static void
nSetTextAlign(long paintPtr, int align)
protected static int
nSetTextLocales(long paintPtr, String locales)
protected static void
nSetTextLocalesByMinikinLocaleListId(long paintPtr, int mMinikinLocaleListId)
protected static void
nSetTextScaleX(long paintPtr, float scaleX)
protected static void
nSetTextSize(long paintPtr, float textSize)
protected static void
nSetTextSkewX(long paintPtr, float skewX)
protected static void
nSetTypeface(long paintPtr, long typeface)
protected static Object
nSetTypeface(Object paintPtr, Object typeface)
protected static void
nSetUnderlineText(long paintPtr, boolean underlineText)
protected static void
nSetWordSpacing(long paintPtr, float wordSpacing)
protected static void
nSetXfermode(long paintPtr, int xfermode)
-
Constructor Details
-
ShadowNativePaint
public ShadowNativePaint()
-
-
Method Details
-
nGetNativeFinalizer
-
nInit
-
nGetHyphenEdit
-
nSetHyphenEdit
@Implementation(minSdk=26, maxSdk=28) protected static void nSetHyphenEdit(long paintPtr, int hyphen) -
nInitWithPaint
-
nBreakText
@Implementation(minSdk=28) protected static int nBreakText(long nObject, char[] text, int index, int count, float maxWidth, int bidiFlags, float[] measuredWidth) -
nBreakText
@Implementation(minSdk=28) protected static int nBreakText(long nObject, String text, boolean measureForwards, float maxWidth, int bidiFlags, float[] measuredWidth) -
nBreakText
@Implementation(minSdk=26, maxSdk=27) protected static int nBreakText(long nObject, long typefacePtr, char[] text, int index, int count, float maxWidth, int bidiFlags, float[] measuredWidth) -
nBreakText
@Implementation(minSdk=26, maxSdk=27) protected static int nBreakText(long nObject, long typefacePtr, String text, boolean measureForwards, float maxWidth, int bidiFlags, float[] measuredWidth) -
nGetTextAdvances
@Implementation(minSdk=28) protected static float nGetTextAdvances(long paintPtr, char[] text, int index, int count, int contextIndex, int contextCount, int bidiFlags, float[] advances, int advancesIndex) -
nGetTextAdvances
@Implementation(minSdk=28) protected static float nGetTextAdvances(long paintPtr, String text, int start, int end, int contextStart, int contextEnd, int bidiFlags, float[] advances, int advancesIndex) -
nGetTextAdvances
@Implementation(minSdk=26, maxSdk=27) protected static float nGetTextAdvances(long paintPtr, long typefacePtr, char[] text, int index, int count, int contextIndex, int contextCount, int bidiFlags, float[] advances, int advancesIndex) -
nGetTextAdvances
@Implementation(minSdk=26, maxSdk=27) protected static float nGetTextAdvances(long paintPtr, long typefacePtr, String text, int index, int count, int contextIndex, int contextCount, int bidiFlags, float[] advances, int advancesIndex) -
nGetTextRunCursor
@Implementation(minSdk=28) protected int nGetTextRunCursor(long paintPtr, char[] text, int contextStart, int contextLength, int dir, int offset, int cursorOpt) -
nGetTextRunCursor
@Implementation(minSdk=28) protected int nGetTextRunCursor(long paintPtr, String text, int contextStart, int contextEnd, int dir, int offset, int cursorOpt) -
nGetTextRunCursor
@Implementation(minSdk=26, maxSdk=27) protected int nGetTextRunCursor(long paintPtr, long typefacePtr, char[] text, int contextStart, int contextLength, int dir, int offset, int cursorOpt) -
nGetTextRunCursor
@Implementation(minSdk=26, maxSdk=27) protected int nGetTextRunCursor(long paintPtr, long typefacePtr, String text, int contextStart, int contextEnd, int dir, int offset, int cursorOpt) -
nGetTextPath
@Implementation(minSdk=28) protected static void nGetTextPath(long paintPtr, int bidiFlags, char[] text, int index, int count, float x, float y, long path) -
nGetTextPath
@Implementation(minSdk=28) protected static void nGetTextPath(long paintPtr, int bidiFlags, String text, int start, int end, float x, float y, long path) -
nGetTextPath
@Implementation(minSdk=26, maxSdk=27) protected static void nGetTextPath(long paintPtr, long typefacePtr, int bidiFlags, char[] text, int index, int count, float x, float y, long path) -
nGetTextPath
@Implementation(minSdk=26, maxSdk=27) protected static void nGetTextPath(long paintPtr, long typefacePtr, int bidiFlags, String text, int start, int end, float x, float y, long path) -
nGetStringBounds
@Implementation(minSdk=28) protected static void nGetStringBounds(long nativePaint, String text, int start, int end, int bidiFlags, Rect bounds) -
nGetStringBounds
@Implementation(minSdk=26, maxSdk=27) protected static void nGetStringBounds(long nativePaint, long typefacePtr, String text, int start, int end, int bidiFlags, Rect bounds) -
nGetColor
-
nGetAlpha
-
nGetCharArrayBounds
@Implementation(minSdk=28) protected static void nGetCharArrayBounds(long nativePaint, char[] text, int index, int count, int bidiFlags, Rect bounds) -
nGetCharArrayBounds
@Implementation(minSdk=26, maxSdk=27) protected static void nGetCharArrayBounds(long nativePaint, long typefacePtr, char[] text, int index, int count, int bidiFlags, Rect bounds) -
nHasGlyph
@Implementation(minSdk=28) protected static boolean nHasGlyph(long paintPtr, int bidiFlags, String string) -
nHasGlyph
@Implementation(minSdk=26, maxSdk=27) protected static boolean nHasGlyph(long paintPtr, long typefacePtr, int bidiFlags, String string) -
nGetRunAdvance
@Implementation(minSdk=28) protected static float nGetRunAdvance(long paintPtr, char[] text, int start, int end, int contextStart, int contextEnd, boolean isRtl, int offset) -
nGetRunAdvance
@Implementation(minSdk=26, maxSdk=27) protected static float nGetRunAdvance(long paintPtr, long typefacePtr, char[] text, int start, int end, int contextStart, int contextEnd, boolean isRtl, int offset) -
nGetOffsetForAdvance
@Implementation(minSdk=26, maxSdk=27) protected static int nGetOffsetForAdvance(long paintPtr, long typefacePtr, char[] text, int start, int end, int contextStart, int contextEnd, boolean isRtl, float advance) -
nGetOffsetForAdvance
@Implementation(minSdk=28) protected static int nGetOffsetForAdvance(long paintPtr, char[] text, int start, int end, int contextStart, int contextEnd, boolean isRtl, float advance) -
nSetTextLocales
-
nSetFontFeatureSettings
@Implementation(minSdk=26) protected static void nSetFontFeatureSettings(long paintPtr, String settings) -
nGetFontMetrics
@Implementation(minSdk=28) protected static float nGetFontMetrics(long paintPtr, Paint.FontMetrics metrics) -
nGetFontMetrics
@Implementation(minSdk=26, maxSdk=27) protected static float nGetFontMetrics(long paintPtr, long typefacePtr, Paint.FontMetrics metrics) -
nGetFontMetricsInt
@Implementation(minSdk=28) protected static int nGetFontMetricsInt(long paintPtr, Paint.FontMetricsInt fmi) -
nGetFontMetricsInt
@Implementation(minSdk=26, maxSdk=27) protected static int nGetFontMetricsInt(long paintPtr, long typefacePtr, Paint.FontMetricsInt fmi) -
nReset
-
nSet
-
nGetStyle
-
nSetStyle
-
nGetStrokeCap
-
nSetStrokeCap
-
nGetStrokeJoin
-
nSetStrokeJoin
-
nGetFillPath
@Implementation(minSdk=26) protected static boolean nGetFillPath(long paintPtr, long src, long dst) -
nSetShader
-
nSetColorFilter
-
nSetXfermode
-
nSetPathEffect
-
nSetMaskFilter
-
nSetTypeface
-
nSetTypeface
-
nGetTextAlign
-
nSetTextAlign
-
nSetTextLocalesByMinikinLocaleListId
@Implementation(minSdk=28) protected static void nSetTextLocalesByMinikinLocaleListId(long paintPtr, int mMinikinLocaleListId) -
nSetShadowLayer
@Implementation(minSdk=29) protected static void nSetShadowLayer(long paintPtr, float radius, float dx, float dy, long colorSpaceHandle, long shadowColor) -
nSetShadowLayer
@Implementation(minSdk=26, maxSdk=28) protected static void nSetShadowLayer(long paintPtr, float radius, float dx, float dy, int color) -
nHasShadowLayer
-
nGetLetterSpacing
-
nSetLetterSpacing
@Implementation(minSdk=26) protected static void nSetLetterSpacing(long paintPtr, float letterSpacing) -
nGetWordSpacing
-
nSetWordSpacing
-
nGetStartHyphenEdit
-
nGetEndHyphenEdit
-
nSetStartHyphenEdit
-
nSetEndHyphenEdit
-
nSetStrokeMiter
-
nGetStrokeMiter
-
nSetStrokeWidth
-
nGetStrokeWidth
-
nSetAlpha
-
nSetDither
-
nGetFlags
-
nSetFlags
-
nGetHinting
-
nSetHinting
-
nSetAntiAlias
-
nSetLinearText
-
nSetSubpixelText
@Implementation(minSdk=26) protected static void nSetSubpixelText(long paintPtr, boolean subpixelText) -
nSetUnderlineText
@Implementation(minSdk=26) protected static void nSetUnderlineText(long paintPtr, boolean underlineText) -
nSetFakeBoldText
@Implementation(minSdk=26) protected static void nSetFakeBoldText(long paintPtr, boolean fakeBoldText) -
nSetFilterBitmap
-
nSetColor
@Implementation(minSdk=29) protected static void nSetColor(long paintPtr, long colorSpaceHandle, long color) -
nSetColor
-
nSetStrikeThruText
@Implementation(minSdk=26) protected static void nSetStrikeThruText(long paintPtr, boolean strikeThruText) -
nIsElegantTextHeight
-
nSetElegantTextHeight
@Implementation(minSdk=26) protected static void nSetElegantTextHeight(long paintPtr, boolean elegant) -
nGetTextSize
-
nGetTextScaleX
-
nSetTextScaleX
-
nGetTextSkewX
-
nSetTextSkewX
-
nAscent
-
nAscent
@Implementation(minSdk=26, maxSdk=27) protected static float nAscent(long paintPtr, long typefacePtr) -
nDescent
-
nDescent
@Implementation(minSdk=26, maxSdk=27) protected static float nDescent(long paintPtr, long typefacePtr) -
nGetUnderlinePosition
-
nGetUnderlineThickness
-
nGetStrikeThruPosition
-
nGetStrikeThruThickness
-
nSetTextSize
-
nEqualsForTextMeasurement
@Implementation(minSdk=28) protected static boolean nEqualsForTextMeasurement(long leftPaintPtr, long rightPaintPtr) -
nGetFontMetricsIntForText
@Implementation(minSdk=33) protected static void nGetFontMetricsIntForText(long paintPtr, char[] text, int start, int count, int ctxStart, int ctxCount, boolean isRtl, Paint.FontMetricsInt outMetrics) -
nGetFontMetricsIntForText
@Implementation(minSdk=33) protected static void nGetFontMetricsIntForText(long paintPtr, String text, int start, int count, int ctxStart, int ctxCount, boolean isRtl, Paint.FontMetricsInt outMetrics) -
nGetRunCharacterAdvance
@Implementation(minSdk=10000) protected static float nGetRunCharacterAdvance(long paintPtr, char[] text, int start, int end, int contextStart, int contextEnd, boolean isRtl, int offset, float[] advances, int advancesIndex)
-