hedgewars/uFLUtils.pas
branchqmlfrontend
changeset 10440 b74a7bbe224e
parent 10434 1614b13ad35e
child 10517 844bd43db47a
equal deleted inserted replaced
10438:50ed968e4fee 10440:b74a7bbe224e
     1 unit uFLUtils;
     1 unit uFLUtils;
     2 interface
     2 interface
     3 
     3 
     4 function str2PChar(const s: shortstring): PChar;
     4 function str2PChar(const s: shortstring): PChar;
     5 function intToStr(n: LongInt): shortstring;
     5 function intToStr(n: LongInt): shortstring;
       
     6 function midStr(s: shortstring; pos: byte): shortstring;
     6 
     7 
     7 implementation
     8 implementation
     8 
     9 
     9 var
    10 var
    10     str2PCharBuffer: array[0..255] of char;
    11     str2PCharBuffer: array[0..255] of char;
    23 function intToStr(n: LongInt): shortstring;
    24 function intToStr(n: LongInt): shortstring;
    24 begin
    25 begin
    25     str(n, intToStr)
    26     str(n, intToStr)
    26 end;
    27 end;
    27 
    28 
       
    29 function midStr(s: shortstring; pos: byte): shortstring;
       
    30 begin
       
    31     midStr:= copy(s, pos, length(s) - pos + 1)
       
    32 end;
       
    33 
    28 end.
    34 end.