Recent

Author Topic: Scrollbar causes program to freeze when run from IDE  (Read 3485 times)

russdirks

  • New Member
  • *
  • Posts: 35
Scrollbar causes program to freeze when run from IDE
« on: January 19, 2016, 06:27:07 am »
I'm trying to get a program originally developed under Windows running on Lazarus 1.6RC2 under Ubuntu 14.04, using the GTK 2 widget set.  After dealing with a number of cross-platform issues, I eventually got it to run, but found that it would freeze up quite often when run from the IDE.  It runs perfectly when launched outside the IDE. 

I think I have narrowed it down to scrollbars!  It seems that any control with a scrollbar will cause the program to lock up when run from the IDE.

Here's my repro steps:
1. Create a new GUI application in Lazarus.
2. Drop a TScrollBar on the form.
3. Run the program from the IDE.

About 75% of the time the form will come up with the scrollbar missing, and if you try to interact with the form, like trying to close it, the window will go dark and a message will come up, "This window is not responding", with the option to Force Quit.

I've also been able to repro this with a scrollbox, a listbox, and 1 or 2 other controls with scrollbars.  I've also been able to repro this bug on a different machine using Laz 1.4.4 on Ubuntu 15.10


I'm thinking I must be doing something wrong, because if this is a bug I don't see how anybody could get any program development done.   Would anybody be willing to try to repro this, or give me some suggestions as to what I might be doing wrong.

If the problem doesn't immediately manifest, try changing a property on the scrollbar, like change it from horizontal to vertical.  That usually does it for me.
« Last Edit: January 19, 2016, 06:29:22 am by russdirks »

Eugene Loza

  • Hero Member
  • *****
  • Posts: 561
    • My "almost daily" development blog
Re: Scrollbar causes program to freeze when run from IDE
« Reply #1 on: January 19, 2016, 10:31:09 am »
Sounds rather strange... Scrollbars work fine for me. Moreover, I've never experienced any corss-platform issues at all (except different path delimiters).

Quote
1. Create a new GUI application in Lazarus.
2. Drop a TScrollBar on the form.
3. Run the program from the IDE.
Works perfectly. Lazarus 1.6RC2, i386, widgetset:gtk2. Debian Jessie.

Maybe, you can post a minimalistic project which causes the failure? Or GDB fails? Are you 32 or 64 bit?
Lazarus 1.9 + FPC 3.1.1 Debian Jessie 64 bit.

My Free and Open Source games in Lazarus/FreePascal/CastleGameEngine:
https://decoherence.itch.io/
(and some ancient games in Turbo Pascal too)
Sources are here: https://github.com/eugeneloza?tab=repositories

russdirks

  • New Member
  • *
  • Posts: 35
Re: Scrollbar causes program to freeze when run from IDE
« Reply #2 on: January 19, 2016, 06:50:12 pm »
Yes I agree ... this is pretty strange.  I'm running 64bit.

I just found out it is not limited to scrollbars.  I was doing a small test with a program that just had a form and a button, and it froze up on me.  See the first attachment.  I then switched back to the IDE and hit the Pause button - see attachment #2 & #3.

You mentioned GDB failure, which I think is a definite possibility.  Any suggestions as to how to diagnose if that is indeed the problem?