Added numbered figure handling

Added numbered figures handling.