How do I programmatically switch to Dark Mode (Dark Theme) in R2025a?

197 ビュー (過去 30 日間)
Mike Croucher
Mike Croucher 2025 年 1 月 13 日 20:44
編集済み: Adam Danz 2025 年 1 月 14 日 19:00
I am running R2025a pre-release. What are the commands to switch to dark mode?

採用された回答

Mike Croucher
Mike Croucher 2025 年 1 月 13 日 20:44
編集済み: Mike Croucher 2025 年 1 月 13 日 20:48
This is supported from R2025a onwards. This is what you need to do
>> s = settings;
>> s.matlab.appearance.MATLABTheme.PersonalValue = "Dark";
  1 件のコメント
Adam Danz
Adam Danz 2025 年 1 月 13 日 20:48
編集済み: Adam Danz 2025 年 1 月 14 日 19:00
And for figures,
theme('dark') % light | auto
% Or
theme(fig,'dark')
% Or
fig = figure(Theme='dark')
% or
fig.Theme = 'dark';

サインインしてコメントする。

その他の回答 (1 件)

Michelle Hirsch
Michelle Hirsch 2025 年 1 月 13 日 21:28
A few more notes:
  • The default behavior is to match your system theme. So, if your system theme is Dark, MATLAB is dark.
  • There's a setting (aka "preference") for it, too. An easy way to get there is to =just search for something like "dark" in the new search bar:

カテゴリ

Help Center および File ExchangeEnvironment and Settings についてさらに検索

タグ

製品

Community Treasure Hunt

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

Start Hunting!

Translated by