Added support for captions in Q/gallery