Ignore:
Timestamp:
Sep 17, 2008, 5:34:43 PM (16 years ago)
Author:
Kevin Toppenberg
Message:

Resync

File:
1 edited

Legend:

Unmodified
Added
Removed
  • cprs/branches/GUI-config/CPRS-Lib/ORFn.pas

    r476 r492  
    114114procedure CallWhenIdleNotifyWhenDone(CallProc, DoneProc: TORIdleCallProc; Msg: String);
    115115procedure menuHideAllBut(aMenuItem: tMenuItem; butItems: array of tMenuItem);
     116function TabIsPressed : Boolean;
     117function ShiftTabIsPressed : Boolean;
    116118
    117119implementation  // ---------------------------------------------------------------------------
     
    129131
    130132     // ConvertSpecialStrings arrays
    131   SearchChars:  array[0..6] of String = (' Ii ',' Iii ',' Iv ',' Vi ',' Vii ',' Viii ',' Ix ');
    132   ReplaceChars: array[0..6] of String = (' II ',' III ',' IV ',' VI ',' VII ',' VIII ',' IX ');
     133  SearchChars:  array[0..7] of String = (' Ii ',' Iii ',' Iv ',' Vi ',' Vii ',' Viii ',' Ix ','-Va');
     134  ReplaceChars: array[0..7] of String = (' II ',' III ',' IV ',' VI ',' VII ',' VIII ',' IX ','-VA');
    133135
    134136  { table for calculating CRC values (DWORD is Integer in Delphi 3, Cardinal in Delphi 4}
     
    832834
    833835procedure LimitStringLength(var AList: TStringList; MaxLength: Integer);
    834 { change a TStringList so that all strings in the list are shorter than MaxLength }
    835836var
    836837  i, SpacePos: Integer;
     
    852853          while (x[SpacePos] <> ' ') and (SpacePos > 1) do Dec(SpacePos);      {**REV**}  {changed 0 to 1}
    853854          if SpacePos = 1 then SpacePos := MaxLength;                          {**REV**}  {changed 0 to 1}
    854           NewList.Add(Copy(x, 1, SpacePos - 1));
     855          NewList.Add(Copy(x, 1, SpacePos ));  // CQ     PSI-05-040 change SpacePos-1 to SpacePos
    855856          Delete(x, 1, SpacePos);
    856857        end; {while Length(x)}
     
    17101711end;
    17111712
     1713function TabIsPressed : Boolean;
     1714begin
     1715  Result := Boolean(Hi(GetKeyState(VK_TAB))) and not Boolean(Hi(GetKeyState(VK_SHIFT)));
     1716end;
     1717
     1718function ShiftTabIsPressed : Boolean;
     1719begin
     1720  Result := Boolean(Hi(GetKeyState(VK_TAB))) and Boolean(Hi(GetKeyState(VK_SHIFT)));
     1721end;
     1722
     1723
    17121724initialization
    17131725  FBaseFont := TFont.Create;
Note: See TracChangeset for help on using the changeset viewer.