remove macros and source for figures