Class: RubyQt6::QtWidgets::QTextEdit

Inherits:
QAbstractScrollArea show all
Defined in:
lib/qt6/qtwidgets/qtextedit.rb

Overview

Direct Known Subclasses

Bando::QTextEdit, QTextBrowser

Defined Under Namespace

Classes: AutoFormatting, AutoFormattingFlag, LineWrapMode

Constant Summary collapse

INITIALIZE_ARG_ERROR_MESSAGE =
"Could not resolve method call for #{name}#initialize\n" \
"  2 overload(s) were evaluated based on the types of Ruby parameters provided:\n" \
"    initialize(QWidget)\n" \
"    initialize(QString, QWidget)\n"

Instance Method Summary collapse

Constructor Details

#initialize(parent = nil) ⇒ QTextEdit #initialize(text, parent = nil) ⇒ QTextEdit

Overloads:

  • #initialize(parent = nil) ⇒ QTextEdit

    Parameters:

    • parent (QWidget) (defaults to: nil)
  • #initialize(text, parent = nil) ⇒ QTextEdit

    Parameters:

    • text (String, QString)
    • parent (QWidget) (defaults to: nil)


70
71
72
73
74
75
76
77
78
# File 'lib/qt6/qtwidgets/qtextedit.rb', line 70

def initialize(*args)
  parent = T.args_nth_delete_qwidget(args, -1)
  case args.size
  when 0 then _initialize(T.to_qstr(""), parent)
  when 1 then _initialize(T.to_qstr(args[-1]), parent)
  else raise ArgumentError, INITIALIZE_ARG_ERROR_MESSAGE
  end
  _take_ownership_from_ruby(self)
end