Sign in Join

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

Mailing lists / lazarus / 2010-09

SynEdit Win32 versus Linux - Does anyone have a suggestion?

3 messages · 3 people · –

Reply by email Subscribe to this list Your subscription

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

Jason P Sage

Hi Folks,

I posted this to the mailing list but I'm not certain it went out. If it did, no one had or clue or opted to not answer - so forgive me for posting again.

I'm hoping someone has even a hint of what path I might go in this venture:

Get Linux and Windows version identical and I'll have less problems?

Known Issue(s)? (I've seen other posts to the mailing list about the invalid file handle error and there wasn't much in the way of suggestions on that error either.)

Should I just get a TRAC/svn account and start debugging and repairing things myself? Is that possible?

Is editing the lfm files a bad thing to do?

------Original Post---PASTED--BEGIN

I have this project I wrote (
http://www.jegas.com/index.php/jegas-products/227-jegas-edit.html ) in Lazarus - and I started it in Win32 using Lazarus 0.9.28.2 beta. I then copied the source code to a Linux machine that has a Trunk SVN download that says 0.9.29 it the version info displayed in the about. So I get there is a version difference here... but this is what I found so far:

The PrinterDialog control didn't fair well in linux, something about I needed to install printer dialogs into lazarus and frankly I had a hard enough time getting lazarus up in linux that I just tossed out the printer dialog and made conditional defines to make it so it worked on windows and not in linux.

so I made some code changes to things like where the configuration file gets saved and other things to make the linux version run in manner that was appropriate in linux.. like saving config to your home directory. Ok
- then I check my code back into SVN and pull it pack down on my windows machine - here is where things got messed up I think.

First off, There were references added to my main form's *.lfm file - a file that I know nothing about except it appears to be a serialized version of classes ( a snapshot perhaps) of all the properties in my form when I last saved it? Anyways, in this file there were now references to a RightGutter regarding the SynEdit control(s) (I have many because the multi-synedit widget - didn't work so well but I digress)... anyways - there were all these empty properties names TSynRightGutter inside the "inline TSynGutterPartList" section.. and this caused compiler errors. They were empty anyways.. like

------Original Post---PASTED--END

Eagerly awaiting and and all responses.
Thank You,
Jason P Sage

Reply by email

Mattias Gaertner
to Jason P Sage
Show quoted text 9 lines
Hi Folks, I posted this to the mailing list but I'm not certain it went out. If it did, no one had or clue or opted to not answer - so forgive me for posting again. I'm hoping someone has even a hint of what path I might go in this venture: Get Linux and Windows version identical and I'll have less problems?

Yes.

Known Issue(s)? (I've seen other posts to the mailing list about the invalid file handle error and there wasn't much in the way of suggestions on that error either.)

I never saw such a bug, so without code it is all speculation.

Should I just get a TRAC/svn account and start debugging and repairing things myself? Is that possible?

Yes, of course, that's why it is open source.

Is editing the lfm files a bad thing to do?

No.
Just close the designer form while doing that, otherwise the IDE will overwrite your changes on next save.

Show quoted text 9 lines
------Original Post---PASTED--BEGIN I have this project I wrote ( http://www.jegas.com/index.php/jegas-products/227-jegas-edit.html ) in Lazarus - and I started it in Win32 using Lazarus 0.9.28.2 beta. I then copied the source code to a Linux machine that has a Trunk SVN download that says 0.9.29 it the version info displayed in the about. So I get there is a version difference here...

Yes, there are some difference.
In general: Lazarus is only backwards compatible. Projects edited/created with newer version must not be opened by older versions.

Show quoted text 7 lines
but this is what I found so far: The PrinterDialog control didn't fair well in linux, something about I needed to install printer dialogs into lazarus and frankly I had a hard enough time getting lazarus up in linux that I just tossed out the printer dialog and made conditional defines to make it so it worked on windows and not in linux.

Have you added the printer4lazarus package?

Show quoted text 5 lines
so I made some code changes to things like where the configuration file gets saved and other things to make the linux version run in manner that was appropriate in linux.. like saving config to your home directory. Ok - then I check my code back into SVN and pull it pack down on my windows machine - here is where things got messed up I think.

You can not share the config files in the IDE config directory between different platforms. Projects and Packages are made for sharing, the IDE configs are not.

First off, There were references added to my main form's *.lfm file - a file that I know nothing about except it appears to be a serialized version of classes ( a snapshot perhaps) of all the properties in my form when I last saved it?

Yes.

Anyways, in this file there were now references to a RightGutter regarding the SynEdit control(s) (I have many because the multi-synedit widget - didn't work so well but I digress)...

These are ok. Although I hope eventually someone will optimize synedit to not store them if not needed.

anyways - there were all these empty properties names TSynRightGutter inside the "inline TSynGutterPartList" section.. and this caused compiler errors.

Without code no one can tell what is wrong.
This could happen when mixing different lazarus/fpc version.

They were empty anyways..

In this case it might be right.

Mattias

Reply by email

Unknown author
to Jason P Sage: I posted this to the mailing list but I'm not certain it went out. If it did, no one had…

Zitat von Jason P Sage :

Show quoted text 12 lines
First off, There were references added to my main form's *.lfm file - a file that I know nothing about except it appears to be a serialized version of classes ( a snapshot perhaps) of all the properties in my form when I last saved it? Anyways, in this file there were now references to a RightGutter regarding the SynEdit control(s) (I have many because the multi-synedit widget - didn't work so well but I digress)... anyways - there were all these empty properties names TSynRightGutter inside the "inline TSynGutterPartList" section.. and this caused compiler errors. They were empty anyways.. like

Right gutter was added recently (is still in progress of being added), if you need to use the lfm, in a version that hasn't got it, you can delete the entry (as long as the file is not open in Lazarus). It will be added again, each time you open/save the file with trunk.

And yes, both (right and left) gutter, add lfm info, even if not modified. I guess, I will add that to my todo.

Martin

Reply by email