.. wxPython Phoenix documentation
This file was generated by Phoenix's sphinx generator and associated
tools, do not edit by hand.
Copyright: (c) 2011-2020 by Total Control Software
License: wxWindows License
.. include:: headings.inc
.. _wx.DateTime.NameForm:
==========================================================================================================================================
|phoenix_title| **wx.DateTime.NameForm**
==========================================================================================================================================
Class representing a name form.
This class describes the form of month or weekday names used in formatting a date. It contains attributes for the requested name length and the formatting context. It is used as a parameter to the :meth:`~wx.DateTime.NameForm.GetWeekDayName` and :meth:`~wx.DateTime.NameForm.GetMonthName` functions.
.. versionadded:: 4.3/wxWidgets-3.3.0
|
|class_hierarchy| Class Hierarchy
=================================
.. raw:: html

Inheritance diagram for class
NameForm:
|
|method_summary| Methods Summary
================================
================================================================================ ================================================================================
:meth:`~wx.DateTime.NameForm.__init__` Constructor for a name form.
:meth:`~wx.DateTime.NameForm.Abbr` Set the flag for abbreviated month or weekday names.
:meth:`~wx.DateTime.NameForm.Formatting` Set the context for date formatting.
:meth:`~wx.DateTime.NameForm.Full` Set the flag for full month or weekday names.
:meth:`~wx.DateTime.NameForm.GetContext` Return the context of name usage.
:meth:`~wx.DateTime.NameForm.GetFlags` Return the flags describing the requested name length.
:meth:`~wx.DateTime.NameForm.Shortest` Set the flag for shortest month or weekday names.
:meth:`~wx.DateTime.NameForm.Standalone` Set the context for standalone use.
================================================================================ ================================================================================
|
|property_summary| Properties Summary
=====================================
================================================================================ ================================================================================
:attr:`~wx.DateTime.NameForm.Context` See :meth:`~wx.DateTime.NameForm.GetContext`
:attr:`~wx.DateTime.NameForm.Flags` See :meth:`~wx.DateTime.NameForm.GetFlags`
================================================================================ ================================================================================
|
|api| Class API
===============
.. class:: wx.DateTime.NameForm(object)
**Possible constructors**::
NameForm(flags=DateTime.NameFlags.Name_Full) -> None
Class representing a name form.
.. method:: __init__(self, flags=DateTime.NameFlags.Name_Full)
Constructor for a name form.
Initializes this object to use the given form of the name (full by default) in the formatting context.
Note that this constructor is `not` explicit, to allow the existing code which passes :ref:`wx.DateTime.NameFlags` to various functions now taking :ref:`wx.DateTime.NameForm` to work. Please beware of the implicit conversions here.
:param `flags`:
:type `flags`: DateTime.NameFlags
:rtype: `None`
.. method:: Abbr(self)
Set the flag for abbreviated month or weekday names.
:rtype: :ref:`wx.DateTime.NameForm`
.. method:: Formatting(self)
Set the context for date formatting.
In some languages, month and day names have different forms depending on whether they're used on their own, e.g. as names of the months in the calendar, or as part of a date representation.
Use this function if you need to localize a date format or in another similar context.
:rtype: :ref:`wx.DateTime.NameForm`
.. seealso:: :meth:`Standalone`
.. method:: Full(self)
Set the flag for full month or weekday names.
:rtype: :ref:`wx.DateTime.NameForm`
.. method:: GetContext(self)
Return the context of name usage.
:rtype: :ref:`wx.DateTime.NameContext`
.. method:: GetFlags(self)
Return the flags describing the requested name length.
:rtype: :ref:`wx.DateTime.NameFlags`
.. method:: Shortest(self)
Set the flag for shortest month or weekday names.
:rtype: :ref:`wx.DateTime.NameForm`
.. method:: Standalone(self)
Set the context for standalone use.
:rtype: :ref:`wx.DateTime.NameForm`
.. attribute:: Context
See :meth:`~wx.DateTime.NameForm.GetContext`
.. attribute:: Flags
See :meth:`~wx.DateTime.NameForm.GetFlags`