⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 _gdi.py

📁 Wxpython Implemented on Windows CE, Source code
💻 PY
📖 第 1 页 / 共 5 页
字号:
#---------------------------------------------------------------------------

class FontMapper(object):
    """Proxy of C++ FontMapper class"""
    thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc='The membership flag')
    __repr__ = _swig_repr
    def __init__(self, *args, **kwargs): 
        """__init__(self) -> FontMapper"""
        _gdi_.FontMapper_swiginit(self,_gdi_.new_FontMapper(*args, **kwargs))
    __swig_destroy__ = _gdi_.delete_FontMapper
    __del__ = lambda self : None;
    def Get(*args, **kwargs):
        """Get() -> FontMapper"""
        return _gdi_.FontMapper_Get(*args, **kwargs)

    Get = staticmethod(Get)
    def Set(*args, **kwargs):
        """Set(FontMapper mapper) -> FontMapper"""
        return _gdi_.FontMapper_Set(*args, **kwargs)

    Set = staticmethod(Set)
    def CharsetToEncoding(*args, **kwargs):
        """CharsetToEncoding(self, String charset, bool interactive=True) -> int"""
        return _gdi_.FontMapper_CharsetToEncoding(*args, **kwargs)

    def GetSupportedEncodingsCount(*args, **kwargs):
        """GetSupportedEncodingsCount() -> size_t"""
        return _gdi_.FontMapper_GetSupportedEncodingsCount(*args, **kwargs)

    GetSupportedEncodingsCount = staticmethod(GetSupportedEncodingsCount)
    def GetEncoding(*args, **kwargs):
        """GetEncoding(size_t n) -> int"""
        return _gdi_.FontMapper_GetEncoding(*args, **kwargs)

    GetEncoding = staticmethod(GetEncoding)
    def GetEncodingName(*args, **kwargs):
        """GetEncodingName(int encoding) -> String"""
        return _gdi_.FontMapper_GetEncodingName(*args, **kwargs)

    GetEncodingName = staticmethod(GetEncodingName)
    def GetEncodingDescription(*args, **kwargs):
        """GetEncodingDescription(int encoding) -> String"""
        return _gdi_.FontMapper_GetEncodingDescription(*args, **kwargs)

    GetEncodingDescription = staticmethod(GetEncodingDescription)
    def GetEncodingFromName(*args, **kwargs):
        """GetEncodingFromName(String name) -> int"""
        return _gdi_.FontMapper_GetEncodingFromName(*args, **kwargs)

    GetEncodingFromName = staticmethod(GetEncodingFromName)
    def SetConfigPath(*args, **kwargs):
        """SetConfigPath(self, String prefix)"""
        return _gdi_.FontMapper_SetConfigPath(*args, **kwargs)

    def GetDefaultConfigPath(*args, **kwargs):
        """GetDefaultConfigPath() -> String"""
        return _gdi_.FontMapper_GetDefaultConfigPath(*args, **kwargs)

    GetDefaultConfigPath = staticmethod(GetDefaultConfigPath)
    def GetAltForEncoding(*args, **kwargs):
        """GetAltForEncoding(self, int encoding, String facename=EmptyString, bool interactive=True) -> PyObject"""
        return _gdi_.FontMapper_GetAltForEncoding(*args, **kwargs)

    def IsEncodingAvailable(*args, **kwargs):
        """IsEncodingAvailable(self, int encoding, String facename=EmptyString) -> bool"""
        return _gdi_.FontMapper_IsEncodingAvailable(*args, **kwargs)

    def SetDialogParent(*args, **kwargs):
        """SetDialogParent(self, Window parent)"""
        return _gdi_.FontMapper_SetDialogParent(*args, **kwargs)

    def SetDialogTitle(*args, **kwargs):
        """SetDialogTitle(self, String title)"""
        return _gdi_.FontMapper_SetDialogTitle(*args, **kwargs)

_gdi_.FontMapper_swigregister(FontMapper)

def FontMapper_Get(*args):
  """FontMapper_Get() -> FontMapper"""
  return _gdi_.FontMapper_Get(*args)

def FontMapper_Set(*args, **kwargs):
  """FontMapper_Set(FontMapper mapper) -> FontMapper"""
  return _gdi_.FontMapper_Set(*args, **kwargs)

def FontMapper_GetSupportedEncodingsCount(*args):
  """FontMapper_GetSupportedEncodingsCount() -> size_t"""
  return _gdi_.FontMapper_GetSupportedEncodingsCount(*args)

def FontMapper_GetEncoding(*args, **kwargs):
  """FontMapper_GetEncoding(size_t n) -> int"""
  return _gdi_.FontMapper_GetEncoding(*args, **kwargs)

def FontMapper_GetEncodingName(*args, **kwargs):
  """FontMapper_GetEncodingName(int encoding) -> String"""
  return _gdi_.FontMapper_GetEncodingName(*args, **kwargs)

def FontMapper_GetEncodingDescription(*args, **kwargs):
  """FontMapper_GetEncodingDescription(int encoding) -> String"""
  return _gdi_.FontMapper_GetEncodingDescription(*args, **kwargs)

def FontMapper_GetEncodingFromName(*args, **kwargs):
  """FontMapper_GetEncodingFromName(String name) -> int"""
  return _gdi_.FontMapper_GetEncodingFromName(*args, **kwargs)

def FontMapper_GetDefaultConfigPath(*args):
  """FontMapper_GetDefaultConfigPath() -> String"""
  return _gdi_.FontMapper_GetDefaultConfigPath(*args)

#---------------------------------------------------------------------------

class Font(GDIObject):
    """
    A font is an object which determines the appearance of text. Fonts are
    used for drawing text to a device context, and setting the appearance
    of a window's text.

    You can retrieve the current system font settings with `wx.SystemSettings`.
    """
    thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc='The membership flag')
    __repr__ = _swig_repr
    def __init__(self, *args, **kwargs): 
        """
        __init__(self, int pointSize, int family, int style, int weight, bool underline=False, 
            String face=EmptyString, 
            int encoding=FONTENCODING_DEFAULT) -> Font

        Creates a font object with the specified attributes.

            :param pointSize:  The size of the font in points.

            :param family: Font family.  A generic way of referring to fonts
                without specifying actual facename.  It can be One of 
                the ``wx.FONTFAMILY_xxx`` constants.

            :param style: One of the ``wx.FONTSTYLE_xxx`` constants.

            :param weight: Font weight, sometimes also referred to as font
                boldness. One of the ``wx.FONTWEIGHT_xxx`` constants.

            :param underline: The value can be ``True`` or ``False`` and
                indicates whether the font will include an underline.  This
                may not be supported on all platforms.

            :param face: An optional string specifying the actual typeface to
                be used. If it is an empty string, a default typeface will be
                chosen based on the family.

            :param encoding: An encoding which may be one of the
                ``wx.FONTENCODING_xxx`` constants.  If the specified encoding isn't
                available, no font is created.

        :see: `wx.FFont`, `wx.FontFromPixelSize`, `wx.FFontFromPixelSize`,
            `wx.FontFromNativeInfoString`, `wx.FontFromNativeInfo`

        """
        if kwargs.has_key('faceName'): kwargs['face'] = kwargs['faceName'];del kwargs['faceName']
        _gdi_.Font_swiginit(self,_gdi_.new_Font(*args, **kwargs))
    __swig_destroy__ = _gdi_.delete_Font
    __del__ = lambda self : None;
    def Ok(*args, **kwargs):
        """
        Ok(self) -> bool

        Returns ``True`` if this font was successfully created.
        """
        return _gdi_.Font_Ok(*args, **kwargs)

    def __nonzero__(self): return self.Ok() 
    def __eq__(*args, **kwargs):
        """__eq__(self, Font other) -> bool"""
        return _gdi_.Font___eq__(*args, **kwargs)

    def __ne__(*args, **kwargs):
        """__ne__(self, Font other) -> bool"""
        return _gdi_.Font___ne__(*args, **kwargs)

    def GetPointSize(*args, **kwargs):
        """
        GetPointSize(self) -> int

        Gets the point size.
        """
        return _gdi_.Font_GetPointSize(*args, **kwargs)

    def GetPixelSize(*args, **kwargs):
        """
        GetPixelSize(self) -> Size

        Returns the size in pixels if the font was constructed with a pixel
        size.
        """
        return _gdi_.Font_GetPixelSize(*args, **kwargs)

    def IsUsingSizeInPixels(*args, **kwargs):
        """
        IsUsingSizeInPixels(self) -> bool

        Returns ``True`` if the font is using a pixelSize.
        """
        return _gdi_.Font_IsUsingSizeInPixels(*args, **kwargs)

    def GetFamily(*args, **kwargs):
        """
        GetFamily(self) -> int

        Gets the font family. 
        """
        return _gdi_.Font_GetFamily(*args, **kwargs)

    def GetStyle(*args, **kwargs):
        """
        GetStyle(self) -> int

        Gets the font style.
        """
        return _gdi_.Font_GetStyle(*args, **kwargs)

    def GetWeight(*args, **kwargs):
        """
        GetWeight(self) -> int

        Gets the font weight. 
        """
        return _gdi_.Font_GetWeight(*args, **kwargs)

    def GetUnderlined(*args, **kwargs):
        """
        GetUnderlined(self) -> bool

        Returns ``True`` if the font is underlined, ``False`` otherwise.
        """
        return _gdi_.Font_GetUnderlined(*args, **kwargs)

    def GetFaceName(*args, **kwargs):
        """
        GetFaceName(self) -> String

        Returns the typeface name associated with the font, or the empty
        string if there is no typeface information.
        """
        return _gdi_.Font_GetFaceName(*args, **kwargs)

    def GetEncoding(*args, **kwargs):
        """
        GetEncoding(self) -> int

        Get the font's encoding.
        """
        return _gdi_.Font_GetEncoding(*args, **kwargs)

    def GetNativeFontInfo(*args, **kwargs):
        """
        GetNativeFontInfo(self) -> NativeFontInfo

        Constructs a `wx.NativeFontInfo` object from this font.
        """
        return _gdi_.Font_GetNativeFontInfo(*args, **kwargs)

    def IsFixedWidth(*args, **kwargs):
        """
        IsFixedWidth(self) -> bool

        Returns true if the font is a fixed width (or monospaced) font, false
        if it is a proportional one or font is invalid.
        """
        return _gdi_.Font_IsFixedWidth(*args, **kwargs)

    def GetNativeFontInfoDesc(*args, **kwargs):
        """
        GetNativeFontInfoDesc(self) -> String

        Returns the platform-dependent string completely describing this font
        or an empty string if the font isn't valid.
        """
        return _gdi_.Font_GetNativeFontInfoDesc(*args, **kwargs)

    def GetNativeFontInfoUserDesc(*args, **kwargs):
        """
        GetNativeFontInfoUserDesc(self) -> String

        Returns a human readable version of `GetNativeFontInfoDesc`.
        """
        return _gdi_.Font_GetNativeFontInfoUserDesc(*args, **kwargs)

    def SetPointSize(*args, **kwargs):
        """
        SetPointSize(self, int pointSize)

        Sets the point size.
        """
        return _gdi_.Font_SetPointSize(*args, **kwargs)

    def SetPixelSize(*args, **kwargs):
        """
        SetPixelSize(self, Size pixelSize)

        Sets the size in pixels rather than points.  If there is platform API
        support for this then it is used, otherwise a font with the closest
        size is found using a binary search.
        """
        return _gdi_.Font_SetPixelSize(*args, **kwargs)

    def SetFamily(*args, **kwargs):
        """
        SetFamily(self, int family)

        Sets the font family.
        """
        return _gdi_.Font_SetFamily(*args, **kwargs)

    def SetStyle(*args, **kwargs):
        """
        SetStyle(self, int style)

        Sets the font style.
        """
        return _gdi_.Font_SetStyle(*args, **kwargs)

    def SetWeight(*args, **kwargs):
        """
        SetWeight(self, int weight)

        Sets the font weight.
        """
        return _gdi_.Font_SetWeight(*args, **kwargs)

    def SetFaceName(*args, **kwargs):
        """
        SetFaceName(self, String faceName) -> bool

        Sets the facename for the font.  The facename, which should be a valid
        font installed on the end-user's system.

        To avoid portability problems, don't rely on a specific face, but
        specify the font family instead or as well. A suitable font will be
        found on the end-user's system. If both the family and the facename
        are specified, wxWidgets will first search for the specific face, and
        then for a font belonging to the same family.
        """
        return _gdi_.Font_SetFaceName(*args, **kwargs)

    def SetUnderlined(*args, **kwargs):
        """
        SetUnderlined(self, bool underlined)

        Sets underlining.
        """
        return _gdi_.Font_SetUnderlined(*args, **kwargs)

    def SetEncoding(*args, **kwargs):
        """
        SetEncoding(self, int encoding)

        Set the font encoding.
        """
   

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -