RNMenuBar

Hierarchy

  • QMenuBar

    RNMenuBar

Implements

  • RNWidget

Index

Constructors

Properties

Methods

Constructors

constructor

+ new RNMenuBar(): RNMenuBar

Inherited from RNMenuBar.constructor

Overrides void

Returns: RNMenuBar

+ new RNMenuBar(parent: NodeWidget‹any›): RNMenuBar

Inherited from RNMenuBar.constructor

Overrides void

Parameters:

NameType
parentNodeWidget‹any›

Returns: RNMenuBar

+ new RNMenuBar(native: NativeElement): RNMenuBar

Inherited from RNMenuBar.constructor

Overrides void

Parameters:

NameType
nativeNativeElement

Returns: RNMenuBar

Properties

_menus

_menus: Set‹QMenu›

Inherited from RNMenuBar._menus


_rawInlineStyle

_rawInlineStyle: string

Inherited from void


actions

actions: Set‹QAction›

Inherited from void


Optional layout

layout? : NodeLayout‹QMenuBarSignals›

Inherited from void


native

native: NativeElement

Inherited from RNMenuBar.native

Overrides void


nodeChildren

nodeChildren: Set‹Component›

Inherited from void


Optional nodeParent

nodeParent? : Component

Inherited from void


type

type: string

Inherited from void


Static tagName

tagName: string = "menubar"

Methods

activateWindow

activateWindow(): void

Inherited from void

Returns: void


addAction

addAction(action: QAction | string): QAction

Inherited from void

Parameters:

NameType
actionQAction | string

Returns: QAction


addEventListener

addEventListenerSignalType›(signalType: SignalType, callback: QMenuBarSignals[SignalType]): void

Inherited from void

Type parameters:

SignalType: keyof QMenuBarSignals

Parameters:

NameTypeDescription
signalTypeSignalTypeSignalType is a signal from the widgets signals interface.
callbackQMenuBarSignals[SignalType]Corresponding callback for the signal as mentioned in the widget's signal interface

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): void

Inherited from void

Parameters:

eventType: WidgetEventTypes

callback: function

For example in the case of QPushButton:

const button = new QPushButton();
button.addEventListener(WidgetEventTypes.HoverEnter,()=>console.log("hovered"));

▸ (event?: NativeRawPointer‹"QEvent"›): void

Parameters:

NameType
event?NativeRawPointer‹"QEvent"›

Returns: void


addMenu

addMenu(menu: QMenu | string): QMenu

Inherited from RNMenuBar.addMenu

Parameters:

NameType
menuQMenu | string

Returns: QMenu


addSeparator

addSeparator(): QAction

Inherited from RNMenuBar.addSeparator

Returns: QAction


adjustSize

adjustSize(): void

Inherited from void

Returns: void


appendChild

appendChild(child: QMenu): void

Parameters:

NameType
childQMenu

Returns: void


appendInitialChild

appendInitialChild(child: QMenu): void

Parameters:

NameType
childQMenu

Returns: void


close

close(): boolean

Inherited from void

Returns: boolean


font

font(): QFont

Inherited from void

Returns: QFont


geometry

geometry(): QRect

Inherited from void

Returns: QRect


getFlexNode

getFlexNode(): FlexNode

Inherited from void

Returns: FlexNode


hasMouseTracking

hasMouseTracking(): boolean

Inherited from void

Returns: boolean


hide

hide(): void

Inherited from void

Returns: void


inherits

inherits(className: string): boolean

Inherited from void

Parameters:

NameType
classNamestring

Returns: boolean


insertBefore

insertBefore(child: NodeWidget‹any›, beforeChild: NodeWidget‹any›): void

Parameters:

NameType
childNodeWidget‹any›
beforeChildNodeWidget‹any›

Returns: void


isEnabled

isEnabled(): boolean

Inherited from void

Returns: boolean


isVisible

isVisible(): boolean

Inherited from void

Returns: boolean


lower

lower(): void

Inherited from void

Returns: void


mapFromGlobal

mapFromGlobal(pos: QPoint): QPoint

Inherited from void

Parameters:

NameType
posQPoint

Returns: QPoint


mapFromParent

mapFromParent(pos: QPoint): QPoint

Inherited from void

Parameters:

NameType
posQPoint

Returns: QPoint


mapToGlobal

mapToGlobal(pos: QPoint): QPoint

Inherited from void

Parameters:

NameType
posQPoint

Returns: QPoint


mapToParent

mapToParent(pos: QPoint): QPoint

Inherited from void

Parameters:

NameType
posQPoint

Returns: QPoint


maximumSize

maximumSize(): QSize

Inherited from void

Returns: QSize


minimumSize

minimumSize(): QSize

Inherited from void

Returns: QSize


move

move(x: number, y: number): void

Inherited from void

Parameters:

NameType
xnumber
ynumber

Returns: void


objectName

objectName(): string

Inherited from void

Returns: string


pos

pos(): object

Inherited from void

Returns: object

  • x: number

  • y: number


property

property(name: string): QVariant

Inherited from void

Parameters:

NameType
namestring

Returns: QVariant


raise

raise(): void

Inherited from void

Returns: void


removeAction

removeAction(action: QAction): void

Inherited from void

Parameters:

NameType
actionQAction

Returns: void


removeChild

removeChild(child: NodeWidget‹any›): void

Parameters:

NameType
childNodeWidget‹any›

Returns: void


removeEventListener

removeEventListenerSignalType›(signalType: SignalType, callback: QMenuBarSignals[SignalType]): void

Inherited from void

Type parameters:

SignalType: keyof QMenuBarSignals

Parameters:

NameType
signalTypeSignalType
callbackQMenuBarSignals[SignalType]

Returns: void

removeEventListener(eventType: WidgetEventTypes, callback: function): void

Inherited from void

Parameters:

eventType: WidgetEventTypes

callback: function

▸ (event?: NativeRawPointer‹"QEvent"›): void

Parameters:

NameType
event?NativeRawPointer‹"QEvent"›

Returns: void


repaint

repaint(): void

Inherited from void

Returns: void


repolish

repolish(): void

Inherited from void

Returns: void


resize

resize(width: number, height: number): void

Inherited from void

Parameters:

NameType
widthnumber
heightnumber

Returns: void


setAttribute

setAttribute(attribute: WidgetAttribute, switchOn: boolean): void

Inherited from void

Parameters:

NameType
attributeWidgetAttribute
switchOnboolean

Returns: void


setContextMenuPolicy

setContextMenuPolicy(contextMenuPolicy: ContextMenuPolicy): void

Inherited from void

Parameters:

NameType
contextMenuPolicyContextMenuPolicy

Returns: void


setCursor

setCursor(cursor: CursorShape | QCursor): void

Inherited from void

Parameters:

NameType
cursorCursorShape | QCursor

Returns: void


setEnabled

setEnabled(enabled: boolean): void

Inherited from void

Parameters:

NameType
enabledboolean

Returns: void


setFixedSize

setFixedSize(width: number, height: number): void

Inherited from void

Parameters:

NameType
widthnumber
heightnumber

Returns: void


setFlexNodeSizeControlled

setFlexNodeSizeControlled(isSizeControlled: boolean): void

Inherited from void

sets whether the widget's size is controlled by someone else (for example a window's size is controlled by its frame when dragged).

Parameters:

NameTypeDescription
isSizeControlledboolean

Returns: void


setFont

setFont(font: QFont): void

Inherited from void

Parameters:

NameType
fontQFont

Returns: void


setGeometry

setGeometry(x: number, y: number, w: number, h: number): void

Inherited from void

Parameters:

NameType
xnumber
ynumber
wnumber
hnumber

Returns: void


setGraphicsEffect

setGraphicsEffect(effect: QGraphicsEffect‹any›): void

Inherited from void

Parameters:

NameType
effectQGraphicsEffect‹any›

Returns: void


setInlineStyle

setInlineStyle(style: string): void

Inherited from void

Parameters:

NameType
stylestring

Returns: void


setLayout

setLayout(parentLayout: NodeLayout‹QMenuBarSignals›): void

Inherited from void

Parameters:

NameType
parentLayoutNodeLayout‹QMenuBarSignals›

Returns: void


setMaximumSize

setMaximumSize(maxw: number, maxh: number): void

Inherited from void

Parameters:

NameType
maxwnumber
maxhnumber

Returns: void


setMinimumSize

setMinimumSize(minw: number, minh: number): void

Inherited from void

Parameters:

NameType
minwnumber
minhnumber

Returns: void


setMouseTracking

setMouseTracking(isMouseTracked: boolean): void

Inherited from void

Parameters:

NameType
isMouseTrackedboolean

Returns: void


setNativeMenuBar

setNativeMenuBar(nativeMenuBar: boolean): void

Inherited from RNMenuBar.setNativeMenuBar

Parameters:

NameType
nativeMenuBarboolean

Returns: void


setNodeParent

setNodeParent(parent?: Component): void

Inherited from void

Parameters:

NameType
parent?Component

Returns: void


setObjectName

setObjectName(objectName: string): void

Inherited from void

Overrides void

Parameters:

NameType
objectNamestring

Returns: void


setProperty

setProperty(name: string, value: QVariantType): boolean

Inherited from void

Parameters:

NameType
namestring
valueQVariantType

Returns: boolean


setProps

setProps(newProps: MenuBarProps, oldProps: MenuBarProps): void

Parameters:

NameType
newPropsMenuBarProps
oldPropsMenuBarProps

Returns: void


setStyleSheet

setStyleSheet(styleSheet: string): void

Inherited from void

Parameters:

NameType
styleSheetstring

Returns: void


setWindowFlag

setWindowFlag(windowType: WindowType, switchOn: boolean): void

Inherited from void

Parameters:

NameType
windowTypeWindowType
switchOnboolean

Returns: void


setWindowIcon

setWindowIcon(icon: QIcon): void

Inherited from void

Parameters:

NameType
iconQIcon

Returns: void


setWindowOpacity

setWindowOpacity(opacity: number): void

Inherited from void

Parameters:

NameType
opacitynumber

Returns: void


setWindowState

setWindowState(state: WindowState): void

Inherited from void

Parameters:

NameType
stateWindowState

Returns: void


setWindowTitle

setWindowTitle(title: string): void

Inherited from void

Parameters:

NameType
titlestring

Returns: void


show

show(): void

Inherited from void

Returns: void


showFullScreen

showFullScreen(): void

Inherited from void

Returns: void


showMaximized

showMaximized(): void

Inherited from void

Returns: void


showMinimized

showMinimized(): void

Inherited from void

Returns: void


showNormal

showNormal(): void

Inherited from void

Returns: void


size

size(): QSize

Inherited from void

Returns: QSize


styleSheet

styleSheet(): string

Inherited from void

Returns: string


testAttribute

testAttribute(attribute: WidgetAttribute): boolean

Inherited from void

Parameters:

NameType
attributeWidgetAttribute

Returns: boolean


update

update(): void

Inherited from void

Returns: void


updateGeometry

updateGeometry(): void

Inherited from void

Returns: void


windowOpacity

windowOpacity(): number

Inherited from void

Returns: number


windowState

windowState(): number

Inherited from void

Returns: number


windowTitle

windowTitle(): string

Inherited from void

Returns: string