Needed to add #ifdef __cplusplus in the right places for it to still work with Obj-C.
Added rectangle based progress meter