[Lazarus] EOL character used in .lfm files keep changing

Mattias Gaertner nc-gaertnma at netcologne.de
Thu Jun 11 14:17:11 CEST 2009


On Thu, 11 Jun 2009 12:46:11 +0200
Graeme Geldenhuys <graemeg at opensoft.homeip.net> wrote:

> Mattias Gaertner wrote:
> > 
> > lfm files are human edited.
> 
> Probably by 0.1% of the general Lazarus users. In that case, the
> Lazarus editor can simply detect that it's a .lfm and always use CRLF
> when saving it. It already detects the .lfm because of syntax
> highlighting.

Same goes for pascal files:
Big parts of pas files are created by code completion and I bet most
lazarus created pas files are only edited with lazarus.
The diff tools handle them both as text files. 

 
> > What .lfm patches are bigger than .pas patches because of the line
> > endings?
> 
>   http://bugs.freepascal.org/view.php?id=13941
>   http://bugs.freepascal.org/view.php?id=13952
> 
> And I was just about to submit another *huge* patch simply because I
> resized a TGroupBox. Which is when I started investigating the issue
> and found the problem is the EOL characters.

I just tested: They are not huge when using svn diff, nor when using
diff of the fsf and many other diff tools can ignore line endings.
Probably you used your diff tool wrong.

 
> > What has csv to do with lfm?
> 
> That it is perfectly acceptable (and practised in the real world) to
> have some files always adhere to a specific EOL character, no matter
> what platform is used.

Many csv readers can only handle windows line endings. So the
recommendation makes sense.

I don't see this given for lfm.

Mattias




More information about the Lazarus mailing list