Hi Ted,
On 29/03/2010, Ted Harding Ted.Harding@manchester.ac.uk wrote:
On 29-Mar-10 09:14:43, Srdjan Todorovic wrote:
Lets say I'm documenting a low-level protocol or file format and want to produce a picture such as the TCP header (etc) table (http://izecksohn.com/pedro/pub/tcp_header.jpg), what's the best program to use for that?
Another example: http://www.wtcs.org/snmp4tpc/images/TCP-Header.jpg
The first one is pure "ASCII ART", so you could do it at the keyboard and then take a screenshot of it :)!
I linked that picture to try to show that the byte boundaries need to be shown.
The second one is skewed, as seen on my screen. Is that intentional?
Oh that's just I think scanned from a book. I was more concerned with the representation of the same information from the ASCII picture into this pretty picture.
In either case (being serious for once) the ideal Unix/Linux-based package for this is groff, using the pic preprocessor (which translates a diagram description language into troff input which then draws the diagram). The output is PostScript (PS), which can be coverted (e.g. into JPEG) by the ImageMagick program 'convert'.
Ugh. Sounds like too much work, but thanks for the idea. Does it end up looking horrible just like the ASCII picture?
What would be great is some kind of C/C++ struct to diagram converter program to take care of this for me.
I could prepare examples emulating your two above for study, but don't have time right now (maybe later today, maybe even later).
Thanks for the offer - I'm managing just fine with Inkscape for the moment. One has to be very careful with Inkscape to get the sizes and layouts right. At least it beats Gimp for this kind of work. :)
Srdjan