Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

When you toggle a style that is set by style_format, ExecCommand is not triggered #4814

JonathanHouck opened this Issue Feb 6, 2019 · 3 comments


None yet
3 participants
Copy link

JonathanHouck commented Feb 6, 2019

Do you want to request a feature or report a bug? Bug

What is the current behavior? When you set a style_format in the Content formatting options, ExecCommand (editor.on('ExecCommand', function (e) { }) is not triggered when you toggle the style.

If the current behavior is a bug, please provide the steps to reproduce and if possible a minimal demo of the problem via or similar.

What is the expected behavior? The ExecCommand should be triggered when you toggle the style.

Which versions of TinyMCE, and which browser / OS are affected by this issue? Did this work in previous versions of TinyMCE? Tested in Google Chrome, this worked in version 4.x

@lnewson lnewson added the 5.x label Feb 21, 2019


This comment has been minimized.

Copy link

lnewson commented Mar 1, 2019

The cause of this looks to be that the new UI moved away from calling execCommand('mceToggleFormat', false, format), however I'm not sure if that was intentional or even if it's expected that toggling should trigger a command since it's a UI action. As such I'll have to talk to the team and find out what's expected.

Out of curiosity though and if it's possible to elaborate, I'd like to know what your use case is here?


This comment has been minimized.

Copy link

lnewson commented Mar 4, 2019

Talked to the team and there wasn't an explicit reason this was changed and was likely just on oversight. I'll log a task for us to revert back to using the mceToggleFormat command.


This comment has been minimized.

Copy link

wonderbugtiny commented Mar 19, 2019

This should now be fixed in 5.0.3. Please let us know if you find any further problems!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.