• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /netgear-R7000-V1.0.7.12_1.2.5/ap/gpl/amule/wxWidgets-2.8.12/src/common/

Lines Matching defs:format

444 static wxString CallStrftime(const wxChar *format, const tm* tm)
451 if ( !wxStrftime(buf, WXSIZEOF(buf), format, tm) )
1032 // if strftime does not return anything because the format string is invalid - OR -
1550 // the dos date and time value is an unsigned 32 bit value in the format:
1600 wxCHECK_MSG( tm, ULONG_MAX, _T("time can't be represented in DOS format") );
2305 wxString wxDateTime::Format(const wxChar *format, const TimeZone& tz) const
2307 wxCHECK_MSG( format, wxEmptyString, _T("NULL format in wxDateTime::Format") );
2314 if ( (time != (time_t)-1) && !wxStrstr(format, _T("%l")) )
2351 return CallStrftime(format, tm);
2357 // we only parse ANSI C format specifications here, no POSIX 2
2358 // complications, no GNU extensions but we do add support for a "%l" format
2376 for ( const wxChar *p = format; *p; p++ )
2386 // set the default format
2403 // it's either another valid format specifier in which case
2404 // the format is "%02d" (for all the rest) or we have the
2405 // field width preceding the format in which case it will
2406 // override the default format anyhow
2415 // start of the format specification
2435 // the problem: there is no way to know what do these format
2441 // of the real year. Then make a copy of the format and
2444 // strftime() to format the date in year YEAR and then replace
2508 // find four strings not occurring in format (this is surely
2510 wxString fmt2 = format;
2533 // use strftime() to format the same date but in supported
2537 // date validity and will happily format the date
2578 // Use "%m/%d/%y %H:%M:%S" format instead
2588 case _T('H'): // hour in 24h format (00-23)
2592 case _T('I'): // hour in 12h format (01-12)
2644 // just use strftime() to format the time for us
2667 // is it the format width?
2688 wxFAIL_MSG(_T("unknown format specificator"));
2697 wxFAIL_MSG(_T("missing format at the end of string"));
2699 // just put the '%' which was the last char in format
2709 // this function parses a string in (strict) RFC 822 format: see the section 5
2841 // time is in the format hh:mm:ss and seconds are optional
3007 // returns the string containing strftime() format used for short dates in the
3028 // according to MSDN 80 chars is max allowed for short date format
3124 // ignore this format
3166 const wxChar *format,
3169 wxCHECK_MSG( date && format, (wxChar *)NULL,
3199 for ( const wxChar *fmt = format; *fmt; fmt++ )
3205 // a white space in the format string matches 0 or more white
3223 // done with this format char
3227 // start of a format specification
3261 // then the format itself
3296 // this is the format which corresponds to ctime() output
3348 case _T('H'): // hour in 24h format (00-23)
3359 case _T('I'): // hour in 12h format (01-12)
3596 // setting which says whether the default time format is
3666 wxFAIL_MSG(_T("unexpected format end"));
3670 default: // not a known format spec
3675 // format matched, try to construct a date from what we have now
3734 // translate to 24hour format
3737 //else: either already in 24h format or no translation needed
3981 // before the month in the japanese format?) (FIXME)
4234 // parse the standard format: normally it is one of the formats above
4285 // not all strftime(3) format specifiers make sense here because, for example,
4290 // %H hour in 24 hour format
4301 wxString wxTimeSpan::Format(const wxChar *format) const
4307 wxString str(Negate().Format(format));
4311 wxCHECK_MSG( format, wxEmptyString,
4312 _T("NULL format in wxTimeSpan::Format") );
4315 str.Alloc(wxStrlen(format));
4326 // interpretation of each format specifier depends on the presence of the
4327 // other format specs in the string: if there was "%H" before "%M", we
4333 for ( const wxChar *pch = format; *pch; pch++ )
4339 // the start of the format specification of the printf() below
4345 // the number of digits for the format string, 0 if unused
4348 ch = *++pch; // get the format spec char
4352 wxFAIL_MSG( _T("invalid format character") );