fpsymbol.pas 35 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249
  1. {
  2. $Id$
  3. This file is part of the Free Pascal Integrated Development Environment
  4. Copyright (c) 1998 by Berczi Gabor
  5. Symbol browse support 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 FPSymbol;
  13. interface
  14. uses Objects,Drivers,Views,Dialogs,Outline,
  15. BrowCol,
  16. FPViews;
  17. const
  18. { Browser tab constants }
  19. btScope = 0;
  20. btReferences = 1;
  21. btInheritance = 2;
  22. btMemInfo = 3;
  23. btBreakWatch = 4;
  24. type
  25. PSymbolView = ^TSymbolView;
  26. TSymbolView = object(TListBox)
  27. constructor Init(var Bounds: TRect; AHScrollBar, AVScrollBar: PScrollBar);
  28. procedure HandleEvent(var Event: TEvent); virtual;
  29. procedure GotoItem(Item: sw_integer); virtual;
  30. procedure TrackItem(Item: sw_integer); virtual;
  31. function GetPalette: PPalette; virtual;
  32. private
  33. function TrackReference(R: PReference): boolean; virtual;
  34. function GotoReference(R: PReference): boolean; virtual;
  35. end;
  36. PSymbolScopeView = ^TSymbolScopeView;
  37. TSymbolScopeView = object(TSymbolView)
  38. constructor Init(var Bounds: TRect; ASymbols: PSymbolCollection; AHScrollBar, AVScrollBar: PScrollBar);
  39. destructor Done; virtual;
  40. function GetText(Item,MaxLen: Sw_Integer): String; virtual;
  41. procedure HandleEvent(var Event: TEvent); virtual;
  42. procedure Draw; virtual;
  43. procedure LookUp(S: string); virtual;
  44. procedure GotoItem(Item: sw_integer); virtual;
  45. procedure TrackItem(Item: sw_integer); virtual;
  46. private
  47. Symbols: PSymbolCollection;
  48. LookupStr: string;
  49. end;
  50. PSymbolReferenceView = ^TSymbolReferenceView;
  51. TSymbolReferenceView = object(TSymbolView)
  52. constructor Init(var Bounds: TRect; AReferences: PReferenceCollection; AHScrollBar, AVScrollBar: PScrollBar);
  53. destructor Done; virtual;
  54. procedure HandleEvent(var Event: TEvent); virtual;
  55. function GetText(Item,MaxLen: Sw_Integer): String; virtual;
  56. procedure SelectItem(Item: Sw_Integer); virtual;
  57. procedure GotoItem(Item: sw_integer); virtual;
  58. procedure TrackItem(Item: sw_integer); virtual;
  59. private
  60. References: PReferenceCollection;
  61. end;
  62. PSymbolMemInfoView = ^TSymbolMemInfoView;
  63. TSymbolMemInfoView = object(TStaticText)
  64. constructor Init(var Bounds: TRect; AMemInfo: PSymbolMemInfo);
  65. destructor Done; virtual;
  66. procedure GetText(var S: String); virtual;
  67. function GetPalette: PPalette; virtual;
  68. private
  69. MemInfo: PSymbolMemInfo;
  70. end;
  71. PSymbolInheritanceView = ^TSymbolInheritanceView;
  72. TSymbolInheritanceView = object(TOutlineViewer)
  73. constructor Init(var Bounds: TRect; AHScrollBar, AVScrollBar: PScrollBar; ARoot: PObjectSymbol);
  74. destructor Done; virtual;
  75. function GetRoot: Pointer; virtual;
  76. function HasChildren(Node: Pointer): Boolean; virtual;
  77. function GetChild(Node: Pointer; I: Integer): Pointer; virtual;
  78. function GetNumChildren(Node: Pointer): Integer; virtual;
  79. function GetText(Node: Pointer): String; virtual;
  80. procedure Adjust(Node: Pointer; Expand: Boolean); virtual;
  81. function IsExpanded(Node: Pointer): Boolean; virtual;
  82. procedure Selected(I: Integer); virtual;
  83. function GetPalette: PPalette; virtual;
  84. private
  85. Root: PObjectSymbol;
  86. end;
  87. PBrowserTabItem = ^TBrowserTabItem;
  88. TBrowserTabItem = record
  89. Sign : char;
  90. Link : PView;
  91. Next : PBrowserTabItem;
  92. end;
  93. PBrowserTab = ^TBrowserTab;
  94. TBrowserTab = object(TView)
  95. Items: PBrowserTabItem;
  96. constructor Init(var Bounds: TRect; AItems: PBrowserTabItem);
  97. function GetItemCount: sw_integer; virtual;
  98. function GetItem(Index: sw_integer): PBrowserTabItem; virtual;
  99. procedure SetParams(AFlags: word; ACurrent: Sw_integer); virtual;
  100. procedure SelectItem(Index: Sw_integer); virtual;
  101. procedure Draw; virtual;
  102. function GetPalette: PPalette; virtual;
  103. procedure HandleEvent(var Event: TEvent); virtual;
  104. destructor Done; virtual;
  105. private
  106. Flags : word;
  107. Current : Sw_integer;
  108. end;
  109. PBrowserWindow = ^TBrowserWindow;
  110. TBrowserWindow = object(TFPWindow)
  111. constructor Init(var Bounds: TRect; ATitle: TTitleStr; ANumber: Sw_Integer;ASym : PSymbol;
  112. const AName: string; ASymbols: PSymbolCollection; AReferences: PReferenceCollection;
  113. AInheritance: PObjectSymbol; AMemInfo: PSymbolMemInfo);
  114. procedure HandleEvent(var Event: TEvent); virtual;
  115. procedure SetState(AState: Word; Enable: Boolean); virtual;
  116. procedure Close; virtual;
  117. procedure SelectTab(BrowserTab: Sw_integer); virtual;
  118. function GetPalette: PPalette; virtual;
  119. private
  120. PageTab : PBrowserTab;
  121. Sym : PSymbol;
  122. ScopeView : PSymbolScopeView;
  123. ReferenceView : PSymbolReferenceView;
  124. InheritanceView: PSymbolInheritanceView;
  125. MemInfoView : PSymbolMemInfoView;
  126. end;
  127. procedure OpenSymbolBrowser(X,Y: Sw_integer;const Name,Line: string;S : PSymbol;
  128. Symbols: PSymbolCollection; References: PReferenceCollection;
  129. Inheritance: PObjectSymbol; MemInfo: PSymbolMemInfo);
  130. function IsSymbolInfoAvailable: boolean;
  131. procedure OpenOneSymbolBrowser(Name : String);
  132. procedure CloseAllBrowsers;
  133. procedure RemoveBrowsersCollection;
  134. const
  135. GlobalsCollection : PSortedCollection = nil;
  136. ModulesCollection : PSortedCollection = nil;
  137. implementation
  138. uses Commands,App,
  139. WEditor,WViews,
  140. FPConst,FPUtils,FPVars,{$ifndef FPDEBUG}FPDebug{$endif};
  141. procedure CloseAllBrowsers;
  142. procedure SendCloseIfBrowser(P: PView); {$ifndef FPC}far;{$endif}
  143. begin
  144. if assigned(P) and
  145. ((TypeOf(P^)=TypeOf(TBrowserWindow)) or
  146. (TypeOf(P^)=TypeOf(TSymbolView)) or
  147. (TypeOf(P^)=TypeOf(TSymbolScopeView)) or
  148. (TypeOf(P^)=TypeOf(TSymbolReferenceView)) or
  149. (TypeOf(P^)=TypeOf(TSymbolMemInfoView)) or
  150. (TypeOf(P^)=TypeOf(TSymbolInheritanceView))) then
  151. Message(P,evCommand,cmClose,nil);
  152. end;
  153. begin
  154. Desktop^.ForEach(@SendCloseIfBrowser);
  155. end;
  156. procedure RemoveBrowsersCollection;
  157. begin
  158. if assigned(GlobalsCollection) then
  159. begin
  160. GlobalsCollection^.deleteAll;
  161. Dispose(GlobalsCollection,done);
  162. GlobalsCollection:=nil;
  163. end;
  164. if assigned(ModulesCollection) then
  165. begin
  166. ModulesCollection^.deleteAll;
  167. Dispose(ModulesCollection,done);
  168. ModulesCollection:=nil;
  169. end;
  170. end;
  171. function NewBrowserTabItem(ASign: char; ALink: PView; ANext: PBrowserTabItem): PBrowserTabItem;
  172. var P: PBrowserTabItem;
  173. begin
  174. New(P); FillChar(P^,SizeOf(P^),0);
  175. with P^ do begin Sign:=ASign; Link:=ALink; Next:=ANext; end;
  176. NewBrowserTabItem:=P;
  177. end;
  178. procedure DisposeBrowserTabItem(P: PBrowserTabItem);
  179. begin
  180. if P<>nil then Dispose(P);
  181. end;
  182. procedure DisposeBrowserTabList(P: PBrowserTabItem);
  183. begin
  184. if P<>nil then
  185. begin
  186. if P^.Next<>nil then DisposeBrowserTabList(P^.Next);
  187. DisposeBrowserTabItem(P);
  188. end;
  189. end;
  190. function IsSymbolInfoAvailable: boolean;
  191. begin
  192. IsSymbolInfoAvailable:=BrowCol.Modules<>nil;
  193. end;
  194. procedure OpenOneSymbolBrowser(Name : String);
  195. var Index : sw_integer;
  196. PS : PSymbol;
  197. P : Pstring;
  198. function Search(P : PSymbol) : boolean;
  199. begin
  200. Search:=UpcaseStr(P^.Items^.LookUp(Name,Index))=Name;
  201. end;
  202. begin
  203. Name:=UpcaseStr(Name);
  204. If BrowCol.Modules<>nil then
  205. begin
  206. PS:=BrowCol.Modules^.FirstThat(@Search);
  207. If assigned(PS) then
  208. OpenSymbolBrowser(0,20,
  209. PS^.Items^.At(Index)^.GetName,'',PS^.Items^.At(Index),
  210. PS^.Items^.At(Index)^.Items,PS^.Items^.At(Index)^.References,nil,PS^.MemInfo)
  211. else
  212. begin
  213. P:=@Name;
  214. ErrorBox(#3'Symbol %s not found',@P);
  215. end;
  216. end
  217. else
  218. ErrorBox('No Browser info available',nil);
  219. end;
  220. (*procedure ReadBrowseLog(FileName: string);
  221. var f: text;
  222. IOOK,EndOfFile: boolean;
  223. Line: string;
  224. procedure NextLine;
  225. begin
  226. readln(f,Line);
  227. EndOfFile:=Eof(f);
  228. end;
  229. var Level: integer;
  230. procedure ProcessSymTable(Indent: integer; Owner: PSymbolCollection);
  231. var IndentS,S,Source: string;
  232. Sym: PSymbol;
  233. Ref: PSymbolReference;
  234. P: byte;
  235. PX: TPoint;
  236. PS: PString;
  237. PCount: integer;
  238. Params: array[0..30] of PString;
  239. Typ: tsymtyp;
  240. ExitBack: boolean;
  241. begin
  242. Inc(Level);
  243. IndentS:=CharStr(' ',Indent); ExitBack:=false;
  244. Sym:=nil;
  245. repeat
  246. if copy(Line,1,length(IndentS))<>IndentS then ExitBack:=true else
  247. if copy(Line,Indent+1,3)='***' then
  248. { new symbol }
  249. begin
  250. S:=copy(Line,Indent+1+3,255);
  251. P:=Pos('***',S); if P=0 then P:=length(S)+1;
  252. S:=Trim(copy(S,1,P-1));
  253. if (copy(S,1,1)='_') and (Pos('$$',S)>0) then
  254. begin
  255. repeat
  256. P:=Pos('$$',S);
  257. if P>0 then Delete(S,1,P+1);
  258. until P=0;
  259. P:=Pos('$',S);
  260. Delete(S,1,P);
  261. PCount:=0;
  262. repeat
  263. P:=Pos('$',S); if P=0 then P:=length(S)+1;
  264. Params[PCount]:=TypeNames^.Add(copy(S,1,P-1));
  265. Inc(PCount);
  266. Delete(S,1,P);
  267. until S='';
  268. Sym^.Typ:=procsym;
  269. Sym^.SetParams(PCount,@Params);
  270. end
  271. else
  272. New(Sym, Init(S, varsym, 0, nil));
  273. Owner^.Insert(Sym);
  274. NextLine;
  275. end else
  276. if copy(Line,Indent+1,3)='---' then
  277. { child symtable }
  278. begin
  279. S:=Trim(copy(Line,Indent+1+12,255));
  280. if Level=1 then Typ:=unitsym else
  281. Typ:=typesym;
  282. if (Sym<>nil) and (Sym^.GetName=S) then
  283. else
  284. begin
  285. New(Sym, Init(S, Typ, 0, nil));
  286. Owner^.Insert(Sym);
  287. end;
  288. Sym^.Typ:=Typ;
  289. NextLine;
  290. New(Sym^.Items, Init(0,50));
  291. ProcessSymTable(Indent+2,Sym^.Items);
  292. end else
  293. { if Sym<>nil then}
  294. if copy(Line,Indent+1,1)=' ' then
  295. { reference }
  296. begin
  297. S:=copy(Line,Indent+1+2,255);
  298. P:=Pos('(',S); if P=0 then P:=length(S)+1;
  299. Source:=Trim(copy(S,1,P-1)); Delete(S,1,P);
  300. P:=Pos(',',S); if P=0 then P:=length(S)+1;
  301. PX.Y:=StrToInt(copy(S,1,P-1)); Delete(S,1,P);
  302. P:=Pos(')',S); if P=0 then P:=length(S)+1;
  303. PX.X:=StrToInt(copy(S,1,P-1)); Delete(S,1,P);
  304. PS:=ModuleNames^.Add(Source);
  305. New(Ref, Init(PS, PX));
  306. if Sym^.References=nil then
  307. New(Sym^.References, Init(10,50));
  308. Sym^.References^.Insert(Ref);
  309. end;
  310. if ExitBack=false then
  311. NextLine;
  312. until EndOfFile or ExitBack;
  313. Dec(Level);
  314. end;
  315. begin
  316. DoneSymbolBrowser;
  317. InitSymbolBrowser;
  318. {$I-}
  319. Assign(f,FileName);
  320. Reset(f);
  321. Level:=0;
  322. NextLine;
  323. while (IOResult=0) and (EndOfFile=false) do
  324. ProcessSymTable(0,Modules);
  325. Close(f);
  326. EatIO;
  327. {$I+}
  328. end;*)
  329. {****************************************************************************
  330. TSymbolView
  331. ****************************************************************************}
  332. constructor TSymbolView.Init(var Bounds: TRect; AHScrollBar, AVScrollBar: PScrollBar);
  333. begin
  334. inherited Init(Bounds,1,AVScrollBar);
  335. HScrollBar:=AHScrollBar;
  336. if assigned(HScrollBar) then
  337. HScrollBar^.SetRange(1,80);
  338. Options:=Options or (ofSelectable+ofTopSelect);
  339. end;
  340. procedure TSymbolView.HandleEvent(var Event: TEvent);
  341. var DontClear: boolean;
  342. begin
  343. case Event.What of
  344. evKeyDown :
  345. begin
  346. DontClear:=false;
  347. case Event.KeyCode of
  348. kbEnter :
  349. GotoItem(Focused);
  350. kbSpaceBar :
  351. TrackItem(Focused);
  352. kbRight,kbLeft :
  353. if HScrollBar<>nil then
  354. HScrollBar^.HandleEvent(Event);
  355. else DontClear:=true;
  356. end;
  357. if DontClear=false then ClearEvent(Event);
  358. end;
  359. evMouseDown :
  360. if Event.double then
  361. GotoItem(Focused);
  362. end;
  363. inherited HandleEvent(Event);
  364. end;
  365. function TSymbolView.GetPalette: PPalette;
  366. const
  367. P: string[length(CBrowserListBox)] = CBrowserListBox;
  368. begin
  369. GetPalette:=@P;
  370. end;
  371. procedure TSymbolView.GotoItem(Item: sw_integer);
  372. begin
  373. SelectItem(Item);
  374. end;
  375. procedure TSymbolView.TrackItem(Item: sw_integer);
  376. begin
  377. SelectItem(Item);
  378. end;
  379. function LastBrowserWindow: PBrowserWindow;
  380. var BW: PBrowserWindow;
  381. procedure IsBW(P: PView); {$ifndef FPC}far;{$endif}
  382. begin
  383. if (P^.HelpCtx=hcBrowserWindow) then
  384. BW:=pointer(P);
  385. end;
  386. begin
  387. BW:=nil;
  388. Desktop^.ForEach(@IsBW);
  389. LastBrowserWindow:=BW;
  390. end;
  391. function TSymbolView.TrackReference(R: PReference): boolean;
  392. var W: PSourceWindow;
  393. BW: PBrowserWindow;
  394. P: TPoint;
  395. begin
  396. Message(Desktop,evBroadcast,cmClearLineHighlights,nil);
  397. Desktop^.Lock;
  398. P.X:=R^.Position.X-1; P.Y:=R^.Position.Y-1;
  399. W:=TryToOpenFile(nil,R^.GetFileName,P.X,P.Y,true);
  400. if W<>nil then
  401. begin
  402. BW:=LastBrowserWindow;
  403. if BW=nil then
  404. W^.Select
  405. else
  406. begin
  407. Desktop^.Delete(W);
  408. Desktop^.InsertBefore(W,BW^.NextView);
  409. end;
  410. W^.Editor^.SetHighlightRow(P.Y);
  411. end;
  412. Desktop^.UnLock;
  413. TrackReference:=W<>nil;
  414. end;
  415. function TSymbolView.GotoReference(R: PReference): boolean;
  416. var W: PSourceWindow;
  417. begin
  418. Desktop^.Lock;
  419. W:=TryToOpenFile(nil,R^.GetFileName,R^.Position.X-1,R^.Position.Y-1,true);
  420. if W<>nil then W^.Select;
  421. Desktop^.UnLock;
  422. GotoReference:=W<>nil;
  423. end;
  424. {****************************************************************************
  425. TSymbolScopeView
  426. ****************************************************************************}
  427. constructor TSymbolScopeView.Init(var Bounds: TRect; ASymbols: PSymbolCollection; AHScrollBar, AVScrollBar: PScrollBar);
  428. begin
  429. inherited Init(Bounds,AHScrollBar, AVScrollBar);
  430. Symbols:=ASymbols;
  431. NewList(ASymbols);
  432. SetRange(Symbols^.Count);
  433. end;
  434. destructor TSymbolScopeView.Done;
  435. begin
  436. {if assigned(Symbols) then
  437. begin
  438. the elements belong to other lists
  439. Symbols^.DeleteAll;
  440. dispose(Symbols,done);
  441. end;}
  442. Inherited Done;
  443. end;
  444. procedure TSymbolScopeView.HandleEvent(var Event: TEvent);
  445. var OldFocus: sw_integer;
  446. begin
  447. case Event.What of
  448. evKeyDown :
  449. case Event.KeyCode of
  450. kbBack :
  451. begin
  452. LookUp(copy(LookUpStr,1,length(LookUpStr)-1));
  453. ClearEvent(Event);
  454. end;
  455. else
  456. if Event.CharCode in[#33..#255] then
  457. begin
  458. LookUp(LookUpStr+Event.CharCode);
  459. ClearEvent(Event);
  460. end;
  461. end;
  462. end;
  463. OldFocus:=Focused;
  464. inherited HandleEvent(Event);
  465. if OldFocus<>Focused then
  466. Lookup('');
  467. end;
  468. procedure TSymbolScopeView.Draw;
  469. begin
  470. inherited Draw;
  471. SetCursor(2+SymbolTypLen+length(LookUpStr),Focused-TopItem);
  472. end;
  473. procedure TSymbolScopeView.LookUp(S: string);
  474. var Idx: Sw_integer;
  475. NS: string;
  476. begin
  477. NS:=LookUpStr;
  478. if (Symbols=nil) or (S='') then NS:='' else
  479. begin
  480. S:=Symbols^.LookUp(S,Idx);
  481. if Idx<>-1 then
  482. begin
  483. NS:=S;
  484. FocusItem(Idx);
  485. end;
  486. end;
  487. LookUpStr:=NS;
  488. SetState(sfCursorVis,LookUpStr<>'');
  489. DrawView;
  490. end;
  491. procedure TSymbolScopeView.GotoItem(Item: sw_integer);
  492. begin
  493. SelectItem(Item);
  494. end;
  495. procedure TSymbolScopeView.TrackItem(Item: sw_integer);
  496. var S: PSymbol;
  497. begin
  498. if Range=0 then Exit;
  499. S:=List^.At(Focused);
  500. if (S^.References<>nil) and (S^.References^.Count>0) then
  501. TrackReference(S^.References^.At(0));
  502. end;
  503. function TSymbolScopeView.GetText(Item,MaxLen: Sw_Integer): String;
  504. var S: string;
  505. begin
  506. S:=Symbols^.At(Item)^.GetText;
  507. GetText:=copy(S,1,MaxLen);
  508. end;
  509. {****************************************************************************
  510. TSymbolReferenceView
  511. ****************************************************************************}
  512. constructor TSymbolReferenceView.Init(var Bounds: TRect; AReferences: PReferenceCollection;
  513. AHScrollBar, AVScrollBar: PScrollBar);
  514. begin
  515. inherited Init(Bounds,AHScrollBar, AVScrollBar);
  516. References:=AReferences;
  517. NewList(AReferences);
  518. SetRange(References^.Count);
  519. end;
  520. destructor TSymbolReferenceView.Done;
  521. begin
  522. Inherited Done;
  523. end;
  524. procedure TSymbolReferenceView.HandleEvent(var Event: TEvent);
  525. var OldFocus: sw_integer;
  526. begin
  527. OldFocus:=Focused;
  528. inherited HandleEvent(Event);
  529. if OldFocus<>Focused then
  530. Message(Desktop,evBroadcast,cmClearLineHighlights,nil);
  531. end;
  532. function TSymbolReferenceView.GetText(Item,MaxLen: Sw_Integer): String;
  533. var S: string;
  534. P: PReference;
  535. begin
  536. P:=References^.At(Item);
  537. S:=P^.GetFileName+'('+IntToStr(P^.Position.Y)+','+IntToStr(P^.Position.X)+')';
  538. GetText:=copy(S,1,MaxLen);
  539. end;
  540. procedure TSymbolReferenceView.GotoItem(Item: sw_integer);
  541. begin
  542. if Range=0 then Exit;
  543. GotoReference(List^.At(Item));
  544. end;
  545. procedure TSymbolReferenceView.TrackItem(Item: sw_integer);
  546. begin
  547. if Range=0 then Exit;
  548. TrackReference(List^.At(Item));
  549. end;
  550. procedure TSymbolReferenceView.SelectItem(Item: Sw_Integer);
  551. begin
  552. GotoItem(Item);
  553. end;
  554. constructor TSymbolMemInfoView.Init(var Bounds: TRect; AMemInfo: PSymbolMemInfo);
  555. begin
  556. inherited Init(Bounds,'');
  557. Options:=Options or (ofSelectable+ofTopSelect);
  558. MemInfo:=AMemInfo;
  559. end;
  560. destructor TSymbolMemInfoView.Done;
  561. begin
  562. { if assigned(MemInfo) then
  563. dispose(MemInfo);}
  564. Inherited Done;
  565. end;
  566. procedure TSymbolMemInfoView.GetText(var S: String);
  567. function SizeStr(Size: longint): string;
  568. var S: string[40];
  569. begin
  570. S:=IntToStrL(Size,7);
  571. S:=S+' byte';
  572. if Size>1 then S:=S+'s';
  573. SizeStr:=S;
  574. end;
  575. function AddrStr(Addr: longint): string;
  576. { Warning this is endian specific code !! (PM) }
  577. type TLongint = record LoW,HiW: word; end;
  578. begin
  579. with TLongint(Addr) do
  580. AddrStr:='$'+IntToHexL(HiW,4)+IntToHexL(HiW,4);
  581. end;
  582. begin
  583. S:=
  584. #13+
  585. { ' Memory location: '+AddrStr(MemInfo^.Addr)+#13+
  586. ' Local address: '+AddrStr(MemInfo^.LocalAddr)+#13+}
  587. { ??? internal linker ??? }
  588. ' Size in memory: '+SizeStr(MemInfo^.Size)+#13+
  589. ' Size on stack: '+SizeStr(MemInfo^.PushSize)+#13+
  590. ''
  591. ;
  592. end;
  593. function TSymbolMemInfoView.GetPalette: PPalette;
  594. begin
  595. GetPalette:=inherited GetPalette;
  596. end;
  597. {****************************************************************************
  598. TSymbolInheritanceView
  599. ****************************************************************************}
  600. constructor TSymbolInheritanceView.Init(var Bounds: TRect; AHScrollBar, AVScrollBar: PScrollBar; ARoot: PObjectSymbol);
  601. begin
  602. inherited Init(Bounds,AHScrollBar,AVScrollBar);
  603. Options:=Options or (ofSelectable+ofTopSelect);
  604. Root:=ARoot;
  605. ExpandAll(GetRoot); Update;
  606. end;
  607. destructor TSymbolInheritanceView.Done;
  608. begin
  609. { do not dispose,
  610. belongs to a symbolcollection (PM)
  611. if assigned(Root) then
  612. dispose(Root,done); }
  613. Inherited Done;
  614. end;
  615. function TSymbolInheritanceView.GetRoot: Pointer;
  616. begin
  617. GetRoot:=Root;
  618. end;
  619. function TSymbolInheritanceView.HasChildren(Node: Pointer): Boolean;
  620. begin
  621. HasChildren:=GetNumChildren(Node)>0;
  622. end;
  623. function TSymbolInheritanceView.GetChild(Node: Pointer; I: Integer): Pointer;
  624. begin
  625. GetChild:=PObjectSymbol(Node)^.GetDescendant(I);
  626. end;
  627. function TSymbolInheritanceView.GetNumChildren(Node: Pointer): Integer;
  628. begin
  629. GetNumChildren:=PObjectSymbol(Node)^.GetDescendantCount;
  630. end;
  631. function TSymbolInheritanceView.GetText(Node: Pointer): String;
  632. begin
  633. GetText:=PObjectSymbol(Node)^.GetName;
  634. end;
  635. procedure TSymbolInheritanceView.Adjust(Node: Pointer; Expand: Boolean);
  636. begin
  637. PObjectSymbol(Node)^.Expanded:=Expand;
  638. end;
  639. function TSymbolInheritanceView.IsExpanded(Node: Pointer): Boolean;
  640. begin
  641. IsExpanded:=PObjectSymbol(Node)^.Expanded;
  642. end;
  643. function TSymbolInheritanceView.GetPalette: PPalette;
  644. const P: string[length(CBrowserOutline)] = CBrowserOutline;
  645. begin
  646. GetPalette:=@P;
  647. end;
  648. procedure TSymbolInheritanceView.Selected(I: Integer);
  649. var P: pointer;
  650. S: PSymbol;
  651. Anc: PObjectSymbol;
  652. begin
  653. P:=GetNode(I);
  654. if P=nil then Exit;
  655. S:=PObjectSymbol(P)^.Symbol;
  656. { this happens for the top objects view (PM) }
  657. if S=nil then exit;
  658. if S^.Ancestor=nil then Anc:=nil else
  659. Anc:=SearchObjectForSymbol(S^.Ancestor);
  660. OpenSymbolBrowser(Origin.X-1,FOC-Delta.Y+1,
  661. S^.GetName,
  662. S^.GetText,S,
  663. S^.Items,S^.References,Anc,S^.MemInfo);
  664. end;
  665. {****************************************************************************
  666. TBrowserTab
  667. ****************************************************************************}
  668. constructor TBrowserTab.Init(var Bounds: TRect; AItems: PBrowserTabItem);
  669. begin
  670. inherited Init(Bounds);
  671. Options:=Options or ofPreProcess;
  672. Items:=AItems;
  673. SetParams(0,0);
  674. end;
  675. procedure TBrowserTab.SetParams(AFlags: word; ACurrent: Sw_integer);
  676. begin
  677. Flags:=AFlags;
  678. SelectItem(ACurrent);
  679. end;
  680. procedure TBrowserTab.SelectItem(Index: Sw_integer);
  681. var P: PBrowserTabItem;
  682. begin
  683. Current:=Index;
  684. P:=GetItem(Current);
  685. if (P<>nil) and (P^.Link<>nil) then
  686. P^.Link^.Focus;
  687. DrawView;
  688. end;
  689. function TBrowserTab.GetItemCount: sw_integer;
  690. var Count: integer;
  691. P: PBrowserTabItem;
  692. begin
  693. Count:=0; P:=Items;
  694. while (P<>nil) do
  695. begin
  696. Inc(Count);
  697. P:=P^.Next;
  698. end;
  699. GetItemCount:=Count;
  700. end;
  701. function TBrowserTab.GetItem(Index: sw_integer): PBrowserTabItem;
  702. var Counter: integer;
  703. P: PBrowserTabItem;
  704. begin
  705. P:=Items; Counter:=0;
  706. while (P<>nil) and (Counter<Index) do
  707. begin
  708. P:=P^.Next;
  709. Inc(Counter);
  710. end;
  711. GetItem:=P;
  712. end;
  713. procedure TBrowserTab.Draw;
  714. var B: TDrawBuffer;
  715. SelColor, NormColor, C: word;
  716. I,CurX,Count: Sw_integer;
  717. function Names(Idx: integer): char;
  718. begin
  719. Names:=GetItem(Idx)^.Sign;
  720. end;
  721. begin
  722. NormColor:=GetColor(1); SelColor:=GetColor(2);
  723. MoveChar(B,'Ä',SelColor,Size.X);
  724. CurX:=0; Count:=0;
  725. for I:=0 to GetItemCount-1 do
  726. if (Flags and (1 shl I))<>0 then
  727. begin
  728. Inc(Count);
  729. if Current=I then C:=SelColor
  730. else C:=NormColor;
  731. if Count=1 then MoveChar(B[CurX],'´',SelColor,1)
  732. else MoveChar(B[CurX],'³',SelColor,1);
  733. MoveCStr(B[CurX+1],' '+Names(I)+' ',C);
  734. Inc(CurX,4);
  735. end;
  736. if Count>0 then
  737. MoveChar(B[CurX],'Ã',SelColor,1);
  738. WriteLine(0,0,Size.X,Size.Y,B);
  739. end;
  740. procedure TBrowserTab.HandleEvent(var Event: TEvent);
  741. var I,Idx: integer;
  742. DontClear: boolean;
  743. P: TPoint;
  744. function GetItemForCoord(X: integer): integer;
  745. var I,CurX,Idx: integer;
  746. begin
  747. CurX:=0; Idx:=-1;
  748. for I:=0 to GetItemCount-1 do
  749. if (Flags and (1 shl I))<>0 then
  750. begin
  751. if (CurX+1<=X) and (X<=CurX+3) then
  752. begin Idx:=I; Break; end;
  753. Inc(CurX,4);
  754. end;
  755. GetItemForCoord:=Idx;
  756. end;
  757. begin
  758. case Event.What of
  759. evMouseDown :
  760. if MouseInView(Event.Where) then
  761. begin
  762. repeat
  763. MakeLocal(Event.Where,P);
  764. Idx:=GetItemForCoord(P.X);
  765. if Idx<>-1 then
  766. SelectItem(Idx);
  767. until not MouseEvent(Event, evMouseMove);
  768. ClearEvent(Event);
  769. end;
  770. evKeyDown :
  771. begin
  772. DontClear:=false; Idx:=-1;
  773. for I:=0 to GetItemCount-1 do
  774. if GetCtrlCode(GetItem(I)^.Sign)=Event.KeyCode then
  775. begin
  776. Idx:=I;
  777. Break;
  778. end;
  779. if Idx=-1 then
  780. DontClear:=true
  781. else
  782. SelectItem(Idx);
  783. if DontClear=false then ClearEvent(Event);
  784. end;
  785. end;
  786. inherited HandleEvent(Event);
  787. end;
  788. function TBrowserTab.GetPalette: PPalette;
  789. const P: string[length(CBrowserTab)] = CBrowserTab;
  790. begin
  791. GetPalette:=@P;
  792. end;
  793. destructor TBrowserTab.Done;
  794. begin
  795. if Items<>nil then DisposeBrowserTabList(Items);
  796. inherited Done;
  797. end;
  798. constructor TBrowserWindow.Init(var Bounds: TRect; ATitle: TTitleStr; ANumber: Sw_Integer;ASym : PSymbol;
  799. const AName: string; ASymbols: PSymbolCollection; AReferences: PReferenceCollection;
  800. AInheritance: PObjectSymbol; AMemInfo: PSymbolMemINfo);
  801. var R: TRect;
  802. ST: PStaticText;
  803. HSB,VSB: PScrollBar;
  804. function CreateVSB(R: TRect): PScrollBar;
  805. var R2: TRect;
  806. SB: PScrollBar;
  807. begin
  808. Sym:=ASym;
  809. R2.Copy(R); R2.Move(1,0); R2.A.X:=R2.B.X-1;
  810. New(SB, Init(R2)); SB^.GrowMode:=gfGrowLoX+gfGrowHiX+gfGrowHiY;
  811. CreateVSB:=SB;
  812. end;
  813. function CreateHSB(R: TRect): PScrollBar;
  814. var R2: TRect;
  815. SB: PScrollBar;
  816. begin
  817. R2.Copy(R); R2.Move(0,1); R2.A.Y:=R2.B.Y-1;
  818. New(SB, Init(R2)); SB^.GrowMode:=gfGrowLoY+gfGrowHiX+gfGrowHiY;
  819. CreateHSB:=SB;
  820. end;
  821. begin
  822. inherited Init(Bounds, ATitle, ANumber);
  823. HelpCtx:=hcBrowserWindow;
  824. GetExtent(R); R.Grow(-1,-1); R.B.Y:=R.A.Y+1;
  825. New(ST, Init(R, ' '+AName)); ST^.GrowMode:=gfGrowHiX;
  826. Insert(ST);
  827. GetExtent(R); R.Grow(-1,-1); Inc(R.A.Y,2);
  828. if assigned(ASymbols) and (ASymbols^.Count>0) then
  829. begin
  830. HSB:=CreateHSB(R); Insert(HSB);
  831. VSB:=CreateVSB(R); Insert(VSB);
  832. New(ScopeView, Init(R, ASymbols, HSB, VSB));
  833. ScopeView^.GrowMode:=gfGrowHiX+gfGrowHiY;
  834. Insert(ScopeView);
  835. end;
  836. if assigned(AReferences) and (AReferences^.Count>0) then
  837. begin
  838. HSB:=CreateHSB(R); Insert(HSB);
  839. VSB:=CreateVSB(R); Insert(VSB);
  840. New(ReferenceView, Init(R, AReferences, HSB, VSB));
  841. ReferenceView^.GrowMode:=gfGrowHiX+gfGrowHiY;
  842. Insert(ReferenceView);
  843. end;
  844. if assigned(AInheritance) then
  845. begin
  846. New(InheritanceView, Init(R, nil,nil, AInheritance));
  847. InheritanceView^.GrowMode:=gfGrowHiX+gfGrowHiY;
  848. Insert(InheritanceView);
  849. end;
  850. if assigned(AMemInfo) then
  851. begin
  852. New(MemInfoView, Init(R, AMemInfo));
  853. MemInfoView^.GrowMode:=gfGrowHiX+gfGrowHiY;
  854. Insert(MemInfoView);
  855. end;
  856. GetExtent(R); R.Grow(-1,-1); R.Move(0,1); R.B.Y:=R.A.Y+1;
  857. New(PageTab, Init(R,
  858. NewBrowserTabItem('S',ScopeView,
  859. NewBrowserTabItem('R',ReferenceView,
  860. NewBrowserTabItem('I',InheritanceView,
  861. NewBrowserTabItem('M',MemInfoView,
  862. nil))
  863. ))));
  864. PageTab^.GrowMode:=gfGrowHiX;
  865. Insert(PageTab);
  866. if assigned(ScopeView) then
  867. SelectTab(btScope)
  868. else
  869. if assigned(ReferenceView) then
  870. SelectTab(btReferences)
  871. else
  872. if assigned(InheritanceView) then
  873. SelectTab(btInheritance);
  874. end;
  875. procedure TBrowserWindow.HandleEvent(var Event: TEvent);
  876. var DontClear: boolean;
  877. S: PSymbol;
  878. Anc: PObjectSymbol;
  879. P: TPoint;
  880. begin
  881. case Event.What of
  882. evBroadcast :
  883. case Event.Command of
  884. cmSearchWindow :
  885. ClearEvent(Event);
  886. cmListItemSelected :
  887. if Event.InfoPtr=ScopeView then
  888. begin
  889. S:=ScopeView^.Symbols^.At(ScopeView^.Focused);
  890. MakeGlobal(ScopeView^.Origin,P);
  891. Desktop^.MakeLocal(P,P); Inc(P.Y,ScopeView^.Focused-ScopeView^.TopItem);
  892. Inc(P.Y);
  893. if S^.Ancestor=nil then Anc:=nil else
  894. Anc:=SearchObjectForSymbol(S^.Ancestor);
  895. if (S^.GetReferenceCount>0) or (S^.GetItemCount>0) or (Anc<>nil) then
  896. OpenSymbolBrowser(Origin.X-1,P.Y,
  897. S^.GetName,
  898. ScopeView^.GetText(ScopeView^.Focused,255),S,
  899. S^.Items,S^.References,Anc,S^.MemInfo);
  900. end;
  901. end;
  902. { evCommand :
  903. begin
  904. DontClear:=false;
  905. case Event.Command of
  906. cmGotoSymbol :
  907. if Event.InfoPtr=ScopeView then
  908. if ReferenceView<>nil then
  909. if ReferenceView^.Range>0 then
  910. ReferenceView^.GotoItem(0);
  911. cmTrackSymbol :
  912. if Event.InfoPtr=ScopeView then
  913. if (ScopeView<>nil) and (ScopeView^.Range>0) then
  914. begin
  915. S:=ScopeView^.At(ScopeView^.Focused);
  916. if (S^.References<>nil) and (S^.References^.Count>0) then
  917. TrackItem(S^.References^.At(0));
  918. else DontClear:=true;
  919. end;
  920. if DontClear=false then ClearEvent(Event);
  921. end;}
  922. evKeyDown :
  923. begin
  924. DontClear:=false;
  925. case Event.KeyCode of
  926. kbEsc :
  927. Close;
  928. else DontClear:=true;
  929. end;
  930. if DontClear=false then ClearEvent(Event);
  931. end;
  932. end;
  933. inherited HandleEvent(Event);
  934. end;
  935. procedure TBrowserWindow.SetState(AState: Word; Enable: Boolean);
  936. var OldState: word;
  937. begin
  938. OldState:=State;
  939. inherited SetState(AState,Enable);
  940. if ((State xor OldState) and sfActive)<>0 then
  941. if GetState(sfActive)=false then
  942. Message(Desktop,evBroadcast,cmClearLineHighlights,nil);
  943. end;
  944. procedure TBrowserWindow.Close;
  945. begin
  946. Message(Desktop,evBroadcast,cmClearLineHighlights,nil);
  947. inherited Close;
  948. end;
  949. procedure TBrowserWindow.SelectTab(BrowserTab: Sw_integer);
  950. var Tabs: Sw_integer;
  951. { PB : PBreakpoint;
  952. PS :PString;
  953. l : longint; }
  954. begin
  955. (* case BrowserTab of
  956. btScope :
  957. if assigned(ScopeView) then
  958. ScopeView^.Select;
  959. btReferences :
  960. if assigned(ReferenceView) then
  961. ReferenceView^.Select;
  962. btBreakWatch :
  963. begin
  964. if Assigned(Sym) then
  965. begin
  966. if Pos('proc',Sym^.GetText)>0 then
  967. { insert function breakpoint }
  968. begin
  969. { make it visible }
  970. PS:=Sym^.Name;
  971. l:=Length(PS^);
  972. If PS^[l]='*' then
  973. begin
  974. PB:=BreakpointsCollection^.GetType(bt_function,copy(GetStr(PS),1,l-1));
  975. If Assigned(PB) then
  976. BreakpointsCollection^.Delete(PB);
  977. Sym^.Name:=NewStr(copy(GetStr(PS),1,l-1));
  978. DrawView;
  979. DisposeStr(PS);
  980. end
  981. else
  982. begin
  983. Sym^.Name:=NewStr(GetStr(PS)+'*');
  984. DrawView;
  985. New(PB,init_function(GetStr(PS)));
  986. DisposeStr(PS);
  987. BreakpointsCollection^.Insert(PB);
  988. BreakpointsCollection^.Update;
  989. end;
  990. end
  991. else if pos('var',Sym^.GetText)>0 then
  992. { insert watch point }
  993. begin
  994. { make it visible }
  995. PS:=Sym^.Name;
  996. l:=Length(PS^);
  997. If PS^[l]='*' then
  998. begin
  999. PB:=BreakpointsCollection^.GetType(bt_awatch,copy(PS^,1,l-1));
  1000. If Assigned(PB) then
  1001. BreakpointsCollection^.Delete(PB);
  1002. Sym^.Name:=NewStr(copy(PS^,1,l-1));
  1003. DrawView;
  1004. DisposeStr(PS);
  1005. end
  1006. else
  1007. begin
  1008. Sym^.Name:=NewStr(GetStr(PS)+'*');
  1009. DrawView;
  1010. New(PB,init_type(bt_awatch,GetStr(PS)));
  1011. DisposeStr(PS);
  1012. BreakpointsCollection^.Insert(PB);
  1013. BreakpointsCollection^.Update;
  1014. end;
  1015. end;
  1016. end;
  1017. end;
  1018. end;*)
  1019. Tabs:=0;
  1020. if assigned(ScopeView) then
  1021. Tabs:=Tabs or (1 shl btScope);
  1022. if assigned(ReferenceView) then
  1023. Tabs:=Tabs or (1 shl btReferences);
  1024. if assigned(InheritanceView) then
  1025. Tabs:=Tabs or (1 shl btInheritance);
  1026. if assigned(MemInfoView) then
  1027. Tabs:=Tabs or (1 shl btMemInfo);
  1028. if Assigned(Sym) then
  1029. if (Pos('proc',Sym^.GetText)>0) or (Pos('var',Sym^.GetText)>0) then
  1030. Tabs:=Tabs or (1 shl btBreakWatch);
  1031. if PageTab<>nil then PageTab^.SetParams(Tabs,BrowserTab);
  1032. end;
  1033. function TBrowserWindow.GetPalette: PPalette;
  1034. const S: string[length(CBrowserWindow)] = CBrowserWindow;
  1035. begin
  1036. GetPalette:=@S;
  1037. end;
  1038. procedure OpenSymbolBrowser(X,Y: Sw_integer;const Name,Line: string;S : PSymbol;
  1039. Symbols: PSymbolCollection; References: PReferenceCollection;
  1040. Inheritance: PObjectSymbol; MemInfo: PSymbolMemInfo);
  1041. var R: TRect;
  1042. begin
  1043. if X=0 then X:=Desktop^.Size.X-35;
  1044. R.A.X:=X; R.A.Y:=Y;
  1045. R.B.X:=R.A.X+35; R.B.Y:=R.A.Y+15;
  1046. while (R.B.Y>Desktop^.Size.Y) do R.Move(0,-1);
  1047. Desktop^.Insert(New(PBrowserWindow, Init(R,
  1048. 'Browse: '+Name,SearchFreeWindowNo,S,Line,Symbols,References,Inheritance,MemInfo)));
  1049. end;
  1050. END.
  1051. {
  1052. $Log$
  1053. Revision 1.19 1999-09-16 14:34:59 pierre
  1054. + TBreakpoint and TWatch registering
  1055. + WatchesCollection and BreakpointsCollection stored in desk file
  1056. * Syntax highlighting was broken
  1057. Revision 1.18 1999/07/28 23:11:22 peter
  1058. * fixes from gabor
  1059. Revision 1.17 1999/06/28 12:35:05 pierre
  1060. + CloseAllBrowsers needed before compilation to avoid problems
  1061. + ModulesCollection and GlobalsCollection to avoid memory leaks
  1062. Revision 1.16 1999/06/17 23:44:01 pierre
  1063. * problem with Inheritance list
  1064. Revision 1.15 1999/04/15 08:58:06 peter
  1065. * syntax highlight fixes
  1066. * browser updates
  1067. Revision 1.14 1999/04/07 21:55:53 peter
  1068. + object support for browser
  1069. * html help fixes
  1070. * more desktop saving things
  1071. * NODEBUG directive to exclude debugger
  1072. Revision 1.13 1999/03/16 00:44:44 peter
  1073. * forgotten in last commit :(
  1074. Revision 1.12 1999/03/01 15:42:02 peter
  1075. + Added dummy entries for functions not yet implemented
  1076. * MenuBar didn't update itself automatically on command-set changes
  1077. * Fixed Debugging/Profiling options dialog
  1078. * TCodeEditor converts spaces to tabs at save only if efUseTabChars is
  1079. set
  1080. * efBackSpaceUnindents works correctly
  1081. + 'Messages' window implemented
  1082. + Added '$CAP MSG()' and '$CAP EDIT' to available tool-macros
  1083. + Added TP message-filter support (for ex. you can call GREP thru
  1084. GREP2MSG and view the result in the messages window - just like in TP)
  1085. * A 'var' was missing from the param-list of THelpFacility.TopicSearch,
  1086. so topic search didn't work...
  1087. * In FPHELP.PAS there were still context-variables defined as word instead
  1088. of THelpCtx
  1089. * StdStatusKeys() was missing from the statusdef for help windows
  1090. + Topic-title for index-table can be specified when adding a HTML-files
  1091. Revision 1.11 1999/02/22 11:51:38 peter
  1092. * browser updates from gabor
  1093. Revision 1.9 1999/02/18 13:44:34 peter
  1094. * search fixed
  1095. + backward search
  1096. * help fixes
  1097. * browser updates
  1098. Revision 1.7 1999/02/16 12:44:20 pierre
  1099. * DoubleClick works now
  1100. Revision 1.6 1999/02/10 09:44:59 pierre
  1101. + added B tab for functions and vars for break/watch
  1102. TBrowserWindow also stores the symbol itself for break/watchpoints
  1103. Revision 1.5 1999/02/04 17:53:47 pierre
  1104. + OpenOneSymbolBrowser
  1105. Revision 1.4 1999/02/04 13:16:14 pierre
  1106. + column info added
  1107. Revision 1.3 1999/01/21 11:54:23 peter
  1108. + tools menu
  1109. + speedsearch in symbolbrowser
  1110. * working run command
  1111. Revision 1.2 1999/01/14 21:42:24 peter
  1112. * source tracking from Gabor
  1113. Revision 1.1 1999/01/12 14:29:40 peter
  1114. + Implemented still missing 'switch' entries in Options menu
  1115. + Pressing Ctrl-B sets ASCII mode in editor, after which keypresses (even
  1116. ones with ASCII < 32 ; entered with Alt+<###>) are interpreted always as
  1117. ASCII chars and inserted directly in the text.
  1118. + Added symbol browser
  1119. * splitted fp.pas to fpide.pas
  1120. Revision 1.0 1999/01/09 11:49:41 gabor
  1121. Original implementation
  1122. }