Adds common window initializations and draw functions.