[ Version ( since = "2.12" ) ]
public uint add_from_file (string filename) throws Error

Parses a file containing a GtkBuilder UI definition and merges it with the current contents of this.

Most users will probably want to use Builder.from_file.

If an error occurs, 0 will be returned and throws will be assigned a Error from the BuilderError , MarkupError or FileError domain.

It’s not really reasonable to attempt to handle failures of this call. You should not use this function with untrusted files (ie: files that are not part of your application). Broken Builder files can easily crash your program, and it’s possible that memory was leaked leading up to the reported failure. The only reasonable thing to do when an error is detected is to call error.



a Builder


the name of the file to parse


A positive value on success, 0 if an error occurred