=== Top of the Swiki === Attachments ===

FileContentsBrowser

Downloads
* Version for Squeak 2.0, ported by William Dargel http://isgwww.cs.uni-magdeburg.de/~raab/fcb/FileContentsBrowser-Squeak2.0.st
* Original version 0.2 for Squeak 1.31 http://isgwww.cs.uni-magdeburg.de/~raab/fcb/FileContentsBrowser-v0.2.st
The following two not yet available:
* ftp://st.cs.uiuc.edu/pub/Smalltalk/Squeak/Goodies/FileContentsBrowser-v0.2.st
* ftp://ftp.cs.uni-magdeburg.de/pub/Smalltalk/Smalltalk/Squeak/Goodies/FileContentsBrowser-v0.2.st

Summary

The class browser is a great tool, but it cannot now be used to give a "structured view" on a (syntactically correct) Smalltalk source code file. That's exactly what the FileContentsBrowser does.

It just scans the file, and you can browse the file's classes and methods _without_ having to actually install it. You can browse classes, methods, and comments just like in a real class browser. Even better, you can rename/remove/reorganize everything, and once you're done you can either file it in (i.e., install it) or file it out again for later work.

Features
* Browse one file or whole collections
* Rename/Remove/Reorganize classes or methods
* Remove all unchanged methods so you see where actual differences are
* Highlights differences in extang methods
* Highlights differences to extant class definitions
* Keeps all unknown doIts so you can decide what to do with them
* Install entire packages, classes, categories, or methods from a package
* FileOut modified packages so you can distribute or work later on them

How to use it: After installing FileContentsBrowser.st, open a NEW FileList and select 'browse selected file(s)' from it. If you have selected a file, it will just browse that one file. If you haven't selected a file, then you can give a pattern for the files from the current directory.

Screen shots

Here are some images showing the appearance of the FileContentsBrowser, and some of its features. You may also visit the FileContentsBrowserLargeImages page: I didn't want to include large pictures on this page.



A browser on one file (left), and on multiple files (right). Note that the edit pane contains all doIts not yet processed. If you do any operation on the entire package (i.e., fileIn or fileOut) then you are asked how to handle these doIts.



The above two images show differences in extant methods or classes. The left image shows the basic formatting rules for methods. Red lines show things to be added by the package, striked lines show things to removed. The right image shows the same for a class definition. In class definitions, the differences are shown based on single tokens (e.g., instance variables) and not entire lines.