If I wanted to overwrite a function in a core plugin, how would I go about it? I tried to make a plugin that overwrote some functionality in a core plugin, but the core plugins always seem to get loaded last of all plugins.
The plugin I want to overwrite in this case is styles. I just want to overwrite individual methods inside the plugin, not the whole plugin.
The plugin I want to overwrite in this case is styles. I just want to overwrite individual methods inside the plugin, not the whole plugin.

Re: Overwrite a core plugin?
/** * @file Sample plugin for override core( native ) functionality in the editor. */ CKEDITOR.plugins.add( 'override', { init : function( editor ) { // Leave it emtpy for now... }, afterInit : function( editor ) { // Override core API here. var old = CKEDITOR.style.prototype.apply; CKEDITOR.style.prototype.apply = function() { // My overrides here... old.apply( this, arguments ); }; } } );Re: Overwrite a core plugin?
var overrideLoader = new CKEDITOR.resourceManager( '_source/' + // @Packager.RemoveLine 'plugins/', 'plugin' ); editor.on('pluginsLoaded', function() { overrideLoader.load(CKEDITOR.config.overridePlugins.split(','), function() { }); });Your way seems better, though.
Now that I've got a way to override, I have another problem. All the internal functions of the plugin are wrapped in an anonymous function, so even if I overwrite one of the style.methods, the new method can't access any of the other functions because it's no longer in the same scope. Is there a way around this or am I pretty much boned?
I really want the ability to modify\customize small bits of functionality without having to simply overwrite the entire plugin.
Re: Overwrite a core plugin?