* merged verbosity check

This commit is contained in:
peter 2002-11-15 01:13:42 +00:00
parent 37247e8cde
commit b716b77913

View File

@ -49,27 +49,46 @@ const
Is_interactive : boolean = false; Is_interactive : boolean = false;
Auto_verbosity : boolean = false; Auto_verbosity : boolean = false;
Procedure GetTranslation( p : PMsg); Procedure GetTranslation( p : PMsg);
var var
s : string; s : string;
i,j : longint; i,j,k : longint;
begin begin
i:=pos('_',p^.text); i:=pos('_',p^.text);
if (i>0) and (i<=5) then if i>0 then
for j:=i+1 to Length(p^.text) do
if p^.text[j]='_' then
begin
i:=j;
break;
end;
if (i>0) and (i<=15) then
Writeln(P^.Enum,' type "',copy(p^.text,1,i-1),'" "',copy(p^.text,i+1,255),'"') Writeln(P^.Enum,' type "',copy(p^.text,1,i-1),'" "',copy(p^.text,i+1,255),'"')
else else
Writeln(P^.enum,' "',p^.text,'"'); Writeln(P^.enum,' "',p^.text,'"');
Writeln('Type translated error message in,');
Writeln('Press return to keep it unchanged, or "q" to finish interactive mode');
Readln(s); Readln(s);
if s='' then if s='' then
exit;
if s='q' then
begin begin
Is_interactive:=false; Is_interactive:=false;
exit; exit;
end; end;
j:=pos('_',s); j:=pos('_',s);
if (j>0) and (j<=5) then if j>0 then
for k:=j+1 to Length(s) do
if s[j]='_' then
begin
j:=k;
break;
end;
if (j>0) then
begin begin
if copy(p^.text,1,i)<>copy(s,1,j) then if copy(p^.text,1,i)<>copy(s,1,j) then
Writeln('Different verbosity !!'); Writeln('Warning : different verbosity !!');
p^.text:=s; p^.text:=s;
end end
else else
@ -511,7 +530,10 @@ begin
end. end.
{ {
$Log$ $Log$
Revision 1.8 2002-05-18 13:34:27 peter Revision 1.9 2002-11-15 01:13:42 peter
* merged verbosity check
Revision 1.8 2002/05/18 13:34:27 peter
* readded missing revisions * readded missing revisions
Revision 1.7 2002/05/16 19:46:53 carl Revision 1.7 2002/05/16 19:46:53 carl