My plugin works with a selected image, so if an image is not selected I'd like the button greyed out, which is what currently happens with buttons like cut or indent. Also, I'd like to emualate the behavior of the bold button, where text you've made bold will show the bold button pressed as long as cursor is on said text.
Googling is proving difficult. I've seen suggestions like the below, which definitely works to disable a button, but then I run into the problem of ever getting it re-enabled, heh.
CKEDITOR.instances.yourEditorInstance.commands.save.disable(); CKEDITOR.instances.yourEditorInstance.commands.save.enable();
Is there documentation specifically for what I'm trying to do? Ultimately that just being toggling button state, as if I'm able to do that the _right way_, I can figure out how to make it work specifically how I want.