Commit Graph

15 Commits

Author SHA1 Message Date
Matthias Clasen
defc3d8cbc builder-tool: Don't strip border-width
Strictly speaking, this would only have to be special-cased inside
GtkDialog, but lets just skip it altogether.
2015-07-19 13:18:30 -04:00
Matthias Clasen
f8b7623b3c builder-tool: Don't strip h/vexpand
Setting these properties has the side-effect of setting the
corresponding -set properties, which makes GTK+ behave subtly
different. So don't mess with these.
2015-06-25 07:01:26 -04:00
Matthias Clasen
4f115ad940 gtk-builder-tool: Some refactoring
Break out similar code into separate functions.
2015-05-02 17:39:05 -04:00
Matthias Clasen
9ff14a8188 gtk-builder-tool: Strip placeholders
glade likes to sprinkle <child><placeholder/></child> all
over the place - get rid of it.
2015-05-02 17:39:05 -04:00
Matthias Clasen
3b0e71cf9b gtk-builder-tool: Simplify non-translatable properties 2015-05-02 17:39:05 -04:00
Matthias Clasen
932e254688 gtk-builder-tool: Always emit translatable properties
Seems unlikely that these would ever have a default value,
but better safe than sorry.
2015-05-02 17:39:05 -04:00
Matthias Clasen
060c4f9c66 gtk-builder-tool: Handle cell properties
These were causing 'unknown property' warnings before.
2015-05-02 17:39:05 -04:00
Matthias Clasen
52bf6d52bb gtk-builder-tool: Add more exceptions 2015-05-02 11:55:57 -04:00
Matthias Clasen
b8548d27a1 gtk-builder-tool: Start an exception list
We have a number of cases where properties should have their
default value overridden in a subclass, but haven't because thats
annoying to do. We also have properties where the absence of
an explicit value has context-dependent meaning.
Add a list of exceptions for these cases.
2015-05-02 07:35:35 -04:00
Matthias Clasen
398399610a gtk-builder-tool: Add an enumerate command
This lists all the named objects from the .ui file.
2015-04-30 07:11:49 -04:00
Matthias Clasen
ec05339858 gtk-builder-tool: Validate templates
Catch an error that indicates the file looks like a template,
and then try again, this time with the template parsing API
of GtkBuilder. This is a little iffy, since we need to create
a 'fake' type and instance to pass in, but it works ok in
simple tests.
2015-04-30 06:19:10 -04:00
Matthias Clasen
d7523423d4 gtk-builder-tool: Separate commands
Add separate commands for validation and simplification.
2015-04-27 23:40:43 -04:00
Matthias Clasen
bf6a2deda0 Translate error messages 2015-04-27 19:10:10 -04:00
Matthias Clasen
169f29998f Do validation before simplification
Use GtkBuilder to parse the file first, and report any errors
it finds before using our own simple-minded parser to simplify.
2015-04-27 19:10:10 -04:00
Matthias Clasen
8bb5a14977 Add a simple commandline tool for ui files
This tool strips properties which are set to their
default value from .ui files.
2015-04-27 19:10:10 -04:00