MyBB Community Forums

Full Version: SCEditor textarea text color?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hi, I'm trying to edit the css of sceditor so it would match my theme's colors. I've already managed to change everything I wanted in default.css except for one thing which is the color of text in textarea. It's #111 by default. Using Firebug I found out I need to edit:
/jscripts/sceditor/textarea_styles/jquery.sceditor.default.css
and change #111 to whichever color I wanted. I edited this file and saved it, but it had no effect.
Edited file: http://hacknslash.pl/jscripts/sceditor/t...efault.css
it's now "color: #b3b3b3;" but it still appears as #111 in textarea + when I use Firebug @ textarea I see this:
http://i.imgur.com/wXdF8my.png - #111 ?

textarea screenshots:
http://screenshu.com/static/uploads/temp...u264no.jpg
http://screenshu.com/static/uploads/temp...86sxof.jpg

it's mybb 1.8.5
Try to change /jscripts/sceditor/textarea_styles/jquery.sceditor.mybb.css

Firebug gives that for me.

EDIT
Did you try to change it (temporarily) with Firebug?
It can be a cache issue. Reset caches in AdminCP
I changed jquery.sceditor.default.css instead of (...).mybb.css, because I have "Default" editor selected.

Changing it in Firebug changes the text color.
(2015-06-10, 03:02 PM)Akiro Wrote: [ -> ]I changed jquery.sceditor.default.css instead of (...).mybb.css, because I have "Default" editor selected.

Changing it in Firebug changes the text color.

Try to reset your caches in AdminCP


EDIT
I tried it with my test forum, and have exactly the same. As far as I can see sceditor has its own cache, but I cannot find how to force reloading of that.
I solved the problem. Had to add this to editpost template:
<link rel="stylesheet" href="{$mybb->settings['bburl']}/jscripts/sceditor/textarea_styles/jquery.sceditor.default.css" type="text/css" media="all" />
Nice, I'll remember that!! Smile

But then also in newreply, newthread and private_send.
I don't think this is hi-jacking the thread at all, as it is exactly up the line with what you were doing. But I am using the JAMPS Gamer Blue theme, and the SCEditor default in 1.8 is a white background, black text. This is silly since posts are white text on blackish background.

How did you accomplish this? I cant identify a *|default|global.css style tag to modify, and all of the styles are as you found, hard coded into the js. There is no MyBB AdminCP edit options to update this, or affect the SCEditor, so its apparent the only way to update it is to edit the js directly?

with that said, what files are the "right" files? what is the load order? I'm guessing the problem you had was a local browser cache? Perhaps we can put an expires tag in it? Please someone kindly elaborate how to make theme edits to sceditor

I think I have gotten a bit farther, it at least works for me. At this point, it seems the answer is yes, you have to modify an existing themes js set, vice any plugin control; that said, I see in MyBB v1.6 the old SCEditor plugin by the author is no longer supported, but that plugin worked and allowed customization.

I'd like to know why the MyBB team went backwards (deprecated functionality from the plugin author, implemented a partial implementation, and left off such a valuable tweak! - I'm guessing there may be a great reason, but I'd love to ask for it back. As I learn more about MyBB I may submit a plugin/fix of my own, but would love it if someone who knows this well would do it?)/.

In either case.... here is what I found (hopefully this will help others in the same scenario)

For the basic QUICK Edit capability in MyBB, the global.css has .editor styles you can edit. (that one is easy).

For the current/applied theme, whatever it is, you need to go to the themes tab, (e.g., Home->Themes->THEM_NAME)
On that screen, there is a list of default editors included/installed. Take a moment to view them all and pick your favorite. (You can select the theme, apply it, and view a thread reply/edit without any fuss).

Once you have a theme in mind you want to work from, go to your FORUM-URL path: ./jscripts/sceditor/editor_themes
Here you will find the themes (*.css) you saw in the drop down. Now make a copy of the theme you liked, and set an appropriate name. This will allow you to change MOST of the styles for codebuttons/sceditor.

Tweak as needed....

Then, you aren't quite done yet.

To modify the default text color, navigate to: jscripts/sceditor/textarea_styles
Here, you will need to repeat the steps as mentioned above. USE THE SAME NAMING SCHEME.

make your final .css edits and save.

I found I didn't need to rebuild or recache, or anything. I just refreshed and it worked. It seems to me this is a very easy method to update. Might even be just as easy to include the sceditor *.css files in the Admin CP style sheet editor.

I attached a zip/7z of the "modern" to "modern_dark" mod I made. All I really did was change background/bg-color to #171717, and color to #fcfcfc.

It boggles my mind why these are excluded???
(2015-06-10, 03:53 PM)Akiro Wrote: [ -> ]I solved the problem. Had to add this to editpost template:
<link rel="stylesheet" href="{$mybb->settings['bburl']}/jscripts/sceditor/textarea_styles/jquery.sceditor.default.css" type="text/css" media="all" />

I have the same problem. Changing jquery.sceditor.default.css seems to make no difference.

Can someone please tell me where I can find the "editpost" template? I can't find the correct place to add the code to make changes to sceditor - jquery.sceditor.default.css - take effect.