Create a Preview in my Plugin using Macro

Hi, I’m implementing a movement detecting plugin using macro language on Fiji. The program is designed to run on the .tiff file. I just want to know how I can add a Preview checkbox in the user interface, like Find Maxima…, to quickly visualize my chosen ROIs on the current slice without running the whole program.