I'm reading "Undocumented Secrets of matlab-java programming" by Yair Altman and try to change editor's font by means which are described in this book, but it has explicit examples only for color. Anyway, I managed to change font in matlab.prf by the following code:
FontName = "Consolas";
javaLangString = java.lang.String(FontName);
javaAwtFont = java.awt.Font(javaLangString,0,10);
It does change font in preferences but doesn't press "apply" button. In other words it doesn't refresh environment font but change it in configuration file (matlab.prf). In case of color it was solved by this:
It there any way to do this for font?