Why can't I get 'diaryfile', 'more', and other properties from groot?

1 view (last 30 days)
In R2014b, groot was introduced as the root object, though "0" can still be used to refer to it. So now I can use the following commands to do return the same value:
r = groot;
ss1 = r.ScreenSize
ss2 = get(r, 'ScreenSize')
ss3 = get(0, 'ScreenSize')
But if I try the same thing with the 'More' property...
m1 = r.More
m2 = get(r, 'More')
m3 = get(0, 'More')
The first two return errors, but the third one works. The same holds true for 'Diary' and 'DiaryFile' properties. Also, if I type get(0,'Scr in the command window and hit tab, MATLAB suggests three different completions ( ScreenDepth, ScreenPixelsPerInch, and ScreenSize). But if I type get(0,'Mor and press tab, I get "No Completions Found."
I've been trying to convert to using more object-oriented syntax like all the cool kids are doing, but it seems that I've been thwarted in this instance. Is there a way to control command-window paging and the diary functions using groot? Or does the fact that the documentation for the diary command -- even in R2017b -- still tells me to use the get(0,'Diary') syntax mean that this functionality is being deprecated?
  1 Comment
Johnny B
Johnny B on 1 Sep 2019
I've found in the 2014b release notes, under "Properties and syntaxes being removed or changed" that "The root properties CommandWindowSize, Diary, DiaryFile, Echo, Format, FormatSpacing, Language, More, RecursionLimit, BeingDeleted, ButtonDownFcn, UIContextMenu, Clipping, CreateFcn, DeleteFcn, BusyAction, Interruptible, HitTest, Selected, SelectionHighlight, and Visible" are removed and that the suggested action is to 'Remove all instances of root properties that are no longer supported. Use supported root properties." But if I type "doc get(0" at the R2018a command prompt, there are 51 (!) results returned. The official MathWorks documentation four years after removing this functionality and telling me to ""use supported root properties" is still telling me to use get(0,'Diary'), get(0,'DiaryFile'), get(0,'Format'), get(0,'More'), and possibly some others (I didn't slog through all 51 results that were returned).
Is there a MathWorks-approved method of accessing this functionality other than using the properties I've pointedly been told not to use?

Sign in to comment.

Answers (0)

Categories

Find more on Just for fun in Help Center and File Exchange

Tags

Products

Community Treasure Hunt

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

Start Hunting!