-
Sub-task
-
Resolution: Fixed
-
Minor
-
2.4
-
MOODLE_24_STABLE
-
MOODLE_24_STABLE
-
w33_
MDL-33041_m24_tinymceplugins -
(NOTE: As this is a new feature, it is probably appropriate for Moodle 2.4. The version is set to 2.3 because there isn't an entry for 2.4 yet.)
At present there are 4 moodle core custom plugins inside TinyMCE. These are stored within the versioned TinyMCE folder, and hardcoded into the TinyMCE options in the lib.php file. This approach sucks because:
- The Moodle plugins shouldn't really be stored inside the third-party library folder, which changes every time the TinyMCE version is updated.
- It is impossible to include extra TinyMCE plugins in a Moodle installation without making a change to core code (lib.php), as well as putting your own plugins inside that third-party library folder.
My proposal is as follows:
- Create a plugins folder directly inside lib/editor/tinymce.
- As editors cannot have subplugins (only modules can), the contents of this folder will not be standard Moodle plugins, but will be a lightweight plugin type defined and handled specially within editor/tinymce.
- lib.php for these plugins contains a suitable plugin class which will be able to do the following:
a) Modify the TinyMCE options (e.g. add or remove plugins from the list of buttons, in whatever row)
b) Return details of their own TinyMCE plugin name and JavaScript file(s) so it can be passed as parameter to the M.editor_tinymce.init_editor or something, so that it can end up calling this function before tinyMCE.init (example from Tim's plugin):
tinymce.PluginManager.load('supsub', M.cfg.wwwroot + '/lib/editor/supsub/supsub_plugin.js');
|
- Move the existing Moodle TinyMCE plugins into this new framework and remove the hardcoded conditions (about whether to use them or not) from the lib.php so that they are equivalent level to any new custom plugins that users may add.
- blocks
-
MDL-33982 Insert/edit embedded media dialog no longer displays a preview
- Closed
- caused a regression
-
MDL-34956 parent fetching regression in pluginlib
- Closed
-
MDL-37965 when loading sup sub editor, TinyMCE editor minify failing with "500 Internal Server Error"
- Closed
- has been marked as being related by
-
MDL-20139 Allow admins to configure which TinyMCE toolbar buttons are used on their site
- Closed
-
MDL-26347 Allow plug-ins to define new user profile fields
- Closed
-
MDL-36059 TinyMCE: make possible to define parameters in the theme
- Closed
- is duplicated by
-
MDL-33737 The tooltip of the Moodle Media button on the HTML editor is not translated
- Closed
-
MDL-13865 Allow buttons that should be displayed in the HTML editor
- Closed
-
MDL-33390 Improve TinyMCE support to display video previews from video repositories
- Closed
-
MDL-34154 Allow configuration of plugins of the TinyMCE editor to open up to plugin contributions
- Closed
- will help resolve
-
MDL-33982 Insert/edit embedded media dialog no longer displays a preview
- Closed
-
MDL-35033 Images and tables cannot be resized using controls in the TinyMCE editor when using Webkit browsers
- Closed