renathy
renathy

Reputation: 5345

tinymce: default toolbar specification

I am using tinymce editor. I am using default toolbars. I mean I am not specifying any additional toolbars:

<script type="text/javascript">
    tinymce.init({
        selector: "textarea",
        height: 400,
        statusbar: false,
        menubar:false
     });
  </script>

However, now I want to add "font-size" and "table" toolbars to the default. Can I find somewhere specification of default toolbars?

Here is how default editor looks like: enter image description here

I was trying to create toolbar option bymyself but I never get the same as in default. So I would like to find default tinymce toolbar specification and add there "table" and "fontsize" options.

Upvotes: 14

Views: 11574

Answers (2)

Ben Long
Ben Long

Reputation: 383

For TinyMCE 5, the default toolbar configuration is:

toolbar: 'undo redo | styleselect | bold italic | alignleft aligncenter alignright alignjustify | outdent indent'

More about TinyMCE toolbar configuration here: https://www.tiny.cloud/blog/tinymce-toolbar

Upvotes: 1

Axi
Axi

Reputation: 1785

You should have figured it out by now but for the next one finding this, this should do the trick:

<script type="text/javascript">
    tinymce.init({
         selector: "textarea",
         height: 400,
         statusbar: false,
         menubar:false,
         toolbar: "undo redo | styleselect | bold italic | alignleft aligncenter alignright alignjustify | bullist numlist outdent indent | table | fontsizeselect"
      });
</script>

So default one is:

         toolbar: "undo redo | styleselect | bold italic | alignleft aligncenter alignright alignjustify | bullist numlist outdent indent"

Upvotes: 33

Related Questions