From 8830b9a2237717b3e36a66a567ed59888836401a Mon Sep 17 00:00:00 2001 From: Werner Almesberger Date: Thu, 28 Jul 2016 15:49:14 -0300 Subject: [PATCH] sch2fig/lib.c (draw_text): also support mirroring test.sch now renders correctly. --- sch2fig/lib.c | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/sch2fig/lib.c b/sch2fig/lib.c index 0c65178..a3adac6 100644 --- a/sch2fig/lib.c +++ b/sch2fig/lib.c @@ -392,6 +392,21 @@ static void draw_text(const struct text_obj *text, int m[6]) default: break; } + + if (matrix_is_mirrored(m)) + switch (txt.rot) { + case 0: + case 180: + txt.hor = text_flip(txt.hor); + break; + case 90: + case 270: + txt.vert = text_flip(txt.vert); + break; + default: + abort(); + } + text_fig(&txt, COLOR_COMP_DWG, WIDTH_COMP_DWG); }