QCalendarWidget
Create and control a selectable monthly calendar.
This class is a JS wrapper around Qt's QCalendarWidget class
A QCalendarWidget
provides a monthly based calendar widget allowing the user to select a date.
Example
const { QCalendarWidget } = require("@nodegui/nodegui");
const calendarWidget = new QCalendarWidget();
// more will follow when .selectedDate() et cetera are implemented
Hierarchy
↳ QWidget‹QCalendarWidgetSignals›
↳ QCalendarWidget
Index
Constructors
Properties
Methods
- _id
- acceptDrops
- accessibleDescription
- accessibleName
- activateWindow
- addAction
- addEventListener
- adjustSize
- autoFillBackground
- baseSize
- childAt
- children
- childrenRect
- clearFocus
- clearMask
- close
- colorCount
- contentsRect
- contextMenuPolicy
- dateEditAcceptDelay
- delete
- deleteLater
- depth
- devicePixelRatio
- devicePixelRatioF
- dumpObjectInfo
- dumpObjectTree
- ensurePolished
- eventProcessed
- firstDayOfWeek
- focusProxy
- focusWidget
- font
- frameGeometry
- frameSize
- geometry
- getFlexNode
- grab
- grabKeyboard
- grabMouse
- hasFocus
- hasHeightForWidth
- hasMouseTracking
- hasTabletTracking
- height
- heightForWidth
- heightMM
- hide
- horizontalHeaderFormat
- inherits
- inputMethodHints
- isActiveWindow
- isAncestorOf
- isDateEditEnabled
- isEnabled
- isEnabledTo
- isFullScreen
- isGridVisible
- isHidden
- isMaximized
- isMinimized
- isModal
- isNavigationBarVisible
- isVisible
- isVisibleTo
- isWindow
- isWindowModified
- killTimer
- layout
- logicalDpiX
- logicalDpiY
- lower
- mapFrom
- mapFromGlobal
- mapFromParent
- mapTo
- mapToGlobal
- mapToParent
- maximumHeight
- maximumSize
- maximumWidth
- minimumHeight
- minimumSize
- minimumSizeHint
- minimumWidth
- move
- nativeParentWidget
- nextInFocusChain
- normalGeometry
- objectName
- paintingActive
- parent
- parentWidget
- physicalDpiX
- physicalDpiY
- pos
- previousInFocusChain
- property
- raise
- rect
- releaseKeyboard
- releaseMouse
- releaseShortcut
- removeAction
- removeEventListener
- repaint
- repolish
- resize
- selectionMode
- setAcceptDrops
- setAccessibleDescription
- setAccessibleName
- setAttribute
- setAutoFillBackground
- setBaseSize
- setContentsMargins
- setContextMenuPolicy
- setCursor
- setDateEditAcceptDelay
- setDateEditEnabled
- setDisabled
- setEnabled
- setEventProcessed
- setFirstDayOfWeek
- setFixedHeight
- setFixedSize
- setFixedWidth
- setFlexNodeSizeControlled
- setFocus
- setFocusPolicy
- setFocusProxy
- setFont
- setGeometry
- setGraphicsEffect
- setGridVisible
- setHidden
- setHorizontalHeaderFormat
- setInlineStyle
- setInputMethodHints
- setLayout
- setMaximumHeight
- setMaximumSize
- setMaximumWidth
- setMinimumHeight
- setMinimumSize
- setMinimumWidth
- setMouseTracking
- setNavigationBarVisible
- setObjectName
- setParent
- setProperty
- setSelectionMode
- setShortcutAutoRepeat
- setShortcutEnabled
- setSizeIncrement
- setSizePolicy
- setStatusTip
- setStyleSheet
- setTabletTracking
- setToolTip
- setToolTipDuration
- setUpdatesEnabled
- setVerticalHeaderFormat
- setVisible
- setWhatsThis
- setWindowFilePath
- setWindowFlag
- setWindowIcon
- setWindowModified
- setWindowOpacity
- setWindowRole
- setWindowState
- setWindowTitle
- show
- showFullScreen
- showMaximized
- showMinimized
- showNormal
- size
- sizeHint
- sizeIncrement
- stackUnder
- startTimer
- statusTip
- style
- styleSheet
- testAttribute
- toolTip
- toolTipDuration
- underMouse
- unsetCursor
- unsetLayoutDirection
- unsetLocale
- update
- updateGeometry
- updateMicroFocus
- updatesEnabled
- verticalHeaderFormat
- whatsThis
- width
- widthMM
- winId
- window
- windowFilePath
- windowHandle
- windowIcon
- windowOpacity
- windowRole
- windowState
- windowTitle
- x
- y
Constructors
constructor
+ new QCalendarWidget(arg?
: QWidget‹QWidgetSignals› | NativeElement): QCalendarWidget
Overrides QAbstractSlider.constructor
Parameters:
Name | Type |
---|---|
arg? | QWidget‹QWidgetSignals› | NativeElement |
Returns: QCalendarWidget
Properties
_rawInlineStyle
• _rawInlineStyle: string
Inherited from QMenu._rawInlineStyle
native
• native: NativeElement | null
Inherited from Component.native
type
• type: string
Methods
_id
▸ _id(): number
Get an ID identifying the underlying C++ object.
This can be useful when debugging memory problems with help from
setLogCreateQObject()
and setLogDestroyQObject()
. The number is
hash of the memory address of the C++ object.
Returns: number
a unique number which is valid for the lifetime of the C++ object.
acceptDrops
▸ acceptDrops(): boolean
Inherited from QMenu.acceptDrops
Returns: boolean
accessibleDescription
▸ accessibleDescription(): string
Inherited from QMenu.accessibleDescription
Returns: string
accessibleName
▸ accessibleName(): string
Inherited from QMenu.accessibleName
Returns: string
activateWindow
▸ activateWindow(): void
Inherited from QMenu.activateWindow
Returns: void
addAction
▸ addAction(action
: QAction | string): QAction
Inherited from QMenu.addAction
Parameters:
Name | Type |
---|---|
action | QAction | string |
Returns: QAction
addEventListener
▸ addEventListener‹SignalType›(signalType
: SignalType, callback
: QCalendarWidgetSignals[SignalType], options?
: EventListenerOptions): void
Inherited from EventWidget.addEventListener
Type parameters:
▪ SignalType: keyof QCalendarWidgetSignals
Parameters:
Name | Type | Description |
---|---|---|
signalType | SignalType | SignalType is a signal from the widgets signals interface. |
callback | QCalendarWidgetSignals[SignalType] | Corresponding callback for the signal as mentioned in the widget's signal interface |
options? | EventListenerOptions | Extra optional options controlling how this event listener is added. |
Returns: void
void
For example in the case of QPushButton:
const button = new QPushButton();
button.addEventListener('clicked',(checked)=>console.log("clicked"));
// here clicked is a value from QPushButtonSignals interface
▸ addEventListener(eventType
: WidgetEventTypes, callback
: function, options?
: EventListenerOptions): void
Inherited from EventWidget.addEventListener
Parameters:
▪ eventType: WidgetEventTypes
▪ callback: function
▸ (event?
: NativeRawPointer‹"QEvent"›): void
Parameters:
Name | Type |
---|---|
event? | NativeRawPointer‹"QEvent"› |
▪Optional
options: EventListenerOptions
Extra optional options controlling how this event listener is added.
For example in the case of QPushButton:
const button = new QPushButton();
button.addEventListener(WidgetEventTypes.HoverEnter,()=>console.log("hovered"));
Returns: void
adjustSize
▸ adjustSize(): void
Inherited from QMenu.adjustSize
Returns: void
autoFillBackground
▸ autoFillBackground(): boolean
Inherited from QMenu.autoFillBackground
Returns: boolean
baseSize
▸ baseSize(): QSize
Returns: QSize
childAt
▸ childAt(x
: number, y
: number): QWidget
Parameters:
Name | Type |
---|---|
x | number |
y | number |
Returns: QWidget
children
▸ children(): QObject[]
Inherited from QObject.children
Returns: QObject[]