Using 'colordef' in my code (some rather old) gives "Warning: colordef will be removed in a future release." I can't find any clear guidance on a replacement. Probably something like set(0, ..?

 채택된 답변

Walter Roberson
Walter Roberson 2025년 2월 2일

0 개 추천

As of R2025a (currently in pre-release) there are new facilities for controlling desktop color schemes that overlap with colordef functionality; see https://www.mathworks.com/help/releases/R2025a/matlab/matlab_env/change-desktop-colors-and-select-dark-theme.html

댓글 수: 4

James
James 2025년 2월 2일
편집: James 2025년 2월 2일
Thanks, could be I'm after changing the axis line/surface (etc.) colours e.g. from Parula to HSV, I can't immediately see anything about that here, I'll play a bit.
set(groot, 'DefaultAxesColormap', hgv(256));
This is not something that would have been previously handled by colordef
James
James 2025년 2월 2일
ah, OK thanks that makes sense, groot is root of all handles hence 0 I guess.
Walter Roberson
Walter Roberson 2025년 2월 2일
set(groot) and set(0) are almost equivalent. I have noticed a few small differences between them, but I cannot recall what they are at the moment.

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

도움말 센터File Exchange에서 Color and Styling에 대해 자세히 알아보기

제품

릴리스

R2024b

태그

질문:

2025년 2월 2일

댓글:

2025년 2월 2일

Community Treasure Hunt

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

Start Hunting!

Translated by