Lines Matching full:maxlen

36 #define CF(format,target,v,maxlen)                              \  argument
39 snprintf (v, maxlen, \
48 #define CC(number,target,v,maxlen) \ argument
51 snprintf (v, maxlen, \
57 #define CC2(number,t1,t2,v,maxlen) \ argument
60 snprintf (v, maxlen, \
443 unsigned int t, ExifShort vs, char *val, unsigned int maxlen) in canon_search_table_value() argument
456 strncpy (val, _(table[j].name), maxlen); in canon_search_table_value()
459 snprintf (val, maxlen, "0x%04x", vs); in canon_search_table_value()
465 unsigned int t, ExifShort vs, char *val, unsigned int maxlen) in canon_search_table_bitfield() argument
492 strncat(val, _(table[i].name), maxlen - strlen (val)); in canon_search_table_bitfield()
494 strncat (val, _(", "), maxlen - strlen (val)); in canon_search_table_bitfield()
499 snprintf (val, maxlen, "0x%04x", vs); in canon_search_table_bitfield()
551 …anon_entry_get_value (const MnoteCanonEntry *entry, unsigned int t, char *val, unsigned int maxlen) in mnote_canon_entry_get_value() argument
564 memset (val, 0, maxlen); in mnote_canon_entry_get_value()
565 maxlen--; in mnote_canon_entry_get_value()
569 CF (entry->format, EXIF_FORMAT_SHORT, val, maxlen); in mnote_canon_entry_get_value()
572 CC (entry->components, n, val, maxlen); in mnote_canon_entry_get_value()
577 strncpy(val, _("Off"), maxlen); in mnote_canon_entry_get_value()
580 snprintf (val, maxlen, _("%i (ms)"), vs * 100); in mnote_canon_entry_get_value()
585 snprintf (val, maxlen, "%i", vs & ~0x4000); in mnote_canon_entry_get_value()
588 canon_search_table_value (entries_settings_1, t, vs, val, maxlen); in mnote_canon_entry_get_value()
594 snprintf (val, maxlen, "%u", vs); in mnote_canon_entry_get_value()
598 snprintf (val, maxlen, "%.2f", apex_value_to_aperture (vs / 32.0)); in mnote_canon_entry_get_value()
601 canon_search_table_bitfield(entries_settings_1, t, vs, val, maxlen); in mnote_canon_entry_get_value()
604 snprintf (val, maxlen, "%.2f", vs / 10.0); in mnote_canon_entry_get_value()
608 snprintf (val, maxlen, "%u", vs); in mnote_canon_entry_get_value()
611 canon_search_table_value (entries_settings_1, t, vs, val, maxlen); in mnote_canon_entry_get_value()
616 CF (entry->format, EXIF_FORMAT_SHORT, val, maxlen); in mnote_canon_entry_get_value()
620 snprintf (val, maxlen, "%u", vs); in mnote_canon_entry_get_value()
624 snprintf (val, maxlen, _("%.2f mm"), vs * 25.4 / 1000); in mnote_canon_entry_get_value()
627 canon_search_table_value (entries_focal_length, t, vs, val, maxlen); in mnote_canon_entry_get_value()
632 CF (entry->format, EXIF_FORMAT_SHORT, val, maxlen); in mnote_canon_entry_get_value()
635 CC (entry->components, n, val, maxlen); in mnote_canon_entry_get_value()
639 snprintf (val, maxlen, "%.3f", pow (2, (ExifSShort)vs / 32.0)); in mnote_canon_entry_get_value()
642 snprintf (val, maxlen, "%.0f", apex_value_to_iso_speed ((ExifSShort)vs / 32.0)); in mnote_canon_entry_get_value()
648 snprintf (val, maxlen, _("%.2f EV"), (ExifSShort)vs / 32.0); in mnote_canon_entry_get_value()
652 snprintf (val, maxlen, "%.2f", apex_value_to_aperture (vs / 32.0)); in mnote_canon_entry_get_value()
658 snprintf (val, maxlen, _("1/%i"),(int)(1.0 / d)); in mnote_canon_entry_get_value()
660 snprintf (val, maxlen, "%i", (int) d); in mnote_canon_entry_get_value()
663 snprintf (val, maxlen, "%u", vs); in mnote_canon_entry_get_value()
666 snprintf (val, maxlen, "%.2f", vs / 32.0); in mnote_canon_entry_get_value()
670 snprintf (val, maxlen, _("%u mm"), vs); in mnote_canon_entry_get_value()
674 strncpy(val, _("Off"), maxlen); in mnote_canon_entry_get_value()
677 snprintf (val, maxlen, _("%i (ms)"), vs * 100); in mnote_canon_entry_get_value()
680 canon_search_table_value (entries_settings_2, t, vs, val, maxlen); in mnote_canon_entry_get_value()
685 CF (entry->format, EXIF_FORMAT_SHORT, val, maxlen); in mnote_canon_entry_get_value()
687 canon_search_table_value (entries_panorama, t, vs, val, maxlen); in mnote_canon_entry_get_value()
691 CC (entry->components, 32, val, maxlen); in mnote_canon_entry_get_value()
694 CF (entry->format, EXIF_FORMAT_ASCII, val, maxlen); in mnote_canon_entry_get_value()
695 strncpy (val, (char *)data, MIN (entry->size, maxlen)); in mnote_canon_entry_get_value()
699 CF (entry->format, EXIF_FORMAT_ASCII, val, maxlen); in mnote_canon_entry_get_value()
700 /* CC2 (entry->components, 24, 32, val, maxlen); Can also be 22 */ in mnote_canon_entry_get_value()
701 strncpy (val, (char *)data, MIN (entry->size, maxlen)); in mnote_canon_entry_get_value()
705 CF (entry->format, EXIF_FORMAT_LONG, val, maxlen); in mnote_canon_entry_get_value()
706 CC (entry->components, 1, val, maxlen); in mnote_canon_entry_get_value()
708 snprintf (val, maxlen, "%03lu-%04lu", in mnote_canon_entry_get_value()
714 CF (entry->format, EXIF_FORMAT_LONG, val, maxlen); in mnote_canon_entry_get_value()
715 CC (entry->components, 1, val, maxlen); in mnote_canon_entry_get_value()
717 snprintf (val, maxlen, "%04X-%05d", (int)vl>>16,(int)vl&0xffff); in mnote_canon_entry_get_value()
721 CF (entry->format, EXIF_FORMAT_SHORT, val, maxlen); in mnote_canon_entry_get_value()
724 CC (entry->components, n, val, maxlen); in mnote_canon_entry_get_value()
727 strncat (val, buf, maxlen - strlen (val)); in mnote_canon_entry_get_value()
731 CF (entry->format, EXIF_FORMAT_SHORT, val, maxlen); in mnote_canon_entry_get_value()
734 CC (entry->components, n, val, maxlen); in mnote_canon_entry_get_value()
736 canon_search_table_value (color_information, t, vs, val, maxlen); in mnote_canon_entry_get_value()
756 strncpy (val, data, MIN (entry->size, maxlen)); in mnote_canon_entry_get_value()