Thread (38 messages) 38 messages, 6 authors, 2019-04-12

Re: [PATCH 5/5] progress: break too long progress bar lines

From: SZEDER Gábor <hidden>
Date: 2019-03-25 11:13:07

On Mon, Mar 25, 2019 at 06:02:13PM +0700, Duy Nguyen wrote:
quoted
@@ -225,6 +241,8 @@ static struct progress *start_progress_delay(const char *title, uint64_t total,
        progress->throughput = NULL;
        progress->start_ns = getnanotime();
        strbuf_init(&progress->counters_sb, 0);
+       progress->title_len = strlen(title);
I think you need utf8_strwidth() so that the "cols < title_len"
comparison above works for multibyte encoding too.
Oh, indeed.  I remember seeing the Chinese translation and wondering
about it, but then completely forgot by the time I got around to it.
quoted
+       progress->split = 0;
        set_progress_signal();
        return progress;
 }
--
2.21.0.539.g07239c3a71.dirty

-- 
Duy
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help