what I'm trying to draw is the following:
But with a plus instead of a minus sign in the center of the arrow.
I want to subtract the minus from the shape of the white base. It is strange that works fine for the minus, but if I draw a plus sign, instead, it no longer subtracts it, but adds it to the main path.
My minus subtraction code is as follows
Path base = new Path(); [... draw the arrow ] Path subtract = new Path(); subtract.moveTo(-xBarWidth/2, -xBarHeight/2);
Code for the plus sign:
int halfBarWidth = xBarWidth/2; subtract.moveTo(-halfBarWidth, -xBarHeight/2); subtract.rLineTo(halfBarWidth, 0); subtract.rLineTo(0, halfBarWidth); subtract.rLineTo(xBarHeight, 0); subtract.rLineTo(0, -halfBarWidth); subtract.rLineTo(halfBarWidth, 0); subtract.rLineTo(0, -xBarHeight); subtract.rLineTo(-halfBarWidth, 0); subtract.rLineTo(0, -halfBarWidth); subtract.rLineTo(-xBarHeight, 0); subtract.rLineTo(0, halfBarWidth); subtract.rLineTo(-halfBarWidth, 0); subtract.rLineTo(0, xBarHeight);
However, now he draws a white plus on top of the arrow. I tried subtract.setFillType(FillType.INVERSE_EVEN_ODD) , but nothing changed.
Unfortunately, I can not find any help in the api.
source share