Fixed some minor portability issues, separated GUI constants from algorithm constants