Lines Matching refs:j
2026 for (size_t j = 0; j < display_columns; j++) { in table_print() local
2027 minimum_width[j] = 1; in table_print()
2028 maximum_width[j] = SIZE_MAX; in table_print()
2034 for (size_t j = 0; j < display_columns; j++) in table_print() local
2035 requested_width[j] = SIZE_MAX; in table_print()
2046 for (size_t j = 0; j < display_columns; j++) { in table_print() local
2050 assert_se(d = row[t->display_map ? t->display_map[j] : j]); in table_print()
2053 width ? width[j] : SIZE_MAX, in table_print()
2067 width ? width[j] : SIZE_MAX, in table_print()
2083 if (requested_width[j] == SIZE_MAX || in table_print()
2084 requested_width[j] < req_width) in table_print()
2085 requested_width[j] = req_width; in table_print()
2088 if (minimum_width[j] < d->minimum_width) in table_print()
2089 minimum_width[j] = d->minimum_width; in table_print()
2093 (maximum_width[j] == SIZE_MAX || in table_print()
2094 maximum_width[j] > d->maximum_width)) in table_print()
2095 maximum_width[j] = d->maximum_width; in table_print()
2098 column_weight[j] += d->weight; in table_print()
2107 for (size_t j = 0; j < display_columns; j++) { in table_print() local
2108 weight_sum += column_weight[j]; in table_print()
2110 table_minimum_width += minimum_width[j]; in table_print()
2112 if (maximum_width[j] == SIZE_MAX) in table_print()
2115 table_maximum_width += maximum_width[j]; in table_print()
2117 table_requested_width += requested_width[j]; in table_print()
2146 for (size_t j = 0; j < display_columns; j++) { in table_print() local
2150 … width[j] = requested_width[j] + extra / (display_columns - j); /* Avoid division by zero */ in table_print()
2152 … width[j] = requested_width[j] + (extra * column_weight[j]) / weight_sum; in table_print()
2154 if (maximum_width[j] != SIZE_MAX && width[j] > maximum_width[j]) in table_print()
2155 width[j] = maximum_width[j]; in table_print()
2157 if (width[j] < minimum_width[j]) in table_print()
2158 width[j] = minimum_width[j]; in table_print()
2160 delta = LESS_BY(width[j], requested_width[j]); in table_print()
2168 assert(weight_sum >= column_weight[j]); in table_print()
2169 weight_sum -= column_weight[j]; in table_print()
2181 for (size_t j = 0; j < display_columns; j++) in table_print() local
2182 width[j] = SIZE_MAX; in table_print()
2187 for (size_t j = 0; j < display_columns; j++) { in table_print() local
2191 if (width[j] != SIZE_MAX) in table_print()
2195 … w = minimum_width[j] + extra / (display_columns - j); /* avoid division by zero */ in table_print()
2197 … w = minimum_width[j] + (extra * column_weight[j]) / weight_sum; in table_print()
2199 if (w >= requested_width[j]) { in table_print()
2205 w = requested_width[j]; in table_print()
2211 width[j] = w; in table_print()
2213 assert(w >= minimum_width[j]); in table_print()
2214 delta = w - minimum_width[j]; in table_print()
2219 assert(weight_sum >= column_weight[j]); in table_print()
2220 weight_sum -= column_weight[j]; in table_print()
2255 for (size_t j = 0; j < display_columns; j++) { in table_print() local
2262 assert_se(d = row[t->display_map ? t->display_map[j] : j]); in table_print()
2264 field = table_data_format(t, d, false, width[j], NULL); in table_print()
2282 if (l > width[j]) { in table_print()
2285 …buffer = ellipsize(field, width[j], /* ellipsize at the end if we truncated coming lines, otherwis… in table_print()
2305 buffer = ellipsize(padded, width[j], 100); in table_print()
2313 if (l < width[j]) { in table_print()
2317 … aligned = align_string_mem(field, d->url, width[j], d->align_percent); in table_print()
2322 if (j == display_columns - 1 && in table_print()
2332 if (l >= width[j] && d->url) { in table_print()
2350 if (j > 0) in table_print()
2664 for (size_t j = 0; j < display_columns; j++) { in table_to_json() local
2669 c = t->display_map ? t->display_map[j] : j; in table_to_json()
2695 r = json_variant_new_string(elements + j*2, n); in table_to_json()
2714 for (size_t j = 0; j < display_columns; j++) { in table_to_json() local
2718 assert_se(d = row[t->display_map ? t->display_map[j] : j]); in table_to_json()
2720 k = j*2+1; in table_to_json()