Gtk.TextView.prototype.add_child_in_window
function add_child_in_window(child:Gtk.Widget, which_window:Gtk.TextWindowType, xpos:Number, ypos:Number):void { // Gjs wrapper for gtk_text_view_add_child_in_window() }
Adds a child at fixed coordinates in one of the text widget's windows.
The window must have nonzero size (see Gtk.set_border_window_size). Note that the child coordinates are given relative to the Gdk.Window in question, and that these coordinates have no sane relationship to scrolling. When placing a child in #GTK_TEXT_WINDOW_WIDGET, scrolling is irrelevant, the child floats above all scrollable areas. But when placing a child in one of the scrollable windows (border windows or text window), you'll need to compute the child's correct position in buffer coordinates any time scrolling occurs or buffer changes occur, and then call Gtk.move_child to update the child's position.
- child
- which_window
which window the child should appear in
- xpos
X position of child in window coordinates
- ypos
Y position of child in window coordinates