"Fossies" - the Fresh Open Source Software Archive

Member "xcircuit-3.10.30/CHANGES" (24 Feb 2020, 135423 Bytes) of package /linux/misc/xcircuit-3.10.30.tgz:

As a special service "Fossies" has tried to format the requested text file into HTML format (style: standard) with prefixed line numbers. Alternatively you can here view or download the uninterpreted source code file.

    1 Xcircuit v3.x  Change Log (file CHANGES)
    2 ----------------------------------------------------------------------
    4 Please note that there is an automatically-generated, up-to-date list
    5 of the most recent code changes at the URL
    7 	http://opencircuitdesign.com/xcircuit/changes.html
    9 Occasionally I spend some time to convert that list into text and put it
   10 back here. So if you're looking for the most recent changes, try the
   11 website.
   13 Version 3.6 (January 2006 to present)
   14 ----------------------------------------------------------------------
   15 369  v3.6 rev 21	4/7/06
   16      Incorporated Michael Goffioul's code for (native) Windows
   17      compilation.
   19 368  v3.6 rev 20	4/5/06
   20      Fixed an error with the -noconsole -nowindow startup, where
   21      the option switches were passed to GUI_init; XCircuit now
   22      searches the arguments for a Tk window name rather than relying
   23      on the number of arguments to figure out whether or not it is
   24      running in batch mode.
   25      Also:  Fixed an error in a Wprintf() statement when a library
   26      file cannot be found.
   28 368  v3.6 rev 19	3/31/06
   29      Fixed the select color, which got changed to cyan because the
   30      wrong line was deleted from the source file.  Also, implemented
   31      a policy of removing redundant points after a line has been
   32      drawn, because some drawing programs use left-button + middle-
   33      button, and I've seen several xcircuit novices doing this.
   34      Also:  Fixed the undo mechanism with respect to rotates and
   35      flips, so that rotates and flips during a move or copy operation
   36      don't screw up the undo operation.
   37      Also:  Changed the look of the GUI a bit, with softer colors and
   38      no red borders around the buttons and message widgets.
   40 367  v3.6 rev 18	3/30/06
   41      Added command option "config database" to update the internal
   42      list of colors, fonts, and other values that should be able
   43      to be set with the Tk "option" command.  This now allows colors
   44      to be redefined from within the startup script.  Removed the
   45      "query" color, which is no longer used, and the "filter2" and
   46      "bar2" colors, which are (and never were) necessary.
   48 366  v3.6 rev 17	3/28/06
   49      Reorganized the source code to separate most of the Xt GUI
   50      functions into two separate files, xtgui.c and xtfuncs.c.
   52 365  v3.6 rev 16	3/27/06
   53      Changed the "keybind" function to be per-window so that the
   54      scroll-wheel and auto-increment functions work in multiple
   55      xcircuit windows.
   56      Also:  Corrected a bad error that allowed an object instance
   57      being moved to be selected when "carrying" it into another
   58      object, causing xcircuit to crash.
   59      Also:  Changed the behavior of Tcl expression parameters so that
   60      the parameter evaluation is done ONLY as part of the opsubstitute()
   61      routine;  this places some restrictions on the use of expression
   62      parameters but should avoid problems where expression parameters
   63      make XCircuit crash.
   64      Also:  Created a new symbol "netpointer" in the generic library
   65      that implements a "netlist get" function.  Corrected a number of
   66      errors related to properly executing expression parameters.
   67      Also:  Added "analoglib3.lps" and "digitallib.lps" to the installed
   68      libraries.
   69      Also:  Corrected the library zoom/position problem definitively
   70      (see note for revision 13).
   72 364  v3.6 rev 15	3/22/06
   73      Added command options "library writable" and "library changed".
   74      Removed the "Library: " string from the beginning of library
   75      names.  Modified the "Write All" Tcl script to handle automatic
   76      writeback of libraries that have changed, and to note libraries
   77      that have changed but which are not writable.
   79 364  v3.6 rev 14	3/21/06
   80      Added the "-target <library>" option to the "page load" command.
   81      This allows objects in a file to be placed somewhere other than
   82      the "User Library", without having to move them by hand.  Let
   83      XCOps(library) stand for *both* the -replace and -target libraries.
   84      Fixed the Tcl wrapper script procedures accordingly.
   85      Also:  Added command-line options "xcircuit --help" and
   86      "xcircuit --version" providing essential information.
   87      Also:  Added command option "library compose", although the fact
   88      that the library does not get composed in certain cases needs to
   89      be investigated.
   90      Also:  Added variable xobjs.hold = XCOps(hold);  when FALSE, the
   91      mouse HOLD modifier is disabled (perhaps this should be an
   92      integer that sets the delay time, with 0 = disabled?).
   93      Also:  Fixed menu command callbacks that were broken for several
   94      revisions.
   96 363  v3.6 rev 13	3/18/06
   97      Various fixes to correct problems found running various steps
   98      while writing tutorial number 3:  Fixed Alt-f key binding for
   99      font changes, user library redraw (still is wrong somewhere),
  100      variable substitution in filenames, and a few others.
  102 362  v3.6 rev 12	3/17/06
  103      Added the ability to move objects both within a library and between
  104      libraries simply by using the "library move" macro (Shift-M) to
  105      pick up the object, then transferring it between library pages.
  106      Also, virtual copies can be made of any object in the library (not
  107      just those that have paramters), and the virtual copies can be
  108      flipped and rotated.
  109      Also: Fixed the "-noconsole -nowindow" invocation, which was
  110      broken.
  111      Also: Added variable and tilde expansion to filenames in the
  112      "%F" and "%f" escapes in info labels.
  114 361  v3.6 rev 11	3/15/06
  115      Corrected a number of event errors, including the inability to
  116      select from the library via a button tap and drop into "move"
  117      mode.
  118      Also: Implemented a version of James Vernon's mouse button hints.
  119      Also: Corrected the LaTeX mode output to properly account for files
  120      with non-".ps" extensions (e.g., ".eps").
  122 360  v3.6 rev 10	3/14/06
  123      Corrected an error which prevented edited library object names
  124      from being applied to the object name.  This resulted in confusion,
  125      because the library would show the modified name, while the
  126      object itself retained its original name.
  127      Also: Added multiple window handling to the undo/redo mechanism.
  128      Also: Added a window close procedure and a command "config delete"
  129      to correspond to it.
  131 359  v3.6 rev 9		3/13/06
  132      A number of fixes to the key binding and function dispatch
  133      routines from rev 8:  Fixed Finish_Copy mode, fixed handling
  134      of ASCII keystrokes in text entry modes, fixed retention of
  135      view scale and position after displaying a library page.
  136      Fixed error in prohibiting justification action in "normal"
  137      mode.
  138      Also:  A number of fixes to the wrapper window menus for
  139      multiple pages:  Changed library and page menus to be shared,
  140      applied new color, font, and encoding functions to all windows,
  141      and fixed the Tk color picker call for the "add new color" menu
  142      option.
  144 359  v3.6 rev 8		3/12/06
  145      Major overhaul of the key binding and function dispatching
  146      mechanisms to accomodate multiple windows.
  147      Still to be done:  Some menu items (lists of Libraries and
  148      Pages, for example) need to be shared among all windows.
  149      Need a window close routine.  Need a routine to transfer a
  150      selection between two windows.  Need to handle multiple
  151      windows in undo/redo.
  152      Also: Fixed a warning message on number of parts that should
  153      apply only to library objects, not pages.
  155 358  v3.6 rev 7		2/24/06
  156      Changed the meaning of CAD_HOME to point to "libdir", such
  157      that distributions can set it to something like /usr/share
  158      without causing trouble.  Changed CAD_HOME to CAD_ROOT so as
  159      to prevent it from breaking backward-compatibility.
  161 357  v3.6 rev 6		2/23/06
  162      Fixed a spurious "Error:  end of file" message.
  163      Corrected the configure.in once again because Tcl/Tk defines
  164      TCL_INCLUDE_SPEC but *not*, stupidly enough, TK_INCLUDE_SPEC.
  166 356  v3.6 rev 5		2/21/06
  167      Added the Shift-Button-1 bindings to duplicate Button-2
  168      functions as an alternative to using "xcircuit -2".
  169      Also:  Added a flag bit to the line styles representing
  170      square end caps.
  172 355  v3.6 rev 4		2/13/06
  173      Fixed an error with the LaTeX mode ".tex" output to correctly
  174      handle the filename when the extension of the xcircuit file
  175      is not the default ".ps".  Also, changed the configure script
  176      to add some other standard locations to the directory search
  177      for tclConfig.sh and tkConfig.sh, and made use of the
  178      TCL_INCLUDE_SPEC and TK_INCLUDE_SPEC from those files to set
  179      the INC_SPECS definition.  Thanks to John Rigg for pointing
  180      out these problems with the Debian compile.
  181      Also:  Fixed a bug that can potentially cause XCircuit to
  182      crash when a box is drawn.
  184 354  v3.6 rev 3		2/3/06
  185      Added a number of "undo" functions for minor things that had
  186      been left unimplemented, including linewidth changes, scale
  187      changes, style changes, and text justification and option
  188      settings (flip invariance, latex mode, etc.).  Thanks to Joel
  189      Kuusk for pointing out the omissions.
  191 353  v3.6 rev 2		1/22/06
  192      Updated a number of changes from around version 3.5.3 that
  193      broke the non-Tcl-based version of xcircuit (not exhaustively
  194      tested).
  196 352  v3.6 rev 1		1/20/06
  197      Finally got around to correcting the crash backup behavior
  198      so that xcircuit ignores crash backup files belonging to an
  199      active process (i.e., another xcircuit currently running).
  201 351  v3.6 rev 0		1/7/06
  202      Restructured variables internally to acommodate multiple
  203      layout pages.  This is only a start, as currently new
  204      windows have no callbacks created.
  205      Also:  Created an enhanced version of the "Make Matching
  206      Symbol" routine, and created a new routine and menu selection
  207      "SPICE to Symbol", which creates a symbol for, and link to,
  208      a SPICE file containing a subcircuit definition.
  209      Also:  Longtime error:  Corrected the quick screen intersection
  210      check to include the schematic bounding box.  Otherwise, when
  211      only pin and info labels intersect the window, nothing is drawn.
  213 Version 3.5 (November 2005 to January 2006)
  214 ----------------------------------------------------------------------
  215 350  v3.5 rev 5		12/19/05
  216      Added command option "object <handle> library [<library>]"
  217      where the final optional argument was previously unavailable.
  218      If present, the final argument declares a new library for the
  219      object.  If not present, the number of the library containing
  220      the object is returned.
  221      Also:  Corrected lib/tcl/symbol.tcl where the "%n" was missing
  222      from the end of the subcircuit call statement.
  224 349  v3.5 rev 4		12/14/05
  225      Fixed an error in netlisting which causes the netlister to
  226      write "X.." lines in the SPICE output of "trivial" symbols
  227      like the "dot" object.
  229 348  v3.5 rev 3		12/13/05
  230      Fixed another fatal error in file writing due to having a
  231      NULL filename.
  232      Also:  Revised the Wprintf() calls to accept variable
  233      argument lists, rewrote the Tcl versions of W*printf() as
  234      calls to a script rather than being hard-coded as a specific
  235      Tk function.  This allows me to rewrite the script equivalent
  236      of Wprintf() to print to both the message widget and the
  237      console output, so the console now gets a complete record of
  238      warning, error, and informational messages produced by
  239      xcircuit.
  240      Also:  Fixed two fatal errors with "Load Dependencies", one
  241      which crashed xcircuit due to a typo in the Tcl code for
  242      command "page links load", and the other which created an
  243      infinite loop if loadfile() failed to load a file inside
  244      the recursive call to "page links load".
  246 347  v3.5 rev 2		12/8/05
  247      Corrected a behavioral error in which xcircuit does not
  248      generate netlist output for a symbol containing an info
  249      label but no pins.  Thanks to Herman Lee for pointing out
  250      this problem.
  251      Also:  Corrected a problem in 3.5.1 in which xcircuit
  252      changes filenames in a multi-schematic session to match
  253      the top-level schematic.  It ignored the setting of
  254      "dmultiple", and thus would make changes without warning
  255      when it generated the crash backup file, for example.
  256      Also:  Added a widget for managing multi-schematic file
  257      writes, with a menu hook from "Files->Write All...".
  258      Also:  Changed the behavior of "page changes" to include
  259      change counts of all descendents.  Fixed the Tcl parsing
  260      of the "page" command for certain options when a page is
  261      specified in the command (e.g., "page 1 fit").  Modified
  262      the "page changes" command so that the change count can
  263      be altered, thus forcing a page to be recognized as either
  264      modified or unmodified.
  266 346  v3.5 rev 1		11/21/05
  267      Separated the source code into distribution (version 3.4) and
  268      development (version 3.5) branches, on the suggestion of
  269      Zvezdan Petkovic.
  270      Also:  Added command option "page changes" which reports the
  271      number of changes on a page.  Modified some behavior so that
  272      starting certain commands like "copy" does not increment the
  273      number of changes, so that the command can be canceled without
  274      xcircuit thinking that the page has been modified.
  275      Also:  Added command option "config search file|library <list>"
  276      with a colon-separated list <list>, specifying the search order
  277      on a specific set of directories.  These lists are initially
  278      null, and behavior remains the same as before while these lists
  279      are null.  A non-null search path overrides the default search
  280      on the current working directory, and a non-null library search
  281      path overrides the search on XCIRCUIT_LIB_DIR and the default
  282      install directory path.  Modified the library manager to use
  283      search paths.
  284      Also:  Allow "library load <filename>" on a regular xcircuit
  285      (.ps) file, which has the behavior of loading the objects from
  286      the file without loading the pages themselves.
  287      Also:  Added command option "netlist get -hier" to generate
  288      a slash-separated hierarchy using device names and indices.
  289      Also:  Fixed "netlist goto <name>" to accept the same syntax
  290      that is produced by "netlist get -hier", and finished the coding
  291      of the routine.
  292      Also:  Added command options "netlist select <netname>" and
  293      "netlist position <netname>".
  294      Also:  Changed behavior of the "%" macro so that it also raises
  295      the console to the top of the window.
  296      Also:  Added command option "netlist parse <mode>" (e.g.,
  297      "netlist parse spice") that allows some selective parsing from
  298      a Tcl script.
  299      Also:  Created a script called "symbol.tcl" that replaces the
  300      function of the "Make Matching Symbol" button in the xcircuit
  301      menu, with a considerably fancier interface.
  302      Also:  Modified the command "color set" to accept color names.
  304 346  v3.5 rev 0		11/21/05
  305      This revision was not posted, but reflects changes made through
  306      version 3.4 revision 10 that were removed from the "stable"
  307      branch of the distribution.
  308      1. Changed the crash backup file name to include the process ID.
  309      This is intended to prevent xcircuit process from treating a backup
  310      file from another existing xcircuit process as a crash file to be
  311      recovered, but the code is not yet finished.
  312      2. Enabled creation of parameters on a top-level page, and revised
  313      the Tcl "param set" command to handle this case.
  314      3. Added a "page links sheet" option to allow querying "sheet A of B".
  315      4. Added a "page links load" option to allow symbols to specify which
  316      file contains the schematic, and load these prior to writing a netlist.
  318 Version 3.4 (August 2005 to November 2005)
  319 ----------------------------------------------------------------------
  320 345  v3.4 rev 10	11/16/05
  321      Removed the problem with automatic generation of pin labels on a
  322      symbol during a copy action in the schematic.
  323      Also:  Added doubly-protected backups to standard file writes.
  324      This renames the existing file to filename + tilde ("~") so
  325      that the file is not truncated if a crash happens during a
  326      normal file write.
  327      Also:  Added patch files by Zvezdan Petkovic for proper
  328      compilation on OpenBSD.
  330 344  v3.4 rev 9		11/14/05
  331      Applied (partially) a patch from Larry Doolittle that fixes a
  332      pointer bug in the non-Tcl version, and allows compilation of
  333      the non-Tcl version on a 64-bit system.
  334      Also: Fixed the event mechanism to allow pages to be selected
  335      in the page directory (otherwise, pages cannot be swapped).
  336      Also: Fixed the Tcl "push" command so that "push selected" now
  337      works, and clicking the "push" toolbar button when an object
  338      is selected has the expected effect.
  339      Also: Fixed the Tcl "label justify" command so that changing
  340      vertical justification does not reset the horizontal justfication.
  341      Also: Fixed the Tcl-to-xcircuit string conversion so that plain
  342      text with spaces is handled as expected (thanks to Mark Martin
  343      for pointing out this problem).
  345 343  v3.4 rev 8		11/10/05
  346      Changed an instance of "regsub" to make it backwardly compatible
  347      to Tcl version 8.3;  otherwise, xcircuit fails to start up
  348      properly when linked to Tcl/Tk 8.3.
  350 342  v3.4 rev 7		10/28/05
  351      Corrected event handling of schematic/symbol association,
  352      which was allowing xcircuit to return to "normal" mode while
  353      on a library page, resulting in bizarre behavior, and preventing
  354      the schematic/symbol association from being made.  Thanks to
  355      James Vernon for pointing out the problem.
  357 341  v3.4 rev 6		10/25/05
  358      Fixed bounding-box calculations on instance loads so that
  359      instanced values of expression parameters are handled correctly
  360      on file read-in.  Also, corrected "resolveparams" to remove
  361      cached expression results before writing a page to a file.
  362      Also: Added component unnumbering feature (as written, only
  363      for devices having the "idx" parameter).
  365 340  v3.4 rev 5		10/21/05
  366      Added command option "label replace", menu items "Text->
  367      Increment" and "Text->Decrement", and key bindings "i" and
  368      "I" (respectively) to auto-increment (decrement) numerical
  369      values inside text labels.  As part of this, I also rewrote
  370      and completed the Tcl list-to-XCircuit string conversion
  371      routine.
  372      Also: Fixed a bug reported by James Vernon due to accessing
  373      free'd memory, which appears to be fatal under Cygwin but
  374      not under Linux.
  376 339  v3.4 rev 4		10/19/05
  377      Added command option "library filename" and the ability to
  378      save the first file from which a library page was loaded.
  379      Also: Added the "page load -replace" and the ability to
  380      load/save specific libraries by name.  Changed the "File"
  381      menu and the popup prompts to allow all of this to be done
  382      from the GUI interface.
  383      Also: Added more Cygwin handling to the Makefile process,
  384      and tested the Cygwin compile and install. 
  386 338  v3.4 rev 3		10/6/05
  387      Some fixes to things broken between versions 3.3 and 3.4:
  388      Move "undo" stays on grid.  Items being moved during move
  389      and copy commands stay with the cursor through pans.
  390      Button-3 now does the proper thing for cancellations
  391      during move mode.
  393 337  v3.4 rev 2		10/6/05
  394      Refined and expanded the hierarchical element handle
  395      notation to cover all commands accepting element handles.
  396      This will now work for commands such as "element type".
  397      Still, only "polygon points", "spline points", and
  398      "instance center" commands translate point positions back
  399      to the top level.
  401 336  v3.4 rev 1		10/5/05
  402      Fixed an error with finishing path edit operations,
  403      added "internal units" type to the grid display types,
  404      and implemented a (preliminary) hierarchical specification
  405      for element handles that can be used with the "polygon
  406      points" command to refer point positions back to the
  407      top level.
  409 335  v3.4 rev 0		10/3/05
  410      Substantially revised the interface and input mechanism,
  411      removing the remaining methods that were hard-coded to
  412      various mouse buttons.  Instead, I have implemented the
  413      button "Hold" mechanism in a general-purpose manner that
  414      also allows definitions of key hold bindings.  I removed
  415      many of the event modes, including all of the element
  416      creation modes available from the GUI tool buttons, as
  417      these are more obviously implemented by changing button
  418      bindings.  This allows the various modes to be switched
  419      on and off, and allows wire drawing mode to be just one
  420      of the modes rather than the default mode.  Adding "wire",
  421      "move", and "pan" modes as more-or-less obvious button
  422      binding variations.  Added ASCII85 and Flate encoding/
  423      decoding to the graphic read/write operations.  Added
  424      a "-2" option to the command-line invocation of xcircuit
  425      to set mouse button bindings for 2-button mice.
  427 Version 3.3 (September 2004 to July 2005)
  428 ----------------------------------------------------------------------
  429 334  v3.3 rev 38        9/28/05
  430      Corrected multiple-button checking routine to look at
  431      the event state only, not the button, as the button
  432      entry is changed by some routines.  This was preventing
  433      the shift-button key bindings from working.
  435 333  v3.3 rev 37        9/20/05
  436      Corrected SPICE output to generate a line break and
  437      continuation "+" character for wraparound lines.
  439 332  v3.3 rev 36        9/16/05
  440      Fixed an error with netlist output in which parameters are
  441      not substituted if xcircuit is run in batch mode.
  443 331  v3.3 rev 35        9/15/05
  444      Fixed parameter indirection---parameter string was not
  445      initialized on library read-in, causing a segfault.  Also,
  446      changed the behavior of ordered spice lines so that they
  447      will be placed after any subcircuits are written, to avoid
  448      nesting subcircuits.  A syntax "spice@" has been added for   
  449      lines that really should go in front of everything (except
  450      for the special title line #1).
  452 330  v3.3 rev 34        9/14/05
  453      Implemented "label latex" in the Tcl version, which was
  454      missed in the move from Xt to Tcl, and because it is an
  455      obscure function, was not noticed for some time.  Thanks
  456      to Eric West for bringing it to my attention.  Also:
  457      Applied a patch by Joerg Wunsch that prevents a segfault
  458      when rotating a path element.
  460 329  v3.3 rev 33        9/8/05
  461      Corrected an error in netlisting that would incorrectly
  462      identify empty parameter strings as the "idx" parameter.
  463      Also, added a "-nowindow" switch to the UNIX command-line
  464      invocation to allow xcircuit to be used as a filter (batch
  465      process) without creating/displaying an X11 window.
  467 328  v3.3 rev 32        9/6/05
  468      Changed the handling of netlist writing from symbols, in
  469      particular to avoid crashing on encountering unexpected
  470      info label contents.  Also:  Added a "-replace" option to
  471      file loads, that causes any object in a file to be
  472      overridden by one in a library "master copy".  Also:  Revised
  473      the "library make" command to allow an arbitrary number of
  474      empty libraries to be created.
  476 327  v3.3 rev 31        8/10/05
  477      Fixed a problem with the graphic image handling in which graphic
  478      images are saved to the output file if they exist, regardless of
  479      whether or not they show up in the output page.  Also fixed the
  480      PPM reader to handle whitespace and newlines in the header
  481      correctly, according to the PPM spec.
  482      Also:  Added revision information to the "welcome"
  483      message in addition to the major.minor version.
  484      Also:  Some changes to the Makefile to properly handle
  485      passing of linker flags in the shared vs. static compiles.
  487 326  v3.3 rev 30	7/28/05
  488      Fixed a problem with the startup TCL code that causes XCircuit
  489      to fail to start if a parse error is found in the user's
  490      ~/.Xdefaults file (even a completely unrelated parse error).
  491      Thanks to Roland Roberts for the bug report (and, much earlier,
  492      Romano Giannetti, although at the time I administered to the
  493      symptoms, not the disease.
  495 325  v3.3 rev 29	7/22/05
  496      And yet more auto-numbering revisions.  Ensure clearing of
  497      device indices prior to both netlist output and auto-numbering.
  498      Also, fixed parseinfo() to correctly handle the mode="" case.
  500 324  v3.3 rev 28	7/21/05
  501      More fixes to auto-numbering code ($#!@&).  Appears to work
  502      now for various cases, although I am not satisfied that it
  503      covers all situations.  One part of the fix forces xcircuit
  504      to ignore all fixed component assignments when generating
  505      flattened netlists.  While this ensures that all component
  506      numbers are unique, the output is not what might be expected,
  507      especially if there is no hierarchy in the schematic.
  508      Probably the parsing for fixed device numbers should *not*
  509      be done by parseinfo() but should be handled separately,
  510      under the assumption that this handles a limited number of
  511      backwardly-compatible cases and that normally it should
  512      expect to find "idx" and "class" parameters for each component.
  514 323  v3.3 rev 27	7/20/05
  515      Revamped the auto-numbering code (again!) to better handle
  516      the "class" and "idx" parameter method, and make auto-numbering
  517      independent of the netlist format (i.e., SPICE vs. pcb).
  518      Device (component) name ("class") was moved from the object
  519      structure to the Calllist structure (after all, if the class
  520      is parameterized, then an instance may have a different class
  521      from the object's default class), and this is generated directly
  522      after generating the Calllist structure, since it is independent
  523      of the netlist output format.
  525 322  v3.3 rev 26	7/19/05
  526      Further corrections to revision 20 code.  Device classes are
  527      now checked and updated for non-pcb devices (e.g., mosfets)
  528      when doing autonumbering.  Also:  parameter setting works
  529      for multiple selections;  e.g., several transistors can be
  530      selected at once and have width or length changed simultaneously
  531      for all of them.  Thanks to Carsten Thomas for the bug report
  532      and feature request.
  534 322  v3.3 rev 25	7/18/05
  535      Finally logged into SourceForge and incorporated some of the
  536      more recent patches found there.  Includes a patch to
  537      configure.in by Min Sik Kim, and a patch to fontfile.c by
  538      Zunda.
  540 321  v3.3 rev 24	7/17/05
  541      Updated keybindings with the new function "Graphic", which
  542      otherwise causes the help utility to crash.  Thanks to John
  543      Rigg for the bug report.
  545 320  v3.3 rev 23	7/15/05
  546      Added file load and save methods for the "graphic" element,
  547      as well as undo/redo operations, a menu item for loading
  548      graphic elements, and all essential operations.
  550 319  v3.3 rev 22	7/14/05
  551      Corrected broken file parsing from revision 21.  Image data
  552      is now read from "objectread" like everything else inside
  553      the Setup block.
  555 318  v3.3 rev 21	7/13/05
  556      Fixed a bug introduced in revision 20.  Also, started adding
  557      the new basic element type "graphic", to handle inclusion and
  558      placement of arbitrary graphic images.  This will eventually
  559      replace the buggy and cumbersome "background postscript"
  560      rendering via ghostscript.
  562 317  v3.3 rev 20	7/8/05
  563      Changed the component auto-numbering so that all component
  564      values are treated as base-36, to allow handling of non-numeric
  565      component numbers.  Also, the routine that determines the
  566      number to assign will return the smallest unused integer
  567      instead of (1 + (largest number found)) so that use of
  568      non-numeric values doesn't cause the auto-numbering algorithm
  569      to generate strangely large numbers.  Also:  The auto-numbering
  570      algorithm now looks at the parameter "idx" if it cannot find
  571      a "pcb"-style info-label.  This allows non-pcb parts like
  572      transistors in VLSI schematics to be auto-numbered.  This is
  573      really the preferred way to handle auto-numbering, and all
  574      library parts ought to be updated to contain the "idx" parameter.
  576 316  v3.3 rev 19	6/28/05
  577      Resolved the issue with retaining the stack order of
  578      parts through a delete-undo cycle, so that all previous
  579      undo records point to the correct parts in the correct
  580      order.  This eliminates a lot of spurious error messages
  581      coming from the undo mechanism.
  582      Also: Resolved the issue with polygon/arc/spline/path
  583      rotations, where rotations cannot be undone exactly due
  584      to accumulating roundoff errors.  The solution is simply
  585      to treat the rotation as an edit for these element types.
  586      Also: Fixed an error with label deletion.  Labels that
  587      are edited out of existance were not handled properly,
  588      an egregious error that was somehow overlooked.
  589      Also:  Modified console.tcl script to withdraw the
  590      console window on a window manager "close" request,
  591      rather than exit the application.  This bolsters
  592      the end-user illusion that the console is a subsidiary
  593      window of the layout, rather than vice versa.
  595 315  v3.3 rev 18	6/16/05
  596      Fixed an error reported by Benoit Bidoggia, in which
  597      an attempt to clean up redundant font changes triggers
  598      a crash becuase it has been passed the top-level instance
  599      instead of NULL (NULL is necessary because this function
  600      is called when reading an object definition, at which
  601      point there are no instances).
  603 314  v3.3 rev 17	6/12/05
  604      Fixed another error that showed up in Uwe's schematic,
  605      which is that the "test_insideness" algorithm fails if
  606      the box is degenerate---which happens for labels that
  607      are parameters set to a null string.
  609 313  v3.3 rev 16	6/10/05
  610      Corrected an error found by Uwe Zimmermann in which
  611      xcircuit calls free() on an unallocated space when 
  612      destroying an object containing an indirect parameter.
  613      Also:  Added some experimental code replacing the
  614      drawing functions with OpenGL.  This can be compiled
  615      in by passing "--with-opengl" to the "configure"
  616      script.  However, the code is currently unfinished.
  618 312  v3.3 rev 15	5/31/05
  619      Added another feature to the change of revision 14:
  620      Info labels that have negative sequence numbers (e.g.,
  621      "spice-1:", "spice-2:", etc.) will be written after all
  622      subcircuit and component output, whereas the usual positive
  623      sequenced labels "spice1:", "spice2:", etc., will be written
  624      before subcircuit and component output.  Each sequenced line
  625      is followed by a return character in the output.  First and
  626      last line of the netlist output is hard-coded (e.g., circuit
  627      title and ".end" line in SPICE (see rev 5 comments)).
  629 311  v3.3 rev 14	5/27/05
  630      Changed behavior of netlist generation to allow (finally!)
  631      info labels on a top-level schematic.  These labels are
  632      written verbatim into the output.  Probably needs checks
  633      to avoid attempting to process certain embedded escapes
  634      like pins. . .
  636 310  v3.3 rev 13	4/08/05
  637      Fixed an error that missed recalulating the instance
  638      bounding box after a text rejustification.
  640 309  v3.3 rev 12	3/29/05
  641      Changed behavior of the netlist connectivity highlight
  642      function in response to a suggestion by Long Yang that
  643      pin connection points should be hightlighted, the better
  644      to show places where a net does not attach to a pin.
  645      Also: Added a feature in response to a comment by John
  646      Barry that error messages disappear when netlists are
  647      saved if the netlist is not recreated.  This feature
  648      includes a checkbox in the Tcl wrapper that by default
  649      forces regeneration of the netlist on each netlist file
  650      write function.
  652      IN PROGRESS---Added "idx" to Pagedata; need to separate
  653      areastruct.page from the actual printed page number.
  654      This simplifies page re-ordering and allows schematic
  655      libraries to be "hidden" among the rest of the pages.
  656      xobjs.pages and areastruct.page will still refer to the
  657      index into pagelist.
  659 308  v3.3 rev 11	3/12/05
  660      Fixed an error, pointed out by Long Yang and Svenn Bjerkem
  661      in which xcircuit crashes when descending into an object.
  662      This was due to out-of-bounds array addressing, and must
  663      have been in the code for some time, but only shows up
  664      on some compilers (Solaris?).
  666 307  v3.3 rev 10	2/27/05
  667      Fixed an error in the flattened netlist output that has
  668      probably existed in most revisions of 3.3 to date,
  669      where net names are not correctly passed down from
  670      parent cell to child cell.  Thanks to Mark Chang for
  671      pointing out the error.
  672      Also:  Fixed a bug in the selection mechanism where
  673      the selection is not NULLed prior to return from the
  674      calling routine if no selections are found.
  676 306  v3.3 rev 9		2/5/05
  677      More changes to the selection mechanism.  Selection
  678      mechanism sorts polygons (wires) according to
  679      distance of the nearest edit point.  Previous
  680      selection is always kept and compared against
  681      current selection.  "pick" is only advanced if the
  682      selections are the same.  Pointer position when
  683      selecting a polygon to edit is restored from the
  684      warped position after a button-3 cancel function.
  685      Also:  Added all edit functions to the "undo"
  686      mechanism, as well as label creation.
  688 305  v3.3 rev 8		2/4/05
  689      Corrected several mistakes in the selection mechanism
  690      that left pending (unfinished) events on the stack.
  691      Also:  Corrected a problem from rev. 7 that did not
  692      register unselection events (key "x") with the undo
  693      mechanism.
  695 304  v3.3 rev 7		2/1/05
  696      Revamped the selection mechanism (finally) to get
  697      rid of the cumbersome "click to select or reject"
  698      method.  The new method picks one element, and
  699      cycles through objects so that a different object
  700      is selected on each button press, if several elements
  701      are found at the pointer position.  This method would
  702      be equally unwieldy save for a change in the way
  703      object instances are selected---the selection routine
  704      recursively searches for elements inside objects that
  705      are close to the pointer position (albeit with a wider
  706      capture range than on the top level).  This prevents
  707      selecting an object instance with lots of white space
  708      if the pointer is in the middle of the white space
  709      (such as a frame or border object).
  710      Also:  Corrected the "Make Matching Symbol" callback.
  711      Thanks to Mark Chang for pointing out the error.
  713 303  v3.3 rev 6		1/4/05
  714      Made additions to the "pcbout.tcl" script to support
  715      SMD integrated circuits, and resistors and capacitors
  716      (both chip and axial).  "pkg" parameter added to the
  717      Resistor and Capacitor parts in the "analoglib2"
  718      library.
  720 302  v3.3 rev 5		12/16/04
  721      Corrected a fatal error in library copies if no valid
  722      object is selected.  Corrected a compile error (C++-like
  723      syntax fails on many compilers).  Added option to print
  724      or not to print the ".end" statement at the end of a
  725      SPICE deck.
  727 301  v3.3 rev 4		12/10/04
  728      Corrected an error that allows "temp label" pins to be
  729      assigned the same name for different nets.  The number
  730      following "int" or "ext" on temp labels is now changed
  731      to match the net number when referencing the label name,
  732      if it is found to be different.
  733      Also:  Corrected another bug that causes a crash when
  734      copying an edited parameter back to an object.  The
  735      data record for the PARAM_END structure was not zeroed.
  736      This was okay previously because the data record was
  737      unused.
  739 300  v3.3 rev 3		12/6/04
  740      Corrected a problem in which drawn subcircuits and
  741      subcircuits declared with an "X.." in the info label
  742      will share index numbers, by forcing SPICE output to
  743      generate a devname of "X" for each drawn subcircuit
  744      object.
  745      Also: Changed the behavior so that device numbering
  746      starts at zero, not one.  Otherwise, if a device is
  747      numbered zero on the drawing (e.g., by having the index
  748      number entered by hand), xcircuit will generate a spurious
  749      "duplicate part" warning.
  751 299  v3.3 rev 2		12/3/04
  752      Fixed an error (apparently from 3.3 rev 0) that caused
  753      parameters to become hosed if changed (also causes program
  754      crashes).
  755      Also: Added handling of X11 button4 and button5 events for
  756      (potential) binding to mouse scroll wheel motion.
  758 298  v3.3 rev 1		10/8/04
  759      Changed the behavior of the PCB netlist generator to be
  760      more intelligent about finding the bottom of the
  761      layout hierarchy.  Also, corrected the netlist generator
  762      where it allowed a global net to be merged into a local
  763      net.
  765 297  v3.3 rev 0		9/28/04
  766      Replaced the "hspice" directory with Conrad Ziesler's
  767      "spiceparser".  The use of routine AddNTermModule() has
  768      broken the spice input for now, although once fixed, the
  769      results should be much improved.
  770      Also, changed the handling of expression parameters so
  771      that expression parameter results may be numeric, and
  772      evaluated results are saved in the PostScript output as
  773      instance values.  When traversing the hierarchy during
  774      redisplay, commands invoking a "selected" element will
  775      pick up the object instance being rendered.  The
  776      combination of these changes allows the implementation
  777      of several useful features such as counter-rotation and
  778      displaying the name of an object within the object.
  780 Version 3.2 (January 2004 to September 2004)
  781 ----------------------------------------------------------------------
  782 296  v3.2 rev 27	9/17/04
  783      Quick fix to allow the non-Tcl code to compile;  the
  784      experimental "ngspice" code contains numerous Tcl references,
  785      and although it does not depend on Tcl in principle, it is
  786      easier just to disable the code for the non-Tcl compile.
  787      It will not be missed.
  788      Also:  Changed the startup method from the hacked-up
  789      redirection of $HOME to a standalone "wish"-like executable
  790      that sets up "wish" to read in the .xcircuitrc file as its
  791      startup script.
  793 295  v3.2 rev 26	9/7/04
  794      Changes based on comments from Dale Grover for correct
  795      compilation/linking/installing under "Fink" on Mac OS-X
  796      10.3.
  798 294  v3.2 rev 25	9/6/04
  799      Fixed the wrapper code to ignore Tk's standard binding for
  800      the Tab and Shift-Tab key events during label text input.
  801      Otherwise, the window loses focus, which is an annoyance.
  803 293  v3.2 rev 24	8/25/04
  804      One major fix to the netlist code to insist that "updatenets"
  805      is never run on a symbol.  Otherwise, a circuit that has a
  806      symbol that is not used anywhere will generate an error when
  807      netlisting, resulting in no netlist.
  808      Also, many minor fixes/enhancements to the TCL command-line
  809      functions, mainly to support scripting.  There is now a
  810      script called "sue_xc.tcl" that supports the generation of
  811      schematics from ".sue" files (in particular, this is to
  812      allow xcircuit support for the IIT standard cell library;
  813      see http://www.ece.iit.edu/~vlsi/scells/).
  815 292  v3.2 rev 23	8/18/04
  816      Rather important fix from back in revision 19, in which routine
  817      "pointtonet" is supposed to merge crossing wires if they cross
  818      on top of a subcell port.  This is the method used to connect
  819      crossing wires with the "dot" symbol, so it is rather important.
  821 291  v3.2 rev 22	6/21/04
  822      Added capability to the parameter selection mechanism to handle
  823      Tcl-expression parameters of the form "lindex {list} <index>".
  824      Such expressions will generate a listbox-type popup window in
  825      which the user is prompted to select one of the choices in the
  826      list.  The parameter will be replaced by the same expression
  827      but with <index> changed to reflect the index position of the
  828      chosen parameter value.  The way to make such parameters in the
  829      first place is "parameter make expression <name> {lindex {list}
  830      <index>}".  To change the expression itself instead of selecting
  831      a choice from the list, use "parameter set" instead of the GUI
  832      interface.  Thanks to Paul Surgeon for suggesting this method.
  834 289  v3.2 rev 21	5/58/04
  835      More quick fixes:  Makefile error installing .tcl and .lps files
  836      due to an error in Makefile.am;  library object import now checks
  837      library version and does not attempt to import libraries that may
  838      be missing a dependency list.  Distribution libraries updated to
  839      make sure all of them will work with the library import function.
  840      Tcl function "library <name> <options...>" changed to accept
  841      "<name>" when library name is "Library: <name>".  This makes more
  842      sense, as it allows one to do, for instance:
  843 	"library load asg_spice"
  844 	"library asg_spice save asg_spice_new"
  846 288  v3.2 rev 20	5/26/04
  847      Quick fix to a bug pointed out by Petter Larsson, which must have
  848      been in the code for some time, which checks for names incompatible
  849      with the PostScript interpreter but then fails to make the change.
  850      Also, cleaned out some source code copies left over from bus
  851      representation implementation.
  853 287  v3.2 rev 19	5/20/04
  854      Finally got the bus notation handling into enough of a working
  855      condition that I dare to post the distribution.  In addition to
  856      basic fixes, improvements include handling of buses and partial
  857      buses with the "connectivity" function, and in particular,
  858      handling of instance-specific labels throughout the netlist
  859      (previously was only applicable to the netlist output).  The
  860      instance-specific labels allow the new "tap" object to work.
  861      Added the tutorial file "buses.ps" to the examples directory.
  863 286  v3.2 rev 18	5/6/04
  864      Removed the requirement that the GUI must be in place prior
  865      to startup.  XCircuit can be embedded directly in another
  866      application with or without its own GUI.  Without the GUI,
  867      it is necessary to create (and map) a "simple" window
  868      (e.g., "simple .mytest.draw -bg white -width 700 -height 400"),
  869      and then set the Tcl array variable "XCOps(window)" to be the
  870      Tk pathname of this window.  This creates a window into which
  871      things can be drawn by Tcl command-line commands.  To enable
  872      button and key actions, it is necessary to do:
  874      bind .mywin.draw <ButtonPress> {xcircuit::standardaction %b down %s}
  875      bind .mywin.draw <ButtonRelease> {xcircuit::standardaction %b up %s}
  876      bind .mywin.draw <KeyPress> {xcircuit::standardaction %k key %s}
  877      bind .mywin.draw <Enter> {focus %W}
  879      from the Tcl command line.  It is also possible to rewrite the
  880      wrapper script so that the whole GUI is present but rooted in a
  881      location different from ".xcircuit".  In that case, set the
  882      variable "XCOps(top)" to the top-level window name before
  883      invoking xcircuit::start.  In either case, one must run "wish"
  884      first, then load "xcircuit.so", create the appropriate Tk window
  885      or windows, set the appropriate XCOps() variable, then do
  886      xcircuit::start.
  888      Handling of bus notation is still unfinished in this (unreleased)
  889      version, and probably breaks the schematic capture altogether.
  890      This will be fixed prior to an actual distribution release.
  892 285  v3.2 rev 17	4/14/04
  893      Major enhancement:  Handling of bus notation in netlists!
  894      Also, Prohibit parameters from shadowing PostScript reserved
  895      names and definitions in xcircps2.pro, as is done for object
  896      names.  Also, finally found and excised the bug that was
  897      preventing correct comparison between object definitions on
  898      read-in, which was introduced along with the parameter type-
  899      promotion code.  Fixed another bug which prevented
  900      parameterizing position.  And, fixed a bug which prevented
  901      disabling flip invariance on text from the menu in the TCL
  902      version.  Also:  made more convenient constructor/destructor
  903      functions in elements.c, for general purpose use; these are
  904      called from tclxcircuit.c.  Also:  Reimplemented "strdup"
  905      as "Tcl_Strdup" in the TCL version; otherwise, there are
  906      places where memory is allocated by strdup, bypassing TCL's
  907      memory allocation, but free'd by Tcl_Free().  Also: modified
  908      the library manager "library import" routine to load any
  909      library instances of an object in addition to the object
  910      itself.
  912 284  v3.2 rev 15	3/15/04
  913      Reinstated colors and other parameters as XDefaults-style options
  914      in the TCL version using the Tk_GetOption() command.  Changed
  915      autoconf so that the TCL version is compiled by default (unless
  916      not found, or explicitly disabled).  Initial work on bus
  917      notation parsing.
  919 283  v3.2 rev 14	3/03/04
  920      Added a library manager (often requested) for handling large
  921      lists of parts.  Allows objects to be imported from libraries
  922      piecemeal.
  924 282  v3.2 rev 13	3/03/04
  925      Changed the TCL scripts and shell startup file so that the
  926      README directions for a test execution prior to install actually
  927      work as advertised.  Also, finally found a way to force automake
  928      to compile the tcl version with just "make" and "make install",
  929      thus hopefully eliminating the greatest source of compile-time
  930      woes.  Re-implemented the .so file loading so that the reported
  931      error is the real root cause error, not "file not found".  Also:
  932      removed Imakefile and all references to it.  Also:  Added a
  933      menu item for the PCB layout generation.  This is not yet
  934      sourced by default.
  936 281  v3.2 rev 12	3/01/04
  937      A couple of fixes to bugs reported by Brek Miller.  1) Library
  938      copy did not copy parameters correctly (missed both the "key"
  939      and "which" entries), and 2) The object comparison mechanism
  940      failed to correctly compare objects with parameters due to a
  941      typo in the code.
  943 280  v3.2 rev 11	2/27/04
  944      Some changes to command functions and netlist output.  Added
  945      file lib/tcl/pcbout.tcl, a script that converts an xcircuit
  946      schematic into a preliminary PCB layout.  This is very spare
  947      at the moment, to say the least; for instance, it only
  948      supports 7400-series devices.  But it's mostly proof-of-
  949      concept.
  951 279  v3.2 rev 10	2/26/04
  952      Some Makefile/configure changes, esp. for systems like Debian
  953      that do not find the Tcl/Tk include files.  Also, rearranged
  954      the menus so that "linewidth" commands (global and wire line-
  955      width) are more obviously placed ("wire linewidth" duplicates
  956      the "element border" entry).  Thanks to Forrest Cook for this
  957      suggestion.  Also, rewrote the library load command in
  958      xcircuit.tcl so that it prints the actual root cause error
  959      instead of complaining about "file not found".  Also, rewrote
  960      and extended the "help" window in Tcl, making it entirely
  961      script-driven from Tcl, and adding help text for each function.
  962      This required adding Tcl command "bindkey" variant with no
  963      arguments, which returns a list of all functions which can be
  964      bound, and "bindkey -func <function>", which definitively
  965      asserts that the argument is a function, not a key (because,
  966      e.g., "Delete" is both a key name and a function).  Also,
  967      made XCF_Prompt (key "%") execute xcircuit::raiseconsole in
  968      the TCL version (previously undefined in TCL).
  970 278  v3.2 rev 9		2/20/04
  971      Greatly expanded the undo mechanism, which now covers most of
  972      the major xcircuit functions.  This is definitely "beta test"
  973      code.  Also, renamed a number of functions and definitions to
  974      be clear about the difference between an element and an
  975      object (this confusion was left over from the really early
  976      days of the program).
  978 277  v3.2 rev 8		2/11/04
  979      Improved the ghostscript rendering mechanism so that it can
  980      handle (non-encapsulated) pages output from ghostview (which
  981      includes some global state-setting commands).  Also, greatly
  982      improved the rendering by backgrounding the process.  Xcircuit
  983      draws a blank background and continues until ghostscript
  984      reports that the page is finished, at which point the page
  985      gets redrawn with the background.
  987 276  v3.2 rev 7		2/6/04
  988      Some fixes to the ASG and hspice routines;  automake now checks
  989      for g++-3 <stl> vs. the older <stl.h> header file and adjusts
  990      accordingly.  The hspice parser no longer produces files
  991      netlist.sp and netlist-flat.sp.  Compilation of ASG is now
  992      disabled by default (and will be until it's stable. . .), and
  993      requires "configure --enable-asg" to enable the module.
  995 275  v3.2 rev 6		2/5/04
  996      Added the ASG and hspice parser modules back in, with additions
  997      to the master Makefile and configure script to support compiling
  998      both modules into the xcircuit Tcl shared object library
  999      xcircuit.so.
 1001 274  v3.2 rev 5		1/29/04
 1002      There was a 3.2 previously for the ASG implementation.  This is
 1003      being done again from scratch, but I'm continuing the revision
 1004      numbers where I left off, at 5.  Prior to adding ASG back in,
 1005      version 3.2 is in the process of implementing the "comprehensive
 1006      undo" function by creating the framework for running undo/redo
 1007      events and recasting the "delete" function into this framework.
 1008      More to be added in coming revisions.
 1010 Version 3.1 (January 2003 to January 2004)
 1011 ----------------------------------------------------------------------
 1012 273  v3.1 rev 38	1/28/04
 1013      Removed #ifdef SCHEMA from everything.  This should have been
 1014      done long ago. . . Also, removed %%PageBoundingBox from the
 1015      output for encapsulated PostScript files, as this appears to
 1016      screw up output when including the drawing in a document, such
 1017      as a LaTeX file.  Changed the behavior of the output dialog box
 1018      such that the page label is checked before writing, and the page
 1019      label is set to the filename if the label is still "Page #"
 1020      at the time the label is set.  Fixed the behavior of selecting
 1021      fill and border styles, especially a critical error with fill
 1022      styles that would allow polygons to acquire an invalid state,
 1023      causing netlist problems and/or unmatching PostScript output.
 1024      Changed the selection behavior such that elements are not
 1025      unselected after border/fill/color changes.  Fixed the behavior
 1026      of network connectivity highlighting to work with multi-page
 1027      schematics.  Changed some event handling to let most button-
 1028      release events act on the mouse position on the previous
 1029      button press (this works for drawing wires and editing polygons,
 1030      but not for copying elements).  Added "%N" escape to the
 1031      tag callback mechanism to allow all arguments to be passed to
 1032      the callback procedure as a list.  Fixed marking of "Closed"
 1033      checkbox in the Tcl "Border" menu.
 1035 272  v3.1 rev 37	1/23/04
 1036      Preparing for XCircuit 3.2 (ASG).
 1037      Revised some of the code structure of netlist.c, added routines
 1038      NameToPosition(), from the ASG code (xcircuit-3.2), and
 1039      PortToPosition(), which is a variant thereof.  Added the routine
 1040      ratsnest(), called by the command "netlist ratsnest" in the
 1041      Tcl console, which demonstrates some of the features required
 1042      for true ASG.  Also:  removes deleted items from the netlist
 1043      piecemeal, so that an ASG system can operate on an invalidated
 1044      netlist without encountering dereferenced pointers, or elements
 1045      which are not on the page they claim to be on.
 1046      Also:  Fixed another bug similar to that in #271 where no space
 1047      was printed after the closing "}" in multipart strings appearing
 1048      in parameters, which equally bad results.
 1050 271  v3.1 rev 36	1/21/04
 1051      Added support for schematics spread over multiple pages.  The
 1052      method is that all top-level pages that have the same page
 1053      label (object name) will be considered part of the same
 1054      schematic.  One of the pages is considered the "master", or
 1055      "primary" page, and keeps the netlist/portlist/calllist for
 1056      all the pages.  The other pages are the "slave" or "secondary"
 1057      pages, and refer to the master page for netlist information.
 1058      Also:  Fixed a couple of bugs resulting from messing with
 1059      the parameter formats, namely 1) put back the check for
 1060      equal "which" value in varpcheck and varfcheck, and 2) added
 1061      a space after printing a null-string "()" parameter value.
 1063 270  v3.1 rev 35	1/16/04
 1064      Modified and completed support for expressions in parameters.
 1065      In the TCL version, this supports all TCL expressions.  In the
 1066      non-TCL version, it allows simple character strings to be used
 1067      in parameters.  The expressions are not translated into
 1068      PostScript; the PostScript output records the expression, which
 1069      is unused, and the last evaluated result, which is taken to be
 1070      the parameter value.  Cleaned up more code for numeric and
 1071      indirect parameters, and added TCL options "-verbatim" and
 1072      "-indirect" to the "parameter" command to facilitate handling
 1073      indirect and expression parameters.
 1075 269  v3.1 rev 34	1/9/04
 1076      Cleaned up and finished most of the stuff having to do with
 1077      numeric parameters, parameters promoted from numeric to string
 1078      types, parameters on a top-level page, and indirectly-referenced
 1079      parameters.  Also:  Tcl variables moved into a single array.
 1080      Also:  Some support for arithmetic expressions in parameters.
 1081      Very rudimentary at present.
 1083 268  v3.1 rev 33	12/16/03
 1084      Fixed the text justification routine in TCL ("label justify ...").
 1085      Thanks to Petter Larsson for the bug report.  Fixed two problems
 1086      with "page clear"---one reported by Brek Miller, showing that
 1087      the free_single() routine was removing parameters from the
 1088      referenced object, not the instance, and one reported by Joel
 1089      Kuusk, where the Tcl "clear page" command allows clearing a page
 1090      while editing an object instance in the hierarchy of that page,
 1091      causing an immediate crash.  Finally, corrected prototypes.h
 1092      for routines setjustbit() and setpinjustbit() for the non-Tcl
 1093      compile, left in an improper state in revision 32.  Thanks to
 1094      Dave Armbruster for this bug report.
 1096 267  v3.1 rev 32	12/10/03
 1097      Fixes to the linewidth/border width changing from the menu in the
 1098      TCL version, as pointed out by Rob Olsen.  Also, on suggestion from
 1099      Makram Mansour, added LaTeX label handling.
 1101 266  v3.1 rev 31	12/08/03
 1102      Three fixes from bug reports by Bliss Carkhuff: "page save" returns
 1103      TCL_OK rather than an undefined value, parameter entry requires
 1104      exact match to keywords to get text escapes such as "underline", and
 1105      substring parameter creation corrected for creating parameters in
 1106      the middle of a label.  Page save error also pointed out by Mark
 1107      Martin, and Rob Olsen who additionally noted the additional error
 1108      in linewidth selection (which has also been fixed).
 1110 265  v3.1 rev 30	12/01/03
 1111      Made another change to the output such that all objects used on
 1112      all pages are output first, inside a PostScript DSC block
 1113      "DocumentSetup", followed by all the pages.  This modification
 1114      allows viewers like ghostview to figure out that these objects
 1115      may be used by any page, and prevents errors that occur when
 1116      skipping pages forwards or backwards in the viewer.
 1118 264  v3.1 rev 29	11/26/03
 1119      In response to Romano Giannetti, fixed the bounding box
 1120      routines so that EPS files are handled the way they used to be.
 1121      The only thing required was to set the overall bounding box to
 1122      remove the 1" margins; the page bounding boxes remain the same,
 1123      and ghostscript, ghostview, and EPS insertions into LaTeX
 1124      documents all appear to be handled correctly.  Also, added the
 1125      "override" commands to the TCL interface, although to match the
 1126      rest of the TCL syntax, these have been changed to "library
 1127      override", "loadfont override", etc.
 1129 263  v3.1 rev 28	11/19/03
 1130      Changed the way XCircuit handles embedded bounding boxes
 1131      and does page scaling and translation in the output.
 1132      Removed the "offsets" comment line from the output and
 1133      changed it to a PostScript translation, which means that
 1134      all the positional values in the PostScript output on a
 1135      top-level page are all in xcircuit internal units, without
 1136      offset, and are therefore invariant with scale, page size,
 1137      etc.  When an embedded bounding box is present, xcircuit
 1138      translates the output such that the bounding box is centered
 1139      on the page.  If "auto-scale" is selected, then the output
 1140      is scaled such that the bounding box fits centered on the
 1141      page with 1" margins minimum.
 1143 262  v3.1 rev 27	11/16/03
 1144      Extended the parameter method to include parameters passed
 1145      inherited by an object instance from its parent.  Fixed the
 1146      "make object" method such that parameters are copied into the
 1147      new object (as yet, the new object does not correctly inherit
 1148      the parameter from the parent).  Added preliminary support
 1149      for promoting numerical parameters to strings.
 1151 261  v3.1 rev 26	11/11/03
 1152      More fixes and extensions related to parameter key:value
 1153      pairs.  Added a popup window in the Tcl version for
 1154      editing substring parameters of an object instance,
 1155      including functions for formatting ASCII strings from
 1156      string parameters and vice versa.  Added a function
 1157      for the "Add New Color" button in the Tcl version, which
 1158      was missing.  Command syntax "color <idx>" changed to
 1159      "color set <idx>" and option "color add <name>" added.
 1161 260  v3.1 rev 25	11/6/02
 1162      Changed parameter handling to a key:value pair model.
 1163      Revised built-in libraries to take advantage of this
 1164      method, using keys like "value", "units", "length",
 1165      "width", etc.  Expanded and revised the "parameter"
 1166      command in Tcl-based XCircuit to provide the key:value
 1167      information, as well as providing parameter information
 1168      down one level in the hierarchy for an object instance
 1169      (using the key "-forward" as the last argument to the
 1170      "parameter" command).  Added command option "type" to
 1171      list parameter types, or to list parameters by type.
 1172      Finished code for removing parameters.
 1174 259  v3.1 rev 24	9/19/03
 1175      Added feature (macro "V" key) to make a library virtual
 1176      instance from an object selected on a page.  This allows
 1177      users to make temporary copies of parameterized (or
 1178      rotated, or flipped) objects for quick retrieval.
 1179      Several corrections:  Xcircuit now checks for symbols
 1180      associated with schematics and saves them, even if the
 1181      symbols are not used in any schematic.  This prevents
 1182      associations from being lost after a save/quit/load
 1183      cycle in an unfinished schematic.  Also:  Snap and
 1184      polygon edit will invalidate the netlist.  Also:  "Make
 1185      matching symbol" reports an error if the schematic page
 1186      has an invalid name.
 1188 258  v3.1 rev 23	9/15/03
 1189      Corrected revision 22, which duplicated the NameToObject
 1190      routine by mistake.  Also added TCL wrapper key bindings
 1191      for function keys "Page Up" and "Page Down" to increment
 1192      or decrement the page number (helps with large numbers of
 1193      schematic pages).
 1195 257  v3.1 rev 22	9/10/03
 1196      Moved routine NameToObject from tclxcircuit.c to schema.c,
 1197      since it is used by the non-Tcl based code and prevents
 1198      compiling the non-Tcl version.  Thanks to Swee-Ann Teo for
 1199      pointing out the error.
 1201 256  v3.1 rev 21	9/5/03
 1202      Fixed a problem with the Tcl calls to the zoom functions,
 1203      which were passing a NULL event structure.  Thanks to Ed
 1204      Casas for pointing out this error.  Also:  Fixed the
 1205      Makefile.am file for compilation under Cygwin, which was
 1206      presented the wrong name for menudep.o.  Thanks to Carlos
 1207      Davila for pointing out this error.
 1209 255  v3.1 rev 20	9/4/03
 1210      Changed key and button handling in Tcl to work using the Tk
 1211      "bind" function, with the usual behavior being bound to the
 1212      "standardaction" command.  Standard actions can be rebound
 1213      using the xcircuit "bindkey" command, or keys can be bound
 1214      to Tcl procedures using the Tk "bind" command.
 1216 254  v3.1 rev 19	8/12/03
 1217      Required reconfiguring without Tcl once to generate the
 1218      "Makefile.in" in the Xw directory;  otherwise, automake 1.7
 1219      becomes a requirement.
 1221 253  v3.1 rev 18	8/6/03
 1222      A fix to the output, correcting the page numbering in the
 1223      PostScript page headers.  The incorrect numbering can cause
 1224      some printers to lock up. . .
 1226 252  v3.1 rev 17	7/14/03
 1227      Thanks to Ted Roth for fixing my rather too-hasty fix of
 1228      revision 16.  Also:  Some fixes to the autoconf script (also
 1229      from Ted Roth), and autoconf script updated to work with the
 1230      latest versions of autoconf/automake/aclocal.
 1232 251  v3.1 rev 16	7/08/03
 1233      Fix to "x" and "y" output for .sim format---thanks to Kath Shih
 1234      for pointing out this error.
 1236 250  v3.1 rev 14	5/05/03
 1237      Incorporated a patch from Max Horn to remove all references
 1238      to "malloc.h" from the headers, and fix the configuration file
 1239      for Mac OS-X compilation.
 1241 249  v3.1 rev 13	4/29/03
 1242      Fixed a problem due to automatic search for schematics which
 1243      prevents a single page from being saved.  The output window
 1244      now shows both "schematics" and "subcircuits" with checkboxes;
 1245      pushing "schematics" unlinks top-level schematics, and pushing
 1246      "subcircuits" can prevent subcircuits from being saved along
 1247      with the file.  In either case, the filename is blanked out
 1248      so the user will not mistakenly overwrite the original file
 1249      with a truncated one.  In conjunction with this method, the
 1250      Tcl "page links" command has been extended to include the
 1251      options "independent", "dependent", "total", "pagedependent",
 1252      and "all".  Eventually, I expect to add an additional option
 1253      "list" to list page names instead of simply enumerating them.
 1254      Thanks to Mark Jones for pointing out this error.
 1256 248  v3.1 rev 12	4/14/03
 1257      Fixed the PostScript background rendering, which was only
 1258      broken because of a broken implementation of ghostscript
 1259      (version 6.5).
 1261 247  v3.1 rev 10	3/21/03
 1262      Replaced TkCon with the version used with magic, fixing a
 1263      minor issue with handling backslash escape sequences.
 1265 246  v3.1 rev 9		2/26/03
 1266      Fixed the install for revision 8, which failed to run the
 1267      xcircuit.tcl script through the m4 preprocessor.  Also, on
 1268      recommendation of Mark Jones, added a warning message when
 1269      pins exist on a symbol which do not exist in the associated
 1270      schematic.
 1272 245  v3.1 rev 8		2/23/03
 1273      Resolved numerous issues with cross-application methods.
 1274      Overloaded the "label" Tcl procedure to accept both xcircuit
 1275      and Tcl syntax, and removed the "bgerror.tcl" file.
 1276      Added procedures for calling netgen, IRSIM, and magic while
 1277      running XCircuit.
 1279 244  v3.1 rev 5		2/19/03
 1280      Fixed (for the third time(!)) occurrences of "getline" which
 1281      should have been changed to "setline".  Fixed the toolbar
 1282      widget so that it recomputes its width when the window size
 1283      changes, and so that it does not squeeze the height of the
 1284      bottom message bar.
 1286 243  v3.1 rev 4		2/12/03
 1287      Added handling of "va_copy" to the configuration script for
 1288      systems which do not define it.  Also:  Added "%x" and "%y"
 1289      escapes to the info label syntax, for writing positional
 1290      information to the output (helps LVS programs like "netgen"
 1291      trace back errors to the schematic).  Split the "Manifest"
 1292      file into "CHANGES" and "TODO" and started adding revision
 1293      numbers to the change log entries to match the revision
 1294      number on the website download page.
 1296 242  v3.1 rev 3		2/10/03
 1297      Added Tcl handling of the string parameter insertion via a
 1298      popup prompt.
 1300 241  v3.1 rev 2		2/04/03
 1301      Traced the "No per display information" error to use of an Xt
 1302      function (XtDispatchEvent()); replaced with Tk_HandleEvent().
 1304 240  v3.1 rev 1		2/03/03
 1305      Fixed numerous problems with the Tcl-based version, and added
 1306      several missing functions (such as the select filter, and
 1307      handling keystroke <return> in the filelist widget).
 1309 239  v3.1 rev 0		1/24/03
 1310      Finished preliminary version of Tcl-based xcircuit.  Relocated
 1311      runtime files back to (default) "/usr/local/lib" (instead of
 1312      autoconf's default $datadir "/usr/local/share").  Threw in
 1313      tkcon.tcl for compatibility with magic/irsim/netgen and recast
 1314      fprintf() as macro Fprintf(), which calls "tcl_printf()" in
 1315      the Tcl version and "fprintf()" in the other versions.  Added
 1316      command-line function "-exec <file>" to the Tcl version for
 1317      running in batch mode (or alternately, just to bypass the
 1318      default startup file).
 1320 Version 3.0 (June 2002 to January 2003)
 1321 ----------------------------------------------------------------------
 1322 238  v3.0		1/15/03
 1323      On advice from Zhengdao Wang, changed the postscript header to
 1324      draw "opaque" styles as solid color, not stipples.  All fill
 1325      styles except for white (empty) are made opaque by default and
 1326      fill style white is made transparent by default.  The "opaque"
 1327      menu button can set the non-default behavior.
 1328      Also:  Added a file loading command to the python and
 1329      non-interpreter command-line interfaces.
 1331 237  v3.0		11/25/02
 1332      Cleaned up some code with respect to 64-bit pointers, checking
 1333      for the size of pointers in "configure", and setting the proper
 1334      integer type for pointers in xcircuit.h.  Should compile cleanly
 1335      on 64-bit systems without the "-taso" switch (which doesn't
 1336      exist for Linux/alpha systems).
 1338 236  v3.0		9/23/02
 1339      Added pixmap image handling to Tk/Tcl, and removed SWIG from
 1340      the "make" process.  Configure option "--enable-wrapper" changed
 1341      to "--enable-tcl", "make wrapper" changed to "make tcl", and
 1342      "make install-wrapper" changed to "make install-tcl".  Added
 1343      the toolbar and associated functions.  Added "netlist" function
 1344      to Tcl for generic netlist handling.  Fixed numerous errors in
 1345      the Tcl callbacks.  Tcl functionality is now about 95% of what
 1346      it should be.  Non-Tcl version has not been affected by these
 1347      changes.
 1349 235) v3.0		7/17/02
 1350      Several bug fixes for bugs reported by Massimo Gaspari (see
 1351      below).
 1353 234) v3.0		7/08/02
 1354      Fixed bug in the Python "bind" command such that keys not
 1355      bound to macros return an xcircuit error, not a Python error
 1356      (bug reported by Bob Paddock).  Also fixed a bug reported by 
 1357      Petter Larsson <f97-pla@nada.kth.se> in which the result of
 1358      getenv("XCIRCUIT_LIB_DIR") is not check for a NULL value
 1359      when executed from (any) interpreter.
 1361 233) v3.0		7/03/02
 1362      Several bug fixes for parameter-functionality bugs found by
 1363      Massimo Gaspari <gaspari@tin.it>.  Changes are relatively minor
 1364      and not worth inducing a version number change.
 1366 232) v3.0		6/24/02
 1367      Abount 90% of the Tcl functionality necessary to duplicate all
 1368      existing functions has been completed.  This makes the Tcl-wrapped
 1369      version useable, but experimental, and a bit crash-prone.  The
 1370      command set it written up in "README.Tcl".  Compiling involves
 1371      doing "configure --enable-wrapper" followed by "make wrapper"
 1372      and "make install-wrapper".  Otherwise, the standard "configure"
 1373      and "make" results in the standard version of xcircuit.
 1375 Version 2.5 (November 2001 to June 2002)
 1376 ----------------------------------------------------------------------
 1377 231) v2.5.5		5/21/02
 1378      Started on the Tcl-wrapped version of XCircuit.  Currently
 1379      this is just a big mess.  I am posting it to the distribution
 1380      with all the wrapper stuff disabled and no instructions on how
 1381      to compile it, mainly so I don't have to keep making sure that
 1382      bug fixes are reflected in both versions.
 1384 230) v2.5.4		5/14/02
 1385      Revised the CvtStringToPixel so that it satisfies (or should
 1386      satisfy) all X servers doing 8 bpp, even those that return
 1387      bogus values on XLookupColor().  Previous "fix" had disabled
 1388      private colormap installation.
 1389      Also:  Improved "gettext.py" to deal with tabs and page breaks,
 1390      and takes optional values for maximum lines per page and font
 1391      to use.  Fixed a bug in "pagebbox.py" and also a related bug
 1392      which clipped color values to size short when set by "setattr"
 1393      in Python.
 1395 229) v2.5.4		5/10/02
 1396      Fixed a bug in which XCIRCUIT_LIB_DIR must be defined or the
 1397      program will crash.  Also:  Added text split and join functions,
 1398      and text "up" and "down", mapped to the Up and Down arrow keys.
 1400 228) v2.5.4		5/09/02
 1401      Changed the format of the output of the Python netlist() function
 1402      to better facilitate flattened netlists.  Nets are passed by
 1403      number and associated to names in a separate dictionary.  This
 1404      allows names to be changed (as required when flattening) without
 1405      altering the netlist.  Otherwise, it becomes a big mess.  The
 1406      new format ends up being smaller than the original.  "flatspice.py"
 1407      has not yet been completed, though.
 1409 227) v2.5.4		5/07/02
 1410      Repaired some problems with the Python netlist() function, and
 1411      wrote a working version of "spice.py".  Will replace the
 1412      internal functions when the "sim" and "pcb" scripts are written.
 1414 226) v2.5.4		4/29/02
 1415      Various changes in response to bug reports:  Fixed library and
 1416      page object exchange, PCB infolabels on quad parts.  Seg fault
 1417      due to missing code in "unmakenumericalp" has been worked around,
 1418      but the routine still needs to be finished.  Patched filelist.c
 1419      to query result of stat().  Fixed error with XQueryColors in
 1420      8-bit pseudocolor mode.
 1422 225) v2.5.4		4/26/02
 1423      Got rid of the "passive grab" action, which seems to be the root
 1424      cause of the video screen blanking on some systems.  Eventually
 1425      discovered that "XtAddEventHandler" doesn't work for ButtonMotion
 1426      if it's called AFTER the button has already been pressed.  With
 1427      this fact in hand, it was easy to avoid all the Add/Remove calls
 1428      and just add the event handler once, at the beginning.
 1430 224) v2.5.4		4/19/02
 1431      Replaced the top-level object with a top-level instance, with
 1432      all the ensuing fallout.  The resulting code is much cleaner.
 1434 223) v2.5.4		3/25/02
 1435      Fixed the problem of parts being auto-deleted by the netlister
 1436      pointed out by Jeremy Brown.  Also:  Fixed a problem found by
 1437      Bob Paddock in which label segments are miscounted on output;
 1438      apparently, this only happens using the "gettext" script.
 1440 222) v2.5.4		3/21/02
 1441      Changed library structure so that every object gets an instance.
 1442      This precipitated many code changes.  Along the way I fixed up
 1443      a bunch of minor errors, too many to list.  Bounding boxes in
 1444      the PostScript output ("bbox" entry) have become obsolete,
 1445      except for font files, where the bounding box is not necessarily
 1446      coincident with its contents.
 1448 221) v2.5.4		3/19/02
 1449      Added key binding for "pin global" (key "G"), which was
 1450      documented but was not actually in the program.  Thanks to
 1451      Jeremy Brown (jhbrown@ai.mit.edu) for pointing this out.
 1452      Also:  On another suggestion of Jeremy's, added a scrollbar
 1453      to the help window.  Along the same lines, cleaned up the
 1454      "file read" window so that the pixmap is never shorter than
 1455      the viewport.  Fixed a small error with PostScript background
 1456      rendering---newline before "end_insert" avoids problems with
 1457      binary-format PostScript.  Changed default key binding for
 1458      BackSpace to equal behavior of Delete.  This seems to be what
 1459      most people expect and/or want as default behavior.
 1461 220) v2.5.4		3/12/02
 1462      Implemented instance-defined bounding boxes and cleaned up a
 1463      lot of stuff related to bounding boxes.  This was needed to
 1464      properly implement the new "libinst" method described below.
 1465      Also: Altered the connectivity highlight function so that it
 1466      retains the number of the highlighted net in the netlist, and
 1467      continues to display the highlight through page changes and
 1468      expose events.  Fixed a bug in the PCB netlister.
 1470 219) v2.5.3		2/27/02
 1471      Fixed a few minor inconsistencies related to color allocation.
 1472      Also:  Implemented a "select previous" command, an undo command
 1473      for selections.  Third mouse button function ("Escape") will
 1474      unselect anything that is selected, but if nothing is selected,
 1475      it will retrieve the last selection.  Page/object changes
 1476      destroy the previous selection record.  Also:  Added intanced
 1477      scale and rotation values to the "libinst" record (values are
 1478      optional).  This allows, for instance, the "arrowhead90" object
 1479      to be replaced by an instance of the original "arrowhead"
 1480      rotated by 90 degrees.  All libraries updated to include
 1481      useful instantiations of objects rotated by 90 degrees:
 1482      arrowhead, arrow, circle, jumper, and all of the analoglib2
 1483      objects which allow instanced rotation and justification of
 1484      their parameter value labels.
 1486 218) v2.5.3		2/26/02
 1487      Bug fixes to incremental netlisting.  Also:  Separated the loading
 1488      of GUI colors from that for layout colors.  The schematic capture
 1489      was re-using SNAPCOLOR, AUXCOLOR, and BBOXCOLOR, which causes bad
 1490      effects if one attempts to change these values in the X defaults.
 1491      Re-used GUI colors were not necessarily duplicated or available
 1492      in the layout color palette, which was also confusing.  Also:
 1493      environment variable XCIRCUIT_LIB_DIR now applies to the search
 1494      for the startup script.  This enables xcircuit to be tested prior
 1495      to installation by doing "setenv XCIRCUIT_LIB_DIR ./lib" in the
 1496      top-level source directory.
 1498 217) v2.5.3		1/30/02
 1499      Changed the behavior of the PostScript background so that it scales,
 1500      rotates, and translates with output selections (Landscape vs. Portrait,
 1501      and vs.  Output Scale), so the behavior is what would be expected.  Still
 1502      allows only one background image per page, though, and the PostScript
 1503      image can't be scaled, rotated, and translated independently of the rest
 1504      of the drawing (those things must be done to the image prior to loading).
 1506 216) v2.5.3		1/3/02
 1507      Minor bugfixes:  variable reading (varfscan, varpscan) requires skip
 1508      over whitespace.  Netlist requires reinstating routine nearpoint()
 1509      because matrix transformations have roundoff errors and pin positions
 1510      should not be compared exactly.  Updated Copyrights to 2002.  Netlist
 1511      generation has been confirmed on a large schematic design.
 1513 215) v2.5.3             1/1/02
 1514      First cut at incremental netlisting---implemented a scheme in which
 1515      netlists are kept after being generated, until they are invalidated
 1516      or the object is destroyed.  This scheme allows the netlist structure
 1517      to be queried at any time.  Netlist creation is independent of the
 1518      netlist mode, as it should have been to begin with.
 1520 215) v2.5.2		12/26/01
 1521      Correction to duplicate object code makes sure that schematic/symbol
 1522      association does not get destroyed along with the duplicate object!
 1524      Also:  Applied Holger Vogt's patches to configure.in for proper
 1525      compilation under Cygwin.
 1527 214) v2.5.2		12/15/01
 1528      XCircuit now allows pin labels to be parameterized, treating them
 1529      as an instance-dependent label.  While this does not alter the
 1530      SPICE and sim netlists, it allows (for example) quad parts such
 1531      as four NAND gates of a 7400 chip, each having its own unique
 1532      pinout but sharing the same object.
 1534      Also:  To go with the pin labels, added a method for generating
 1535      "virtual copies" of an object to appear on a library page ("V"
 1536      key from the library page).  The virtual copy is a different
 1537      instance of the object, and can take different parameters.
 1538      Started on library "quadparts" with 7400-series pinouts to
 1539      facilitate use of the new feature with PCB netlisting.
 1541 213) v2.5.1		12/06/01
 1542      Revised the routines that deal with duplicate objects.  New routines
 1543      prevent propagation of appended underscores (used to differentiate
 1544      between objects with the same name but different structure).  The
 1545      major change is that a list of aliases is kept for objects with the
 1546      same structure but different names, so there is no confusion through
 1547      the process of reading the library.  When the loading is done, the
 1548      aliases are removed and the names are cleaned up.
 1550      Also:  Switched the copyright to GPL for better compatibility with
 1551      other open-source tools, and because it's the Right Thing To Do.
 1553 212) v2.5.0		11/28/01
 1554      Removed an ill-conceived routine which would delete duplicate
 1555      copies of an object even if the names were different.  This action
 1556      can give rise to very bad inconsistencies.  A better idea would be
 1557      to try to "clean up" leading underscores whenever an object with
 1558      a leading underscore is deleted.  However, this is a minor point.
 1560      Also:  Fixed a string overrun bug in charreport().
 1562 211) v2.5.0		11/16/01
 1563      Finally (!) added support for parameterized values other than
 1564      label (sub)strings.  This includes parameterization of all
 1565      element values except color (which is handled by an inheritance
 1566      model).  Includes parameterization of:  point position (x, y, or
 1567      both), line style, linewidth, scale, rotation, label justification,
 1568      and arc radius, minor axis, and endpoint angles.  Includes support
 1569      loading, saving, displaying, printing, and editing.
 1571 Version 2.4 (November 2001)
 1572 ----------------------------------------------------------------------
 1573 210) v2.4.0		11/14/01
 1574      Added python script "pagebbox.py" to create standard page-size
 1575      bounding boxes (request from Bob Paddock).  Along with this,
 1576      I updated the python code to handle colors by name or RGB
 1577      components, rather than by index, which is visual-dependent.
 1579 209) v2.4.0		11/12/01
 1580      Bug fixes to 2.4.0:  Fallback resources string must be null-
 1581      terminated, added 2 remaining fallback resources that are
 1582      not taken care of by the XtGetApplicationResources() routine,
 1583      and changed XtAddConverter to XtAppAddConverter.  I hope that
 1584      the application-specific references will prevent problems
 1585      with the timeout functions, and maybe with input focus as well.
 1587      Also: Fixed type casting of values retrieved from the message3
 1588      widget---values are type "Dimension" and "Position" (usually
 1589      defined as unsigned short and short, respectively), not int.
 1590      Causes errors under Solaris and probably other systems, too.
 1592 208) v2.4.0		11/09/01
 1593      Switched to a new method for defining rotation.  Rotation in
 1594      xcircuit is now given in degrees, which matches the PostScript
 1595      output.  Flipping is done in the obvious way by declaring a
 1596      negative scale value (which is applied only to the X component
 1597      in the transformation matrix;  Y is always positive).  Lookup
 1598      tables for sines and cosines are replaced by the math library
 1599      functions, which presumably are fast enough not to show any
 1600      performance hit on most machines.  The redefinition of the
 1601      PostScript prologue prompts the move to a new minor version
 1602      number.  Rotation is still an integer value, so the minimum
 1603      rotation increment is 1 degree.
 1605      Also: Fixed an error in the PostScript prolog in which text
 1606      flip invariance was incorrectly implemented after the addition
 1607      of text kerning & scaling methods.  Fixed another error in which
 1608      XCircuit and PostScript disagree about text orientation due to
 1609      roundoff errors.  Matrix values must be compared to some epsilon,
 1610      not zero, to determine when the orientation is 90 or 270 degrees.
 1611      epsilon = 1e-9 works fine.
 1613      Also: Changed certain Xt routines to include XtAppContext in the
 1614      hope of avoiding the problem with the TimeOut function conflicting
 1615      with other X11 programs (namely, screensavers).  Hopefully the
 1616      addition of fallback_resources to XtOpenApplication will prevent
 1617      problems with the X defaults when the X defaults file cannot be
 1618      found.
 1620 Version 2.3 (May 2001 to November 2001) 
 1621 ----------------------------------------------------------------------
 1622 208) v2.3.6		11/05/01
 1623      Added rudimentary "edit-in-place".  Currently, this is a bit odd,
 1624      because the hierarchy above the object is rotated to match the
 1625      "natural" orientation of the object, rather than the other way
 1626      around.  This should be fixed by allowing rotation and flips to
 1627      the top-level page (keep the transformation matrix for the page
 1628      rather than just the scale and position).  Skewing of the grid
 1629      due to rotations is a can of worms, though.  Probably rotating
 1630      to the nearest 90 degrees would suffice for most purposes.
 1631      Edit-in-Place is turned on by default.  It can be turned off if
 1632      the extra drawing clutters the window.
 1634 207) v2.3.6		11/01/01
 1635      Fixed a long-standing error in which the "rejustify" routine
 1636      was giving labels invalid "justify" bit fields.  Fixed a problem
 1637      with the "visible pins" in which the visibility flag would always
 1638      be reset by a rejustification of the label.
 1640      Also:  Removed the ":n" suffix from pages in multiple-page files
 1641      with the same name.  The addition of the suffix was screwing up
 1642      the association of symbols to schematics on file reads, and it
 1643      seems to work fine without it.  Some attempt is made to enforce
 1644      unique names for pages associated to symbols, but it seems to
 1645      work correctly whether or not names are unique.
 1647      Also:  Fixed an error in string parameter deletion, and added
 1648      a call to mergestring() after deletestring() to connect any
 1649      divided text.
 1651 206) v2.3.6		10/25/01
 1652      Revamped the file list window on the suggestion of Zhengdao
 1653      to highlight files that match the expected file extension.
 1654      Extended this idea to include a "file filter" which displays
 1655      only those files with matching extensions.  This feature can
 1656      be turned off by clicking a toggle button in case a file with
 1657      an unusual name or extension cannot be seen.
 1659      Also: Added a flag to the label justification value which
 1660      allows pins to be seen on hierarchical levels other than the
 1661      top.  Changes to the prolog prompted the change to subversion
 1662      6 although the change is fully backward-compatible.  Thanks
 1663      to Bob Paddock for the suggestion.
 1665 205) v2.3.5		10/24/01
 1666      Fixed a netlisting bug pointed out by Bryce Denny in which the
 1667      layer ordering of label vs. polygon can cause the label to not
 1668      be associated with the network under it.  This led me to
 1669      discover another bug in which a label position would update the
 1670      netlist properly but the actual label itself would not be added
 1671      to the netlist (the only apparent consequence is that the label
 1672      is not hightlighted during a connectivity check).
 1674      Also:  Fixed the behavior of the .xcircuitrc file loading so that
 1675      keys can be rebound from the file.  Added Python commands for
 1676      pan and zoom, and wrote an example script which rebinds keys "Z"
 1677      and "z" to a python function which combines the pan and zoom.
 1678      Separated zoom functions between those with and without screen
 1679      refresh.
 1681 204) v2.3.4		10/22/01
 1682      Fixed some buggy behavior with respect to loading and setting
 1683      default fonts in .xcircuitrc and xcstartup.py.  Thanks to Jeremy
 1684      Braun (jtbraun@MIT.EDU) for reporting these errors in detail.
 1685      Also:  Fixed a missing requirement in checking object name
 1686      syntax.  A PostScript name must be a string which cannot be
 1687      interpreted as a number.  Thus, "+9" and "1E9" are illegal
 1688      names.  Thanks to Bob Paddock (bpaddock@csonline.net) for
 1689      reporting this bug.
 1691      Also:  Changed behavior with respect to environtment variables,
 1692      allowing "TMPDIR" to set the temporary directory and allowing
 1693      an override of the "XAPPLRESDIR" directory.  Added a list of
 1694      environment variables used by xcircuit to the manual page.
 1696      Also: Revised the tempfile mechanism once again to include a
 1697      check on the number of times a file has been modified;  heavy
 1698      modification will induce a temp-file save even if the timer
 1699      has not expired.
 1701 203) v2.3.4		10/19/01
 1702      Implemented a "changed" file mechanism which checks for changes
 1703      to pages and objects and queries for confirmation if there are
 1704      unsaved changes upon quitting.  Changed filename behavior so that
 1705      all filenames have their own malloc'd space, instead of sharing
 1706      filenames.  Extended file backup to include different filenames
 1707      on different pages.  Added a toggle box on the output popup
 1708      window so that a page can be unlinked from a multipage file,
 1709      and displays the number of pages in the file.  Added the simple
 1710      popup window (no text entry) to the list of python calls.
 1712 202) v2.3.4		10/18/01
 1713      Fixed the crash file recovery so that ONLY the given crash file
 1714      can be loaded (load and cancel are the only choices).  Also,
 1715      the actual temp file name is hidden from view, and the original
 1716      filename is recovered from the "%%Title:" header line.
 1717      Also:  Fixed the problem in which startwire() was called after
 1718      a popup window button was selected.
 1720 201) v2.3.4		9/18/01
 1721      Names of pages added to the library and page directories.
 1722      Thanks to Bob Paddock <bpaddock@csonline.net> for suggesting
 1723      the feature.
 1725      Also: Updated "configure.in" to check for the infamous python
 1726      version 1.5, and disable the python interface if found.
 1728 200) v2.3.4             9/10/01
 1729      RPM package makefile fixes (thanks to Alex Habig
 1730      <habig@neutrino.d.umn.edu>).  Also:  changed undelete() to
 1731      xc_undelete() to avoid conflict with OpenBSD/FreeBSD system
 1732      calls.  Thanks to Mike Andrews <mikea@mikea.ath.cx> for
 1733      bringing this to my attention.
 1735 200) v2.3.4		8/12/01
 1736      Implemented a Python interface into the netlist structures.
 1737      Set up for use of Python scripts to generate all netlist
 1738      output, as well as dealing with non-PostScript format input.
 1740      Also: fixed a problem with crash recovery caused by the
 1741      program exiting on call to Py_Exit.  Improved the crash
 1742      recovery mechanism to automatically find crash files on
 1743      startup, and prompt user to load.
 1745      Also: added more Python functions, for page clear, page change,
 1746      add key bindings to Python functions, and create menu buttons
 1747      with callbacks to Python functions.  Added Python functions for
 1748      calling a popup prompt, file browser.
 1750 198) v2.3.3		7/27/01
 1751      Fixed more man page problems with the make process.  Added
 1752      default values for Python libraries when the Python Makefile
 1753      can't be found.  Made the rcfile parsing more robust, esp.
 1754      so it doesn't crash if it attempts to read a non-script file.
 1756 197) v2.3.3		7/26/01
 1757      Added auto-numbering of component numbers using netlist mode
 1758      "idxpcb".  This works for all component numbering (including
 1759      SPICE and sim) where the component number is parameterized and
 1760      denoted by a question mark ("?").  Thanks to Lapo Pieri
 1761      <lapo@iroe.fi.cnr.it> for the suggestion and some code to
 1762      implement the function outside of xcircuit.
 1764      Also: Fixed Imakefile so that imake uses m4 to generate the
 1765      man page correctly on "make install.man".
 1767 196) v2.3.3		7/18/01
 1768      Fixed two errors, one which split global nets in hierarchical PCB
 1769      netlists, the other which failed to find nested parameters.
 1771 195) v2.3.3		7/17/01
 1772      Some changes to the GNU autoconf (with much help from Albert
 1773      Chin) for correct parsing of the path to python, avoidance of
 1774      errors when generating the man page, and re-instantiation of
 1775      the keyboard input focus workaround.
 1777      Also: Removed the behavior of turning pins back into labels
 1778      when creating objects or moving labels between pages or
 1779      objects.  Added behavior that if a pin is removed (or moved
 1780      out of an object), and the pin has a unique string, any pin
 1781      on the corresponding symbol/schematic will revert to a plain
 1782      label.  This was the intended behavior.
 1784 194) v2.3.3		7/09/01
 1785      Added label strings to the Python setattr() command.  Added a
 1786      getcursor() command to Python.  Created a python script called
 1787      "gettext(filename)" which creates an xcircuit label from the
 1788      contents of an ASCII file.
 1790 193) v2.3.3		7/06/01
 1791      Quick fix to an error in interpreting key names for key bindings.
 1793 192) v2.3.3		7/05/01
 1794      Added environment variable XAPPLRESDIR so that application
 1795      defaults come from the location specified by the configure script,
 1796      not /usr/lib/X11/app-defaults.  This also allows app-defaults to
 1797      be used even if xcircuit is compiled without root privileges.
 1798      The configure script was modified to compile in Xpm, if it can
 1799      be found.
 1801 191) v2.3.3		7/02/01
 1802      Changed netlist behavior so that wires only connect at endpoints
 1803      (although an endpoint may attach TO any location along a segment
 1804      of another wire).  Optimized a few routines for speed.  Netlist
 1805      output now changes symbol font and standard font "mu" (i.e.,
 1806      micro) to "u".  Fixed a bug preventing correct loading of files
 1807      containing multi-part strings as parameters.
 1809 190) v2.3.3		6/28/01
 1810      Cleaned up some behavior with respect to component numbering,
 1811      including fixing numbering for flattened SPICE output.  Added
 1812      a PCB library for generic IC parts.
 1814 189) v2.3.3		6/27/01
 1815      Corrected the parseinfo() routine so that it correctly uses the
 1816      symbol, not the schematic, to pick up information about a pcb
 1817      name.  Changed some of the library objects (namely the passive
 1818      devices like Resistor and Capacitor) so that pin names are PCB-
 1819      like and device can be given a part number.  Changed the netlist
 1820      compiler behavior so that all indices are numbered relative to
 1821      a particular component, rather than numbered relative to all
 1822      components.
 1824 188) v2.3.2		6/25/01
 1825      Replaced the imake build with a GNU configure build.  Thanks to
 1826      Albert Chin-A-Young <china@thewrittenword.com> for setting up
 1827      the scripts for automake/autoconf.  For purposes of compliance
 1828      with modern directory nomenclature, startup files and such are
 1829      now installed in /usr/local/share/ instead of /usr/local/lib/.
 1831      Also:  Added a "show pin positions" feature (recommended by
 1832      Larry Doolittle) to the Options menu, which allows pin locations
 1833      to appear on the hierarchical level above, to help in finding
 1834      pin connections into objects.
 1836 187) v2.3.1		6/22/01
 1837      More patches from Larry Doolittle, some cleaning up cruft flagged
 1838      by compiling with -Wall, and re-patching a string function (an
 1839      error which I am unable to duplicate.  But I will take his word
 1840      for it).  Also, worked on Xw/TextEdit.c to implement horizontal
 1841      scrolling of text (so it will no longer run off the end of the
 1842      window).
 1844      Also, finally implemented a way to check for overlapping objects
 1845      caused by a copy or move (this is not exhaustive, but covers the
 1846      most obvious ways this can happen).  This is especially critical
 1847      for schematics, because multiple circuit elements will end up in
 1848      the netlist when they cannot be seen on the schematic.
 1850 186) v2.3.1		6/21/01
 1851      Applied patch from Larry Doolittle <ldoolitt@recycle.lbl.gov>
 1852      to correct error in line length computation when writing output.
 1853      Also modified file reader to treat lines ending with "{" as
 1854      continuation lines (such as the beginning of a label), if they
 1855      don't look like object definitions.
 1857      Also: Copying library objects now also copies the parameters,
 1858      and the page viewing parameters.  Corrected an error wherein
 1859      stringcopy() calls makesegment(), although the former is
 1860      supposed to ignore parameters, and the latter doesn't.  Also,
 1861      instantiated a slightly "improved" object compare that is able
 1862      to compare objects against objects with underscore-prepended name
 1863      adjustments, in an attempt to avoid a proliferation of underscores.
 1864      Fixed an error that reset "version" in the middle of a file read
 1865      if a font was loaded.  Updated some of the "examples" files to the
 1866      current format.
 1868 185) v2.3.1		6/18/01
 1869      Added tilde ('~') expansions to filenames.  Thanks to Norman
 1870      Werner <norman.werner@student.uni-magdeburg.de> for patches which
 1871      seeded the final version of this code.
 1873 184) v2.3.1		6/12/01
 1874      Changed the Imakefile for Python-2.1 and added instructions to the
 1875      README file on how to make a shared (.so) python library.
 1877 183) v2.3.1		6/11/01
 1878      Corrected a few errors which showed up on other compilers (thanks
 1879      once again to Albert Chin, <china@thewrittenword.com>).
 1881 182) v2.3.1		6/04/01
 1882      Fixed an error caught by John Livsey (<jlivsey@bigpond.com>) in
 1883      which loading old library files causes the version number to
 1884      revert to 1.9, causing havoc when reloading saved files.  This
 1885      has been fixed along with code to check more decisively for
 1886      which label syntax is in the file, and adjust the version number
 1887      accordingly rather than depend solely on the version number
 1888      extracted from the file header.
 1890 181) v2.3.1		5/31/01
 1891      Cleaned up errors found in the netlist code while doing a large
 1892      chip project.  Added flattened SPICE output and changed SPICE
 1893      output to be compatible with "hspice" syntax.  Netlist compilation
 1894      runs about three times faster than before, but should be able to
 1895      do better, still.
 1897 180) v2.3		5/16/01
 1898      Completed the full hierarchy search on subschematics.  searchconnect()
 1899      makes a call to search_on_siblings(), looking for any connection from
 1900      any object in the hierarchy of viewable (sub)schematics to the object
 1901      under consideration.  Added a bounding box disjoint test to reduce
 1902      unnecessary searching.  Could use a lot more optimization, though.
 1904      Also, from the March 27 version, genportpins() has been merged back
 1905      into gencalllist().  Spice and Sim netlists are correct for numerous
 1906      torture tests given to xcircuit.
 1908      Corrected errors in text generation stemming from the new
 1909      PostScript profile (thanks to Jeremy T Braun <jtbraun@MIT.EDU>
 1910      for patches).  Ultimately, decided to more closely match the
 1911      PostScript and XCircuit label formats by declaring an overall
 1912      scale outside of the label segments.  All font scales declared
 1913      by "cf" commands are therefore relative, not absolute.  The
 1914      change in output format prompted the change to version number
 1915      2.3.
 1917 Version 2.2 (December 2000 to May 2001)
 1918 ----------------------------------------------------------------------
 1919 179) v2.2.3		3/27/01
 1920      Completely overhauled the method for text strings, implementing
 1921      a linked-list method.  In conjunction with this change, also
 1922      overhauled parameters to be called bottom-up rather than top-
 1923      down, thus eliminating the need for tracking reallocated
 1924      memory (which was not compiling correctly under the latest
 1925      version of gcc).  Also made other structural changes, removed
 1926      the text backspace character, and replaced it with a tabbing
 1927      system.  Made key bindings for text home, end, left, right,
 1928      delete, return, and special character insert, as well as the
 1929      new tabbing commands.  PostScript profile revised to
 1930      incorporate the tabbing features.
 1931      Also:  Overhauled the netlist generator.  The result is much
 1932      cleaner and more understandable.  The main difference is that
 1933      the Netlist structure is comprised of nets and pins (no
 1934      separate Pinlist), and the Paramlist (now called a Portlist
 1935      to distinguish from object parameters) calls by net number,
 1936      not by pin name.  Ports are accessed dictionary-style, by
 1937      key-value pairs (port ID : netID).  The netlist is generated
 1938      in by three recursive routines, gennetlist(), genportpins(),
 1939      and gencalllist().  genportpins() now searches for net
 1940      connections arbitrarily far down into the netlist hierarchy.
 1941      gencalllist() resolves net numbers and removes empty calls
 1942      as it traverses the hierarchy.
 1943      Also:  Implemented recursive selection for finding network
 1944      connectivity, so any net visible on the page can be queried
 1945      for both a net name and highlighting the network.
 1946      Also:  Implemented automatic redraw of text with parameters,
 1947      so that parameters which are edited are immediately updated
 1948      wherever they occur in the current top-level page.
 1949      Also:  Thanks to Masao Kawamura (kawamura@mlb.co.jp) Media Lab.
 1950      Inc., Japan, for tracking down several bugs, including a very
 1951      bad one in which the admittedly dubious syntax
 1952                 a[x] = a[--x];
 1953      acts like (the intended) 
 1954                 a[x] = a[x - 1];  x--;
 1955      when compiled with -g (debug) option, but acts like
 1956                 x--; a[x] = a[x];
 1957      when compiled without debug.  Also, temporary files have been
 1958      reimplemented using mkstemp(), which is more secure than
 1959      tempnam() and tmpnam().
 1961 178) v2.2.2		3/7/01
 1962      Added significantly to the Python interface, including access to
 1963      all elements on a page by dictionary key:value pair assignment.
 1964      Added mouse button handling to the key binding, and changed the
 1965      help window to reflect current key bindings.
 1967 177) v2.2.2		3/1/01
 1968      Fixed a bug in the PostScript profile introduced with version 2.2,
 1969      wherein string bounding boxes were computed incorrectly because
 1970      user space was rotated.
 1972 176) v2.2.1		2/27/01
 1973      Implemented code for user-defined key bindings; set up default
 1974      key bindings to match all prior versions of xcircuit, and added
 1975      python and script commands to bind and unbind keys with function
 1976      definitions.
 1978 175) v2.2.1		1/30/01
 1979      Cleaned up a lot of code, making the subroutine parameter lists
 1980      consistent.  Added all the necessary function prototypes as a
 1981      separate prototypes.h file, and removed unused parameters and
 1982      unused variables.  Fixed a few heretofore unnoticed bugs in the
 1983      process.  Thanks to Karim Kaschani (karim.kaschani@arcormail.de)
 1984      for instigating this process, although I failed to find the bugs
 1985      he was experiencing, and may have to revamp the label and
 1986      parameter string concept (again!) to fix it.  Also, thanks to
 1987      David Nicholls (davidallannicholls@hotmail.com) for a fix to
 1988      nosprint(), although I didn't implement the rest of his
 1989      thoughtfully provided code (and there was a lot of it!),
 1990      preferring to leave much of it to Python scripts, which are
 1991      coming soon.  Expanded the Python functions, but so far, still
 1992      mostly experimental.
 1994 174) v2.2.1		1/22/01
 1995      Completely redefined the command-line, including the startup
 1996      script and .xcircuitrc file to be Python scripts, and embedded
 1997      the Python interpreter into xcircuit.
 1999 173) v2.2.0		12/19/00
 2000      Made additions to the command-line functions; also, declared
 2001      the library inclusion commands "loadlibrary" and "loadfontencoding"
 2002      to be obsolete, and changed the startup file "builtins.lps" to
 2003      a startup script called "startup.script".  This makes a lot more
 2004      sense.
 2006 172) v2.2.0		12/15/00
 2007      Finally declared version to be stable enough for a non-beta
 2008      release.  Revised methods for generating schematics and symbols
 2009      in the circuit hierarchy.  Added (a modified) analoglib2.lps
 2010      (circuit elements with parameters) to the "builtins" list.
 2011      Fixed errors with sim and pcb netlist outputs, and cleaned up
 2012      other minor things.  Object types are now "fundamental",
 2013      "trivial", and "subschematic", as well as "normal" object,
 2014      with the type depending partly on context.
 2016 Version 2.1b (July 2000 to December 2000)
 2017 ----------------------------------------------------------------------
 2018 171) v2.1b9 (beta)	11/30/00
 2019      Added full functionality for text blocks (carriage-return),
 2020      kerning, scaling, and color change within labels.
 2022 170) v2.1b8 (beta)	11/11/00
 2023      More fixes to the parameterization and netlist functions (thanks
 2024      to Terry Hancock <hancock@earthlink.net> for help with testing
 2025      and debugging this extraordinarily complex code).  Created a new
 2026      PostScript prolog which not only fixes one very long-standing
 2027      error, but also allows text blocks with carriage returns and
 2028      kerning within text blocks.  These functions have not yet been
 2029      reflected in the xcircuit code.
 2031 169) v2.1b7 (beta)	10/30/00
 2032      Possible fix (again!) to the input focus problem:  Added an
 2033      event handler to catch map and unmap events, so xcircuit should
 2034      never attempt to set input focus on an unmapped window.  Also:
 2035      extention to information labels allows labels to be broken into
 2036      parts, i.e., "sim1:", "sim2:", etc., and extended the protocol
 2037      of '%' sequences to include %r (carriage-return), %t (tab), and
 2038      %% ('%' symbol, literal).
 2040 168) v2.1b7 (beta)	10/25/00
 2041      Extended PCB netlist capability:  An info label beginning with
 2042      "pcb:" now indicates the object name to be used in naming the
 2043      pins.  The info label can contain all the %-escapes used for
 2044      spice: and sim: info labels, and similarly, can use parameters
 2045      with the Alt-p key sequence.  A new escape "%n" has been added
 2046      which inserts the name of the object into the output.  The new
 2047      pcb method can be used to explicitly define instances of an
 2048      object (i.e., "cap_1", "cap_2") or to redefine a name locally
 2049      ("inverter" becomes "1/6 74HC04", for instance).
 2051 167) v2.1b6 (beta)      10/23/00
 2052      Fixed a fatal bug pointed out by Wilson Barroz
 2053      (wbarroz@bol.com.br), in which a break statement got lost,
 2054      effectively crashing xcircuit if a path was selected.
 2056 166) v2.1b6 (beta)	10/2/00
 2057      Fixed problem with schematic capture on/off, so that pins and
 2058      info labels are not displayed or saved when schematic capture
 2059      has been turned off.  Fixed much of the problem with parameter
 2060      strings, and added simple capability to apply a single parameter
 2061      to multiple strings.
 2063 165) v2.1b5 (beta)	9/27/00
 2064      Fixed problem with writing empty parameter strings to the output;
 2065      also, fixed a fatal crash error when an entire string is a
 2066      parameter and is deleted.  XCircuit now prevents the creation of
 2067      parameters on a top-level page.
 2069 164) v2.1b5 (beta)	9/25/00
 2070      More changes to bounding box calculation:  Everything was correct
 2071      except for the top-level page offsets, which were calculated from
 2072      the bounding box excluding schematic pins and info labels.  Thanks
 2073      to Albert Ma <ama@cag.lcs.mit.edu> for pointing this out.
 2075 163) v2.1b4 (beta)	9/22/00
 2076      Added menu option to read a script, which has the same
 2077      functionality as the .xcircuitrc script (see #160, below).  Added
 2078      "enable toolbar" and "enable xschema" to the command-line parser.
 2080 162) v2.1b3 (beta)	8/7/00
 2081      Changes to fix problems caused by (158) below; the toolbar widget
 2082      has finally been arranged to use multiple columns when there is
 2083      not enough room for one.
 2085 161) v2.1b2 (beta)	8/4/00
 2086      Added a "auto-fit" feature to automatically scale the drawing to
 2087      fit the output page.  Also improved the behavior of the text-edit
 2088      widget to delete a selection if it exists in lieu of deleting a
 2089      character.
 2091 160) v2.1b2 (beta)	8/3/00
 2092      Added a command-line window which accepts the same commands as
 2093      the .xcircuitrc file.  This syntax will be expanded in the near
 2094      future.  Added text hints to the toolbar buttons.  Added a
 2095      user-definable bounding-box capability, and fixed the automatic
 2096      bounding-box calculation to include spacing between pins and
 2097      their text.
 2099 159) v2.1b1 (beta)	8/1/00
 2100      Added a temporary file saving feature for recovery from crashes,
 2101      sudden power-downs, or emergency exit.  Added a Control-C handler
 2102      to execute graceful exits from a hung state.  Temporary files are
 2103      doubly-protected by duplication before writing, so crashes during
 2104      writes will not cause the (previous) backup to be lost.
 2106 158) v2.1b1 (beta)	7/31/00
 2107      Minor changes for compilation using HP/UX's ANSI-C compiler; one
 2108      major fix preventing loadlibrary() from calling composelib()
 2109      with argument FONTLIB (composefontlib() should be used for that).
 2110      Updated version number to 2.1 after Graham Murphy pointed out
 2111      that xcircuit-2.0a11 crashes when reading 2.0b4 input:
 2112      incompatibility is due to the reformatted label statement.
 2113      Added warning if file version is greater than executable version.
 2115 Version 2.0b (October 1999 to July 2000)
 2116 ----------------------------------------------------------------------
 2117 157) v2.0b4 (beta)	7/18/00
 2118      Corrected the partial-text-selection algorithm;  new algorithm
 2119      makes an insideness test between each string character and the
 2120      select box.
 2122 156) v2.0b4 (beta)	6/28/00
 2123      Corrected and enhanced the routine printing the cursor position
 2124      and other information to the top of the window.
 2126 155) v2.0b4 (beta)	2/25/00
 2127      Finished implementing ghostscript-rendered backgrounds.  Added
 2128      a toolbar widget for easy access to common commands; this
 2129      implementation is not yet complete.
 2131 154) v2.0b3 (beta)	2/13/00
 2132      More bug fixes, covering several bugs which were introduced
 2133      with the 2.0b series:  bbox calculation after copy & move
 2134      across pages, segmentation fault when using middle mouse button
 2135      to finish a text label, double-printing of non-ASCII characters
 2136      in the output, confusion of grid and snap space functions from
 2137      the menu, and incorrect path starting position saved when 1st
 2138      path component is a spline or arc.
 2140 153) v2.0b3 (beta)	2/8/00
 2141      Testing preliminary support for Ghostscript-rendered backgrounds.
 2142      Bugfix to multiple library code (fatal error---adding new library
 2143      writes over current user library).  Another bugfix---objcompare
 2144      was not being called.
 2146 152) v2.0b3 (beta)	1/26/00
 2147      Further implementation of multiple libraries, including loading,
 2148      appending, and saving; specifying library pages from the rc
 2149      file and the library file (specifically, "builtins.lps"), and
 2150      a menu item for creating new library pages.  Currently there
 2151      is no way to move objects from one library page to any other
 2152      than the "User Library" (always defined as the last library
 2153      page), which is also true for object creation using "M" or
 2154      "Make Object".
 2156 151) v2.0b3 (beta)      1/13/00
 2157      Fixed behavior of rotate and flip when acting on groups and
 2158      extended behavior of both to cover all elements.  Fixed a bug
 2159      in text select.  Added a library-list page to enable multiple
 2160      libraries.  Fixed bounding box calculations so that the bounding
 2161      box updates on every element change, and that update is reflected
 2162      in the page directory, libraries, and library directory as
 2163      required.
 2165 150) v2.0b2 (beta)     1/10/00
 2166      More changes:  Added a page-list page to enable page reordering.
 2167      Structural changes:  Put page parameters into separate structure
 2168      and viewscale and pcorner parameters into the object structure.
 2169      Now every object retains its zoom scale and position where last
 2170      edited.  Also: some attempt to keep all/only variables required
 2171      by the top-level window in "areastruct", so later it will be
 2172      possible to implement multiple windows.  Also some bug fixes and
 2173      other cleanups to the code, particularly the window/object
 2174      resizing and centering.
 2176 149) v2.0b2 (beta)     1/5/00
 2177      Numerous minor bug fixes, including automatic loading of derived
 2178      fonts (previously handled incorrectly), proper drawing during
 2179      scrollbar drags, and many fixes to the schematic capture system.
 2180      Symbol-Schematic association redone so that the symbol and
 2181      schematic do not have to have the same name.  Because this code
 2182      is beta, this feature will not be backwardly compatible with
 2183      previous versions.
 2185 148) v2.0b1 (beta)     11/2/99
 2186      Changes to the Imakefile from Monte Bateman fix the reported
 2187      problems with both the RPM creation, and with the make process
 2188      not generating the proper subdirectories/installing files.
 2189      Changes to the RPM spec file go along with these fixes.
 2190      Support added for parameterized objects (full support for
 2191      string parameters, partial implementation of integer
 2192      parameters).
 2194 Version 2.0a (July 1998 to November 1999)
 2195 ----------------------------------------------------------------------
 2196 147) v2.0a11 (alpha)   11/19/99
 2197      Thanks to Mathieu Clar (mclar@ulg.ac.be) for finding that fix
 2198      #144 can be overridden if environment variable LANG is set
 2199      (e.g., to "french") and results in the same kind of program
 2200      crash.  Now xcircuit sets LANG to "POSIX" internally.
 2202 146) v2.0a11 (alpha)   10/26/99
 2203      After a number of partial fixes, and with the help of Raymond
 2204      Burns (rayburns@eskimo.com), I fixed the keyboard input focus
 2205      problem which plagued, especially, the WindowMaker window
 2206      manager.  Neverthess, this problem refuses to go away, and
 2207      this appears not yet to be the end of the story.
 2209 145) v2.0a10 (alpha)	6/25/99
 2210      Changed behavior of wire drawing so that mouse button 3 deletes
 2211      only the last segment of the line rather than deleting the
 2212      whole line.  Added key macro "." to place a dot object or draw
 2213      a dot at the cursor position.
 2215 144) v2.0a10 (alpha)    6/16/99
 2216      Fixed a problem under non-US UNIX versions in which LC_NUMERIC
 2217      is set to use a comma character as a numeric decimal point.
 2218      Thanks to Lars Pettersson <larsp@oso.chalmers.se> and Paulo
 2219      Mario dos Santos Dias de Moraes <paulo.mario@omninet.com.br>
 2220      for helping to track down the problem  (6/24/99---changed from
 2221      LC_NUMERIC to LC_ALL because there are apparently other things
 2222      which also screw up file loads if not set to US or equivalent).
 2224 143) v2.0a10 (alpha)    6/14/99
 2225      Added ISO-Latin5 (Turkish) on request from Recai Oktas at
 2226      Ondokuz Mayis University <roktas@samsun.omu.edu.tr>.  Rewrote
 2227      source to allow future inclusion of all ISO-LatinX encodings.
 2229 142) v2.0a10 (alpha)    5/25/99
 2230      Finally got around to instantiating edit mode for paths.
 2232 141) v2.0a10 (alpha)	5/24/99
 2233      In text edit modes, the backslash character brings up a
 2234      page containing the font encoding, allowing entry of non-
 2235      printing characters by simple point-and-click.  Use of
 2236      backslash escape sequences is deprecated.  Also, fixed a
 2237      bug which prevented compilation if MAKE_LGF was not defined
 2238      in the Imakefile;  thanks to Zhengdao Wang for the bug fix
 2239      <zhengdao@aphrodite.ee.umn.edu>.
 2241 140) v2.0a9 (alpha)	5/20/99
 2242      Finally fixed the "actions not found" bug, which seems to
 2243      be due to conflicting names of widget classes between Xaw
 2244      and Xw, and changed the popup menu behavior to place the
 2245      popup menu such that the cursor is initially on the title,
 2246      not on the top button.   Also, added a README.ISOLatin2 file
 2247      giving instructions on how to setup xcircuit for Latin2
 2248      encoded output.
 2250 139) v2.0a9 (alpha)	5/17/99
 2251      Changed menu button calling to the style adopted for
 2252      the abandoned attempt at using Motif;  this style calls
 2253      each menubutton by its Widget address rather than explicitly
 2254      referring to the path created by panes, managers, etc., which
 2255      can be toolkit-dependent.
 2257 138) v2.0a9 (alpha)	5/12/99
 2258      Added font vectors for ISO-Latin2 encoding.  Also, reparied
 2259      two fatal bugs (one involving the backslash character in
 2260      text, the other involving large user library files), and
 2261      reintroduced fix number 117 which somehow got lost.
 2263 137) v2.0a9 (alpha)	5/1/99
 2264      Font-drawing mechanism completely overhauled and replaced
 2265      with object-encoded fonts.  Added font encoding selection
 2266      and a better interface for choosing font family, shape,
 2267      and encoding.  Added PostScript output for generating
 2268      ISOLatin1 encodings of standard PostScript fonts.  Fonts
 2269      extended and heavily revised;  Courier, Helvetica, Times,
 2270      and Symbol all have unique font vectors.
 2272 136) v2.0a8 (alpha)     5/6/99
 2273      Zoltan Csahok <csahok@phase4.ujf-grenoble.fr> sent a bug fix
 2274      for the problem in which some objects would be made "hidden"
 2275      without being declared hidden in the library.
 2277 135) v2.0a8 (alpha)	4/14/99
 2278      Paul Ortyl <ortylp@key.net.pl> sent a fix to allow keyboard
 2279      entry of 8-bit characters (e.g., ISO-Latin1 or ISO-Latin2
 2280      encoding).  Text vectors still reflect Adobe Standard
 2281      encoding but hopefully this will be extended in the near
 2282      future.  Added "W" key macro for popping up Write-Xcircuit
 2283      dialog, at Paul's request.
 2285 134) v2.0a8 (alpha)	2/25/99
 2286      Possibly just fixed the problematic window manager hints
 2287      (WMHints) bug which has been plaguing the system.
 2289 133) v2.0a7 (alpha)     1/26/99
 2290      Fixed a bug which was introduced into version 2.0a7 which
 2291      prevents landscape-oriented files from being loaded back into
 2292      xcircuit.
 2294 132) v2.0a7 (alpha)	12/18/98
 2295      Fixed a problem wherein the FileList and Help widgets set
 2296      their own fonts directly rather than getting them from the
 2297      X Resource manager.  This causes XCircuit to crash when the
 2298      computer does not have that particular font preinstalled, as
 2299      noted by Niitsu Yoichiro <niitsu@amc.toshiba.co.jp>.
 2301 131) v2.0a7 (alpha)	11/20/98
 2302      Fixed a long-standing bug by making gridspace and snapspace
 2303      per-page variables, and permitting loading and saving these
 2304      values in the output file.  At the same time, made these
 2305      values type float for better resolution (preliminary to
 2306      making all internal point values type float).
 2308 130) v2.0a7 (alpha)	11/19/98
 2309      Added the "zoom-out" box suggested by ():
 2310      the current area of the drawing window is made to fit into
 2311      the area bounded by the box.  Added a button to the little
 2312      square at the intersection of the horizontal and vertical
 2313      scrollbars which acts like the "zoom view" function or "v"
 2314      key macro.
 2316 129) v2.0a7 (alpha)	11/17/98
 2317      Changed the behavior of the horizontal and vertical scrollbars
 2318      so that some smooth scrolling is possible (that which can be
 2319      accomplished by copying from the existing pixmap onto the
 2320      window, without redrawing the whole window).
 2322 128) v2.0a6 (alpha)	11/16/98
 2323      Made some fixes for Dale Scheetz <dwarf@polaris.net> to correct
 2324      some odd behavior under Linux:  The help page has been shortened
 2325      by 30 pixels to clear the Windows-95-like menu bar in fvwm95, and
 2326      the "done" button has been moved to the top of the help window.
 2327      Also, reduced argv[0] (the command from the command line) to its
 2328      root before comparing to "xschema" and loading Xdefaults so that
 2329      the program isn't confused by an appended pathname.
 2331 127) v2.0a6 (alpha)	11/12/98
 2332      Added code suggested by Alireza Moini <moini@eleceng.adelaide.edu.au>
 2333      to use environment variable "XCIRCUIT_LIB_DIR" for searching for
 2334      libraries before trying the hard-coded BUILTINS_DIR as a last
 2335      resort.
 2337 126) v2.0a6 (alpha)	10/4/98
 2338      Cleaned up the code a little;  moved most of the menu button
 2339      callbacks into a single file "menucalls.c", moved the file
 2340      list widget code into "filelist.c", and moved the help window
 2341      code into "help.c".
 2343 125) v2.0a6 (alpha)	10/4/98
 2344      Fixed a long-standing problem with the simple help window in
 2345      which it could not be repositioned.  In addition, I prevented
 2346      the window from exceeding the computer screen boundary; when
 2347      it does, the help window is truncated but can be "scrolled"
 2348      in a simple sense by clicking the mouse in the help text
 2349      window.
 2351 124) v2.0a5 (alpha)	9/27/98
 2352      Fixed a problem apparently due to the above pixmap icon code
 2353      which caused window managers to lose input focus for the whole
 2354      xcircuit window.  This appears to be fixed at least for "i386"
 2355      Linux systems.
 2357 123) v2.0a4 (alpha)	9/1/98
 2358      Upon urging of Michael Le, I generated a built-in pixmap icon. 
 2359      Also fixed what was apparently a long-standing bug in resizearea().
 2361 122) v2.0a3 (alpha)	8/23/98
 2362      Fixed a bug pointed out by Geert Jordaens which limited library
 2363      object names to 20 characters on file input.  Added flip-invariant
 2364      text.  Added pad space to pin labels.  Began preliminary work on
 2365      support for parameterized objects (beginning with some example
 2366      code and a postscript prolog).  Added missing definitions for
 2367      quarter and half space to xcircps2.pro.  Changed library files
 2368      to take advantage of flip invariant text.
 2370 121) v2.0a2 (alpha)     8/11/98
 2371      More "load file" fixing:  Modified the file loading routine so that
 2372      library files can be loaded with "Read Xcircuit PS"; i.e., they are
 2373      read like normal postscript files, and so can be read on the command
 2374      line.  Only restriction is that they go into the user library, as
 2375      they would if read as part of a regular xcircuit postscript file.
 2377 120) v2.0a2 (alpha)	8/10/98
 2378      Fixed three LGF-related errors:  1) LGF files were imported whether
 2379      "read" or "import" was selected, 2) labels needed to set property
 2380      "pin", and 3) one of the connections in the definition for "TO"
 2381      in lgf.lps needed to be moved.
 2383 119) v2.0a1 (alpha)	7/17/98
 2384      Fixed some errors in setting filename and object name when loading
 2385      or attempting to load files.  Fixed netlist error for connecting
 2386      multiple instances of the same label on a page.  Got rid of
 2387      string-sharing behavior for labels and malloc'd each copy instead.
 2389 118) v2.0a0 (alpha)	7/10/98
 2390      Replaced Xcircuit version 1.7 with version 2.0, schematic capture
 2391      system included.  Instantiating better management for version
 2392      numbers, starting right here!
 2394 Version 1.6 (January 1998 to May 1998)
 2395 ----------------------------------------------------------------------
 2396 May 1998
 2398 117) A few bugfixes and additions courtesy of Jo"rg Wunsch, including
 2399      the addition of handling WM_DELETE_WINDOW client messages to
 2400      allow the program to be closed by window manager controls.
 2402 116) Bug fixes from Paul Slootman for the 64-bit Alpha platform.
 2404 115) David DiGiacomo pointed out that the problem with the "make"
 2405      halting under Solaris is the indeterminate exit status returned
 2406      by the menudep program.  This has been fixed.
 2408 April 1998
 2410 114) Backspace can no longer be typed from the keyboard; instead,
 2411      the keyboard Backspace acts like Delete, and a Backspace
 2412      character can be inserted from the "Text" menu.
 2414 March 1998
 2416 113) Fixed a bug found by Cliff Koch <koch@cig.mot.com> in which
 2417      xcircuit did not check if an object name consists entirely of
 2418      numerals, which screws up the PostScript interpreter, which
 2419      tries to treat it as an integer.
 2420 112) Fixed a bug found by Dale Scheetz <dwarf@polaris.net> in which
 2421      a divide by zero would occur if a directory list was longer than
 2422      the pixel height of the file read window.
 2423 111) Fixed the colormap problem by figuring out how to get XCircuit
 2424      to gracefully install its own colormap on startup if the default
 2425      map is full.
 2427 February 1998
 2429 110) Cleaned up the last typecasting problems in both the toplevel
 2430      directory and Xw;  now should compile cleanly on all platforms
 2431      without specifically setting CCOPTIONS and CDEBUGFLAGS in the
 2432      Imakefile.
 2433 109) Changed the file loading routine so that Xcircuit automatically
 2434      figures out whether the file is a PostScript or LGF file, so  
 2435      that there are no longer two separate "load" commands in the
 2436      File menu.
 2437 108) Added a number of "diglog" gates to the lgf.lps library;  fixed
 2438      a bug reported by Jean-Luc Margot in which Imakefile refuses
 2439      to create the lib directory.
 2440 107) Fixed more problems with the inch/cm conversion, bugs reported
 2441      by Uwe Steinmann.  Made all displays report in cm when in cm
 2442      gridstyle mode.  Also made the full page switch from letter
 2443      size to A4 size when switching between inch and cm grids.
 2445 January 1998
 2447 106) Cleaned up typecasting problems which produced compile-time
 2448     warnings.  Added "integral" sign to the alphabet vectors and
 2449     revised the signal.lps library to include it.
 2450 105) Fixed longstanding bug in which the library (M)ove command would
 2451     overwrite an object with another.
 2452 104) Fixed another bug found by Monte Bateman in which the system
 2453     crashed when one tried to delete an object which had a dependency
 2454     somewhere.
 2455 103) Fixed a bug found by Monte Bateman which was that the alternate
 2456     color scheme flag did not toggle if the alternate color set was
 2457     chosen from the .xcircuitrc file, and in which the catalog objects
 2458     did not invert color and so became black-on-black or white-on-white.
 2459     All catalog objects now have color DEFAULTCOLOR instead of color
 2460     FOREGROUND, which makes more sense anyway.
 2462 Version 1.5 (May 1997 to December 1997)
 2463 ----------------------------------------------------------------------
 2465 December 1997
 2467 102) Added a copyright "artistic license".  Changed filename
 2468     of distribution tarfile to contain the version number
 2469     (xcircuit-6.1.tar.gz).  Began posting xcircuit to
 2470     sunsite.unc.edu.
 2472 November 1997
 2474 101) Fixed a bug found by Mark Cohen in which xcircuit loses track of
 2475     the drawing area-to-window coordinate transformation whenever the
 2476     window is resized.
 2478 October 1997
 2480 100) Fixed a long-standing problem with rhomboid-edit style for
 2481     polygons.  The edit points can no longer spontaneously change
 2482     during editing; they are fixed when the editing begins.  Added
 2483     a "Rhomboid-A" style, which is similar to Manhattan style.
 2484 99) Used a global variable to keep track of which element is being
 2485     edited so that it is unnecessary to swap elements to the end of
 2486     the list in order to edit them.
 2487 98) Fixed "bug" to make RHOMBOID edit like NORMAL edit when there are
 2488     only 2 points in the line (otherwise the second point gets dragged
 2489     along with the first).
 2490 97) Added capability to "hide" objects if the name of the object ends
 2491     with an ampersand ('&').
 2492 96) Added override of default colors and addition of new colors to the
 2493     .xcircuitrc file definition.
 2494 95) Changed all color entries from type "short" to type "int" to allow
 2495     xcircuit to run on 16- and 24-bit TrueColor visuals.
 2497 August 1997
 2499 94) Added "setmiterlimit" command to xcircps.pro to supress odd glitches
 2500     in some renderers (gs and certain printers) when drawing paths.  Do
 2501     these devices not have the (stated) default value of 10?
 2502 93) Finished adding color.  Added "scb" and "sce" (select-color-begin
 2503     and -end) to PS profile.  "Opaque-stipple" style no longer selects
 2504     "setgray" in postscript;  gray is selected by choosing the color
 2505     gray.  Added "Inherited" color to list & based color scheme on the
 2506     idea of "color inheritence".
 2507 92) Began adding color; separated definitions for color and stipple
 2508     patterns, and set default color scheme to black-on-white.  Added
 2509     stippled and colored rectangles to the Xw MenuBtn options for
 2510     menu buttons.
 2512 July 1997:
 2514 91) Added path horizontal and vertical flipping;  fixed a long-standing
 2515     bug to let user cancel a "make object" command during the object
 2516     name popup prompt.
 2517 90) Stopped linking the filename to the page (object) name.
 2518 89) Enabled creation of paths through the use of the "join" function,
 2519     and the ability to deconstruct the path into its constituent parts
 2520     with the "unjoin" (keystroke "J") function.
 2521 88) Implemented paths (currently no editing capability).
 2522 87) Redesigned the edit and element creation modes to be consistent
 2523     between polygons, arcs, and splines.  Arcs and splines can be
 2524     edited when created by using mouse button 1 to cycle between
 2525     control points.
 2526 86) Finished implementation of the revised "attach" command, including
 2527     attachment to ellipses and to the chord on a closed arc.
 2528 85) Finished implementation of ellipses.
 2529 84) Implemented a dual color scheme which is switchable from the menu;
 2530     no longer need XCircuit.ad.alt.  This is preliminary to adding full
 2531     color.
 2534 May 1997:
 2536 83) Preliminary implementation of ellipses.  On the top level, ellipses
 2537     are constrained to the x-y axes, but can be rotated as part of an
 2538     object.
 2539 82) Changed the "attach" command to operate on *all* elements, so,
 2540     e.g., a polygon end can be forcibly attached to a circle perimeter,
 2541     and so forth.  Needs a little refining, plus effects should be
 2542     duplicated for edit mode in "trackpoly", "trackarc", and
 2543     "trackspline".
 2544 81) Finished implementing rotate and flip for all element types.
 2545 80) Implemented optional graphics double-buffering for very clean and
 2546     quick refreshing of graphics.
 2547 79) Changed lists of elements from separate list for each element to
 2548     one list of type (genericptr *), which is re-typecast to each
 2549     element type.  Makes a number of things much cleaner
 2550 78) Got rid of type WIRE altogether; only has polygons.  No more "J"
 2551     command for unjoin, but "j" joins polygons together and the
 2552     algorithm is much cleaner than before and shouldn't be error-prone.
 2553 77) Gave arcs a line-segment representation, thus fixing the problem
 2554     of filled arcs and paving the way for the "path" aggregate element.
 2556 Version 1.4 (August 1995 to March 1997)
 2557 ----------------------------------------------------------------------
 2559 March 1997:
 2561 76) Made the scaling slightly more restrictive, to prevent xcircuit
 2562     from exceeding bounds of type short int either in the window or
 2563     in the page coordinate system.
 2564 75) Prevented drawing objects and labels outside of the window area
 2565     in order to speed up rendering at close scales.
 2566 74) Better precision for Bezier curve rendering and object attachment.
 2567 73) Changed rendering to a stacked transformation matrix model.
 2568     Speeds up rendering, makes rendering more accurate, and cuts
 2569     down on code complexity.
 2570 72) Added Fixed-Width (Courier) font, made proper widths for both
 2571     Times and Helvetica fonts;  implemented some different
 2572     characters for each font.
 2573 71) Allow change of font, style, and justification for one or more
 2574     selected labels.  Now deselects labels and arc/poly/spline after
 2575     a style change.
 2576 70) Menu entries for text font, style and arc/poly/spline style change
 2577     to reflect the status of the currently selected element.
 2578 69) Colormap allocation problem fixed by new CvtStringToPixel() routine
 2579     which searches colormap for best approximation to color on a failed
 2580     color allocation.
 2581 68) Wrote program to automatically generate the pathnames for button
 2582     and cascade widgets in the pulldown menus.
 2583 67) Added polygon flip capability.
 2585 February 1997:
 2587 66) Expanded file selection widget to select and load multiple files,
 2588     also to load (single or multiple) library .lps and analog .lgf files.
 2589 65) Added a file selection widget to the popup prompt when selecting
 2590     a file to read.
 2591 64) Changed structure "select" to "selection" in order to get around
 2592     problem compiling under Solaris.
 2594 January 1997:
 2596 63) Added an output page width and height per xcircuit page instead
 2597     of the default 8.5" x 11" page that existed previously.  Output
 2598     continues to be centered on the page.
 2599 62) Separated file names and page names.  These are linked by default,
 2600     but can be separated by supplying a different page name, or by
 2601     having a multi-page output.
 2603 December 1996:
 2605 61) Added inch/cm reporting for keyboard-adjusted snap spacing.
 2607 November 1996:
 2609 60) Fixed minor bugs in the DSC-PostScript: %%PageTrailer statement
 2610     is not needed, and %%Trailer *must* come after all page commands
 2611     including the "showpage".  Only the XCIRCsave restore statement
 2612     should be between %%Trailer and %%EOF.
 2613 59) Output scale changed to default of 1.0, with the arbitrary
 2614     pixel-to-PostScript-units constants bansished to the
 2615     PostScript prologue.
 2616 58) Changed grid and snap spacing routines to display inches/cm
 2617     instead of pixel coordinates.  Pixel coordinates are now
 2618     entirely hidden from the user, who only sees things in
 2619     inches or centimeters (with a default of inches, reported
 2620     in fractions).
 2621 57) Position display now gives length of simple wires in addition
 2622     to the cursor position.
 2623 56) Modified routine to print coordinates in fractional inches,
 2624     to be able to generate a fraction from an arbitrary float.
 2626 October 1996:
 2628 55) Added code to prevent infinite recursion by attempting
 2629     to place an object within itself.
 2630 54) Revised .lgf-file reading for an exact 1:1 correspondence
 2631     of lgf names to the xcircuit library object names; made
 2632     a library "lgf.lps" to cover the main analog gates, with
 2633     some stylistic changes to the look of some of the gates.
 2634 53) Added capability to move objects around inside the
 2635     libraries.
 2636 52) Added capability to make a copy of an object from
 2637     either library page into the user library.
 2638 51) Added capability to delete objects from the library.
 2640 September 1996:
 2642 50) Cleaned up the Xw code so that it will compile on
 2643     not-so-forgiving compilers;  also pruned out a
 2644     few things that are not used by Xcircuit.
 2645 49) Finally wrote the routine to compare objects and
 2646     avoid name conflicts.
 2647 48) Made PostScript output DSC-compliant, made file
 2648     reading more robust to errors in the input file.
 2649 47) Started implementing library manipulation routines
 2650     with library object rename; also added keystroke
 2651     "c" from library mode for "copy".
 2652 46) Fixed some problems with catalog organization of
 2653     objects.
 2654 45) Added multiple page loads and saves:  pages with
 2655     the same name will be grouped together into one
 2656     file.  EPS is not an option for multiple pages.
 2657 44) Made pages reallocatable, and added "Goto Page"
 2658     option in menu for accessing page numbers > 10.
 2659     New pages are automatically added to the pull-down
 2660     menu.  Page names are the same as the object name.
 2661 43) Changed format of file ".xcircuitrc" and added
 2662     ability to load libraries, override the default
 2663     library load, load extra fonts, and set certain
 2664     variables.
 2665 42) Added ability to load an arbitrary number of
 2666     user-defined fonts.  New fonts are automatically
 2667     added to the pull-down Font menu.
 2668 41) Changed embedded commands in text string to two bytes
 2669     each, allowing future extension of embedded commands.
 2670 40) Added handling of Ctrl-A and Ctrl-E for moving
 2671     to beginning and end of text, respectively
 2673 August 1996:
 2675 39) Added reading of ".xcircuitrc" in user's home
 2676     directory as an additional library file (file
 2677     takes same form as xcircuit or library files).
 2678 38) String text appears in message window immediately
 2679     upon starting or editing a label, and disappears
 2680     when done.
 2681 37) Fixed bugs in labels:  Rewrote routines so all
 2682     labels start with a font-change specifier;
 2683     removed "fontset" command from PostScript profile.
 2685 February 1996:
 2687 36) Differentiate between Writing and Overwriting
 2688     a file (to prevent disasters!) and warn user
 2689     when file is about to be overwritten.
 2690 35) Made all spline routines relative to SPLINESEGS
 2691     and increased default SPLINESEGS to 20
 2693 January 1996:
 2695 34) Allow push and pop while an object or objects
 2696     are selected and being dragged.
 2697 33) Added Rhomboid box editing in addition to
 2698     Manhattan box edit.
 2699 32) Added arrow-attachment routine to align arrows
 2700     with an underlying wire/polygon/spline/arc while
 2701     dragging.
 2702 31) Changed selection mechanism (again) to a simple
 2703     cartesian measure of distance from a line to
 2704     the cursor position.
 2705 30) Added capability to flip, rotate, and snap-to 
 2706     while an object is selected and being dragged.
 2708 August 1995:
 2710 29) Added vertical flipping capability using macro "F".
 2711 28) Added extended character set capability;
 2712     both octal codes and LaTeX-like symbol names
 2713     can be entered at the text prompt after a
 2714     backslash.
 2715 27) Added lines to show spline control points and
 2716     arc center during creation and editing.
 2717 26) Moved to PostScript prologue version 1.5, for
 2718     which the order of parameters for polygon, arc,
 2719     and spline are rearranged and made similar to
 2720     each other.  Reading of v1.4 files is kept for
 2721     backward compatibility.
 2722 25) Added rudimentary opaque-fill style for polygons,
 2723     arcs, and splines.  "Vertical" alignment can only
 2724     be controlled on the object level, using the X
 2725     command (exchange).
 2726 24) Added "Manhattan Box Edit" style (default: ON)
 2727     such that right angles in polygons are maintained
 2728     during editing.
 2730 Version 1.3 (March 1995 to June 1995)
 2731 ----------------------------------------------------------------------
 2733 May/June 1995:
 2735 23) Added backspace character handling in text.
 2736 22) One-step keystroke for dotted/dashed/solid line.
 2737 21) Allowed "join wires" to join wires and polygons.
 2738 20) Allowed "styles" options to operate on wires
 2739     by automatically converting them to polygons.
 2740 19) Fixed bug in which Xw copy buffer overflowed
 2741     string in sprintf() [solution: restrict
 2742     "precision" of string thus: "%.149s"].
 2743 18) Added "edit (e)" command to menu.
 2744 17) Added capability to read Caltech tools' "analog"
 2745     .lgf format files.
 2747 March 1995:
 2749 16) Added feature to report non-printing characters
 2750     in a label, when editing.
 2751 15) Added Zoom Box function.
 2752 14) Changed copy behavior to allow multiple copies
 2753     when button1 is used, and a single copy when
 2754     button2 is used.
 2755 13) Fixed problems with pixel trash left behind by
 2756     text editing.
 2757 12) Beeps when it doesn't write file due to filename
 2758     problem.
 2759 11) Added countdown for multiple selections.
 2760 10) Added new cursor for edit mode.
 2761 9) Xcircuit *only* does auto delete/addition of the
 2762    extension if extension is ".ps".  All other
 2763    filename extensions are left alone.
 2764 8) Changed behavior so that request to load a file
 2765    which does not exist will change the current
 2766    file name, provided that current page is empty.
 2767 7) Changed library pages to be actual objects, made
 2768    routine "composelib" to arrange the library objects
 2769    based on height and width of each object, changed
 2770    names of objects to xcircuit labels.
 2771 6) Fixed numerous malloc() bugs.
 2772 5) Added function to import xcircuit files into the
 2773    current file as well as loading them into a page
 2774    with page reset.
 2775 4) Added ability to change coordinate grid and
 2776    report coordinates in inches (decimal and
 2777    fractional) and centimeters as well as the usual
 2778    pixel grid.
 2779 3) Added (simple) help screen
 2780 2) Added simple scrollbars on side and bottom, allowing
 2781    click-to-pan.  Added global variables to save current
 2782    GC state and foreground color.
 2783 1) Added 2 message widgets, one for name of file
 2784    to edit, one for coordinates, one for information
 2786 ----------------------------------------------------------------------