In what way is the new R2021b Editor UI "improved"?
Afficher commentaires plus anciens
I find the "new and improved" Editor UI in R2021b to be extremely irritating, in no way better than R2021a. How did this get past SQA? Following is a list of miscellaneous nuisances that I've run into:
The text search/replace box obscures the top text line in my file, which is a problem if the search text is obscured.
It isn't obvious how to revert to previous search strings in the search box.
I want to rename a variable in my m-file, and before doing so I want to ensure that the new name, "num_subset", does not already exist in the file. However, there are many occurrences of the substring "num" in my file, and as soon as I start typing in the search box it jumps to the next occurrence of "num" before I've finished typing. So now I have to go back and find the place where I was working.
In an auto-indented code section such as a while ... end block, if you insert more than one consecutive blank line in the code the auto-indenting is lost on all but one of the blank lines.
In an auto-indented block of code, if you put the cursor between two characters and press ENTER, the Editor will put in a line break with the new line indented, as expected. However, if you select (click-and-drag over) a character and press ENTER, the Editor will delete the character and replace it with a line break, as expected, but the new line will not be auto-indented.
After doing a text search you can do subsequent searches for the same text string using F3 without re-opening the search box. However, if you switch to another file (in the tabbed Editor window) F3 does not work; you have to re-open the search box. It worked in R2021a.
The search always wraps, but I usually don't want it to wrap. There appears to be no way to disable wrapping. In R2020a the search box had an option for enabling/disabling wrapping.
The behavior of Smart Indent has changed in 2020b. In 2020a all lines in a code block would be auto-indented. In 2020b the indenting of all blank lines is removed. So if you start typing in a blank line you have to either manually put in leading tabs or re-select Smart Indent.
12 commentaires
Scaler
le 8 Fév 2022
I agree with the view here. Most of the changes listed above have caused me frustration and reduced my productivity.
In addition:
- The lag is a real problem. Sometimes I hit tab multiple times just waiting for the editor to respond.
- I used to double-click on an identifier and check the notice at the bottom of the editor (e.g., '3 usages of "thisMakesMeCry" found`) to make sure I was seeing all uses of that identifier. The new editor still displays that message, but only for some identifier that I selected who knows when--not the one currently selected or the one last searched for. It is totally broken.
- Have some versioned code written with a previous editor? Don't you dare smart-indent that file! Since the definition of "smart" apparently changed (I won't say to what!), so will all your blank lines.
Massimiliano Zanoli
le 27 Avr 2022
This! Completely agree on everything.
Especially the search function, it has become so ridiculous.
With this fancy "immediate" search behavior you get thrown all over the place and waste time finding your way back to the point in the code you actually wanted to search around.
The new behavior of smart indentation is not even consistent with the the indentation that R2021b itself does when hitting return on an indented line of code.
I hope they will completely refactor MATLAB soon. You can tell from the GUI behavior that this software has become a pile of fixes and workarounds that is simply unmanageable.
Kenneth Johnson
le 27 Avr 2022
goc3
le 2 Mai 2022
These regressions are quite unfortunate. Hopefully they will fix them. (Though, they seem to have persisted into 2022a...)
The problem is that they consider some of these changes to be improvements or the way the editor should function. For example, I submitted a service request regarding the change to smart indenting removing all tab space in blank lines (which I find to be infuriating) and was told that that is the new intended functionality!!
Jon Dattorro
le 9 Mai 2022
This new search box, introduced in 2021B, should be reverted back to 2021A.
Where are previous search terms?
Where does it say "match case"?
Where does it say "whole word"?
Why is arcane & ad hoc symbology better than English descriptors and check boxes?
_____________________________________________________________________
The large Run button in 2021A Editor has been demoted and moved right to an inferior position in 2021B. Run has been replaced with another arbitrary flavor of conditional Run that should never have achieved prominence nor displaced the primary Run function.
_____________________________________________________________________
Which textbooks on ergonomic design were consulted prior to introducing these atrocities?
These are a major steps backward and certainly misguided in development of the Editor GUI.
creepydog
le 13 Mai 2022
I fully agree and want to add the font issue. The new editor has a different interpretation of Monospaced than the Command Window.
Dmitry Kaplan
le 10 Juin 2022
OMG I hear you guys. I've been using Matlab for decades, and this is this editor is the worst UI decision they have ever made. Everything about it drives me nuts: The non-detachable search box, the immediate jumpiness of searches, the moronic function argument suggestions ("thank you, I know how to use sprintf()"), the fugly section highlighting, the 99% wrong argument suggestions .... WHY WHY WHY?
Why can't I turn off all this crud?
Why does no-one at Mathworks realize the there are experienced programmers out there who HATE all the junk flashing on/off while trying to concentrate on something complicated?
Why isn't this editor be the old editor with new options?
Why can't I use the old editor?
Felipe Jiménez Hernández
le 15 Fév 2023
Modifié(e) : John Kelly
le 21 Fév 2023
Please give us the old editor. This one is not worth even fixing.
Jan
le 15 Fév 2023
A businesslike wording is preferred in the forum. I ask you to support this. Thanks.
Image Analyst
le 19 Fév 2023
Modifié(e) : Image Analyst
le 19 Fév 2023
"unbusiness-like" language that includes profanity can and will be deleted by any of the numerous moderators of this forum. But OK, point taken: you don't like the new editor style.
Walter Roberson
le 19 Fév 2023
Tips for Creating Helpful Answers
Be honest and considerate with all responses to all contributors.
Tips for Making Comments Helpful
Be aware that responses containing profanity, vulgarity, or an offensive tone will be removed.
Jan
le 19 Fév 2023
Modifié(e) : John Kelly
le 21 Fév 2023
Regardless of these guidelines, if moderators or administrators tell you not to do something, don't do it. They reserve the right to change or delete any content if they feel it is inappropriate.
Réponse acceptée
Plus de réponses (3)
Giles
le 13 Avr 2023
1 vote
At the very least there should be an option to re-enable the old editor.
The old editor was perfect. The new editor might become perfect in time, but we're going to have to wait years for all the problems to be worked out--and even then no guarantees. And even if it does get there in time, we're just going to end up with something resembling the old editor. I don't understand why this was done at all.
You can add the problem that it used to be easy to block-select one or more lines by clicking and dragging in the left margin. In the new editor the area where you can do that is now so thin it becomes tricky/painful to use.
Agree that auto-jumping the search while typing is a terrible idea. Might be nice if you're searching a document or the web. Not nice for coding. I don't get how that made it into version 1.
1 commentaire
Felipe Jiménez Hernández
le 15 Avr 2023
I have skipped upgrading to the latest versions just for this. You must be f* s* to worsen a product so terribly out of nowhere. For most users, a friendly programming environment is much more important than any improvements they can make under the hood.
Jan
le 15 Fév 2023
0 votes
I still miss the editor option existing inMatlab 6.5, which allowed to provide the selected text as input to functions defined by the user. This could be defined directly in the menu of the editor. Sigh.
The introduction of the ribbon style in R2012b was a hard stroke already (see: https://www.mathworks.com/matlabcentral/answers/48070-experiences-with-release-2012b )
2 commentaires
Steven Lord
le 15 Fév 2023
I still miss the editor option existing inMatlab 6.5, which allowed to provide the selected text as input to functions defined by the user.
I'm not 100% sure what you're describing, but I've done something like this with shortcuts or favorites in MATLAB. Open a document in the MATLAB Editor and select some text, then run this code (almost certainly won't work in MATLAB Answers.)
s = matlab.desktop.editor.getActive().SelectedText
You might want to safeguard this a bit before using this in your code by checking that matlab.desktop.editor.getActive returns a non-empty output. You could also use this in conjunction with the clipboard command to copy the SelectedText to the clipboard.
Jan
le 16 Fév 2023
@Steven Lord: Thanks for this useful suggestion.
As far as I remember, the mentioned feature was in the "Tools" menu of Matlab 6.5, where a list of functions could be defined and triggered by hot keys. The input was the current selection and maybe this selection was replaced, if the function had outputs.
Unfortunately my virtual machine with WinXP crashed and I cannot find the old documentation currently. Actually FEX: EditorMacro could fill this gap, but I have some doubt concerning the stability of this tool.
Felipe Jiménez Hernández
le 29 Sep 2025
Modifié(e) : Felipe Jiménez Hernández
le 29 Sep 2025
0 votes
Each time I open the editor, the ribbon is open and I have to hide it. Is there a way to hide it forever by default?
(I have it undocked so I can swap to/from it with Alt-Tab.)
Catégories
En savoir plus sur Entering Commands dans Centre d'aide et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!


