Added support for subscript, superscript, underline, overline, italics and newline in the pin labels and (optional) note. They're implemented as escape character sequences (ie. \o for overline).
Cleaned up the code and restructured the XML file for simplicty. Now I just need to add a Search function and some proper user input validation and then I'm done coding. I'll probably launch a website where anyone can search the database and registered users can add IC definitions.
This is the user interface I'm working on... in this example, the user has just clicked the 'Add IC' button and entered the number of pins (16). This is the blank template with placeholder values and the user can now click those elements to edit them.
UPDATE: decided on a complete overhaul of the rendering process. This will enable me to include other package formats besides DIL. Instead of CSS elements I'm now using a HTML5 canvas to draw the IC, pins and labels. Early experiments are going well. Because browsers do not properly support Canvas.addHitRegion() yet I'm using transparent DIV elements on top of the Canvas to catch mouseclicks and fire up the appropriate edit function. it's a bit of a dirty hack but it gets the job done.
First attempts at rendering PLCC packages are encouraging. I've written the code to divvy up the pins along all four sides and number them correctly. Still wondering where I'm going to leave the pin labels but i'll work something out. Scaling down the image might work
OK, I've cracked the code for rendering the PLCC body and pins at the right position with the correct pin numbers. This was not as easy as it looks because the position of pin 1 is not fixed but moves around according to the number of pins per side. A couple of hours experimenting and some thinking eventually led towards an elegant solution that works for any number of pins. The code for adding the horizontal labels on both sides is finished and now I'm working on the vertical labels. Onwards and upwards!
I've run into a bit of a dilemma with the vertical labels. There are basically two ways of implementing them. The complicated way depends on canvas.rotate(), the easy way on the CSS properties text-orientation and writing-mode. Unfortunately, Internet Explorer does not support either method and Chrome doesn't support the CSS properties. Darn!
I'm contemplating to let this PLCC malarky rest for a while and continue work on the user interface. So many ideas, so little time!
UPDATE 16/06/06 : got side-tracked by a couple of other projects and real life! Anyway, I've decided to drop the PLCC packages and did some work on the user interface but it needs a bit more. Also aAdded Single-In-Line (SIL) package support because it was really easy to do.