Use var.
Made some methods static.
Allow max number of output colours to be specified.

Preliminary testing seems positive, but more testing is needed.
Optimised usings.
Removed redundant return statement.
Use var.