forked from AuroraMiddleware/gtk
inspector: Add a few more debug flags
Add check buttons for GTK_DEBUG=constraints and GTK_DEBUG=layout in the logs page.
This commit is contained in:
parent
378e594f75
commit
95fc81c565
@ -76,6 +76,8 @@ struct _GtkInspectorLogs
|
||||
GtkWidget *printing;
|
||||
GtkWidget *tree;
|
||||
GtkWidget *text;
|
||||
GtkWidget *constraints;
|
||||
GtkWidget *layout;
|
||||
|
||||
GdkDisplay *display;
|
||||
};
|
||||
@ -170,6 +172,8 @@ flag_toggled (GtkWidget *button,
|
||||
update_flag (logs->printing, &flags, GTK_DEBUG_PRINTING);
|
||||
update_flag (logs->tree, &flags, GTK_DEBUG_TREE);
|
||||
update_flag (logs->text, &flags, GTK_DEBUG_TEXT);
|
||||
update_flag (logs->constraints, &flags, GTK_DEBUG_CONSTRAINTS);
|
||||
update_flag (logs->layout, &flags, GTK_DEBUG_LAYOUT);
|
||||
gtk_set_display_debug_flags (logs->display, flags);
|
||||
}
|
||||
|
||||
@ -211,6 +215,8 @@ gtk_inspector_logs_class_init (GtkInspectorLogsClass *klass)
|
||||
gtk_widget_class_bind_template_child (widget_class, GtkInspectorLogs, printing);
|
||||
gtk_widget_class_bind_template_child (widget_class, GtkInspectorLogs, tree);
|
||||
gtk_widget_class_bind_template_child (widget_class, GtkInspectorLogs, text);
|
||||
gtk_widget_class_bind_template_child (widget_class, GtkInspectorLogs, constraints);
|
||||
gtk_widget_class_bind_template_child (widget_class, GtkInspectorLogs, layout);
|
||||
gtk_widget_class_bind_template_callback (widget_class, flag_toggled);
|
||||
|
||||
gtk_widget_class_set_layout_manager_type (widget_class, GTK_TYPE_BOX_LAYOUT);
|
||||
|
@ -215,6 +215,18 @@
|
||||
<signal name="toggled" handler="flag_toggled"/>
|
||||
</object>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkCheckButton" id="constraints">
|
||||
<property name="label">Constraints</property>
|
||||
<signal name="toggled" handler="flag_toggled"/>
|
||||
</object>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkCheckButton" id="layout">
|
||||
<property name="label">Layout</property>
|
||||
<signal name="toggled" handler="flag_toggled"/>
|
||||
</object>
|
||||
</child>
|
||||
</object>
|
||||
</child>
|
||||
</object>
|
||||
|
Loading…
Reference in New Issue
Block a user