The PlainTextEdit component provides ability to add and manipulate native editable text field widgets. It is based on NodeGui's QPlainTextEdit.


import React from "react";
import { Renderer, PlainTextEdit, Window } from "@nodegui/react-nodegui";
const plainTextRef = React.createRef();
const App = () => {
React.useEffect(() => {
plainTextRef.current.addEventListener("textChanged", () =>
return (
<PlainTextEdit ref={plainTextRef} />
Renderer.render(<App />);







Optional attributes

attributes? : WidgetAttributesMap

Inherited from ViewProps.attributes

Prop to set the Widget Attributes. example: <View attributes={{[WidgetAttributes.WA_Disabled]: true}} />

Optional cursor

cursor? : CursorShape | QCursor

Inherited from ViewProps.cursor

Sets the window mouse cursor. QWidget: setCursor

Optional enabled

enabled? : undefined | false | true

Inherited from ViewProps.enabled

Sets the property that tells whether the widget is enabled. In general an enabled widget handles keyboard and mouse events; a disabled widget does not. QWidget: setEnabled

Optional geometry

geometry? : Geometry

Inherited from ViewProps.geometry

Sets the screen position as well as size of the widget. QWidget: setGeometry

Optional id

id? : undefined | string

Inherited from

Sets the object name (id) of the widget in Qt. Object name can be analogous to id of an element in the web world. Using the objectName of the widget one can reference it in the Qt's stylesheet much like what we do with id in the web world. QWidget: setObjectName

Optional maxSize

maxSize? : Size

Inherited from ViewProps.maxSize

Sets the maximum size of the widget. QWidget: setMaximumSize

Optional minSize

minSize? : Size

Inherited from ViewProps.minSize

Sets the minimum size of the widget. QWidget: setMinimumSize

Optional mouseTracking

mouseTracking? : undefined | false | true

Inherited from ViewProps.mouseTracking

Sets the property that tells whether mouseTracking is enabled for the widget. QWidget: setMouseTracking

Optional on

on? : Partial‹WidgetEventListeners | QPlainTextEditSignals›

Inherited from ViewProps.on

Prop to set the event listener map. See Handlong Events

Optional placeholderText

placeholderText? : undefined | string

Optional pos

pos? : Position

Inherited from ViewProps.pos

Sets the screen position of the widget. QWidget: move

Optional readOnly

readOnly? : undefined | false | true

Optional ref

ref? : any

Inherited from ViewProps.ref

Prop to set the ref. The ref will return the underlying nodegui widget.

Optional size

size? : ViewSize

Inherited from ViewProps.size

Sets both the minimum and maximum sizes of the widget. QWidget: setFixedSize

Optional style

style? : undefined | string

Inherited from

Sets the inline stylesheet property. QWidget: setInlineStyle

Optional styleSheet

styleSheet? : undefined | string

Inherited from ViewProps.styleSheet

Sets the property that holds the widget's style sheet. QWidget: setStyleSheet

Optional text

text? : undefined | string

Optional visible

visible? : undefined | false | true

Inherited from ViewProps.visible

Shows or hides the widget and its children. QWidget: show

Optional windowFlags

windowFlags? : WindowFlagsMap

Inherited from ViewProps.windowFlags

Prop to set the Widget flags. example: <View windowFlags={{[WindowType.SplashScreen]: true}} />

Optional windowIcon

windowIcon? : QIcon

Inherited from ViewProps.windowIcon

Sets the window icon. QWidget: setWindowIcon

Optional windowOpacity

windowOpacity? : undefined | number

Inherited from ViewProps.windowOpacity

This property holds the level of opacity for the window. QWidget: setWindowOpacity

Optional windowState

windowState? : WindowState

Inherited from ViewProps.windowState

Sets the window state. QWidget: setWindowState

Optional windowTitle

windowTitle? : undefined | string

Inherited from ViewProps.windowTitle

Sets the window title property. QWidget: setWindowTitle