diff options
Diffstat (limited to 'source/a/dialog/dialog.no.aspect.ratio.autoajust.patch')
-rw-r--r-- | source/a/dialog/dialog.no.aspect.ratio.autoajust.patch | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/source/a/dialog/dialog.no.aspect.ratio.autoajust.patch b/source/a/dialog/dialog.no.aspect.ratio.autoajust.patch new file mode 100644 index 000000000..7bce97b80 --- /dev/null +++ b/source/a/dialog/dialog.no.aspect.ratio.autoajust.patch @@ -0,0 +1,31 @@ +--- ./util.c.orig 2019-11-10 17:20:58.000000000 -0600 ++++ ./util.c 2019-12-07 14:40:23.404722986 -0600 +@@ -1237,28 +1237,6 @@ + justify_text((WINDOW *) 0, prompt, max_y, max_x, &high, &wide); + car = (float) (wide / high); + +- /* +- * If the aspect ratio is greater than it should be, then decrease the +- * width proportionately. +- */ +- if (car > ar) { +- float diff = car / (float) ar; +- max_x = (int) ((float) wide / diff + 4); +- justify_text((WINDOW *) 0, prompt, max_y, max_x, &high, &wide); +- car = (float) wide / (float) high; +- } +- +- /* +- * If the aspect ratio is too small after decreasing the width, then +- * incrementally increase the width until the aspect ratio is equal to or +- * greater than the specified aspect ratio. +- */ +- while (car < ar && max_x < max_width) { +- max_x += 4; +- justify_text((WINDOW *) 0, prompt, max_y, max_x, &high, &wide); +- car = (float) (wide / high); +- } +- + *height = high; + *width = wide; + } |