change kodualcolorbutton about to simply code.
This doesn't prevent a crash when closing all available documents, sadly.