• Good afternoon
    I am new to WordPress and still having (a lot of) trouble finding my way around. Asking about the one thing that bothered me from the very beginning will most likely be a very stupid question.
    Using Gutenberg -> edit blocks with text -> select parts or all of the text -> choose text color.
    However, the colors presented in the box are everything but appealing. When I choose “custom color”, I am presented with a color slider and a color field with related colors. Yet – I tried for hours on end a million times – , no matter what I do, I ALWAYS get colors that can best be described as “dirty”: some shade of red, green, blue or anything else mixed with a lot of soot. These colors give a very depressive impression.
    The other day I stumbled upon inserting a “classic block”. There one has the option of using the classic editor and THAT gives you the chance to choose from a color palette including the primary (pure) colors red, green and blue.
    Question: is there a trick to get those primary colors in the Gutenberg editor?
    So far all my efforts have failed and I would really appreciate some help with this.
    Thank you.

    • This topic was modified 3 years, 4 months ago by Jan Dembowski.

    The page I need help with: [log in to see the link]

Viewing 4 replies - 1 through 4 (of 4 total)
  • Hi @nyuwa. You can modify your theme to use theme.json or add_theme_support( 'editor-color-palette', array( /* insert settings here */ ) ) to change the colour options that appear in the colour picker.

    https://developer.www.ads-software.com/block-editor/how-to-guides/themes/theme-json/#presets
    https://developer.www.ads-software.com/block-editor/how-to-guides/themes/theme-support/

    For example:

    add_theme_support(
    	'editor-color-palette',
    	array(
    		array(
    			'name'  => 'Red',
    			'slug'  => 'red',
    			'color' => '#ff0000',
    		),
    		array(
    			'name'  => 'Green',
    			'slug'  => 'green',
    			'color' => '#00ff00',
    		),
    	)
    );
    
    Thread Starter nyuwa

    (@nyuwa)

    Thank you very much for your reply.
    Unfortunately, I have absolutely no idea what (and how) I am supposed to do with this coding. All I want to have, is a simple color picker, where I can choose a color I like – for PIECES OF TEXT and not the entire theme.
    Like the one, offered by the classic editor.
    Can that be so difficult?

    I am really sorry, that my lack of education causes so much trouble.

    I haven’t used it myself but maybe this plugin can help?

    https://www.ads-software.com/plugins/block-editor-colors/

    Thread Starter nyuwa

    (@nyuwa)

    Thank you.
    Probably I am simply too stupid for this.
    I installed this plugin (I tried similar plugins before that), changed two color settings and tried to apply those to a test page.
    No change at all – and an attempt at applying “highlight” (= supposed to be a dirty yellow) to a piece of text gives me an equally dirty green.
    Maybe I have to resign to the idea, that WordPress is not up to the task. Which appears to be very strange to me, since every single software I know of, is capable of offering a choice of colors, including those primary colors.

    I am really sorry for having wasted your time.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Font/background color’ is closed to new replies.