Gtk.EntryBuffer.prototype.set_text

function set_text(chars:String, n_chars:Number):void {
    // Gjs wrapper for gtk_entry_buffer_set_text()
}

Sets the text in the buffer.

This is roughly equivalent to calling Gtk.EntryBuffer.prototype.delete_text and Gtk.EntryBuffer.prototype.insert_text.

Note that n_chars is in characters, not in bytes.

Since 2.18

chars

the new text

n_chars

the number of characters in @text, or -1