diff --git a/mdl/m_strings.pas b/mdl/m_strings.pas index d9c73cd..c7747d9 100644 --- a/mdl/m_strings.pas +++ b/mdl/m_strings.pas @@ -53,6 +53,13 @@ Var Space : Byte; Temp : Byte; Begin + If Length(Str) > Len Then Begin + Str[0] := Chr(Len); + Result := Str; + + Exit; + End; + Space := (Len - Length(Str)) DIV 2; Temp := Len - ((Space * 2) + Length(Str)); Result := strRep(Ch, Space) + Str + strRep(Ch, Space + Temp);