Some PythonNotes

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_2_2_BRANCH@7478 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Robin Dunn
2000-05-24 17:30:38 +00:00
parent 37bb827fa9
commit 9be0381b20
4 changed files with 103 additions and 56 deletions

View File

@@ -88,15 +88,15 @@ Time zone symbolic names:
\end{verbatim} \end{verbatim}
Month names: Jan, Feb, Mar, Apr, May, Jun, Jul, Aug, Sep, Oct, Nov, Dec and Month names: Jan, Feb, Mar, Apr, May, Jun, Jul, Aug, Sep, Oct, Nov, Dec and
Inv\_Month for an invalid.month value are the values of {\tt wxDateTime::Month} Inv\_Month for an invalid.month value are the values of {\tt wxDateTime::Month}
enum. enum.
Likely, Sun, Mon, Tue, Wed, Thu, Fri, Sat, and Inv\_WeekDay are the values in Likewise, Sun, Mon, Tue, Wed, Thu, Fri, Sat, and Inv\_WeekDay are the values in
{\tt wxDateTime::WeekDay} enum. {\tt wxDateTime::WeekDay} enum.
Finally, Inv\_Year is defined to be an invalid value for year parameter. Finally, Inv\_Year is defined to be an invalid value for year parameter.
\helpref{GetMonthName()}{wxdatetimegetmonthname} and \helpref{GetMonthName()}{wxdatetimegetmonthname} and
\helpref{GetWeekDayName}{wxdatetimegetweekdayname} functions use the followign \helpref{GetWeekDayName}{wxdatetimegetweekdayname} functions use the followign
flags: flags:
@@ -121,7 +121,7 @@ parameters is one of the following values:
\end{verbatim} \end{verbatim}
Date calculatiosn often depend on the country adn wxDateTime allows to set the Date calculatiosn often depend on the country adn wxDateTime allows to set the
country which conventions should be used using country which conventions should be used using
\helpref{SetCountry}{wxdatetimesetcountry}. It takes one of the following \helpref{SetCountry}{wxdatetimesetcountry}. It takes one of the following
values as parameter: values as parameter:
@@ -149,7 +149,7 @@ Differnet parst of the world use different conventions for the week start.
In some countries, the week starts on Sunday, while in others - on Monday. In some countries, the week starts on Sunday, while in others - on Monday.
The ISO standard doesn't address this issue, so we support both conventions in The ISO standard doesn't address this issue, so we support both conventions in
the functions whose result depends on it ( the functions whose result depends on it (
\helpref{GetWeekOfYear}{wxdatetimegetweekofyear} and \helpref{GetWeekOfYear}{wxdatetimegetweekofyear} and
\helpref{GetWeekOfMonth}{wxdatetimegetweekofmonth}). \helpref{GetWeekOfMonth}{wxdatetimegetweekofmonth}).
The desired behvaiour may be specified by giving one of the following The desired behvaiour may be specified by giving one of the following
@@ -188,10 +188,13 @@ either set or return the static variables of wxDateSpan (the country), return
the current moment, year, month or number of days in it, or do some general the current moment, year, month or number of days in it, or do some general
calendar-related actions. calendar-related actions.
Please note that although several function accept an extra {\it Calendar} Please note that although several function accept an extra {\it Calendar}
parameter, it is currently ignored as only the Gregorian calendar is parameter, it is currently ignored as only the Gregorian calendar is
supported. Future versions will support other calendars. supported. Future versions will support other calendars.
\pythonnote{These methods are standalone functions named
{\tt wxDateTime_<StaticMethodName>} in wxPython.}
\helpref{SetCountry}{wxdatetimesetcountry}\\ \helpref{SetCountry}{wxdatetimesetcountry}\\
\helpref{GetCountry}{wxdatetimegetcountry}\\ \helpref{GetCountry}{wxdatetimegetcountry}\\
\helpref{IsWestEuropeanCountry}{wxdatetimeiswesteuropeancountry}\\ \helpref{IsWestEuropeanCountry}{wxdatetimeiswesteuropeancountry}\\
@@ -247,7 +250,7 @@ values were correct as constructors can not return an error code.
\membersection{Accessors} \membersection{Accessors}
Here are the trivial accessors. Other functions, which might have to perform Here are the trivial accessors. Other functions, which might have to perform
some more complicated calculations to find the answer are under some more complicated calculations to find the answer are under
\helpref{Calendar calculations}{wxdatetimecalculations} section. \helpref{Calendar calculations}{wxdatetimecalculations} section.
\helpref{IsValid}{wxdatetimeisvalid}\\ \helpref{IsValid}{wxdatetimeisvalid}\\
@@ -309,25 +312,25 @@ defined to be equivalent to the second forms of these functions.
These functions perform convert wxDateTime obejcts to and from text. The These functions perform convert wxDateTime obejcts to and from text. The
conversions to text are mostly trivial: you can either do it using the default conversions to text are mostly trivial: you can either do it using the default
date and time representations for the current locale ( date and time representations for the current locale (
\helpref{FormatDate}{wxdatetimeformatdate} and \helpref{FormatDate}{wxdatetimeformatdate} and
\helpref{FormatTime}{wxdatetimeformattime}), using the international standard \helpref{FormatTime}{wxdatetimeformattime}), using the international standard
representation defined by ISO 8601 ( representation defined by ISO 8601 (
\helpref{FormatISODate}{wxdatetimeformatisodate} and \helpref{FormatISODate}{wxdatetimeformatisodate} and
\helpref{FormatISOTime}{wxdatetimeformatisotime}) or by specifying any format \helpref{FormatISOTime}{wxdatetimeformatisotime}) or by specifying any format
at all and using \helpref{Format}{wxdatetimeformat} directly. at all and using \helpref{Format}{wxdatetimeformat} directly.
The conversions from text are more interesting, as there are much more The conversions from text are more interesting, as there are much more
possibilities to care about. The simples cases can be taken care of with possibilities to care about. The simples cases can be taken care of with
\helpref{ParseFormat}{wxdatetimeparseformat} which can parse any date in the \helpref{ParseFormat}{wxdatetimeparseformat} which can parse any date in the
given (rigid) format. \helpref{ParseRfc822Date}{wxdatetimeparserfc822date} is given (rigid) format. \helpref{ParseRfc822Date}{wxdatetimeparserfc822date} is
another function for parsing dates in predefined format - the one of RFC 822 another function for parsing dates in predefined format - the one of RFC 822
which (still...) defines the format of email messages on the Internet. This which (still...) defines the format of email messages on the Internet. This
format can not be described with {\tt strptime(3)}-like format strings used by format can not be described with {\tt strptime(3)}-like format strings used by
\helpref{Format}{wxdatetimeformat}, hence the need for a separate function. \helpref{Format}{wxdatetimeformat}, hence the need for a separate function.
But the most interesting functions are But the most interesting functions are
\helpref{ParseDateTime}{wxdatetimeparsedatetime} and \helpref{ParseDateTime}{wxdatetimeparsedatetime} and
\helpref{ParseDate}{wxdatetimeparsedate} and \helpref{ParseDate}{wxdatetimeparsedate} and
\helpref{ParseTime}{wxdatetimeparsetime}. They try to parse the date ans time \helpref{ParseTime}{wxdatetimeparsetime}. They try to parse the date ans time
(or only one of them) in `free' format, i.e. allow them to be specified in any (or only one of them) in `free' format, i.e. allow them to be specified in any
of possible ways. These functions will usually be used to parse the of possible ways. These functions will usually be used to parse the
@@ -375,13 +378,13 @@ wxDateTime - they only work with the date part of it.
\membersection{Astronomical/historical functions} \membersection{Astronomical/historical functions}
Some degree of support for the date units used in astronomy and/or history is Some degree of support for the date units used in astronomy and/or history is
provided. You can construct a wxDateTime object from a provided. You can construct a wxDateTime object from a
\helpref{JDN}{wxdatetimesetjdn} and you may also get its JDN, \helpref{JDN}{wxdatetimesetjdn} and you may also get its JDN,
\helpref{MJD}{wxdatetimegetmodifiedjuliandaynumber} or \helpref{MJD}{wxdatetimegetmodifiedjuliandaynumber} or
\helpref{Rata Die number}{wxdatetimegetratadie} from it. \helpref{Rata Die number}{wxdatetimegetratadie} from it.
\helpref{wxDateTime(double jdn)}{wxdatetimewxdatetimejdn}\\ \helpref{wxDateTime(double jdn)}{wxdatetimewxdatetimejdn}\\
\helpref{Set(double jdn)}{wxdatetimesetjdn} \helpref{Set(double jdn)}{wxdatetimesetjdn}\\
\helpref{GetJulianDayNumber}{wxdatetimegetjuliandaynumber}\\ \helpref{GetJulianDayNumber}{wxdatetimegetjuliandaynumber}\\
\helpref{GetJDN}{wxdatetimegetjdn}\\ \helpref{GetJDN}{wxdatetimegetjdn}\\
\helpref{GetModifiedJulianDayNumber}{wxdatetimegetmodifiedjuliandaynumber}\\ \helpref{GetModifiedJulianDayNumber}{wxdatetimegetmodifiedjuliandaynumber}\\
@@ -439,7 +442,7 @@ the corresponding value is not needed.
\func{static wxDateTime}{GetBeginDST}{\param{int }{year = Inv\_Year}, \param{Country }{country = Country\_Default}} \func{static wxDateTime}{GetBeginDST}{\param{int }{year = Inv\_Year}, \param{Country }{country = Country\_Default}}
Get the beginning of DST for the given country in the given year (current one Get the beginning of DST for the given country in the given year (current one
by default). This function suffers from limitations described in by default). This function suffers from limitations described in
\helpref{DST overview}{tdatedst}. \helpref{DST overview}{tdatedst}.
\wxheading{See also} \wxheading{See also}
@@ -509,6 +512,9 @@ year.
The only supported value for {\it cal} parameter is currently {\tt Gregorian}. The only supported value for {\it cal} parameter is currently {\tt Gregorian}.
\pythonnote{These two methods are named {\tt GetNumberOfDaysInYear}
and {\tt GetNumberOfDaysInMonth} in wxPython.}
\membersection{wxDateTime::GetWeekDayName}\label{wxdatetimegetweekdayname} \membersection{wxDateTime::GetWeekDayName}\label{wxdatetimegetweekdayname}
\func{static wxString}{GetWeekDayName}{\param{WeekDay }{weekday}, \param{NameFlags }{flags = Name\_Full}} \func{static wxString}{GetWeekDayName}{\param{WeekDay }{weekday}, \param{NameFlags }{flags = Name\_Full}}
@@ -567,7 +573,7 @@ Example:
Sets the country to use by default. This setting influences the DST Sets the country to use by default. This setting influences the DST
calculations, date formatting and other things. calculations, date formatting and other things.
The possible values for {\it country} parameter are enumerated in The possible values for {\it country} parameter are enumerated in
\helpref{wxDateTime constants section}{wxdatetime}. \helpref{wxDateTime constants section}{wxdatetime}.
\wxheading{See also} \wxheading{See also}
@@ -600,30 +606,40 @@ later.
Same as \helpref{Set}{wxdatetimewxdatetimetimet}. Same as \helpref{Set}{wxdatetimewxdatetimetimet}.
\pythonnote{This constructor is named {\tt wxDateTimeFromTimeT} in wxPython.}
\membersection{wxDateTime::wxDateTime}\label{wxdatetimewxdatetimetm} \membersection{wxDateTime::wxDateTime}\label{wxdatetimewxdatetimetm}
\func{wxDateTime\&}{wxDateTime}{\param{const struct tm\& }{tm}} \func{wxDateTime\&}{wxDateTime}{\param{const struct tm\& }{tm}}
Same as \helpref{Set}{wxdatetimewxdatetimetm} Same as \helpref{Set}{wxdatetimewxdatetimetm}
\pythonnote{Unsupported.}
\membersection{wxDateTime::wxDateTime}\label{wxdatetimewxdatetimejdn} \membersection{wxDateTime::wxDateTime}\label{wxdatetimewxdatetimejdn}
\func{wxDateTime\&}{wxDateTime}{\param{double }{jdn}} \func{wxDateTime\&}{wxDateTime}{\param{double }{jdn}}
Same as \helpref{Set}{wxdatetimewxdatetimejdn} Same as \helpref{Set}{wxdatetimewxdatetimejdn}
\pythonnote{This constructor is named {\tt wxDateTimeFromJDN} in wxPython.}
\membersection{wxDateTime::wxDateTime}\label{wxdatetimewxdatetimetime} \membersection{wxDateTime::wxDateTime}\label{wxdatetimewxdatetimetime}
\func{wxDateTime\&}{wxDateTime}{\param{wxDateTime\_t }{hour}, \param{wxDateTime\_t }{minute = 0}, \param{wxDateTime\_t }{second = 0}, \param{wxDateTime\_t }{millisec = 0}} \func{wxDateTime\&}{wxDateTime}{\param{wxDateTime\_t }{hour}, \param{wxDateTime\_t }{minute = 0}, \param{wxDateTime\_t }{second = 0}, \param{wxDateTime\_t }{millisec = 0}}
Same as \helpref{Set}{wxdatetimewxdatetimetime} Same as \helpref{Set}{wxdatetimewxdatetimetime}
\pythonnote{This constructor is named {\tt wxDateTimeFromHMS} in wxPython.}
\membersection{wxDateTime::wxDateTime}\label{wxdatetimewxdatetimedate} \membersection{wxDateTime::wxDateTime}\label{wxdatetimewxdatetimedate}
\func{wxDateTime\&}{wxDateTime}{\param{wxDateTime\_t }{day}, \param{Month }{month = Inv\_Month}, \param{wxDateTime\_t }{hour = 0}, \param{wxDateTime\_t }{minute = 0}, \param{wxDateTime\_t }{second = 0}, \param{wxDateTime\_t }{millisec = 0}} \func{wxDateTime\&}{wxDateTime}{\param{wxDateTime\_t }{day}, \param{Month }{month = Inv\_Month}, \param{wxDateTime\_t }{hour = 0}, \param{wxDateTime\_t }{minute = 0}, \param{wxDateTime\_t }{second = 0}, \param{wxDateTime\_t }{millisec = 0}}
Same as \helpref{Set}{wxdatetimesetdate} Same as \helpref{Set}{wxdatetimesetdate}
\pythonnote{This constructor is named {\tt wxDateTimeFromDMY} in wxPython.}
\membersection{wxDateTime::SetToCurrent}\label{wxdatetimesettocurrent} \membersection{wxDateTime::SetToCurrent}\label{wxdatetimesettocurrent}
\func{wxDateTime&}{SetToCurrent}{\void} \func{wxDateTime&}{SetToCurrent}{\void}
@@ -638,13 +654,17 @@ of \helpref{Now()}{wxdatetimenow} to this object.
Constructs the object from {\it timet} value holding the number of seconds Constructs the object from {\it timet} value holding the number of seconds
since Jan 1, 1970. since Jan 1, 1970.
\pythonnote{This method is named {\tt SetTimeT} in wxPython.}
\membersection{wxDateTime::Set}\label{wxdatetimesettm} \membersection{wxDateTime::Set}\label{wxdatetimesettm}
\func{wxDateTime\&}{Set}{\param{const struct tm\& }{tm}} \func{wxDateTime\&}{Set}{\param{const struct tm\& }{tm}}
Sets the date and tiem from the broken down representation in the standard Sets the date and tiem from the broken down representation in the standard
{\tt tm} structure. {\tt tm} structure.
\pythonnote{Unsupported.}
\membersection{wxDateTime::Set}\label{wxdatetimesetjdn} \membersection{wxDateTime::Set}\label{wxdatetimesetjdn}
\func{wxDateTime\&}{Set}{\param{double }{jdn}} \func{wxDateTime\&}{Set}{\param{double }{jdn}}
@@ -656,6 +676,8 @@ particular instant is the fractional number of days since 12 hours Universal
Coordinated Time (Greenwhich mean noon) on January 1 of the year -4712 in the Coordinated Time (Greenwhich mean noon) on January 1 of the year -4712 in the
Julian proleptic calendar. Julian proleptic calendar.
\pythonnote{This method is named {\tt SetJDN} in wxPython.}
\membersection{wxDateTime::Set}\label{wxdatetimesettime} \membersection{wxDateTime::Set}\label{wxdatetimesettime}
\func{wxDateTime\&}{Set}{\param{wxDateTime\_t }{hour}, \param{wxDateTime\_t }{minute = 0}, \param{wxDateTime\_t }{second = 0}, \param{wxDateTime\_t }{millisec = 0}} \func{wxDateTime\&}{Set}{\param{wxDateTime\_t }{hour}, \param{wxDateTime\_t }{minute = 0}, \param{wxDateTime\_t }{second = 0}, \param{wxDateTime\_t }{millisec = 0}}
@@ -663,6 +685,8 @@ Julian proleptic calendar.
Sets the date to be equal to \helpref{Today}{wxdatetimetoday} and the time Sets the date to be equal to \helpref{Today}{wxdatetimetoday} and the time
from supplied parameters. from supplied parameters.
\pythonnote{This method is named {\tt SetHMS} in wxPython.}
\membersection{wxDateTime::Set}\label{wxdatetimesetdate} \membersection{wxDateTime::Set}\label{wxdatetimesetdate}
\func{wxDateTime\&}{Set}{\param{wxDateTime\_t }{day}, \param{Month }{month = Inv\_Month}, \param{wxDateTime\_t }{hour = 0}, \param{wxDateTime\_t }{minute = 0}, \param{wxDateTime\_t }{second = 0}, \param{wxDateTime\_t }{millisec = 0}} \func{wxDateTime\&}{Set}{\param{wxDateTime\_t }{day}, \param{Month }{month = Inv\_Month}, \param{wxDateTime\_t }{hour = 0}, \param{wxDateTime\_t }{minute = 0}, \param{wxDateTime\_t }{second = 0}, \param{wxDateTime\_t }{millisec = 0}}
@@ -823,7 +847,7 @@ specified by the {\it flags} argument.
Returns the ordinal number of the week in the month (in $1\ldots5$ range). Returns the ordinal number of the week in the month (in $1\ldots5$ range).
As \helpref{GetWeekOfYear}{wxdatetimegetweekofyear}, this function supports As \helpref{GetWeekOfYear}{wxdatetimegetweekofyear}, this function supports
both conventions for the week start. See the description of these both conventions for the week start. See the description of these
\helpref{week start}{wxdatetime} conventions. \helpref{week start}{wxdatetime} conventions.
\membersection{wxDateTime::IsWorkDay}\label{wxdatetimeisworkday} \membersection{wxDateTime::IsWorkDay}\label{wxdatetimeisworkday}
@@ -874,7 +898,7 @@ Returns {\tt TRUE} if this date lies strictly between the two others,
\constfunc{bool}{IsBetween}{\param{const wxDateTime& }{t1}, \param{const wxDateTime& }{t2}} \constfunc{bool}{IsBetween}{\param{const wxDateTime& }{t1}, \param{const wxDateTime& }{t2}}
Returns {\tt TRUE} if \helpref{IsStrictlyBetween}{wxdatetimeisstrictlybetween} Returns {\tt TRUE} if \helpref{IsStrictlyBetween}{wxdatetimeisstrictlybetween}
is {\tt TRUE} or if the date is equal to one of the limi values. is {\tt TRUE} or if the date is equal to one of the limi values.
\wxheading{See also} \wxheading{See also}
@@ -913,6 +937,8 @@ this interval.
Adds the given time span to this object. Adds the given time span to this object.
\pythonnote{This method is named {\tt AddTS} in wxPython.}
\membersection{wxDateTime::Subtract}\label{wxdatetimesubtractts} \membersection{wxDateTime::Subtract}\label{wxdatetimesubtractts}
\constfunc{wxDateTime}{Subtract}{\param{const wxTimeSpan\& }{diff}} \constfunc{wxDateTime}{Subtract}{\param{const wxTimeSpan\& }{diff}}
@@ -923,6 +949,8 @@ Adds the given time span to this object.
Subtracts the given time span from this object. Subtracts the given time span from this object.
\pythonnote{This method is named {\tt SubtractTS} in wxPython.}
\membersection{wxDateTime::Add}\label{wxdatetimeaddds} \membersection{wxDateTime::Add}\label{wxdatetimeaddds}
\constfunc{wxDateTime}{Add}{\param{const wxDateSpan\& }{diff}} \constfunc{wxDateTime}{Add}{\param{const wxDateSpan\& }{diff}}
@@ -933,6 +961,8 @@ Subtracts the given time span from this object.
Adds the given date span to this object. Adds the given date span to this object.
\pythonnote{This method is named {\tt AddDS} in wxPython.}
\membersection{wxDateTime::Subtract}\label{wxdatetimesubtractds} \membersection{wxDateTime::Subtract}\label{wxdatetimesubtractds}
\constfunc{wxDateTime}{Subtract}{\param{const wxDateSpan\& }{diff}} \constfunc{wxDateTime}{Subtract}{\param{const wxDateSpan\& }{diff}}
@@ -943,6 +973,8 @@ Adds the given date span to this object.
Subtracts the given date span from this object. Subtracts the given date span from this object.
\pythonnote{This method is named {\tt SubtractDS} in wxPython.}
\membersection{wxDateTime::Subtract}\label{wxdatetimesubtractdt} \membersection{wxDateTime::Subtract}\label{wxdatetimesubtractdt}
\constfunc{wxTimeSpan}{Subtract}{\param{const wxDateTime\& }{dt}} \constfunc{wxTimeSpan}{Subtract}{\param{const wxDateTime\& }{dt}}
@@ -969,17 +1001,17 @@ the returned pointer will be pointing to a {\tt NUL} character.
This function is intenionally strict, it will return an error for any string This function is intenionally strict, it will return an error for any string
which is not RFC 822 compliant. If you need to parse date formatted in more which is not RFC 822 compliant. If you need to parse date formatted in more
free ways, you should use \helpref{ParseDateTime}{wxdatetimeparsedatetime} or free ways, you should use \helpref{ParseDateTime}{wxdatetimeparsedatetime} or
\helpref{ParseDate}{wxdatetimeparsedate} instead. \helpref{ParseDate}{wxdatetimeparsedate} instead.
\membersection{wxDateTime::ParseFormat}\label{wxdatetimeparseformat} \membersection{wxDateTime::ParseFormat}\label{wxdatetimeparseformat}
\func{const wxChar *}{ParseFormat}{\param{const wxChar *}{date}, \param{const wxChar *}{format = "\%c"}, \param{const wxDateTime\& }{dateDef = wxDefaultDateTime}} \func{const wxChar *}{ParseFormat}{\param{const wxChar *}{date}, \param{const wxChar *}{format = "\%c"}, \param{const wxDateTime\& }{dateDef = wxDefaultDateTime}}
This function parses the string {\it date} according to the given This function parses the string {\it date} according to the given
{\it format}. The system {\tt strptime(3)} function is used whenever available, {\it format}. The system {\tt strptime(3)} function is used whenever available,
but even if it is not, this function is still implemented (although support but even if it is not, this function is still implemented (although support
for locale-dependent format specificators such as {\tt "\%c"}, {\tt "\%x"} or for locale-dependent format specificators such as {\tt "\%c"}, {\tt "\%x"} or
{\tt "\%X"} may be not perfect). This function does handle the month and {\tt "\%X"} may be not perfect). This function does handle the month and
weekday names in the current locale on all platforms, however. weekday names in the current locale on all platforms, however.
@@ -987,7 +1019,7 @@ Please the description of ANSI C function {\tt strftime(3)} for the syntax of
the format string. the format string.
The {\it dateDef} parameter is used to fill in the fields which could not be The {\it dateDef} parameter is used to fill in the fields which could not be
determined from the format string. For example, if the format is {\tt "\%d"} determined from the format string. For example, if the format is {\tt "\%d"}
(the day of the month), the month and the year are taken from {\it dateDef}. (the day of the month), the month and the year are taken from {\it dateDef}.
If it is not specified, \helpref{Today}{wxdatetimetoday} is used as the If it is not specified, \helpref{Today}{wxdatetimetoday} is used as the
default date. default date.
@@ -1013,7 +1045,7 @@ the character which stopped the scan.
\func{const wxChar *}{ParseDate}{\param{const wxChar *}{date}} \func{const wxChar *}{ParseDate}{\param{const wxChar *}{date}}
This function is like \helpref{ParseDateTime}{wxdatetimeparsedatetime}, but it This function is like \helpref{ParseDateTime}{wxdatetimeparsedatetime}, but it
only allows the date to be specified. It is thus flexible then only allows the date to be specified. It is thus flexible then
\helpref{ParseDateTime}{wxdatetimeparsedatetime}, but also has less chances to \helpref{ParseDateTime}{wxdatetimeparsedatetime}, but also has less chances to
misinterpret the user input. misinterpret the user input.
@@ -1045,14 +1077,14 @@ Please see its description for the meaning of {\it format} parameter.
\constfunc{wxString }{FormatDate}{\void} \constfunc{wxString }{FormatDate}{\void}
Identical to calling \helpref{Format()}{wxdatetimeformat} with {\tt "\%x"} Identical to calling \helpref{Format()}{wxdatetimeformat} with {\tt "\%x"}
argument (which means `preferred date representation for the current locale'). argument (which means `preferred date representation for the current locale').
\membersection{wxDateTime::FormatTime}\label{wxdatetimeformattime} \membersection{wxDateTime::FormatTime}\label{wxdatetimeformattime}
\constfunc{wxString }{FormatTime}{\void} \constfunc{wxString }{FormatTime}{\void}
Identical to calling \helpref{Format()}{wxdatetimeformat} with {\tt "\%X"} Identical to calling \helpref{Format()}{wxdatetimeformat} with {\tt "\%X"}
argument (which means `preferred time representation for the current locale'). argument (which means `preferred time representation for the current locale').
\membersection{wxDateTime::FormatISODate}\label{wxdatetimeformatisodate} \membersection{wxDateTime::FormatISODate}\label{wxdatetimeformatisodate}
@@ -1084,7 +1116,7 @@ Returns the reference to the modified object itself.
\constfunc{wxDateTime}{GetWeekDayInSameWeek}{\param{WeekDay }{weekday}} \constfunc{wxDateTime}{GetWeekDayInSameWeek}{\param{WeekDay }{weekday}}
Returns the copy of this object to which Returns the copy of this object to which
\helpref{SetToWeekDayInSameWeek}{wxdatetimesettoweekdayinsameweek} was \helpref{SetToWeekDayInSameWeek}{wxdatetimesettoweekdayinsameweek} was
applied. applied.
@@ -1101,7 +1133,7 @@ Returns the reference to the modified object itself.
\constfunc{wxDateTime}{GetNextWeekDay}{\param{WeekDay }{weekday}} \constfunc{wxDateTime}{GetNextWeekDay}{\param{WeekDay }{weekday}}
Returns the copy of this object to which Returns the copy of this object to which
\helpref{SetToNextWeekDay}{wxdatetimesettonextweekday} was applied. \helpref{SetToNextWeekDay}{wxdatetimesettonextweekday} was applied.
\membersection{wxDateTime::SetToPrevWeekDay}\label{wxdatetimesettoprevweekday} \membersection{wxDateTime::SetToPrevWeekDay}\label{wxdatetimesettoprevweekday}
@@ -1117,7 +1149,7 @@ Returns the reference to the modified object itself.
\constfunc{wxDateTime}{GetPrevWeekDay}{\param{WeekDay }{weekday}} \constfunc{wxDateTime}{GetPrevWeekDay}{\param{WeekDay }{weekday}}
Returns the copy of this object to which Returns the copy of this object to which
\helpref{SetToPrevWeekDay}{wxdatetimesettoprevweekday} was applied. \helpref{SetToPrevWeekDay}{wxdatetimesettoprevweekday} was applied.
\membersection{wxDateTime::SetToWeekDay}\label{wxdatetimesettoweekday} \membersection{wxDateTime::SetToWeekDay}\label{wxdatetimesettoweekday}
@@ -1130,7 +1162,7 @@ may be either opsitive (counting from the beginning of the month) or negative
(counting from the end of it). (counting from the end of it).
For example, {\tt SetToWeekDay(2, wxDateTime::Wed)} will set the date to the For example, {\tt SetToWeekDay(2, wxDateTime::Wed)} will set the date to the
second Wednesday in the current month and second Wednesday in the current month and
{\tt SetToWeekDay(-1, wxDateTime::Sun)} - to the last Sunday in it. {\tt SetToWeekDay(-1, wxDateTime::Sun)} - to the last Sunday in it.
Returns {\tt TRUE} if the date was modified successfully, {\tt FALSE} Returns {\tt TRUE} if the date was modified successfully, {\tt FALSE}
@@ -1140,15 +1172,15 @@ otherwise meaning that the specified date doesn't exist.
\constfunc{wxDateTime}{GetWeekDay}{\param{WeekDay }{weekday}, \param{int }{n = 1}, \param{Month }{month = Inv\_Month}, \param{int }{year = Inv\_Year}} \constfunc{wxDateTime}{GetWeekDay}{\param{WeekDay }{weekday}, \param{int }{n = 1}, \param{Month }{month = Inv\_Month}, \param{int }{year = Inv\_Year}}
Returns the copy of this object to which Returns the copy of this object to which
\helpref{SetToWeekDay}{wxdatetimesettoweekday} was applied. \helpref{SetToWeekDay}{wxdatetimesettoweekday} was applied.
\membersection{wxDateTime::SetToLastWeekDay}\label{wxdatetimesettolastweekday} \membersection{wxDateTime::SetToLastWeekDay}\label{wxdatetimesettolastweekday}
\func{bool}{SetToLastWeekDay}{\param{WeekDay }{weekday}, \param{Month }{month = Inv\_Month}, \param{int }{year = Inv\_Year}} \func{bool}{SetToLastWeekDay}{\param{WeekDay }{weekday}, \param{Month }{month = Inv\_Month}, \param{int }{year = Inv\_Year}}
The effect of calling this function is the same as of calling The effect of calling this function is the same as of calling
{\tt SetToWeekDay(-1, weekday, month, year)}. The date will be set to the last {\tt SetToWeekDay(-1, weekday, month, year)}. The date will be set to the last
{\it weekday} in the given month and year (the current ones by default). {\it weekday} in the given month and year (the current ones by default).
Always returns {\tt TRUE}. Always returns {\tt TRUE}.
@@ -1157,14 +1189,14 @@ Always returns {\tt TRUE}.
\func{wxDateTime}{GetLastWeekDay}{\param{WeekDay }{weekday}, \param{Month }{month = Inv\_Month}, \param{int }{year = Inv\_Year}} \func{wxDateTime}{GetLastWeekDay}{\param{WeekDay }{weekday}, \param{Month }{month = Inv\_Month}, \param{int }{year = Inv\_Year}}
Returns the copy of this object to which Returns the copy of this object to which
\helpref{SetToLastWeekDay}{wxdatetimesettolastweekday} was applied. \helpref{SetToLastWeekDay}{wxdatetimesettolastweekday} was applied.
\membersection{wxDateTime::SetToTheWeek}\label{wxdatetimesettotheweek} \membersection{wxDateTime::SetToTheWeek}\label{wxdatetimesettotheweek}
\func{bool}{SetToTheWeek}{\param{wxDateTime\_t }{numWeek}, \param{WeekDay }{weekday = Mon}} \func{bool}{SetToTheWeek}{\param{wxDateTime\_t }{numWeek}, \param{WeekDay }{weekday = Mon}}
Set the date to the given {\it weekday} in the week with given number Set the date to the given {\it weekday} in the week with given number
{\it numWeek}. The number should be in range $1\ldots53$ and {\tt FALSE} will {\it numWeek}. The number should be in range $1\ldots53$ and {\tt FALSE} will
be returned if the specified date doesn't exist. {\tt TRUE} is returned if the be returned if the specified date doesn't exist. {\tt TRUE} is returned if the
date was changed successfully. date was changed successfully.
@@ -1173,7 +1205,7 @@ date was changed successfully.
\constfunc{wxDateTime}{GetWeek}{\param{wxDateTime\_t }{numWeek}, \param{WeekDay }{weekday = Mon}} \constfunc{wxDateTime}{GetWeek}{\param{wxDateTime\_t }{numWeek}, \param{WeekDay }{weekday = Mon}}
Returns the copy of this object to which Returns the copy of this object to which
\helpref{SetToTheWeek}{wxdatetimesettotheweek} was applied. \helpref{SetToTheWeek}{wxdatetimesettotheweek} was applied.
\membersection{wxDateTime::SetToLastMonthDay}\label{wxdatetimesettolastmonthday} \membersection{wxDateTime::SetToLastMonthDay}\label{wxdatetimesettolastmonthday}
@@ -1189,7 +1221,7 @@ Returns the reference to the modified object itself.
\constfunc{wxDateTime}{GetLastMonthDay}{\param{Month }{month = Inv\_Month}, \param{int }{year = Inv\_Year}} \constfunc{wxDateTime}{GetLastMonthDay}{\param{Month }{month = Inv\_Month}, \param{int }{year = Inv\_Year}}
Returns the copy of this object to which Returns the copy of this object to which
\helpref{SetToLastMonthDay}{wxdatetimesettolastmonthday} was applied. \helpref{SetToLastMonthDay}{wxdatetimesettolastmonthday} was applied.
\membersection{wxDateTime::SetToYearDay}\label{wxdatetimesettoyearday} \membersection{wxDateTime::SetToYearDay}\label{wxdatetimesettoyearday}
@@ -1207,7 +1239,7 @@ Returns the reference to the modified object itself.
\constfunc{wxDateTime}{GetYearDay}{\param{wxDateTime\_t }{yday}} \constfunc{wxDateTime}{GetYearDay}{\param{wxDateTime\_t }{yday}}
Returns the copy of this object to which Returns the copy of this object to which
\helpref{SetToYearDay}{wxdatetimesettoyearday} was applied. \helpref{SetToYearDay}{wxdatetimesettoyearday} was applied.
%%%%%%%%%%%%%%%%%%%%%%%%%%% astronomical functions %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %%%%%%%%%%%%%%%%%%%%%%%%%%% astronomical functions %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
@@ -1269,7 +1301,7 @@ Returns the date in the new time zone.
\func{wxDateTime\&}{MakeTimezone}{\param{const TimeZone\& }{tz}, \param{bool }{noDST = FALSE}} \func{wxDateTime\&}{MakeTimezone}{\param{const TimeZone\& }{tz}, \param{bool }{noDST = FALSE}}
Modifies the object in place to represent the date in another time zone. If Modifies the object in place to represent the date in another time zone. If
{\it noDST} is {\tt TRUE}, no DST adjustments will be made. {\it noDST} is {\tt TRUE}, no DST adjustments will be made.
\membersection{wxDateTime::ToGMT}\label{wxdatetimetogmt} \membersection{wxDateTime::ToGMT}\label{wxdatetimetogmt}
@@ -1294,7 +1326,7 @@ Returns {\tt TRUE} if the DST is applied for this date in the given country.
\wxheading{See also} \wxheading{See also}
\helpref{GetBeginDST}{wxdatetimegetbegindst} and \helpref{GetBeginDST}{wxdatetimegetbegindst} and
\helpref{GetEndDST}{wxdatetimegetenddst} \helpref{GetEndDST}{wxdatetimegetenddst}
\section{\class{wxDateTimeHolidayAuthority}}\label{wxdatetimeholidayauthority} \section{\class{wxDateTimeHolidayAuthority}}\label{wxdatetimeholidayauthority}

View File

@@ -204,6 +204,9 @@ and refreshes the window.
Sets the number of fields, and optionally the field widths. Sets the number of fields, and optionally the field widths.
\pythonnote{Only the first parameter is accepted. Use SetStatusWidths
to set the widths of the fields.}
\wxheading{Parameters} \wxheading{Parameters}
\docparam{number}{The number of fields.} \docparam{number}{The number of fields.}

View File

@@ -67,8 +67,8 @@ implemented in the system library {\tt comctl32.dll}. Some versions of this
library are known to have bugs with handling the tree control colours: the library are known to have bugs with handling the tree control colours: the
usual symptom is that the expanded items leave black (or otherwise incorrectly usual symptom is that the expanded items leave black (or otherwise incorrectly
coloured) background behind them, especially for the controls using non coloured) background behind them, especially for the controls using non
default background colour. The recommended solution is to upgrade the {\tt comctl32.dll} default background colour. The recommended solution is to upgrade the {\tt comctl32.dll}
to a newer version: see to a newer version: see
\urlref{http://www.microsoft.com/msdownload/ieplatform/ie/comctrlx86.asp}{http://www.microsoft.com/msdownload/ieplatform/ie/comctrlx86.asp}. \urlref{http://www.microsoft.com/msdownload/ieplatform/ie/comctrlx86.asp}{http://www.microsoft.com/msdownload/ieplatform/ie/comctrlx86.asp}.
\latexignore{\rtfignore{\wxheading{Members}}} \latexignore{\rtfignore{\wxheading{Members}}}
@@ -178,7 +178,7 @@ will be sent which can be vetoed as well.
\wxheading{See also} \wxheading{See also}
\helpref{wxTreeCtrl::EndEditLabel}{wxtreectrlendeditlabel}, \helpref{wxTreeCtrl::EndEditLabel}{wxtreectrlendeditlabel},
\helpref{wxTreeEvent}{wxtreeevent} \helpref{wxTreeEvent}{wxtreeevent}
\membersection{wxTreeCtrl::EndEditLabel}\label{wxtreectrlendeditlabel} \membersection{wxTreeCtrl::EndEditLabel}\label{wxtreectrlendeditlabel}
@@ -329,7 +329,7 @@ Returns the last child of the item (or an invalid tree item if this item has no
\wxheading{See also} \wxheading{See also}
\helpref{GetFirstChild}{wxtreectrlgetfirstchild}, \helpref{GetFirstChild}{wxtreectrlgetfirstchild},
\helpref{GetLastChild}{wxtreectrlgetlastchild} \helpref{GetLastChild}{wxtreectrlgetlastchild}
\membersection{wxTreeCtrl::GetNextChild}\label{wxtreectrlgetnextchild} \membersection{wxTreeCtrl::GetNextChild}\label{wxtreectrlgetnextchild}
@@ -408,7 +408,7 @@ Returns the root item for the tree control.
\constfunc{int}{GetItemSelectedImage}{\param{const wxTreeItemId\& }{item}} \constfunc{int}{GetItemSelectedImage}{\param{const wxTreeItemId\& }{item}}
Gets the selected item image (this function is obsolete, use Gets the selected item image (this function is obsolete, use
{\tt GetItemImage(item, wxTreeItemIcon\_Selected}) instead). {\tt GetItemImage(item, wxTreeItemIcon\_Selected}) instead).
\membersection{wxTreeCtrl::GetSelection}\label{wxtreectrlgetselection} \membersection{wxTreeCtrl::GetSelection}\label{wxtreectrlgetselection}
@@ -416,7 +416,7 @@ Gets the selected item image (this function is obsolete, use
\constfunc{wxTreeItemId}{GetSelection}{\void} \constfunc{wxTreeItemId}{GetSelection}{\void}
Returns the selection, or an invalid item if there is no selection. Returns the selection, or an invalid item if there is no selection.
This function only works with the controls without wxTR\_MULTIPLE style, use This function only works with the controls without wxTR\_MULTIPLE style, use
\helpref{GetSelections}{wxtreectrlgetselections} for the controls which do have \helpref{GetSelections}{wxtreectrlgetselections} for the controls which do have
this style. this style.
@@ -476,6 +476,9 @@ Inserts an item after a given one ({\it previous}) or before one identified by i
If {\it image} > -1 and {\it selImage} is -1, the same image is used for If {\it image} > -1 and {\it selImage} is -1, the same image is used for
both selected and unselected items. both selected and unselected items.
\pythonnote{The second form of this method is called
\tt{InsertItemBefore} in wxPython.}
\membersection{wxTreeCtrl::IsBold}\label{wxtreectrlisbold} \membersection{wxTreeCtrl::IsBold}\label{wxtreectrlisbold}
\constfunc{bool}{IsBold}{\param{const wxTreeItemId\& }{item}} \constfunc{bool}{IsBold}{\param{const wxTreeItemId\& }{item}}
@@ -609,7 +612,7 @@ usage and loading time.
\func{void}{SetItemImage}{\param{const wxTreeItemId\&}{ item}, \func{void}{SetItemImage}{\param{const wxTreeItemId\&}{ item},
\param{int }{image}, \param{wxTreeItemIcon }{which = wxTreeItemIcon\_Normal}} \param{int }{image}, \param{wxTreeItemIcon }{which = wxTreeItemIcon\_Normal}}
Sets the specified item image. See \helpref{GetItemImage}{wxtreectrlgetitemimage} Sets the specified item image. See \helpref{GetItemImage}{wxtreectrlgetitemimage}
for the description of the {\it which} parameter. for the description of the {\it which} parameter.
\membersection{wxTreeCtrl::SetItemSelectedImage}\label{wxtreectrlsetitemselectedimage} \membersection{wxTreeCtrl::SetItemSelectedImage}\label{wxtreectrlsetitemselectedimage}
@@ -640,7 +643,7 @@ Sets the state image list (from which application-defined state images are taken
\func{void}{SortChildren}{\param{const wxTreeItemId\&}{ item}} \func{void}{SortChildren}{\param{const wxTreeItemId\&}{ item}}
Sorts the children of the given item using Sorts the children of the given item using
\helpref{OnCompareItems}{wxtreectrloncompareitems} method of wxTreeCtrl. You \helpref{OnCompareItems}{wxtreectrloncompareitems} method of wxTreeCtrl. You
should override that method to change the sort order (the default is ascending should override that method to change the sort order (the default is ascending
alphabetical order). alphabetical order).
@@ -665,7 +668,7 @@ Removes the selection from the currently selected item (if any).
\func{void}{UnselectAll}{\void} \func{void}{UnselectAll}{\void}
This function either behaves the same as \helpref{Unselect}{wxtreectrlunselect} This function either behaves the same as \helpref{Unselect}{wxtreectrlunselect}
if the control doesn't have wxTR\_MULTIPLE style, or removes the selection from if the control doesn't have wxTR\_MULTIPLE style, or removes the selection from
all items if it does have this style. all items if it does have this style.

View File

@@ -360,6 +360,7 @@ as possible to the C++ spec over time.
\item \helpref{wxBusyCursor}{wxbusycursor} \item \helpref{wxBusyCursor}{wxbusycursor}
\item \helpref{wxButton}{wxbutton} \item \helpref{wxButton}{wxbutton}
\item \helpref{wxCalculateLayoutEvent}{wxcalculatelayoutevent} \item \helpref{wxCalculateLayoutEvent}{wxcalculatelayoutevent}
\item \helpref{wxCalendarCtrl}{wxcalendarctrl}
\item wxCaret \item wxCaret
\item \helpref{wxCheckBox}{wxcheckbox} \item \helpref{wxCheckBox}{wxcheckbox}
\item \helpref{wxCheckListBox}{wxchecklistbox} \item \helpref{wxCheckListBox}{wxchecklistbox}
@@ -380,6 +381,8 @@ as possible to the C++ spec over time.
\item \helpref{wxDataObject}{wxdataobject} \item \helpref{wxDataObject}{wxdataobject}
\item \helpref{wxDataObjectComposite}{wxdataobjectcomposite} \item \helpref{wxDataObjectComposite}{wxdataobjectcomposite}
\item \helpref{wxDataObjectSimple}{wxdataobjectsimple} \item \helpref{wxDataObjectSimple}{wxdataobjectsimple}
\item \helpref{wxDateTime}{wxdatetime}
\item \helpref{wxDateSpan}{wxdatespan}
\item \helpref{wxDC}{wxdc} \item \helpref{wxDC}{wxdc}
\item \helpref{wxDialog}{wxdialog} \item \helpref{wxDialog}{wxdialog}
\item \helpref{wxDirDialog}{wxdirdialog} \item \helpref{wxDirDialog}{wxdirdialog}
@@ -390,6 +393,7 @@ as possible to the C++ spec over time.
\item \helpref{wxEraseEvent}{wxeraseevent} \item \helpref{wxEraseEvent}{wxeraseevent}
\item \helpref{wxEvent}{wxevent} \item \helpref{wxEvent}{wxevent}
\item \helpref{wxEvtHandler}{wxevthandler} \item \helpref{wxEvtHandler}{wxevthandler}
\item wxFileConfig
\item \helpref{wxFileDataObject}{wxfiledataobject} \item \helpref{wxFileDataObject}{wxfiledataobject}
\item \helpref{wxFileDialog}{wxfiledialog} \item \helpref{wxFileDialog}{wxfiledialog}
\item \helpref{wxFileDropTarget}{wxfiledroptarget} \item \helpref{wxFileDropTarget}{wxfiledroptarget}
@@ -401,9 +405,11 @@ as possible to the C++ spec over time.
\item \helpref{wxGauge}{wxgauge} \item \helpref{wxGauge}{wxgauge}
\item wxGIFHandler \item wxGIFHandler
\item wxGLCanvas \item wxGLCanvas
\begin{comment}
\item wxGridCell \item wxGridCell
\item wxGridEvent \item wxGridEvent
\item \helpref{wxGrid}{wxgrid} \item \helpref{wxGrid}{wxgrid}
\end{comment}
\item \helpref{wxHtmlCell}{wxhtmlcell} \item \helpref{wxHtmlCell}{wxhtmlcell}
\item \helpref{wxHtmlContainerCell}{wxhtmlcontainercell} \item \helpref{wxHtmlContainerCell}{wxhtmlcontainercell}
\item \helpref{wxHtmlDCRenderer}{wxhtmldcrenderer} \item \helpref{wxHtmlDCRenderer}{wxhtmldcrenderer}
@@ -505,6 +511,8 @@ as possible to the C++ spec over time.
\item \helpref{wxTextDropTarget}{wxtextdroptarget} \item \helpref{wxTextDropTarget}{wxtextdroptarget}
\item \helpref{wxTextEntryDialog}{wxtextentrydialog} \item \helpref{wxTextEntryDialog}{wxtextentrydialog}
\item \helpref{wxTimer}{wxtimer} \item \helpref{wxTimer}{wxtimer}
\item \helpref{wxTimerEvent}{wxtimerevent}
\item \helpref{wxTimeSpan}{wxtimespan}
\item \helpref{wxTipProvider}{wxtipprovider} \item \helpref{wxTipProvider}{wxtipprovider}
\item wxToolBarTool \item wxToolBarTool
\item \helpref{wxToolBar}{wxtoolbar} \item \helpref{wxToolBar}{wxtoolbar}
@@ -524,14 +532,15 @@ as possible to the C++ spec over time.
Since wxPython is a blending of multiple technologies, help comes from Since wxPython is a blending of multiple technologies, help comes from
multiple sources. See multiple sources. See
\urlref{http://alldunn.com/wxPython}{http://alldunn.com/wxPython} for details on \urlref{http://wxpython.org/}{http://wxpython.org/} for details on
various sources of help, but probably the best source is the various sources of help, but probably the best source is the
wxPython-users mail list. You can view the archive or subscribe by wxPython-users mail list. You can view the archive or subscribe by
going to going to
\urlref{http://starship.python.net/mailman/listinfo/wxpython-users}{http://starship.python.net/mailman/listinfo/wxpython-users} \urlref{http://wxwindows.org/mailman/listinfo/wxpython-users}{http://wxwindows.org/mailman/listinfo/wxpython-users}
Or you can send mail directly to the list using this address: Or you can send mail directly to the list using this address:
wxpython-users@starship.python.net wxpython-users@wxwindows.org