Defining a simple function with text/string 'on'
Ältere Kommentare anzeigen
The Idea I'm thinking about really is simple and actually just for getting used to 'functions'
My Code is just based on:
ax = gca
ax.GridColor = [1, 1, 1];
set(ax,'color','k')
I can actually copy it in any script wher plots are included for getting a dark background. But it just strikes me as it would be easier for such things to have a simple command like grid on
So maybe you see where I am getting at: I want a function like
darkmode('Color',[1,1,1])
or simply
darkmode on
as short-cut for the code above.
It's not a huge reduction, but I could actually draw a lot of the mechanism.
2 Kommentare
Stephen23
am 18 Mai 2021
@Niklas Kurz: what is your question?
Niklas Kurz
am 20 Mai 2021
Akzeptierte Antwort
Weitere Antworten (0)
Kategorien
Mehr zu Functions finden Sie in Hilfe-Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!