Archive for June 18th, 2001

QDB: Quick Database Components

Borland’s Delphi© makes the construction of Windows applications easier than ever. In particular, the Borland Database Engine (BDE) offers enormous power with great ease. Sometimes, however, the full might of the BDE is overkill. Wouldn’t it be better for your simple projects to use a simple tool, one that could be distributed inside your EXE and didn’t require enormous DLLs to function?
The QDB components for Delphi offer fast, indexed access to a flat-file database of variable-sized items. QDB is quick, easy to use, and comes with full installable help. It’s also free! Caveat! It is some years since these components were developed and they probably won’t function beyond D5 without a lot of tweaking. They are–regrettably–also unsupported. Nevertheless I hope you find them useful in some way.
Also available are the usual demonstration applications written to show the power and ease of QDB. There is a simple address book, a rewrite of Borland’s Animals demo, and a rudimentary knowledge-base system. They each come with full source code.

6 comments June 18th, 2001

Snoop: Memory Leak Sniffer

Writing programs that work at all is difficult enough without having to track down memory leaks and strange problems with overwritten memory. Snoop and Snoop Monitor make it easy to snoop out those bugs — and they’re free. Caveat! It is some years since these components were developed and they won’t function beyond D5. They are–regrettably–also unsupported. Nevertheless I hope you find them useful in some way.

Snoop v2.0 has been completely rewritten and has a bunch of new features. It works correctly with DLL files and with multi-threaded programs and now comes with a Delphi expert to display its memory-leak reports and jump to the offending line in your source code.

5 comments June 18th, 2001

CompDocs: Structured Storage Wrapper

OLE Structured Storage (or Compound Documents or DocFiles … the names change regularly!) provide a clever way to have a whole file-system within a single file with nested ‘directories’ (storages) and ‘files’ (streams). There’s also the ability to do transaction processing: keeping modifications in limbo until ‘committed’ or rolled-back. The only catch has been that the necessary APIs are complex, most un-Delphi-like, and in places self-contradictory. Indeed, the DCU supplied with Delphi 1 is error-ridden. There’s also the matter of the small print and the arcane error codes! With these complexities it’s no wonder that most Delphi developers have avoided Compound Documents.
The CompDocs components available here encapsulate OLE structured storage in a straightforward and Delphi-like way. They protect you from most of the hidden problems with using the API directly and work with all versions of Delphi. As usual these components are available for free. Caveat! It is some years since these components were developed and they probably won’t function beyond D5 without a lot of tweaking. They are–regrettably–also unsupported. Nevertheless I hope you find them useful in some way.

TRootStorage models a physical file on disk while TStorage and TStorageStream model substorages and streams. Storages can be nested and can be opened in transacted mode. Creating temporary storages and streams is made easy. The TStorageStream is fully compatible with other Delphi stream types.
I have provided a simple example program, Viewer, which browses the contents of a compound file, showing the names of storages and streams. You’ll be surprised to discover the complexity of many files.

June 18th, 2001

Widgets: Title-Bar Buttons

Another title-bar button? Yes, but one that works simply and cleanly to provide buttons which mimic the look and feel of Windows’ own frame controls by using Windows’ own drawing technique.
Each Widget contains a single glyph from a truetype font. Windows uses the “Marlett” font for its own glyphs but you can use any and choose a colour and weight too. Widgets have their own Hint property and are even visible at design-time. A component editor is included to make Widgets very easy to use. Caveat! It is some years since these components were developed and they probably won’t function beyond D5 without a lot of tweaking. They are–regrettably–also unsupported. Nevertheless I hope you find them useful in some way.

June 18th, 2001

Maps: Generic Associative Containers

The Maps Library offers nine genuine generic container classes. Just as TStringList lets you keep lists of objects indexed by a string value, Maps let you keep lists of just about any type, object or atomic, indexed by whatever type you like.
The nine different kinds of map have different performance characteristics allowing you to choose the perfect container for your application, whether you need fast insertion, super-fast searching, random-access, or whatever.
The library is quite compact and surprisingly efficient given its generic nature. A simple demo is also available. Caveat! It is some years since these components were developed and they probably won’t function beyond D5 without a lot of tweaking. They are–regrettably–also unsupported. Nevertheless I hope you find them useful in some way.

1 comment June 18th, 2001

FirstAid

Every so often the Delphi IDE (from D2 until at least D7) seems to get confused about its line numbers: errors are reported in places there is no code; the debugger jumps about with no apparent relation to the code that is being executed. The Delphi newsgroups propose many diagnoses but, in my experience, the culprit has always been code pasted into the IDE from another source. The Delphi IDE flags line breaks with the characters $D$A but some other editors use $A$D or even just $A or $D. The IDE understands such markers enough to format the code correctly but not enough to mark errors properly. The solution is straightforward but awkward: filter out any improper codes. FirstAid does the job for you.

June 18th, 2001


Calendar

June 2001
M T W T F S S
« May   Jul »
 123
45678910
11121314151617
18192021222324
252627282930  

Posts by Month