change color of words in matlab figure text

78 visualizaciones (últimos 30 días)
Maurilio Matracia
Maurilio Matracia el 23 de Feb. de 2022
Comentada: Maurilio Matracia el 29 de Sept. de 2022
Hello everyone,
I have a matlab figure... is it possible to make a textbox with different colors for each word?
Thanks in advance
  1 comentario
Maurilio Matracia
Maurilio Matracia el 29 de Sept. de 2022
Hi everyone, I found out that using something like '\color[rgb]{0,.447,.741}text1 \color[rgb]{1,0,0}text2' solves the problem.
However, this works only on the tex interpreter, does anyone know how to make it work with latex interpreter?

Iniciar sesión para comentar.

Respuestas (1)

KSSV
KSSV el 23 de Feb. de 2022
Editada: KSSV el 23 de Feb. de 2022
Two options:
  1. USe GUI (matlab's figure) . Go to edit, insert text box, add the word, change the font color and size etc.
  2. Read about the function text.
  2 comentarios
Maurilio Matracia
Maurilio Matracia el 23 de Feb. de 2022
Thank you.
However, I think that will only allow to change the entire text.
What I am asking for is to get a text with different colors for each word.
KSSV
KSSV el 23 de Feb. de 2022
Do the same for each word.

Iniciar sesión para comentar.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by