1

I am trying to implement TextView outline in one of my android application which is described here

I have made custom textView class as mentioned and there no any error. I am trying to use it in my activity but as I am learning yet, I am confused to use it in Activity as setStroke method.

I am trying as below

text_quotes.setStroke(0,R.color.toolbar_color,0,0);

can anybody please suggest me this four filed which value I should enter?

in CustomeTextView class is defined as below

strokeWidth = width;
strokeColor = color;
strokeJoin = join;
strokeMiter = miter;

I have issue in strokeJoin field, which value I should enter for it ? Thanks

KeLiuyue
  • 8,149
  • 4
  • 25
  • 42

1 Answers1

1

StrokeJoin seems to be a value of the Paint.Join enumeration. So you should try one of the Paint.Join values like :

Paint.Join.MITER;
Paint.Join.BEVEL;
Paint.Join.ROUND;

Look the different values here : https://developer.android.com/reference/android/graphics/Paint.Join.html

olivejp
  • 900
  • 1
  • 9
  • 14