def get_tree(model=None):
if model is None:<EOL><INDENT>model = mx.cur_model()<EOL><DEDENT>treemodel = ModelTreeModel(model._baseattrs)<EOL>view = QTreeView()<EOL>view.setModel(treemodel)<EOL>view.setWindowTitle("<STR_LIT>" % model.name)<EOL>view.setAlternatingRowColors(True)<EOL>return view<EOL>
Get QTreeView object containing the model tree.

    Args:
        model: :class:`Model <modelx.core.model.Model>` object.
            Defaults to the current model.