From 0640eca05c89e7670785fd39969a2e01ebfe32e9 Mon Sep 17 00:00:00 2001 From: Araki Ken Date: Thu, 14 Mar 2013 04:53:45 +0900 Subject: * file.c: nw and ni are rounded up instead of rounded off to show every corner of images. --- file.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'file.c') diff --git a/file.c b/file.c index 10ad444..b907c14 100644 --- a/file.c +++ b/file.c @@ -3345,8 +3345,14 @@ process_img(struct parsed_tag *tag, int width) if (i < 0) i = pixel_per_line; } - nw = (w > 3) ? (int)((w - 3) / pixel_per_char + 1) : 1; - ni = (i > 3) ? (int)((i - 3) / pixel_per_line + 1) : 1; + if (support_remote_image) { + nw = (w > 1) ? ((w - 1) / pixel_per_char_i + 1) : 1 ; + ni = (i > 1) ? ((i - 1) / pixel_per_line_i + 1) : 1 ; + } + else { + nw = (w > 3) ? (int)((w - 3) / pixel_per_char + 1) : 1; + ni = (i > 3) ? (int)((i - 3) / pixel_per_line + 1) : 1; + } Strcat(tmp, Sprintf("