Ok, I compiled lazarus svn 14912 with -dVerboseIDEEncoding option.
Checking my source files in lazarus I noticed that the files I can see
have UTF-8 encoding, while the files I cannot see have ansi encoding.
I attached one of the file I am not able to see.
Regards,
Andrea
Andrea Mauri ha scritto:
Sorry Mattias, I would like to help but:
- how can I check my codepage?
- I updated my svn to 14912, how can I compile with
-dVerboseIDEEncoding? Can I compile lazarus using lazarus Build tool or
I have to compile by dos windows, how?
- once compiled using -dVerboseIDEEncoding I have to open lazarus and
reproduce the bug, which concole output I have to send you?
Regards,
Andrea
Mattias Gärtner ha scritto:
Zitat von Andrea Mauri <[EMAIL PROTECTED]>:
Dear all,
I have some problems with last lazarus svn. With last svn version I am
not able to see some of my project's units.
The editor shows an empty tab for such units. But I am not able to
understand why. I can see some units but not all of them.
Lazarus works fine with this svn:
v0.9.25 r14888 i386-win32-win32/win64
But not with this:
v0.9.25 r14915 i386-win32-win32/win64
(FPC 2.2)
Any help?
You can help me to fix the bug.
See here:
http://bugs.freepascal.org/view.php?id=11177
What is your windows codepage?
Please compile svn 14912 with -dVerboseIDEEncoding, reproduce the bug and send
the console output and one of the "empty" files.
Mattias
_______________________________________________
Lazarus mailing list
Lazarus@lazarus.freepascal.org
http://www.lazarus.freepascal.org/mailman/listinfo/lazarus
_______________________________________________
Lazarus mailing list
Lazarus@lazarus.freepascal.org
http://www.lazarus.freepascal.org/mailman/listinfo/lazarus
{*******************************************************}
{ }
{ AM Basic Types }
{ Types, Functions, Procedures }
{ }
{ Copyright (c) 2004,2006 Andrea Mauri }
{ }
{*******************************************************}
unit am_basic_types;
{$mode objfpc}{$H+}
interface
uses
Classes, Sysutils;
type
TVTextFile = array of TextFile;
TEdge = record
Vertex1: integer;
Vertex2: integer;
Bond_Order: Single;
end;
TVEdges = array of TEdge;
TVString = array of string;
type
TRoundToRange = -37..37;
const
MissingValue = -999;
TAB = Chr(9);
CRLF = Chr(13) + Chr(10);
CR = Chr(13);
LF = Chr(10);
function SuperTrim(const Str, SubStr: string): string;
function Split(const str: string; const separator: string): TVString;
function AnsiPosAd(SToFind, S: string; Index: integer; CaseSens: Boolean):
integer;
function RoundTo(const AValue: Double; const ADigit: TRoundToRange): Double;
function Replace(const Str, SubstrToRemove, SubstrToIntroduce:string): string;
procedure SaveToFile(Messages: TStringList; FileName: string);
implementation
uses
Math;
function RoundTo(const AValue: Double; const ADigit: TRoundToRange): Double;
var
LFactor: Double;
begin
LFactor := IntPower(10, ADigit);
Result := Round(AValue / LFactor) * LFactor;
end;
function Replace(const Str, SubstrToRemove, SubstrToIntroduce: string): string;
var
PosSubStr: integer;
NewStr, NewStrToIntroduce: string;
begin
// remove the occurrence of SustrToRemove from SubstrToIntroduce
NewStrToIntroduce:= SubstrToIntroduce;
PosSubstr:= Pos(SubstrToRemove, NewStrToIntroduce);
while PosSubStr > 0 do
begin
Delete(NewStrToIntroduce, PosSubStr, Length(SubstrToRemove));
PosSubStr:= Pos(SubStrToRemove, NewStrToIntroduce);
end;
// Replace SbstrToRemove with SubstrToIntroduce
NewStr:= Str;
PosSubStr:= Pos(SubstrToRemove, NewStr);
while PosSubStr > 0 do
begin
Delete(NewStr, PosSubStr, Length(SubstrToRemove));
Insert(NewStrToIntroduce, NewStr, PosSubStr);
PosSubStr:= Pos(SubStrToRemove, NewStr);
end;
Result:= NewStr;
end;
procedure SaveToFile(Messages: TStringList; FileName: string);
var
i: integer;
begin
for i:= 0 to Messages.Count - 1 do
begin
if (FileName = 'stdout') or (FileName = '') then
Writeln(StdOut, Messages.Strings[i])
else
if (FileName = 'stderr') then
Writeln(StdErr, Messages.Strings[i])
else
Writeln(FileName, Messages.Strings[i]);
end;
end;
function Occurs(const str, separator: string): integer;
var
i, nSep: integer;
begin
nSep:= 0;
for i:= 1 to Length(str) do
if str[i] = separator then Inc(nSep);
Result:= nSep;
end;
function SuperTrim(const Str, SubStr: string): string;
var
PosSubStr: integer;
NewStr: string;
begin
NewStr:= Str;
PosSubStr:= Pos(SubStr + SubStr, NewStr);
while PosSubStr > 0 do
begin
Delete(NewStr, PosSubStr, 1);
PosSubStr:= Pos(SubStr + SubStr, NewStr);
end;
Result:= NewStr;
end;
// Returns an array with the parts of "str" separated by "separator"
function Split(const str: string; const separator: string): TVString;
var
i, n: integer;
Linea, Campo: string;
begin
n:= Occurs(str, separator);
SetLength(Result, n + 1);
i := 0;
Linea := str;
repeat
if Pos(separator, Linea) > 0 then
begin
Campo:= Copy(Linea, 1, Pos(separator, Linea) - 1);
Linea:= Copy(Linea, Pos(separator, Linea) + 1, Length(Linea) -
pos(separator,Linea));
end
else
begin
Campo:= Linea;
Linea:= '';
end;
Result[i]:= Campo;
Inc(i);
until Linea = '';
if Result[High(Result)] = '' then SetLength(Result, Length(Result) -1);
end;
(* funzione analoga ad AnsiPos ma con un indice sul punto da cui partire
il carattere in posizione index è compreso nella ricerca *)
function AnsiPosAd(SToFind, S: string; Index: integer; CaseSens: Boolean):
integer;
var
Count, Pos: integer;
begin
if not(CaseSens) then
begin
SToFind:= AnsiUpperCase(SToFind);
S:= AnsiUpperCase(S);
end;
Count:= Length(S) - Index + 1;
S:= Copy(S, Index, Count);
Pos:= AnsiPos(SToFind, S);
if Pos > 0 then
Result:= Index + Pos - 1
else
Result:= 0;
end;
end.
_______________________________________________
Lazarus mailing list
Lazarus@lazarus.freepascal.org
http://www.lazarus.freepascal.org/mailman/listinfo/lazarus