MCPcopy Index your code
hub / github.com/git/git / pp_utf8_width

Function pp_utf8_width

pretty.c:2169–2181  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2167}
2168
2169static int pp_utf8_width(const char *start, const char *end)
2170{
2171 int width = 0;
2172 size_t remain = end - start;
2173
2174 while (remain) {
2175 int n = utf8_width(&start, &remain);
2176 if (n < 0 || !start)
2177 return -1;
2178 width += n;
2179 }
2180 return width;
2181}
2182
2183static void strbuf_add_tabexpand(struct strbuf *sb, struct grep_opt *opt,
2184 enum git_colorbool color, int tabwidth, const char *line,

Callers 1

strbuf_add_tabexpandFunction · 0.85

Calls 1

utf8_widthFunction · 0.85

Tested by

no test coverage detected