Recent

Author Topic: Installing v2010 seems to have messed up my v1.8.4  (Read 1381 times)

RedOctober

  • Sr. Member
  • ****
  • Posts: 414
Installing v2010 seems to have messed up my v1.8.4
« on: January 18, 2021, 07:33:41 pm »
Platform: Windows Server 2016, multiple versions of Lazarus installed.  1.8.2, 1.8.4 - both were installed as independent environments. Both worked correctly.  Yesterday I installed v2010 and did not start it up.  This morning I used v1.8.4 for several hours.  I then started v2010 and it ran through a configuration dialog, with the series of tabs I had to answer questions on.  I finished the startup, then I shut it down.  Now, when I go back to 1.8.4 and open my project and continue to work on it, when I try to open a certain tab, I get this error message:

[Window Title]
Lazarus IDE v1.8.4 - RUBI - Medical (D:\Projects\Lazarus\Rubi\rubi_core\src)

[Content]
TWinControl.SetBounds (:TPaintPanel): Width 10008 not allowed.

Press OK to ignore and risk data corruption.
Press Abort to kill the program.

[OK] [Abort]

I abort out to try to save my project.  I'm now stuck.


What do I need to do to get my project going again?  Did I somehow unwittingly upgrade my debugger or something and it's less forgiving than the one in 1.8.4?

Martin_fr

  • Administrator
  • Hero Member
  • *
  • Posts: 7398
  • Debugger - SynEdit - and more
    • wiki
Re: Installing v2010 seems to have messed up my v1.8.4
« Reply #1 on: January 18, 2021, 07:56:13 pm »
First: Make a backup of your project. Just in case.

Backup your primary config dir
C:\Users\<YOURNAME>\AppData\Local\lazarus
And maybe primary conf of your 2ndary installs.


When you start the IDE, pay attention if you get any message
- upgrade / downgrade
- big dialog, saying something about IDE file location changed


If the error happens during IDE startup: (see below, probably not)
Selectively remove config files, and let the IDE load defaults.
 environmentoptions.xml
 editoroptions.xml
 any saved IDE layout for anchordocking, if you use that (I don't, so I don't have the filenames)


Start the IDE, and under menu Tools > Options > Environments
check that all the entries for fpc, make.... point into the lazarus install dir.
I.e. if you have c:\laz184
then fpc should be somewhere c:\laz184\fpc\2.6.4\bin\x64_64-win64
Note: I am not sure if its 2.6.4 or 3.0.0. Also it may be 32 bit, you should know what you installed
Make should be in this path too. And fpc sources.

you can also start the ide with
lazarus.exe --setup
and check all the paths.

gdb  would be under c:\laz184\mingw


Quote
TWinControl.SetBounds (:TPaintPanel): Width 10008 not allowed.
I guess that this is related to loading your project.

check if you have backups of the lfm files (the IDE may have created them in a backup folder)

Or open the lfm in a texteditor, and check for an invalid/unreasonable Width.

RedOctober

  • Sr. Member
  • ****
  • Posts: 414
Re: Installing v2010 seems to have messed up my v1.8.4
« Reply #2 on: January 18, 2021, 08:41:22 pm »
I'm searching... does this seem to be related?  Still not sure how to fix.  I'm going through my backups of this project source now.

https://bugs.freepascal.org/view.php?id=34377

Martin_fr

  • Administrator
  • Hero Member
  • *
  • Posts: 7398
  • Debugger - SynEdit - and more
    • wiki
Re: Installing v2010 seems to have messed up my v1.8.4
« Reply #3 on: January 18, 2021, 10:42:44 pm »
The linked bug is marked "Linux". If there was a bug report, you may have to look through closed bugs, because 1.8.4 is old.

Just an idea, the error may be caused by using anchorsides (i.e. having the pos of one component on your form depend on another component).
I have no idea if 1.8.4 may have had any bugs there. But if it had, that can quickly lead to large unexpected values.

It is then possible that a newer lazarus updated the lfm, and that causes 1.8.4 to fail.

In general, once you open a project with a newer IDE there is always the chance that older IDE may be unable to read it.

If the error is in the project data, then your old IDE should be fine, if you test with a project that was never touched by a newer IDE.

RedOctober

  • Sr. Member
  • ****
  • Posts: 414
Re: Installing v2010 seems to have messed up my v1.8.4
« Reply #4 on: January 18, 2021, 10:54:43 pm »
Thank you Martin.  Your most recent idea was the correct one.  This problem has nothing to do with Laz 2010.  It was just an unfortunate series of events that led me to suspect that.  Have a look at the attached image.  The THTMLViewer component, being set to alClient at design time, is what causes the error.  I spent some time hacking out component after component out of the .lfm, then reopening, trying that tab again, until I happened to pick the correct one.  So, to get around this, I merely leave the THTMLViewer.Align at "alNone" at design time and then when the form creates, I set it to "alClient", and everything is happy.  I am looking forward to modernizing onto Laz2010 and above.  Lazarus is a great product, and I appreciate the team that builds it every day. (So do my customers/users)
« Last Edit: January 18, 2021, 11:14:11 pm by RedOctober »

 

TinyPortal © 2005-2018