This stops crash when loading projects but doesn't fix the issue.

Re #7117
Renamed UserFunction class in MantidPlot. Re #7117
Changes to qtiplot UserFunction to make it work better with Mantid.

Re #7117
Trying to guard some pointers. Re #7117.

MantidPlot crashes when a MantidMatrix and a 3D graph are shown and
you delete the underlying workspace in the dock widget. I am trying
to find its cause.
Dettached MantidMatrixFunction from MantidMatrix.

Removed some deletes. Re #7117
Merge branch 'bugfix/7117_qtiplot_objects_crash' into develop