Lines Matching refs:format
131 static bool date_format_parse (const char *format);
132 static bool number_format_parse (const char *format);
133 static bool choice_format_parse (const char *format, struct spec *spec,
142 if (*format == '\'' && *++format != '\'') \
152 message_format_parse (const char *format, struct spec *spec, in message_format_parse() argument
160 if (!quoting && *format == '{') in message_format_parse()
173 element_start = ++format; in message_format_parse()
175 for (; *format != '\0'; format++) in message_format_parse()
177 if (*format == '{') in message_format_parse()
179 else if (*format == '}') in message_format_parse()
187 if (*format == '\0') in message_format_parse()
193 element_end = format++; in message_format_parse()
330 else if (!quoting && *format == '}') in message_format_parse()
336 else if (*format != '\0') in message_format_parse()
337 format++; in message_format_parse()
347 date_format_parse (const char *format) in date_format_parse() argument
359 number_format_parse (const char *format) in number_format_parse() argument
389 while (*format != '\0' in number_format_parse()
390 && !(!quoting && (*format == '0' || *format == '#'))) in number_format_parse()
392 if (format[0] == '\\') in number_format_parse()
394 if (format[1] == 'u' in number_format_parse()
395 && c_isxdigit (format[2]) in number_format_parse()
396 && c_isxdigit (format[3]) in number_format_parse()
397 && c_isxdigit (format[4]) in number_format_parse()
398 && c_isxdigit (format[5])) in number_format_parse()
399 format += 6; in number_format_parse()
401 format += 2; in number_format_parse()
404 format += 1; in number_format_parse()
409 if (!(!quoting && (*format == '0' || *format == '#'))) in number_format_parse()
411 while (!quoting && *format == '#') in number_format_parse()
413 format++; in number_format_parse()
415 if (!quoting && *format == ',') in number_format_parse()
417 format++; in number_format_parse()
421 while (!quoting && *format == '0') in number_format_parse()
423 format++; in number_format_parse()
425 if (!quoting && *format == ',') in number_format_parse()
427 format++; in number_format_parse()
433 if (!quoting && *format == '.') in number_format_parse()
435 format++; in number_format_parse()
437 while (!quoting && *format == '0') in number_format_parse()
439 format++; in number_format_parse()
442 while (!quoting && *format == '#') in number_format_parse()
444 format++; in number_format_parse()
450 if (!quoting && *format == 'E') in number_format_parse()
452 const char *format_save = format; in number_format_parse()
453 format++; in number_format_parse()
455 if (!quoting && *format == '0') in number_format_parse()
459 format++; in number_format_parse()
462 while (!quoting && *format == '0'); in number_format_parse()
467 format = format_save; in number_format_parse()
473 while (*format != '\0' in number_format_parse()
474 && (seen_semicolon || !(!quoting && *format == ';'))) in number_format_parse()
476 if (format[0] == '\\') in number_format_parse()
478 if (format[1] == 'u' in number_format_parse()
479 && c_isxdigit (format[2]) in number_format_parse()
480 && c_isxdigit (format[3]) in number_format_parse()
481 && c_isxdigit (format[4]) in number_format_parse()
482 && c_isxdigit (format[5])) in number_format_parse()
483 format += 6; in number_format_parse()
485 format += 2; in number_format_parse()
488 format += 1; in number_format_parse()
492 if (seen_semicolon || !(!quoting && *format == ';')) in number_format_parse()
496 return (*format == '\0'); in number_format_parse()
502 choice_format_parse (const char *format, struct spec *spec, in choice_format_parse() argument
516 if (*format == '\0') in choice_format_parse()
529 while (*format != '\0' in choice_format_parse()
530 && !(!quoting && (*format == '<' || *format == '#' in choice_format_parse()
531 || strncmp (format, "\\u2264", 6) == 0 in choice_format_parse()
532 || *format == '|'))) in choice_format_parse()
534 if (format[0] == '\\') in choice_format_parse()
536 if (format[1] == 'u' in choice_format_parse()
537 && c_isxdigit (format[2]) in choice_format_parse()
538 && c_isxdigit (format[3]) in choice_format_parse()
539 && c_isxdigit (format[4]) in choice_format_parse()
540 && c_isxdigit (format[5])) in choice_format_parse()
541 format += 6; in choice_format_parse()
543 format += 2; in choice_format_parse()
546 format += 1; in choice_format_parse()
552 if (*format == '\0') in choice_format_parse()
562 if (*format == '<' || *format == '#') in choice_format_parse()
563 format += 1; in choice_format_parse()
564 else if (strncmp (format, "\\u2264", 6) == 0) in choice_format_parse()
565 format += 6; in choice_format_parse()
574 msgformat = (char *) xallocsa (strlen (format) + 1); in choice_format_parse()
577 while (*format != '\0' && !(!quoting && *format == '|')) in choice_format_parse()
579 *mp++ = *format++; in choice_format_parse()
591 if (*format == '\0') in choice_format_parse()
594 format++; in choice_format_parse()
611 format_parse (const char *format, bool translated, char **invalid_reason) in format_parse() argument
621 if (!message_format_parse (format, &spec, invalid_reason)) in format_parse()