fpdebug.pas 21 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785
  1. {
  2. $Id$
  3. This file is part of the Free Pascal Integrated Development Environment
  4. Copyright (c) 1998 by Berczi Gabor
  5. Debugger call routines for the IDE
  6. See the file COPYING.FPC, included in this distribution,
  7. for details about the copyright.
  8. This program is distributed in the hope that it will be useful,
  9. but WITHOUT ANY WARRANTY; without even the implied warranty of
  10. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
  11. **********************************************************************}
  12. unit FPDebug;
  13. interface
  14. uses
  15. Objects,Views,
  16. GDBCon,GDBInt,
  17. WViews,
  18. FPViews;
  19. type
  20. PDebugController=^TDebugController;
  21. TDebugController=object(TGDBController)
  22. InvalidSourceLine : boolean;
  23. LastFileName : string;
  24. LastSource : PView; {PsourceWindow !! }
  25. HiddenStepsCount : longint;
  26. constructor Init(const exefn:string);
  27. destructor Done;
  28. procedure DoSelectSourceline(const fn:string;line:longint);virtual;
  29. { procedure DoStartSession;virtual;
  30. procedure DoBreakSession;virtual;}
  31. procedure DoEndSession(code:longint);virtual;
  32. procedure AnnotateError;
  33. procedure InsertBreakpoints;
  34. procedure RemoveBreakpoints;
  35. procedure ResetBreakpointsValues;
  36. procedure DoDebuggerScreen;virtual;
  37. procedure DoUserScreen;virtual;
  38. procedure Reset;virtual;
  39. procedure Run;virtual;
  40. procedure Continue;virtual;
  41. procedure CommandBegin(const s:string);virtual;
  42. procedure CommandEnd(const s:string);virtual;
  43. end;
  44. BreakpointType = (bt_function,bt_file_line,bt_watch,bt_awatch,bt_rwatch,bt_invalid);
  45. BreakpointState = (bs_enabled,bs_disabled,bs_deleted);
  46. PBreakpointCollection=^TBreakpointCollection;
  47. PBreakpoint=^TBreakpoint;
  48. TBreakpoint=object(TObject)
  49. typ : BreakpointType;
  50. state : BreakpointState;
  51. owner : PBreakpointCollection;
  52. Name : PString; { either function name or expr to watch }
  53. FileName : PString;
  54. OldValue,CurrentValue : Pstring;
  55. Line : Longint; { only used for bt_file_line type }
  56. Conditions : PString; { conditions relative to that breakpoint }
  57. IgnoreCount : Longint; { how many counts should be ignored }
  58. Commands : pchar; { commands that should be executed on breakpoint }
  59. GDBIndex : longint;
  60. GDBState : BreakpointState;
  61. constructor Init_function(Const AFunc : String);
  62. constructor Init_file_line(AFile : String; ALine : longint);
  63. constructor Init_type(atyp : BreakpointType;Const AnExpr : String);
  64. procedure Insert;
  65. procedure Remove;
  66. procedure Enable;
  67. procedure Disable;
  68. procedure ResetValues;
  69. destructor Done;virtual;
  70. end;
  71. TBreakpointCollection=object(TCollection)
  72. function At(Index: Integer): PBreakpoint;
  73. function GetGDB(index : longint) : PBreakpoint;
  74. function GetType(typ : BreakpointType;Const s : String) : PBreakpoint;
  75. function ToggleFileLine(Const FileName: String;LineNr : Longint) : boolean;
  76. procedure Update;
  77. procedure FreeItem(Item: Pointer); virtual;
  78. procedure ShowBreakpoints(W : PSourceWindow);
  79. end;
  80. const
  81. BreakpointTypeStr : Array[BreakpointType] of String[9]
  82. = ( 'function','file-line','watch','awatch','rwatch','invalid' );
  83. BreakpointStateStr : Array[BreakpointState] of String[8]
  84. = ( 'enabled','disabled','invalid' );
  85. var
  86. Debugger : PDebugController;
  87. BreakpointCollection : PBreakpointCollection;
  88. procedure InitDebugger;
  89. procedure DoneDebugger;
  90. procedure InitGDBWindow;
  91. procedure DoneGDBWindow;
  92. procedure InitBreakpoints;
  93. procedure DoneBreakpoints;
  94. implementation
  95. uses
  96. Dos,Mouse,Video,
  97. App,Strings,
  98. FPVars,FPUtils,FPConst,
  99. FPIntf,FPCompile,FPIde;
  100. {****************************************************************************
  101. TDebugController
  102. ****************************************************************************}
  103. constructor TDebugController.Init(const exefn:string);
  104. var f: string;
  105. begin
  106. inherited Init;
  107. f := exefn;
  108. LoadFile(f);
  109. SetArgs(GetRunParameters);
  110. Debugger:=@self;
  111. InsertBreakpoints;
  112. end;
  113. procedure TDebugController.InsertBreakpoints;
  114. procedure DoInsert(PB : PBreakpoint);
  115. begin
  116. PB^.Insert;
  117. end;
  118. begin
  119. BreakpointCollection^.ForEach(@DoInsert);
  120. end;
  121. procedure TDebugController.RemoveBreakpoints;
  122. procedure DoDelete(PB : PBreakpoint);
  123. begin
  124. PB^.Remove;
  125. end;
  126. begin
  127. BreakpointCollection^.ForEach(@DoDelete);
  128. end;
  129. procedure TDebugController.ResetBreakpointsValues;
  130. procedure DoResetVal(PB : PBreakpoint);
  131. begin
  132. PB^.ResetValues;
  133. end;
  134. begin
  135. BreakpointCollection^.ForEach(@DoResetVal);
  136. end;
  137. destructor TDebugController.Done;
  138. begin
  139. { kill the program if running }
  140. Reset;
  141. RemoveBreakpoints;
  142. inherited Done;
  143. end;
  144. procedure TDebugController.Run;
  145. begin
  146. ResetBreakpointsValues;
  147. inherited Run;
  148. MyApp.SetCmdState([cmResetDebugger],true);
  149. end;
  150. procedure TDebugController.Continue;
  151. begin
  152. if not debugger_started then
  153. Run;
  154. inherited Continue;
  155. end;
  156. procedure TDebugController.CommandBegin(const s:string);
  157. begin
  158. if assigned(GDBWindow) and (in_command>1) then
  159. begin
  160. { We should do something special for errors !! }
  161. If StrLen(GetError)>0 then
  162. GDBWindow^.WriteErrorText(GetError);
  163. GDBWindow^.WriteOutputText(GetOutput);
  164. end;
  165. if assigned(GDBWindow) then
  166. GDBWindow^.WriteString(S);
  167. end;
  168. procedure TDebugController.CommandEnd(const s:string);
  169. begin
  170. if assigned(GDBWindow) and (in_command=0) then
  171. begin
  172. { We should do somethnig special for errors !! }
  173. If StrLen(GetError)>0 then
  174. GDBWindow^.WriteErrorText(GetError);
  175. GDBWindow^.WriteOutputText(GetOutput);
  176. GDBWindow^.Editor^.TextEnd;
  177. end;
  178. end;
  179. procedure TDebugController.Reset;
  180. var
  181. W : PSourceWindow;
  182. begin
  183. inherited Reset;
  184. MyApp.SetCmdState([cmResetDebugger],false);
  185. W:=PSourceWindow(LastSource);
  186. if assigned(W) then
  187. W^.Editor^.SetHighlightRow(-1);
  188. end;
  189. procedure TDebugController.AnnotateError;
  190. var errornb : longint;
  191. begin
  192. if error then
  193. begin
  194. errornb:=error_num;
  195. ErrorBox(#3'Error within GDB'#13#3'Error code = %d',@errornb);
  196. end;
  197. end;
  198. procedure TDebugController.DoSelectSourceLine(const fn:string;line:longint);
  199. var
  200. W: PSourceWindow;
  201. Found : boolean;
  202. PB : PBreakpoint;
  203. S : String;
  204. BreakIndex : longint;
  205. begin
  206. BreakIndex:=stop_breakpoint_number;
  207. Desktop^.Lock;
  208. if Line>0 then
  209. dec(Line);
  210. if (fn=LastFileName) then
  211. begin
  212. W:=PSourceWindow(LastSource);
  213. if assigned(W) then
  214. begin
  215. W^.Editor^.SetCurPtr(0,Line);
  216. W^.Editor^.TrackCursor(true);
  217. W^.Editor^.SetHighlightRow(Line);
  218. if Not assigned(GDBWindow) or not GDBWindow^.GetState(sfActive) then
  219. W^.Select;
  220. InvalidSourceLine:=false;
  221. end
  222. else
  223. InvalidSourceLine:=true;
  224. end
  225. else
  226. begin
  227. W:=TryToOpenFile(nil,fn,0,Line,false);
  228. if assigned(W) then
  229. begin
  230. W^.Editor^.SetHighlightRow(Line);
  231. W^.Editor^.TrackCursor(true);
  232. if Not assigned(GDBWindow) or not GDBWindow^.GetState(sfActive) then
  233. W^.Select;
  234. LastSource:=W;
  235. InvalidSourceLine:=false;
  236. end
  237. { only search a file once }
  238. else
  239. begin
  240. Desktop^.UnLock;
  241. Found:=MyApp.OpenSearch(fn);
  242. Desktop^.Lock;
  243. if not Found then
  244. begin
  245. InvalidSourceLine:=true;
  246. LastSource:=Nil;
  247. end
  248. else
  249. begin
  250. { should now be open }
  251. W:=TryToOpenFile(nil,fn,0,Line,true);
  252. W^.Editor^.SetHighlightRow(Line);
  253. W^.Editor^.TrackCursor(true);
  254. if Not assigned(GDBWindow) or not GDBWindow^.GetState(sfActive) then
  255. W^.Select;
  256. LastSource:=W;
  257. InvalidSourceLine:=false;
  258. end;
  259. end;
  260. end;
  261. LastFileName:=fn;
  262. Desktop^.UnLock;
  263. if BreakIndex>0 then
  264. begin
  265. PB:=BreakpointCollection^.GetGDB(stop_breakpoint_number);
  266. { For watch we should get old and new value !! }
  267. if (Not assigned(GDBWindow) or not GDBWindow^.GetState(sfActive)) and
  268. (PB^.typ<>bt_file_line) then
  269. begin
  270. Command('p '+GetStr(PB^.Name));
  271. S:=StrPas(GetOutput);
  272. If Pos('=',S)>0 then
  273. S:=Copy(S,Pos('=',S)+1,255);
  274. If S[Length(S)]=#10 then
  275. Delete(S,Length(S),1);
  276. if Assigned(PB^.OldValue) then
  277. DisposeStr(PB^.OldValue);
  278. PB^.OldValue:=PB^.CurrentValue;
  279. PB^.CurrentValue:=NewStr(S);
  280. If PB^.typ=bt_function then
  281. WarningBox(#3'GDB stopped due to'#13+
  282. #3+BreakpointTypeStr[PB^.typ]+' '+GetStr(PB^.Name),nil)
  283. else if (GetStr(PB^.OldValue)<>S) then
  284. WarningBox(#3'GDB stopped due to'#13+
  285. #3+BreakpointTypeStr[PB^.typ]+' '+GetStr(PB^.Name)+#13+
  286. #3+'Old value = '+GetStr(PB^.OldValue)+#13+
  287. #3+'New value = '+GetStr(PB^.CurrentValue),nil)
  288. else
  289. WarningBox(#3'GDB stopped due to'#13+
  290. #3+BreakpointTypeStr[PB^.typ]+' '+GetStr(PB^.Name)+#13+
  291. #3+' value = '+GetStr(PB^.CurrentValue),nil);
  292. end;
  293. end;
  294. end;
  295. procedure TDebugController.DoEndSession(code:longint);
  296. var P :Array[1..2] of longint;
  297. W : PSourceWindow;
  298. begin
  299. MyApp.SetCmdState([cmResetDebugger],false);
  300. W:=PSourceWindow(LastSource);
  301. if assigned(W) then
  302. W^.Editor^.SetHighlightRow(-1);
  303. If HiddenStepsCount=0 then
  304. InformationBox(#3'Program exited with '#13#3'exitcode = %d',@code)
  305. else
  306. begin
  307. P[1]:=code;
  308. P[2]:=HiddenStepsCount;
  309. WarningBox(#3'Program exited with '#13+
  310. #3'exitcode = %d'#13+
  311. #3'hidden steps = %d',@P);
  312. end;
  313. end;
  314. procedure TDebugController.DoDebuggerScreen;
  315. begin
  316. MyApp.ShowIDEScreen;
  317. end;
  318. procedure TDebugController.DoUserScreen;
  319. begin
  320. MyApp.ShowUserScreen;
  321. end;
  322. {****************************************************************************
  323. TBreakpoint
  324. ****************************************************************************}
  325. constructor TBreakpoint.Init_function(Const AFunc : String);
  326. begin
  327. typ:=bt_function;
  328. state:=bs_enabled;
  329. GDBState:=bs_deleted;
  330. Name:=NewStr(AFunc);
  331. FileName:=nil;
  332. Line:=0;
  333. IgnoreCount:=0;
  334. Commands:=nil;
  335. Conditions:=nil;
  336. OldValue:=nil;
  337. CurrentValue:=nil;
  338. end;
  339. constructor TBreakpoint.Init_type(atyp : BreakpointType;Const AnExpr : String);
  340. begin
  341. typ:=atyp;
  342. state:=bs_enabled;
  343. GDBState:=bs_deleted;
  344. Name:=NewStr(AnExpr);
  345. IgnoreCount:=0;
  346. Commands:=nil;
  347. Conditions:=nil;
  348. OldValue:=nil;
  349. CurrentValue:=nil;
  350. end;
  351. constructor TBreakpoint.Init_file_line(AFile : String; ALine : longint);
  352. begin
  353. typ:=bt_file_line;
  354. state:=bs_enabled;
  355. GDBState:=bs_deleted;
  356. { d:test.pas:12 does not work !! }
  357. { I do not know how to solve this if
  358. if (Length(AFile)>1) and (AFile[2]=':') then
  359. AFile:=Copy(AFile,3,255);
  360. Only use base name for now !! PM }
  361. FileName:=NewStr(AFile);
  362. Name:=nil;
  363. Line:=ALine;
  364. IgnoreCount:=0;
  365. Commands:=nil;
  366. Conditions:=nil;
  367. OldValue:=nil;
  368. CurrentValue:=nil;
  369. end;
  370. procedure TBreakpoint.Insert;
  371. begin
  372. If not assigned(Debugger) then Exit;
  373. Remove;
  374. Debugger^.last_breakpoint_number:=0;
  375. if (GDBState=bs_deleted) and (state=bs_enabled) then
  376. begin
  377. if (typ=bt_file_line) then
  378. Debugger^.Command('break '+NameAndExtOf(FileName^)+':'+IntToStr(Line))
  379. else if typ=bt_function then
  380. Debugger^.Command('break '+name^)
  381. else if typ=bt_watch then
  382. Debugger^.Command('watch '+name^)
  383. else if typ=bt_awatch then
  384. Debugger^.Command('awatch '+name^)
  385. else if typ=bt_rwatch then
  386. Debugger^.Command('rwatch '+name^);
  387. if Debugger^.last_breakpoint_number<>0 then
  388. begin
  389. GDBIndex:=Debugger^.last_breakpoint_number;
  390. GDBState:=bs_enabled;
  391. Debugger^.Command('cond '+IntToStr(GDBIndex)+' '+GetStr(Conditions));
  392. Debugger^.Command('ignore '+IntToStr(GDBIndex)+' '+IntToStr(IgnoreCount));
  393. If Assigned(Commands) then
  394. begin
  395. {Commands are not handled yet }
  396. end;
  397. end
  398. else
  399. { Here there was a problem !! }
  400. begin
  401. GDBIndex:=0;
  402. ErrorBox(#3'Could not set Breakpoint'#13+
  403. #3+BreakpointTypeStr[typ]+' '+Name^,nil);
  404. state:=bs_disabled;
  405. end;
  406. end
  407. else if (GDBState=bs_disabled) and (state=bs_enabled) then
  408. Enable
  409. else if (GDBState=bs_enabled) and (state=bs_disabled) then
  410. Disable;
  411. end;
  412. procedure TBreakpoint.Remove;
  413. begin
  414. If not assigned(Debugger) then Exit;
  415. if GDBIndex>0 then
  416. Debugger^.Command('delete '+IntToStr(GDBIndex));
  417. GDBIndex:=0;
  418. GDBState:=bs_deleted;
  419. end;
  420. procedure TBreakpoint.Enable;
  421. begin
  422. If not assigned(Debugger) then Exit;
  423. if GDBIndex>0 then
  424. Debugger^.Command('enable '+IntToStr(GDBIndex))
  425. else
  426. Insert;
  427. GDBState:=bs_enabled;
  428. end;
  429. procedure TBreakpoint.Disable;
  430. begin
  431. If not assigned(Debugger) then Exit;
  432. if GDBIndex>0 then
  433. Debugger^.Command('disable '+IntToStr(GDBIndex));
  434. GDBState:=bs_disabled;
  435. end;
  436. procedure TBreakpoint.ResetValues;
  437. begin
  438. if assigned(OldValue) then
  439. DisposeStr(OldValue);
  440. OldValue:=nil;
  441. if assigned(CurrentValue) then
  442. DisposeStr(CurrentValue);
  443. CurrentValue:=nil;
  444. end;
  445. destructor TBreakpoint.Done;
  446. begin
  447. Remove;
  448. ResetValues;
  449. if assigned(Name) then
  450. DisposeStr(Name);
  451. if assigned(FileName) then
  452. DisposeStr(FileName);
  453. if assigned(Conditions) then
  454. DisposeStr(Conditions);
  455. if assigned(Commands) then
  456. StrDispose(Commands);
  457. inherited Done;
  458. end;
  459. {****************************************************************************
  460. TBreakpointCollection
  461. ****************************************************************************}
  462. function TBreakpointCollection.At(Index: Integer): PBreakpoint;
  463. begin
  464. At:=inherited At(Index);
  465. end;
  466. procedure TBreakpointCollection.FreeItem(Item: Pointer);
  467. begin
  468. if Item<>nil then
  469. Dispose(PBreakpoint(Item),Done);
  470. end;
  471. procedure TBreakpointCollection.Update;
  472. begin
  473. if assigned(Debugger) then
  474. begin
  475. Debugger^.RemoveBreakpoints;
  476. Debugger^.InsertBreakpoints;
  477. end;
  478. end;
  479. function TBreakpointCollection.GetGDB(index : longint) : PBreakpoint;
  480. function IsNum(P : PBreakpoint) : boolean;{$ifndef FPC}far;{$endif}
  481. begin
  482. IsNum:=P^.GDBIndex=index;
  483. end;
  484. begin
  485. if index=0 then
  486. GetGDB:=nil
  487. else
  488. GetGDB:=FirstThat(@IsNum);
  489. end;
  490. procedure TBreakpointCollection.ShowBreakpoints(W : PSourceWindow);
  491. procedure SetInSource(P : PBreakpoint);{$ifndef FPC}far;{$endif}
  492. begin
  493. If assigned(P^.FileName) and (P^.FileName^=W^.Editor^.FileName) then
  494. W^.Editor^.SetLineBreakState(P^.Line,P^.state=bs_enabled);
  495. end;
  496. begin
  497. ForEach(@SetInSource);
  498. end;
  499. function TBreakpointCollection.GetType(typ : BreakpointType;Const s : String) : PBreakpoint;
  500. function IsThis(P : PBreakpoint) : boolean;{$ifndef FPC}far;{$endif}
  501. begin
  502. IsThis:=(P^.typ=typ) and (P^.Name^=S);
  503. end;
  504. begin
  505. GetType:=FirstThat(@IsThis);
  506. end;
  507. function TBreakpointCollection.ToggleFileLine(Const FileName: String;LineNr : Longint) : boolean;
  508. var PB : PBreakpoint;
  509. function IsThere(P : PBreakpoint) : boolean;{$ifndef FPC}far;{$endif}
  510. begin
  511. IsThere:=(P^.typ=bt_file_line) and (P^.FileName^=FileName) and (P^.Line=LineNr);
  512. end;
  513. begin
  514. PB:=FirstThat(@IsThere);
  515. ToggleFileLine:=false;
  516. If Assigned(PB) then
  517. if PB^.state=bs_disabled then
  518. begin
  519. PB^.state:=bs_enabled;
  520. ToggleFileLine:=true;
  521. end
  522. else if PB^.state=bs_enabled then
  523. PB^.state:=bs_disabled;
  524. If not assigned(PB) then
  525. begin
  526. PB:= New(PBreakpoint,Init_file_line(FileName,LineNr));
  527. if assigned(PB) then
  528. Begin
  529. Insert(PB);
  530. ToggleFileLine:=true;
  531. End;
  532. end;
  533. Update;
  534. end;
  535. {****************************************************************************
  536. Initialize
  537. ****************************************************************************}
  538. procedure InitDebugger;
  539. begin
  540. {$ifdef DEBUG}
  541. Assign(gdb_file,'gdb$$$.out');
  542. Rewrite(gdb_file);
  543. Use_gdb_file:=true;
  544. {$endif}
  545. if (not ExistsFile(ExeFile)) or (CompilationPhase<>cpDone) then
  546. DoCompile(cRun);
  547. if CompilationPhase<>cpDone then
  548. Exit;
  549. if (EXEFile='') then
  550. begin
  551. ErrorBox('Oooops, nothing to debug.',nil);
  552. Exit;
  553. end;
  554. { init debugcontroller }
  555. if assigned(Debugger) then
  556. dispose(Debugger,Done);
  557. new(Debugger,Init(ExeFile));
  558. {$ifdef GDBWINDOW}
  559. InitGDBWindow;
  560. {$endif def GDBWINDOW}
  561. end;
  562. procedure DoneDebugger;
  563. begin
  564. if assigned(Debugger) then
  565. dispose(Debugger,Done);
  566. Debugger:=nil;
  567. {$ifdef DEBUG}
  568. If Use_gdb_file then
  569. Close(GDB_file);
  570. Use_gdb_file:=false;
  571. {$endif}
  572. {DoneGDBWindow;}
  573. end;
  574. procedure InitGDBWindow;
  575. var
  576. R : TRect;
  577. begin
  578. if GDBWindow=nil then
  579. begin
  580. DeskTop^.GetExtent(R);
  581. new(GDBWindow,init(R));
  582. DeskTop^.Insert(GDBWindow);
  583. end;
  584. end;
  585. procedure DoneGDBWindow;
  586. begin
  587. if assigned(GDBWindow) then
  588. begin
  589. DeskTop^.Delete(GDBWindow);
  590. GDBWindow:=nil;
  591. end;
  592. end;
  593. procedure InitBreakpoints;
  594. begin
  595. New(BreakpointCollection,init(10,10));
  596. end;
  597. procedure DoneBreakpoints;
  598. begin
  599. Dispose(BreakpointCollection,Done);
  600. BreakpointCollection:=nil;
  601. end;
  602. end.
  603. {
  604. $Log$
  605. Revision 1.18 1999-03-16 00:44:42 peter
  606. * forgotten in last commit :(
  607. Revision 1.17 1999/03/02 13:48:28 peter
  608. * fixed far problem is fpdebug
  609. * tile/cascading with message window
  610. * grep fixes
  611. Revision 1.16 1999/03/01 15:41:52 peter
  612. + Added dummy entries for functions not yet implemented
  613. * MenuBar didn't update itself automatically on command-set changes
  614. * Fixed Debugging/Profiling options dialog
  615. * TCodeEditor converts spaces to tabs at save only if efUseTabChars is
  616. set
  617. * efBackSpaceUnindents works correctly
  618. + 'Messages' window implemented
  619. + Added '$CAP MSG()' and '$CAP EDIT' to available tool-macros
  620. + Added TP message-filter support (for ex. you can call GREP thru
  621. GREP2MSG and view the result in the messages window - just like in TP)
  622. * A 'var' was missing from the param-list of THelpFacility.TopicSearch,
  623. so topic search didn't work...
  624. * In FPHELP.PAS there were still context-variables defined as word instead
  625. of THelpCtx
  626. * StdStatusKeys() was missing from the statusdef for help windows
  627. + Topic-title for index-table can be specified when adding a HTML-files
  628. Revision 1.15 1999/02/20 15:18:29 peter
  629. + ctrl-c capture with confirm dialog
  630. + ascii table in the tools menu
  631. + heapviewer
  632. * empty file fixed
  633. * fixed callback routines in fpdebug to have far for tp7
  634. Revision 1.14 1999/02/16 12:47:36 pierre
  635. * GDBWindow does not popup on F7 or F8 anymore
  636. Revision 1.13 1999/02/16 10:43:54 peter
  637. * use -dGDB for the compiler
  638. * only use gdb_file when -dDEBUG is used
  639. * profiler switch is now a toggle instead of radiobutton
  640. Revision 1.12 1999/02/11 19:07:20 pierre
  641. * GDBWindow redesigned :
  642. normal editor apart from
  643. that any kbEnter will send the line (for begin to cursor)
  644. to GDB command !
  645. GDBWindow opened in Debugger Menu
  646. still buggy :
  647. -echo should not be present if at end of text
  648. -GDBWindow becomes First after each step (I don't know why !)
  649. Revision 1.11 1999/02/11 13:10:03 pierre
  650. + GDBWindow only with -dGDBWindow for now : still buggy !!
  651. Revision 1.10 1999/02/10 09:55:07 pierre
  652. + added OldValue and CurrentValue field for watchpoints
  653. + InitBreakpoints and DoneBreakpoints
  654. + MessageBox if GDB stops bacause of a watchpoint !
  655. Revision 1.9 1999/02/08 17:43:43 pierre
  656. * RestDebugger or multiple running of debugged program now works
  657. + added DoContToCursor(F4)
  658. * Breakpoints are now inserted correctly (was mainlyy a problem
  659. of directories)
  660. Revision 1.8 1999/02/05 17:21:52 pierre
  661. Invalid_line renamed InvalidSourceLine
  662. Revision 1.7 1999/02/05 13:08:41 pierre
  663. + new breakpoint types added
  664. Revision 1.6 1999/02/05 12:11:53 pierre
  665. + SourceDir that stores directories for sources that the
  666. compiler should not know about
  667. Automatically asked for addition when a new file that
  668. needed filedialog to be found is in an unknown directory
  669. Stored and retrieved from INIFile
  670. + Breakpoints conditions added to INIFile
  671. * Breakpoints insterted and removed at debin and end of debug session
  672. Revision 1.5 1999/02/04 17:54:22 pierre
  673. + several commands added
  674. Revision 1.4 1999/02/04 13:32:02 pierre
  675. * Several things added (I cannot commit them independently !)
  676. + added TBreakpoint and TBreakpointCollection
  677. + added cmResetDebugger,cmGrep,CmToggleBreakpoint
  678. + Breakpoint list in INIFile
  679. * Select items now also depend of SwitchMode
  680. * Reading of option '-g' was not possible !
  681. + added search for -Fu args pathes in TryToOpen
  682. + added code for automatic opening of FileDialog
  683. if source not found
  684. Revision 1.3 1999/02/02 16:41:38 peter
  685. + automatic .pas/.pp adding by opening of file
  686. * better debuggerscreen changes
  687. Revision 1.2 1999/01/22 18:14:09 pierre
  688. * adaptd to changes in gdbint and gdbcon for to /
  689. Revision 1.1 1999/01/22 10:24:03 peter
  690. * first debugger things
  691. }