1
0
mirror of git://projects.qi-hardware.com/eda-tools.git synced 2024-12-23 16:25:10 +02:00

sch2fig/lib.c (draw_pin_num): correct pin number flipping

This commit is contained in:
Werner Almesberger 2016-07-26 20:56:43 -03:00
parent e5ba111258
commit ff12e388e2

View File

@ -282,10 +282,27 @@ static void draw_pin_num(const struct comp *comp, const struct pin_obj *pin,
text_rot(&txt, matrix_to_angle(m) % 180);
if (matrix_is_mirrored(m)) {
if ((txt.rot % 180) == 0)
switch (txt.rot) {
case 0:
txt.hor = text_flip(txt.hor);
else
txt.vert = text_flip(txt.vert);
break;
case 90:
break;
case 180:
txt.hor = text_flip(txt.hor);
break;
case 270:
break;
}
}
switch (txt.rot) {
case 180:
case 270:
text_flip_x(&txt);
break;
default:
break;
}
text_fig(&txt, COLOR_PIN_NUMBER, LAYER_PIN_NUMBER);