Some cleanupos

svn path=/trunk/; revision=5844
This commit is contained in:
Matthias Clasen 2007-11-09 03:59:00 +00:00
parent c8fe40d439
commit dd9cdb33aa

View File

@ -81,8 +81,8 @@ Similar to the <structname>struct timeval</structname> returned by
the <function>gettimeofday()</function> UNIX call. the <function>gettimeofday()</function> UNIX call.
</para> </para>
@tv_sec: seconds. @tv_sec: seconds
@tv_usec: microseconds. @tv_usec: microseconds
<!-- ##### FUNCTION g_get_current_time ##### --> <!-- ##### FUNCTION g_get_current_time ##### -->
<para> <para>
@ -100,7 +100,7 @@ depending on hardware and operating system; don't rely on the exact
length of the sleep. length of the sleep.
</para> </para>
@microseconds: number of microseconds to pause. @microseconds: number of microseconds to pause
<!-- ##### FUNCTION g_time_val_add ##### --> <!-- ##### FUNCTION g_time_val_add ##### -->
@ -203,19 +203,19 @@ Enumeration representing a month; values are #G_DATE_JANUARY,
#G_DATE_FEBRUARY, etc. #G_DATE_BAD_MONTH is the invalid value. #G_DATE_FEBRUARY, etc. #G_DATE_BAD_MONTH is the invalid value.
</para> </para>
@G_DATE_BAD_MONTH: invalid value. @G_DATE_BAD_MONTH: invalid value
@G_DATE_JANUARY: January. @G_DATE_JANUARY: January
@G_DATE_FEBRUARY: February. @G_DATE_FEBRUARY: February
@G_DATE_MARCH: March. @G_DATE_MARCH: March
@G_DATE_APRIL: April. @G_DATE_APRIL: April
@G_DATE_MAY: May. @G_DATE_MAY: May
@G_DATE_JUNE: June. @G_DATE_JUNE: June
@G_DATE_JULY: July. @G_DATE_JULY: July
@G_DATE_AUGUST: August. @G_DATE_AUGUST: August
@G_DATE_SEPTEMBER: September. @G_DATE_SEPTEMBER: September
@G_DATE_OCTOBER: October. @G_DATE_OCTOBER: October
@G_DATE_NOVEMBER: November. @G_DATE_NOVEMBER: November
@G_DATE_DECEMBER: December. @G_DATE_DECEMBER: December
<!-- ##### TYPEDEF GDateYear ##### --> <!-- ##### TYPEDEF GDateYear ##### -->
<para> <para>
@ -231,14 +231,14 @@ Enumeration representing a day of the week; #G_DATE_MONDAY,
#G_DATE_TUESDAY, etc. #G_DATE_BAD_WEEKDAY is an invalid weekday. #G_DATE_TUESDAY, etc. #G_DATE_BAD_WEEKDAY is an invalid weekday.
</para> </para>
@G_DATE_BAD_WEEKDAY: invalid value. @G_DATE_BAD_WEEKDAY: invalid value
@G_DATE_MONDAY: Monday. @G_DATE_MONDAY: Monday
@G_DATE_TUESDAY: Tuesday. @G_DATE_TUESDAY: Tuesday
@G_DATE_WEDNESDAY: Wednesday. @G_DATE_WEDNESDAY: Wednesday
@G_DATE_THURSDAY: Thursday. @G_DATE_THURSDAY: Thursday
@G_DATE_FRIDAY: Friday. @G_DATE_FRIDAY: Friday
@G_DATE_SATURDAY: Saturday. @G_DATE_SATURDAY: Saturday
@G_DATE_SUNDAY: Sunday. @G_DATE_SUNDAY: Sunday
<!-- ##### MACRO G_DATE_BAD_DAY ##### --> <!-- ##### MACRO G_DATE_BAD_DAY ##### -->
<para> <para>
@ -268,7 +268,7 @@ be cleared (as if you'd called g_date_clear()) but invalid (it won't
represent an existing day). Free the return value with g_date_free(). represent an existing day). Free the return value with g_date_free().
</para> </para>
@Returns: a newly-allocated #GDate. @Returns: a newly-allocated #GDate
<!-- ##### FUNCTION g_date_new_dmy ##### --> <!-- ##### FUNCTION g_date_new_dmy ##### -->
@ -278,10 +278,10 @@ day-month-year triplet you pass in represents an existing day, the
returned date will be valid. returned date will be valid.
</para> </para>
@day: day of the month. @day: day of the month
@month: month of the year. @month: month of the year
@year: year @year: year
@Returns: a newly-allocated #GDate initialized with @day, @month, and @year. @Returns: a newly-allocated #GDate initialized with @day, @month, and @year
<!-- ##### FUNCTION g_date_new_julian ##### --> <!-- ##### FUNCTION g_date_new_julian ##### -->
@ -291,8 +291,8 @@ Julian day number you pass in is valid (greater than 0, less than an
unreasonably large number), the returned date will be valid. unreasonably large number), the returned date will be valid.
</para> </para>
@julian_day: days since January 1, Year 1. @julian_day: days since January 1, Year 1
@Returns: a newly-allocated #GDate initialized with @julian_day. @Returns: a newly-allocated #GDate initialized with @julian_day
<!-- ##### FUNCTION g_date_clear ##### --> <!-- ##### FUNCTION g_date_clear ##### -->
@ -303,8 +303,8 @@ not contain garbage. Useful to init a date declared on the stack.
Validity can be tested with g_date_valid(). Validity can be tested with g_date_valid().
</para> </para>
@date: pointer to one or more dates to clear. @date: pointer to one or more dates to clear
@n_dates: number of dates to clear. @n_dates: number of dates to clear
<!-- ##### FUNCTION g_date_free ##### --> <!-- ##### FUNCTION g_date_free ##### -->
@ -312,7 +312,7 @@ Validity can be tested with g_date_valid().
Frees a #GDate returned from g_date_new(). Frees a #GDate returned from g_date_new().
</para> </para>
@date: a #GDate. @date: a #GDate
<!-- ##### FUNCTION g_date_set_day ##### --> <!-- ##### FUNCTION g_date_set_day ##### -->
@ -321,8 +321,8 @@ Sets the day of the month for a #GDate. If the resulting day-month-year
triplet is invalid, the date will be invalid. triplet is invalid, the date will be invalid.
</para> </para>
@date: a #GDate. @date: a #GDate
@day: day to set. @day: day to set
<!-- ##### FUNCTION g_date_set_month ##### --> <!-- ##### FUNCTION g_date_set_month ##### -->
@ -331,8 +331,8 @@ Sets the month of the year for a #GDate. If the resulting
day-month-year triplet is invalid, the date will be invalid. day-month-year triplet is invalid, the date will be invalid.
</para> </para>
@date: a #GDate. @date: a #GDate
@month: month to set. @month: month to set
<!-- ##### FUNCTION g_date_set_year ##### --> <!-- ##### FUNCTION g_date_set_year ##### -->
@ -341,8 +341,8 @@ Sets the year for a #GDate. If the resulting day-month-year triplet is
invalid, the date will be invalid. invalid, the date will be invalid.
</para> </para>
@date: a #GDate. @date: a #GDate
@year: year to set. @year: year to set
<!-- ##### FUNCTION g_date_set_dmy ##### --> <!-- ##### FUNCTION g_date_set_dmy ##### -->
@ -352,10 +352,10 @@ triplet must be valid; if you aren't sure it is, call g_date_valid_dmy() to
check before you set it. check before you set it.
</para> </para>
@date: a #GDate. @date: a #GDate
@day: day. @day: day
@month: month. @month: month
@y: year. @y: year
<!-- ##### FUNCTION g_date_set_julian ##### --> <!-- ##### FUNCTION g_date_set_julian ##### -->
@ -363,8 +363,8 @@ check before you set it.
Sets the value of a #GDate from a Julian day number. Sets the value of a #GDate from a Julian day number.
</para> </para>
@date: a #GDate. @date: a #GDate
@julian_date: Julian day number (days since January 1, Year 1). @julian_date: Julian day number (days since January 1, Year 1)
<!-- ##### FUNCTION g_date_set_time ##### --> <!-- ##### FUNCTION g_date_set_time ##### -->
@ -411,8 +411,8 @@ user means by a given string (and it does work pretty well in that
capacity). capacity).
</para> </para>
@date: a #GDate to fill in. @date: a #GDate to fill in
@str: string to parse. @str: string to parse
<!-- ##### FUNCTION g_date_add_days ##### --> <!-- ##### FUNCTION g_date_add_days ##### -->
@ -421,8 +421,8 @@ Increments a date some number of days. To move forward by weeks, add
weeks*7 days. The date must be valid. weeks*7 days. The date must be valid.
</para> </para>
@date: a #GDate to increment. @date: a #GDate to increment
@n_days: number of days to move the date forward. @n_days: number of days to move the date forward
<!-- ##### FUNCTION g_date_subtract_days ##### --> <!-- ##### FUNCTION g_date_subtract_days ##### -->
@ -431,8 +431,8 @@ Moves a date some number of days into the past. To move by weeks, just
move by weeks*7 days. The date must be valid. move by weeks*7 days. The date must be valid.
</para> </para>
@date: a #GDate to decrement. @date: a #GDate to decrement
@n_days: number of days to move. @n_days: number of days to move
<!-- ##### FUNCTION g_date_add_months ##### --> <!-- ##### FUNCTION g_date_add_months ##### -->
@ -443,8 +443,8 @@ the destination month may not have the current day in it). The date
must be valid. must be valid.
</para> </para>
@date: a #GDate to increment. @date: a #GDate to increment
@n_months: number of months to move forward. @n_months: number of months to move forward
<!-- ##### FUNCTION g_date_subtract_months ##### --> <!-- ##### FUNCTION g_date_subtract_months ##### -->
@ -454,8 +454,8 @@ the month doesn't exist in the destination month, the day of the month
may change. The date must be valid. may change. The date must be valid.
</para> </para>
@date: a #GDate to decrement. @date: a #GDate to decrement
@n_months: number of months to move. @n_months: number of months to move
<!-- ##### FUNCTION g_date_add_years ##### --> <!-- ##### FUNCTION g_date_add_years ##### -->
@ -465,8 +465,8 @@ and the destination year is not a leap year, the date will be changed
to February 28. The date must be valid. to February 28. The date must be valid.
</para> </para>
@date: a #GDate to increment. @date: a #GDate to increment
@n_years: number of years to move forward. @n_years: number of years to move forward
<!-- ##### FUNCTION g_date_subtract_years ##### --> <!-- ##### FUNCTION g_date_subtract_years ##### -->
@ -477,8 +477,8 @@ move to a non-leap-year) then the day is changed to February 29. The date
must be valid. must be valid.
</para> </para>
@date: a #GDate to decrement. @date: a #GDate to decrement
@n_years: number of years to move. @n_years: number of years to move
<!-- ##### FUNCTION g_date_days_between ##### --> <!-- ##### FUNCTION g_date_days_between ##### -->
@ -488,21 +488,21 @@ If @date2 is prior to @date1, the returned value is negative.
Both dates must be valid. Both dates must be valid.
</para> </para>
@date1: the first date. @date1: the first date
@date2: the second date. @date2: the second date
@Returns: the number of days between @date1 and @date2. @Returns: the number of days between @date1 and @date2
<!-- ##### FUNCTION g_date_compare ##### --> <!-- ##### FUNCTION g_date_compare ##### -->
<para> <para>
<function>qsort()</function>-style comparsion function for dates. Both qsort()-style comparsion function for dates. Both
dates must be valid. dates must be valid.
</para> </para>
@lhs: first date to compare. @lhs: first date to compare
@rhs: second date to compare. @rhs: second date to compare
@Returns: 0 for equal, less than zero if @lhs is less than @rhs, @Returns: 0 for equal, less than zero if @lhs is less than @rhs,
greater than zero if @lhs is greater than @rhs. greater than zero if @lhs is greater than @rhs
<!-- ##### FUNCTION g_date_clamp ##### --> <!-- ##### FUNCTION g_date_clamp ##### -->
@ -513,9 +513,9 @@ Either @min_date and @max_date may be %NULL. All non-%NULL dates
must be valid. must be valid.
</para> </para>
@date: a #GDate to clamp. @date: a #GDate to clamp
@min_date: minimum accepted value for @date. @min_date: minimum accepted value for @date
@max_date: maximum accepted value for @date. @max_date: maximum accepted value for @date
<!-- ##### FUNCTION g_date_order ##### --> <!-- ##### FUNCTION g_date_order ##### -->
@ -524,8 +524,8 @@ Checks if @date1 is less than or equal to @date2,
and swap the values if this is not the case. and swap the values if this is not the case.
</para> </para>
@date1: the first date. @date1: the first date
@date2: the second date. @date2: the second date
<!-- ##### FUNCTION g_date_get_day ##### --> <!-- ##### FUNCTION g_date_get_day ##### -->
@ -533,8 +533,8 @@ and swap the values if this is not the case.
Returns the day of the month. The date must be valid. Returns the day of the month. The date must be valid.
</para> </para>
@date: a #GDate to extract the day of the month from. @date: a #GDate to extract the day of the month from
@Returns: day of the month. @Returns: day of the month
<!-- ##### FUNCTION g_date_get_month ##### --> <!-- ##### FUNCTION g_date_get_month ##### -->
@ -542,8 +542,8 @@ Returns the day of the month. The date must be valid.
Returns the month of the year. The date must be valid. Returns the month of the year. The date must be valid.
</para> </para>
@date: a #GDate to get the month from. @date: a #GDate to get the month from
@Returns: month of the year as a #GDateMonth. @Returns: month of the year as a #GDateMonth
<!-- ##### FUNCTION g_date_get_year ##### --> <!-- ##### FUNCTION g_date_get_year ##### -->
@ -551,8 +551,8 @@ Returns the month of the year. The date must be valid.
Returns the year of a #GDate. The date must be valid. Returns the year of a #GDate. The date must be valid.
</para> </para>
@date: a #GDate. @date: a #GDate
@Returns: year in which the date falls. @Returns: year in which the date falls
<!-- ##### FUNCTION g_date_get_julian ##### --> <!-- ##### FUNCTION g_date_get_julian ##### -->
@ -563,8 +563,8 @@ January 1, Year 1 is Julian day 1; January 2, Year 1 is Julian day 2,
etc. The date must be valid. etc. The date must be valid.
</para> </para>
@date: a #GDate to extract the Julian day from. @date: a #GDate to extract the Julian day from
@Returns: Julian day. @Returns: Julian day
<!-- ##### FUNCTION g_date_get_weekday ##### --> <!-- ##### FUNCTION g_date_get_weekday ##### -->
@ -582,8 +582,8 @@ Returns the day of the year, where Jan 1 is the first day of the
year. The date must be valid. year. The date must be valid.
</para> </para>
@date: a #GDate to extract day of year from. @date: a #GDate to extract day of year from
@Returns: day of the year. @Returns: day of the year
<!-- ##### FUNCTION g_date_get_days_in_month ##### --> <!-- ##### FUNCTION g_date_get_days_in_month ##### -->
@ -591,9 +591,9 @@ year. The date must be valid.
Returns the number of days in a month, taking leap years into account. Returns the number of days in a month, taking leap years into account.
</para> </para>
@month: month. @month: month
@year: year. @year: year
@Returns: number of days in @month during the @year. @Returns: number of days in @month during the @year
<!-- ##### FUNCTION g_date_is_first_of_month ##### --> <!-- ##### FUNCTION g_date_is_first_of_month ##### -->
@ -601,8 +601,8 @@ Returns the number of days in a month, taking leap years into account.
Returns %TRUE if the date is on the first of a month. The date must be valid. Returns %TRUE if the date is on the first of a month. The date must be valid.
</para> </para>
@date: a #GDate to check. @date: a #GDate to check
@Returns: %TRUE if the date is the first of the month. @Returns: %TRUE if the date is the first of the month
<!-- ##### FUNCTION g_date_is_last_of_month ##### --> <!-- ##### FUNCTION g_date_is_last_of_month ##### -->
@ -610,8 +610,8 @@ Returns %TRUE if the date is on the first of a month. The date must be valid.
Returns %TRUE if the date is the last day of the month. The date must be valid. Returns %TRUE if the date is the last day of the month. The date must be valid.
</para> </para>
@date: a #GDate to check. @date: a #GDate to check
@Returns: %TRUE if the date is the last day of the month. @Returns: %TRUE if the date is the last day of the month
<!-- ##### FUNCTION g_date_is_leap_year ##### --> <!-- ##### FUNCTION g_date_is_leap_year ##### -->
@ -619,8 +619,8 @@ Returns %TRUE if the date is the last day of the month. The date must be valid.
Returns %TRUE if the year is a leap year. Returns %TRUE if the year is a leap year.
</para> </para>
@year: year to check. @year: year to check
@Returns: %TRUE if the year is a leap year. @Returns: %TRUE if the year is a leap year
<!-- ##### FUNCTION g_date_get_monday_week_of_year ##### --> <!-- ##### FUNCTION g_date_get_monday_week_of_year ##### -->
@ -630,8 +630,8 @@ Monday. If the date is before the first Monday of the year, return
0. The date must be valid. 0. The date must be valid.
</para> </para>
@date: a #GDate. @date: a #GDate
@Returns: week of the year. @Returns: week of the year
<!-- ##### FUNCTION g_date_get_monday_weeks_in_year ##### --> <!-- ##### FUNCTION g_date_get_monday_weeks_in_year ##### -->
@ -644,8 +644,8 @@ the year, i.e. there are 53 Mondays if one of the extra days happens
to be a Monday.) to be a Monday.)
</para> </para>
@year: a year. @year: a year
@Returns: number of Mondays in the year. @Returns: number of Mondays in the year
<!-- ##### FUNCTION g_date_get_sunday_week_of_year ##### --> <!-- ##### FUNCTION g_date_get_sunday_week_of_year ##### -->
@ -655,8 +655,8 @@ are understood to being on Sunday. The date must be valid. Can return 0 if
the day is before the first Sunday of the year. the day is before the first Sunday of the year.
</para> </para>
@date: a #GDate. @date: a #GDate
@Returns: week number. @Returns: week number
<!-- ##### FUNCTION g_date_get_sunday_weeks_in_year ##### --> <!-- ##### FUNCTION g_date_get_sunday_weeks_in_year ##### -->
@ -669,8 +669,8 @@ the year, i.e. there are 53 Sundays if one of the extra days happens
to be a Sunday.) to be a Sunday.)
</para> </para>
@year: year to count weeks in. @year: year to count weeks in
@Returns: number of weeks. @Returns: number of weeks
<!-- ##### FUNCTION g_date_get_iso8601_week_of_year ##### --> <!-- ##### FUNCTION g_date_get_iso8601_week_of_year ##### -->
@ -699,11 +699,11 @@ expect that using g_date_strftime() would make the %F provided by the C99
strftime() work on Windows where the C library only complies to C89. strftime() work on Windows where the C library only complies to C89.
</para> </para>
@s: destination buffer. @s: destination buffer
@slen: buffer size. @slen: buffer size
@format: format string. @format: format string
@date: valid #GDate. @date: valid #GDate
@Returns: number of characters written to the buffer, or 0 the buffer was too small. @Returns: number of characters written to the buffer, or 0 the buffer was too small
<!-- ##### FUNCTION g_date_to_struct_tm ##### --> <!-- ##### FUNCTION g_date_to_struct_tm ##### -->
@ -724,8 +724,8 @@ contain garbage; it should have been initialized with g_date_clear()
if it wasn't allocated by one of the g_date_new() variants. if it wasn't allocated by one of the g_date_new() variants.
</para> </para>
@date: a #GDate to check. @date: a #GDate to check
@Returns: Whether the date is valid. @Returns: Whether the date is valid
<!-- ##### FUNCTION g_date_valid_day ##### --> <!-- ##### FUNCTION g_date_valid_day ##### -->
@ -734,8 +734,8 @@ Returns %TRUE if the day of the month is valid (a day is valid if it's
between 1 and 31 inclusive). between 1 and 31 inclusive).
</para> </para>
@day: day to check. @day: day to check
@Returns: %TRUE if the day is valid. @Returns: %TRUE if the day is valid
<!-- ##### FUNCTION g_date_valid_month ##### --> <!-- ##### FUNCTION g_date_valid_month ##### -->
@ -744,8 +744,8 @@ Returns %TRUE if the month value is valid. The 12 #GDateMonth
enumeration values are the only valid months. enumeration values are the only valid months.
</para> </para>
@month: month. @month: month
@Returns: %TRUE if the month is valid. @Returns: %TRUE if the month is valid
<!-- ##### FUNCTION g_date_valid_year ##### --> <!-- ##### FUNCTION g_date_valid_year ##### -->
@ -754,8 +754,8 @@ Returns %TRUE if the year is valid. Any year greater than 0 is valid,
though there is a 16-bit limit to what #GDate will understand. though there is a 16-bit limit to what #GDate will understand.
</para> </para>
@year: year. @year: year
@Returns: %TRUE if the year is valid. @Returns: %TRUE if the year is valid
<!-- ##### FUNCTION g_date_valid_dmy ##### --> <!-- ##### FUNCTION g_date_valid_dmy ##### -->
@ -765,29 +765,29 @@ in the range of days #GDate understands (Year 1 or later, no more than
a few thousand years in the future). a few thousand years in the future).
</para> </para>
@day: day. @day: day
@month: month. @month: month
@year: year. @year: year
@Returns: %TRUE if the date is a valid one. @Returns: %TRUE if the date is a valid one
<!-- ##### FUNCTION g_date_valid_julian ##### --> <!-- ##### FUNCTION g_date_valid_julian ##### -->
<para> <para>
Returns %TRUE if the Julian day is valid. Anything greater than zero is basically a Returns %TRUE if the Julian day is valid. Anything greater than zero
valid Julian, though there is a 32-bit limit. is basically a valid Julian, though there is a 32-bit limit.
</para> </para>
@julian_date: Julian day to check. @julian_date: Julian day to check
@Returns: %TRUE if the Julian day is valid. @Returns: %TRUE if the Julian day is valid
<!-- ##### FUNCTION g_date_valid_weekday ##### --> <!-- ##### FUNCTION g_date_valid_weekday ##### -->
<para> <para>
Returns %TRUE if the weekday is valid. The 7 #GDateWeekday enumeration Returns %TRUE if the weekday is valid. The seven #GDateWeekday enumeration
values are the only valid weekdays. values are the only valid weekdays.
</para> </para>
@weekday: weekday. @weekday: weekday
@Returns: %TRUE if the weekday is valid. @Returns: %TRUE if the weekday is valid