builder-tool: Rename GtkHeaderBar:custom-title to title-widget

Add a test.
This commit is contained in:
Alexander Mikhaylenko 2020-05-01 18:48:03 +05:00
parent 739f681076
commit 6b4bed2c7a
3 changed files with 29 additions and 0 deletions

View File

@ -733,6 +733,7 @@ maybe_rename_property (Element *element, MyParserData *data)
{ "GtkWidget", "margin-left", GTK_TYPE_WIDGET, PROP_KIND_OBJECT, "margin-start", { NULL, NULL, NULL } },
{ "GtkWidget", "margin-right", GTK_TYPE_WIDGET, PROP_KIND_OBJECT, "margin-end", { NULL, NULL, NULL } },
{ "GtkHeaderBar", "show-close-button", GTK_TYPE_HEADER_BAR, PROP_KIND_OBJECT, "show-title-buttons", { NULL, NULL, NULL } },
{ "GtkHeaderBar", "custom-title", GTK_TYPE_HEADER_BAR, PROP_KIND_OBJECT, "title-widget", { NULL, NULL, NULL } },
{ "GtkStack", "homogeneous", GTK_TYPE_STACK, PROP_KIND_OBJECT, "hhomogeneous", { "vhomogeneous", NULL, NULL } }
};
int i, k, l;

View File

@ -0,0 +1,12 @@
<?xml version="1.0" encoding="UTF-8"?>
<interface>
<object class="GtkWindow" id="window1">
<child type="titlebar">
<object class="GtkHeaderBar" id="headerbar1">
<property name="show-title-buttons">1</property>
<property name="title-widget">box1</property>
</object>
</child>
</object>
<object class="GtkBox" id="box1"/>
</interface>

View File

@ -0,0 +1,16 @@
<?xml version="1.0" encoding="UTF-8"?>
<interface>
<!-- interface-requires gtk+ 3.0 -->
<object class="GtkWindow" id="window1">
<child type="titlebar">
<object class="GtkHeaderBar" id="headerbar1">
<property name="visible">True</property>
<property name="show-close-button">True</property>
<property name="custom-title">box1</property>
</object>
</child>
</object>
<object class="GtkBox" id="box1">
<property name="visible">True</property>
</object>
</interface>