From: yu.dongliang <18588496441@163.com> Date: Sat, 4 Nov 2023 03:14:20 +0000 (+0800) Subject: __ses_layout_lines2() X-Git-Url: http://baseworks.info/?a=commitdiff_plain;h=3433d583beb966b5de56a5ce59ec6e4ad10d1a6f;p=ses.git __ses_layout_lines2() --- diff --git a/ses_layout.c b/ses_layout.c index f702e84..180d91e 100644 --- a/ses_layout.c +++ b/ses_layout.c @@ -341,6 +341,20 @@ int ses_lines_same_components(ScfEfunction* f) } qsort(f->elines, f->n_elines, sizeof(ScfEline*), eline_cmp); + return 0; +} + +static int __ses_layout_lines2(ScfEfunction* f) +{ + ScfEline* tmp; + ScfEline* el0; + ScfEline* el1; + ScfEconn* ec; + + size_t i; + size_t j; + size_t k0; + size_t k1; if (f->n_elines <= 2) return 0; @@ -502,6 +516,10 @@ static int __ses_layout_lines(ScfEfunction* f, int d) size_t i; + int ret = __ses_layout_lines2(f); + if (ret < 0) + return ret; + for (i = 0; i < f->n_elines; i++) { el = f->elines[i]; @@ -522,6 +540,8 @@ static int __ses_layout_lines(ScfEfunction* f, int d) if (f->h < l->y0) f->h = l->y0; } + + return 0; } static void __ses_layout_components(ScfEfunction* f, int d)