Translate python errors to exceptions during fit func calls.

Avoiding the boost python wrappers means we have to handle this too.
Refs #970
Fix ExamplePeakFunction & test. Refs #970
Add Example1DFunction. Refs #970
Switch to AlgorithmFactory.subscribe rather than registerAlgorithm

since the latter is now deprecated. Refs #970
Merge branch 'feature/970_python_fitfunctions' into develop