How do I keep Delphi from automatically expanding folded code regions? -


I use {$ Regions} widely in my units, Ever since the VCL editor makes annoying decisions, by clicking on the <+> <+> button to expand all the areas on its own till I do not clarify, till then do not extend those parts to the editor Is there any way to tell?


Updates from comments:

Unfolding,

  1. Introducing a new nested "Process" header with nested procs / funcs As soon as you type the 'P' character, all the nested procs / funcs are coming out, this also happens, for example, by mistake, you can "expire" any nested proc / func (or some type) Remove
  2. If you start a comment with "{" with fields, then immediately open the area below. "(*" All provinces have been shown below to start a comment and it applies to all processes / fanks under those areas.

Unfortunately this is one of the problems of Delphi, which exists since Delphi XE, even if not from the earlier versions and still not fixed .

The fact that the code is officially exposed is the fact that Even error insight system detects any syntax error in your unit, then it considers all the codes under all the code as non-valid and thus extends all the multiplication codes under that point.

So far the only way I know to avoid this is to disable Insight, but this means that you do not try to compile your program.

But It's a hope that Embarcadero will go away soon enough because this code makes the code coding unnecessary, because you have the error insight disabled because you spend more time in the automatically expedited D code again a new code Have to write

EDIT: Steps to reproduce it (a way to reproduce it)

Create a new application

Your form or any other Handler for OnCrute and On-Close for two ways.

  Process TForm1.FormCreate (Sender: Tubaxide); Initial end; Process TForm1.FormClose (Sender: Tubect; ​​var Action: TCloseAction); Start / end;  

If you also create handlers, make sure that the least handler is at least some code in the Metrhad or at least one comment, so that the Optimizer automatically has the "Impy" Remove event handler.

Now type "form" in the top event handler. And the event handler below you will be automatically expanded.

You will see that at this point Delphi Dissent also knows where and where the current method code blocks in which the syntax error has been detected and also recognizing any code block right below that point. Makes it impossible for


Comments

Popular posts from this blog

winforms - C# Form - Property Change -

javascript - amcharts makechart not working -

java - Algorithm negotiation fail SSH in Jenkins -