View Issue Details

IDProjectCategoryView StatusLast Update
0022591LazarusIDEpublic2016-04-08 14:51
ReporterGraeme GeldenhuysAssigned ToJuha Manninen 
PrioritynormalSeveritymajorReproducibilityalways
Status resolvedResolutionunable to reproduce 
PlatformLinuxOSOpenSUSEOS Version12.1
Product Version1.0.0RC1Product Buildrc1 
Target VersionFixed in Version 
Summary0022591: GTK2: z-order for modal win ["File Open" from toolbar freezes IDE]
DescriptionIf I have a project open, and then open another .LPR file using the "File Open" toolbar button, I 9/10 times get the IDE to freeze up and the mouse cursor simply shows the "busy" state.

As I said, I can reproduce this quite easily, thou sometimes it works, but 9/10 times it doesn't. I'm using Lazarus 1.0 RC1 rexported FPC 2.6.1 x86_64-linux-gtk 2. I downloaded the source tar.gz archive of RC1 from SourceForge, then built my IDE using 'make all', using FPC 2.6.1 r22001.

Unfortunately no visible errors appear in the console output:
==========================================
$ ./lazarus --pcp=~/.lazarus-rc1
SetPrimaryConfigPath NewValue="~/.lazarus-rc1" -> "/home/graemeg/.lazarus-rc1"
TMainIDE.ParseCmdLineOptions:
  PrimaryConfigPath="/home/graemeg/.lazarus-rc1/"
  SecondaryConfigPath="/etc/lazarus"
LAZARUS END - cleaning up ...
[TMainIDE.Destroy] A
[TMainIDE.Destroy] B -> inherited Destroy... TMainIDE
[TMainIDE.Destroy] END
[lazarus-rc1 (master)]$ ./lazarus --pcp=~/.lazarus-rc1
SetPrimaryConfigPath NewValue="~/.lazarus-rc1" -> "/home/graemeg/.lazarus-rc1"
TMainIDE.ParseCmdLineOptions:
  PrimaryConfigPath="/home/graemeg/.lazarus-rc1/"
  SecondaryConfigPath="/etc/lazarus"

==========================================
Tags1.0 rc1
Fixed in Revision
LazTarget-
Widgetset
Attached Files

Activities

Graeme Geldenhuys

2012-08-06 19:07

reporter   ~0061449

I must add that using Ctrl+O shortcut to open a file seems to always work. It's only when I use the "File Open" from the toolbar buttons.

Martin Friebe

2012-08-06 20:36

manager   ~0061450

Last edited: 2012-08-06 20:39

When the IDE asks "Open as project or normal file?" What do you select?

In case, you do not see the dialog. Can it be z-order? That is the dialog is behind the Editor?

Graeme Geldenhuys

2012-08-07 02:01

reporter   ~0061456

@Martin
I never even saw that prompt. I tried again, after reading about the z-order idea. You hit the nail on the head. That is indeed the problem. The prompt is hidden behind the editor window.

I just tested with an older Trunk build (before rc1 was announced), and get the same issue. Lazarus 1.1 r37291 FPC 2.7.1 x86_64-linux-gtk 2

I then tested with Lazarus 0.9.30.1 r33214M FPC 2.5.1 x86_64-linux-gtk 2 (my trusty stable version), and the prompt is always above other IDE windows.

So that rules out JWM - my window manager - causing the problem. It seems somewhere in recent times the z-order in LCL got all screwy.

Martin Friebe

2012-08-07 03:27

manager   ~0061458

Any docking-mgr involved?

Mattias Gaertner

2012-08-07 09:39

manager   ~0061460

The mouse click versus short cut issue sounds like freeing an active control.
But in this case the toolbar buttons are not recreated when closing/opening a project.

Is it a 100% CPU freeze?

Can you start the IDE in gdb and when it freezes, create a backtrace?

Graeme Geldenhuys

2012-08-07 18:28

reporter   ~0061485

Last edited: 2012-08-07 18:29

@Martin: No I have no docking managers installed.

@Mattias: It is apparently not the IDE that freezes up, simply the "Open as projet or normal file?" dialog, which is modal, and which is hidden behind other IDE windows. So I didn't notice it all all. Moving the other IDE windows out of the way, I can click the "open as normal file" button, and the IDE is back to normal.

This "modal dialog behind other windows" bug only happens when I use the "File Open" toolbar button, not the Ctrl+O keyboard shortcut. And as I mentioned, this bug does not happen in Lazarus 0.9.30.1

Mattias Gaertner

2012-08-20 13:32

manager   ~0061751

I have never seen that under Ubuntu.
Probably the LCL is now doing something that your wm does not like, or not doing anymore what your wm needs.

What is the easiest way to setup a jvm?

Zeljan Rikalo

2012-08-23 11:39

developer   ~0061824

@Graeme please:
See what GetWindowManager returns for your wm.
Then in TGtk2WidgetSet.Create add it.
So,
 ...
  if GetWindowManager = 'kwin' then
  begin
 ..
becomes
  if (GetWindowManager = 'kwin') or (GetWindowManager = 'yourwm') then
  begin

then try how it works with modal windows and problematic dialog.

Juha Manninen

2016-03-16 10:47

developer   ~0091113

Is this still valid?
I remember many similar problems a long time ago but they got solved somehow.

Juha Manninen

2016-04-08 14:51

developer   ~0091862

No feedback. Resolving.

Issue History

Date Modified Username Field Change
2012-08-06 19:05 Graeme Geldenhuys New Issue
2012-08-06 19:07 Graeme Geldenhuys Note Added: 0061449
2012-08-06 20:36 Martin Friebe Note Added: 0061450
2012-08-06 20:39 Martin Friebe Note Edited: 0061450
2012-08-07 00:25 Mattias Gaertner Status new => assigned
2012-08-07 00:25 Mattias Gaertner Assigned To => Mattias Gaertner
2012-08-07 02:01 Graeme Geldenhuys Note Added: 0061456
2012-08-07 03:27 Martin Friebe Note Added: 0061458
2012-08-07 09:39 Mattias Gaertner Note Added: 0061460
2012-08-07 18:28 Graeme Geldenhuys Note Added: 0061485
2012-08-07 18:29 Graeme Geldenhuys Note Edited: 0061485
2012-08-07 18:29 Graeme Geldenhuys Tag Attached: 1.0 rc1
2012-08-13 00:02 Martin Friebe LazTarget => -
2012-08-13 00:02 Martin Friebe Summary "File Open" from toolbar freezes IDE => GTK2: z-order for modal win ["File Open" from toolbar freezes IDE]
2012-08-20 13:32 Mattias Gaertner Note Added: 0061751
2012-08-23 11:39 Zeljan Rikalo Note Added: 0061824
2016-03-16 10:46 Juha Manninen Assigned To Mattias Gaertner => Juha Manninen
2016-03-16 10:47 Juha Manninen Note Added: 0091113
2016-03-16 10:47 Juha Manninen Status assigned => feedback
2016-04-08 14:51 Juha Manninen Note Added: 0091862
2016-04-08 14:51 Juha Manninen Status feedback => resolved
2016-04-08 14:51 Juha Manninen Resolution open => unable to reproduce