Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / lazarus / 2018-07

Debugging Lazarus using Lazarus

5 messages · 2 people ·

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Mark Morgan Lloyd

When multiple copies of the same version (e.g. trunk) Lazarus are being run, with a view to stepping through a problem in IDE-related code, is there any way to force an override so that all windows associated with the "inner" copy are marked distinctively with e.g. an implausible background colour, a thin diagonal line overlaying the content, or at the very least an instance identifier in every caption?

Mark Morgan Lloyd markMLl .AT. telemetry.co .DOT. uk [Opinions above are the author's, not those of his employers or colleagues]

Reply by email

Martin Frb
to Mark Morgan Lloyd
Mark Morgan Lloyd wrote 7 lines
When multiple copies of the same version (e.g. trunk) Lazarus are being run, with a view to stepping through a problem in IDE-related code, is there any way to force an override so that all windows associated with the "inner" copy are marked distinctively with e.g. an implausible background colour, a thin diagonal line overlaying the content, or at the very least an instance identifier in every caption?

In menu Run > Run Parameter, specify --primary-config-path=/somefolder

- Then on first run, go into options > editor > colors, and change whatever color you like. (e.g. background or gutter). well ok that is only the editor windows. It will not affect breakpoints, etc....
- The main IDE bar has/has not the word "debugging" in it.
- You can also have a different projects open. As the last open project will be re-open, and that is stored in primary conf. With that, the debugged IDE will not open the stack and watches window (unless you want it to).

Reply by email

Mark Morgan Lloyd
to Martin Frb
Martin Frb wrote 15 lines
On 07/07/2018 11:46, Mark Morgan Lloyd via Lazarus wrote:> When multiple copies of the same version (e.g. trunk) Lazarus are > being run, with a view to stepping through a problem in IDE-related > code, is there any way to force an override so that all windows > associated with the "inner" copy are marked distinctively with e.g. an > implausible background colour, a thin diagonal line overlaying the > content, or at the very least an instance identifier in every caption?>In menu Run > Run Parameter, specify --primary-config-path=/somefolder - Then on first run, go into options > editor > colors, and change whatever color you like. (e.g. background or gutter). well ok that is only the editor windows. It will not affect breakpoints, etc....- The main IDE bar has/has not the word "debugging" in it.- You can also have a different projects open. As the last open project will be re-open, and that is stored in primary conf. With that, the debugged IDE will not open the stack and watches window (unless you want it to).

I've got /two/ main editor bars with "debugging" in them, two windws called "Source Editor (2)" and so on :-)

I'd have thought that a comparatively easy way round this would have been a global option to put the main-process PID on all form/dialogue captions. That would have result in a useful distinction even when multiple instances were using the same configuration files.

But I'm not volunteering to do it this weekend ;-)

Mark Morgan Lloyd markMLl .AT. telemetry.co .DOT. uk [Opinions above are the author's, not those of his employers or colleagues]

Reply by email

Martin Frb
to Mark Morgan Lloyd
Mark Morgan Lloyd wrote 20 lines
On 07/07/18 10:45, Martin Frb via Lazarus wrote: > On 07/07/2018 11:46, Mark Morgan Lloyd via Lazarus wrote:> When > multiple copies of the same version (e.g. trunk) Lazarus are > being > run, with a view to stepping through a problem in IDE-related > code, > is there any way to force an override so that all windows > > associated with the "inner" copy are marked distinctively with e.g. > an > implausible background colour, a thin diagonal line overlaying > the > content, or at the very least an instance identifier in every > caption?>In menu Run > Run Parameter, specify > --primary-config-path=/somefolder > - Then on first run, go into options > editor > colors, and change > whatever color you like. (e.g. background or gutter). well ok that is > only the editor windows. It will not affect breakpoints, etc....- The > main IDE bar has/has not the word "debugging" in it.- You can also > have a different projects open. As the last open project will be > re-open, and that is stored in primary conf. With that, the debugged > IDE will not open the stack and watches window (unless you want it to). I've got /two/ main editor bars with "debugging" in them, two windws called "Source Editor (2)" and so on :-)

But unless the inner IDE (the one being debugged) is itself debugging a third IDE, you can use the current project name.

Tools > Options > Window: CheckBox "IDE title shows starts with project name" (and related options)
In fact, I think the project name is always show (just usually at the end)

And with separate primary conf, the debugged IDE loads a project of your choice
But if you need to have the IDE as 3rd debuggee, then modify/hide the component palette.

Show quoted text 5 lines
I'd have thought that a comparatively easy way round this would have been a global option to put the main-process PID on all form/dialogue captions. That would have result in a useful distinction even when multiple instances were using the same configuration files.

Do they need the same config?

But your idea with the PID, just hack TForm.SetCaption (or SetRealText)

Reply by email

Martin Frb
to Martin Frb: In menu Run > Run Parameter, specify --primary-config-path=/somefolder - Then on first…
Martin Frb wrote
In menu Run > Run Parameter, specify --primary-config-path=/somefolder

Another big benefit: You can move the windows of the debugged IDE to a different location, and that will be saved. So from then on, when you start debugging the IDE, the windows will not overlap/clash with the outer IDE.
(and the position also helps identifying which is which)

I am doing exactly this myself, right now.

Reply by email