Skip to content

Commit 3ecb1d4

Browse files
committed
Merge pull request sebp#32 from anarcat/patch-1
mention disconnect_by_func() function
2 parents b6a255e + 184c270 commit 3ecb1d4

1 file changed

Lines changed: 8 additions & 0 deletions

File tree

source/basics.txt

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,14 @@ has been connected to.
5353

5454
widget.disconnect(handler_id)
5555

56+
If you have lost the "handler_id" for some reason (for example the handlers
57+
were installed using :func:`Gtk.Builder.connect_sinals`), you can still
58+
disconnect a specific callback using the function :func:`disconnect_by_func`:
59+
60+
.. code-block:: python
61+
62+
widget.disconnect_by_func(callback)
63+
5664
Almost all applications will connect to the "delete-event" signal of the
5765
top-level window. It is emitted if a user requests that a toplevel window is
5866
closed. The default handler for this signal destroys the window, but does

0 commit comments

Comments
 (0)