PDA

View Full Version : Subshapes in a BIGFONT file [gbcbig]


Christopher Bahns
08-17-2004, 02:07 PM
Hello All,
I am new to AutoCAD and am trying to figure out the SHP/SHX file
format. I have read through Chapter 3 of AutoCAD R13 Customization
Guide (related to SHP files) and just ordered Maximizing AutoCAD R13
(I will not have it for at least a few days). I'm trying to parse
these files on my own (for single-stroke fonts).

I more or less understand the SHP/SHX file formats. But, I'm having
trouble with a Chinese bigfont called "gbcbig.shx". The following text
are the header info and the "zhong1" (0xD6D0) character. It seems all
of the characters in the file have the same three starting bytes and
three ending bytes.


*BIGFONT 7703,1,0A1,0FE
*0,4,¹¤³Ìºº×Ö×Ö·û¼¯ 1998.1. FAW/Autodesk CTC CBX(0293)
0,64,2,0

*0D6D0,46,ÖÐ
7,-114,5,2,8,(12,62),1,8,(42,5),2,8,(-42,5),1,8,(0,-44),2,8,(21,62),1,8,(0,-89),
2,8,(22,68),1,8,(-3,-30),2,8,(2,0),1,8,(-42,-5),7,-113,0


I do not understand the beginning "7,-114,5," and ending ",7,-113,0".
Code 7 means that the next byte (-114 = 0x8E) is a subshape code
referencing another record (in the same file?). The end has a similar
command (-113 = 0x8F). But, gbcbig.shx does not contain characters
0x8E or 0x8F (I could not find them).

Also, the "5" after "7,-114" at the beginning seems to indicate a
"position stack push" command. But, there is no corresponding "pop"
command later in the record, causing my parsing code to generate stack
overflow errors. The file does however load properly into SHXVIEW.EXE
without generating warnings or errors.

I read that code 7 is actually followed by two bytes (although not
documented). This makes sense in a BIGFONT file. But, I also could not
find codes 0x058E or 0x8E05, and there is no room for another byte
after "7,-113" and before the "0" terminator at the end of the record.


Can someone tell me what I'm missing? The Customization Guide just
does not have much detail, and may be out of date with respect to this
font file.

TIA For any help
- Chris

Christopher Bahns
08-18-2004, 07:50 AM
Okay, never mind. I've been told that 0x8E and 0x8F are in that file,
only in decimal format (142 and 143).

This also clears up the missing "pop" command (it is in one of the
subshapes).

- Chris


MyLounge.com Site Map
Forum: Cars, Cell Phone, Database, Games, Home Improvement, IT, Music, School, Sports, Web Design, Web Server, Weight Loss

The MyLounge.com forum is intended for informational use only and should not be relied upon and is not a substitute for any advice. The information contained on MyLounge.com are opinions and suggestions of members and is not a representation of the opinions of MyLounge.com. MyLounge.com does not warrant or vouch for the accuracy, completeness or usefulness of any postings or the qualifications of any person responding. Please consult a expert or seek the services of an attorney in your area for more accuracy on your specific situation. Please note that our forums also serve as mirrors to Usenet newsgroups. Many posts you see on our forums are made by newsgroup users who may not be members of MyLounge.com Term of Service