fixed a bug in the ui that would not execute formatting if the wrong part of the button was clicked