code: int CountCharset(int Offset,int NumofGlyphs){
      	int format;
      	int Length=0;
      	seek(Offset);
      	// Read the format
      	format = getCard8();
      	// Calc according to format
      	switch (format){
      		case 0:
      			Length = 1+2*NumofGlyphs;
      			break;
      		case 1:
      			Length = 1+3*CountRange(NumofGlyphs,1);
      			break;
      		case 2:
      			Length = 1+4*CountRange(NumofGlyphs,2);
      			break;
      		default:
      			break;
      	}
      	return Length;
      }
docs: Calculates the length of the charset according to its format
  @param Offset The Charset Offset
  @param NumofGlyphs Number of glyphs in the font
  @return the length of the Charset