diff options
author | Matthias Clasen <mclasen@redhat.com> | 2019-03-28 19:28:05 -0400 |
---|---|---|
committer | Matthias Clasen <mclasen@redhat.com> | 2019-03-28 19:28:05 -0400 |
commit | c30fc92b3e1030394a287d8dec5a8c4ec015ca46 (patch) | |
tree | 557fd9c7e913431e7c6f5f4bcd680165de620689 | |
parent | 7222bda146713f83829848389d2926e62ed03553 (diff) | |
download | gtk+-c30fc92b3e1030394a287d8dec5a8c4ec015ca46.tar.gz |
builder-tool: Don't strip the xml declaration
This is useful for interoperability with other tools.
-rw-r--r-- | gtk/tools/gtk-builder-tool-simplify.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/gtk/tools/gtk-builder-tool-simplify.c b/gtk/tools/gtk-builder-tool-simplify.c index 2c7f4e52cf..44f5f59e53 100644 --- a/gtk/tools/gtk-builder-tool-simplify.c +++ b/gtk/tools/gtk-builder-tool-simplify.c @@ -1265,8 +1265,15 @@ dump_element (Element *element, } static void +write_xml_declaration (FILE *output) +{ + g_fprintf (output, "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n"); +} + +static void dump_tree (MyParserData *data) { + write_xml_declaration (data->output); dump_element (data->root, data->output, 0); } |