GtkInspector
GtkInspector is the built-in interactive debugging support in GTK+. It was added in GTK+ 3.14, based on a copy of the well-estabished gtkparasite.
To enable the debugger, you can use the Control-Shift-I or Control-Shift-D keyboard shortcuts, or include the value interactive in the GTK_DEBUG environment variable. The keyboard shortcuts can be disabled with the enable-inspector-keybinding key in the org.gtk.Settings.Debug GSettings schema.
Ideas for further development
GtkInspector is already pretty useful, but it could be even better. Here are some ideas for things to work on, in no particular order. Your help is appreciated!
Link from GtkActionable::action-name properties to the action they refer to
Show GObject memory statistics: how many objects of each type are alive. Needs support in GObject 354457
Show mainloop statistics: how many sources are attached, how often do they fire, how long they take ... Needs support in GLib 710723
- Add a more structured css editor. Look at any major web browser for ideas
- Capture g_log output and show it - recursion danger here, if showing the log generates more logs
- Save custom css
- Add logging (property changes, traced signal emissions, etc)
- Allow editing of cell renderer attributes
- Visual box model debugging: highlight margin, borders, etc
- Show frame clock information: frame rate, animations, etc
Bring back scripting. gtkparasite has support for python scripting. The code is still there in the inspector, just not enabled to avoid a python dependency. May base it on https://git.gnome.org/browse/archive/gscript instead ?
- Add a D-Bus api; being able to introspect the application and inject changes from an IDE is a powerful idea
- Isolate the inspector window from global state changes (style, text direction, visual debugging,...) if they come from the inspector itself. We currently do it (in a hacky way) just for text direction
- Show child types (ie. 'center', 'title', 'tab' etc). Needs GTK+ api
- Indicate modified properties in the UI, and add a way to reset them

