RQtClass: Class Definitions

Description Details Author(s) See Also Examples

Description

Each class defined by a library has a corresponding RQtClass object. Each object is a function and serves as the constructor for the class. Special behavior is defined, so that the function also behaves as a container of static methods and enumeration values defined by the class.

Details

Besides serving as a constructor, this object contains two types of members: static methods and enumeration values. Their names may be listed by calling names on the object. To access a member, use $, which supports auto-completion, thanks to the names method.

Namespaces within a library are also represented as RQtClass objects, even though they are not actually classes.

Author(s)

Michael Lawrence

See Also

RQtLibrary (container of class objects), RQtObject (an instance of a class)

Examples

1
2
3
4
5
6
## calling a constructor
widget <- Qt$QWidget()
## calling a static method
Qt$QWidget$tr("hello world")
## access an enum value within the 'Qt' namespace
Qt$Qt$AbsoluteSize

ggobi/qtbase documentation built on May 17, 2019, 3:15 a.m.