PDA

View Full Version : Changing the default colors in the text editor drop-down (picker, swatch, selector)


getwhatuask4
04-19-2014, 03:56 AM
Hey,

I have been searching the forums for a solution to how to swap out the colors in the WYSIWYG text editor so as to better fit my site's overall style. Especially, I would like to remove certain colors and add other colors in their place.

I see a few people asking this question in previous versions of VB, but I am running 4.2.2

Any help much appreciated!

TheLastSuperman
04-19-2014, 05:08 AM
This will help with the rest of the site - https://vborg.vbsupport.ru/showthread.php?t=256370

For the editor colors try looking under the stylevars in the style manager, there will be a family of editor stylevars listed simply scroll to find ;).

getwhatuask4
04-19-2014, 11:24 AM
Sorted! :-)

After having a look here (https://vborg.vbsupport.ru/showthread.php?t=276993&highlight=adding+colors+to+the+color+swatch+palett e+in+the+Quick+Editor+WYSIWYG+editor) as well as many other places on this forum, I finally found the correct location and made the easy edit so as to replace the colors I wanted to swap out.

After changing the files outlined in that post (to no effect), the location that actually controls this color swatch is as follows -

httpdocs/clientscript/ckeditor/ckeditor.js

Simply replace the hex values with the ones you want at both locations in the file, one near the top and one near the bottom.

I would not suggest adding extra colors as they will not fit within the established frame.

(strangely a search of the entire site data did not pick this file up as containing the color codes that did in fact reside here, so it took a fair bit of poking around..and a bit of luck)

Man, that was a mission for something so simple... so hopefully this helps someone else!

*Note: by the time I had finished, I had added the desired colors to almost every file that contained color arrays etc, but I don't think that made any difference until I found the right one - but if you do this and it doesn't work for you then I can always let you know which other ones I also adjusted..

--------------- Added 1397910923 at 1397910923 ---------------

This will help with the rest of the site - https://vborg.vbsupport.ru/showthread.php?t=256370

For the editor colors try looking under the stylevars in the style manager, there will be a family of editor stylevars listed simply scroll to find ;).

Yes that is precisely where I thought this simple option might be found, but if you examine my question more carefully you will see that what I was seeking to do was to adjust the default colors in the drop-down picker menu within the WYSIWYG editor at every level of the site, and in the end I had to go far far farther afield in my quest :'(

This could be a simple option in the stylevars, after all, almost all sites have favorite header and highlight colors that suit their theme etc.

Thanks for your suggestion anyway! Happy to at least get a fast response...