Commit Graph

22 Commits

Author SHA1 Message Date
R. Timothy Edwards 9ca81f8ea6 Modified the "tag" command to add an optional subcommand "add" or
"replace" as the 2nd argument.  This allows a simpler 'tag add
<command> <value>' than the existing awkward 'tag <command>
"[tag <command>]; <value>'.  Using "add" also helps avoid
mistakes like one that was in the code for a long time which
overwrites one of the helper window callbacks.  With this done,
added some additional callbacks to the "library manager" to
update when a new file is created by "select save" or "writeall".
Also added "Refresh" buttons to these windows, just in case.
Implemented a zoom function on the mouse scroll wheel when the
Control key is pressed.  This is a stop-gap for a problem with
overriding button bindings that re-establish themselves when the
tool (box, wiring, etc.) changes.  That needs to have a more
comprehensive solution (such as tool-specific bindings).
2025-10-08 17:11:27 -04:00
Tim Edwards e2c3eb3e20 Corrected the previous commit, which did not fix the problem that
it claimed to fix, but caused an incorrect DRC maxwidth check
instead.  The problem appears to be correctly resolved now.
Also:  Tracked down a recently-introduced minor issue in which
the interactive DRC stops running after issuing "drc check" and
does not resume until another key or mouse even occurs.  This
turned out to be caused by the work on the "logcommands" command,
which should have used "*bypass" before "logcommands suspend"
and "logcommands resume", since the "*bypass" indicates that
the command has no impact on layout and should not interrupt
the DRC checker.
2024-10-01 21:14:12 -04:00
Tim Edwards 3e0ad4ff58 Finally got around to restoring the behavior of the toolbar with
respect to using the 3rd mouse button to hide a layer, and
indicating the layer is hidden by blanking the icon (which works
better with the new scrollable icon list, but got broken by the
same).  Also:  Added a previously missing behavior, which is to
correctly update the icon settings based on using the command
"see" and "see no" with layer aliases (e.g., "allm1").
2024-10-01 16:01:28 -04:00
Vasil Yordanov affd68aad9 EDIT: wrapper maketoolbar method refactored into a separate script, with changes to the toolbar. Reorder layers functionality added as well 2023-12-15 15:54:05 -05:00
Tim Edwards c8a2d06e08 Finally got around to fixing the "logcommands" command, which has
been broken ever since moving to the Tcl/Tk wrapped version.  Added
some new features that allow background commands from the window
handling (like pointer tracking) to be omitted from the log file
via a suspend/resume function.  Added a header file and a few
commands at the top of the log file that align the log file contents
with the screen and box state at the start of logging.  This makes
a log file which can be "played back" by sourcing it from the magic
console prompt.  Per request from Harald Pretl.
2023-06-28 21:31:24 -04:00
Tim Edwards f45f3c96e5 Updated version to go along with the merge of pull requests 175 and 176
(OpenBSD/NetBSD/DragonFly support), and a change to the wrapper to allow
manual override of the number of icon columns (because sometimes some
window managers are clueless about the correct window dimensions).
2022-08-22 12:20:59 -04:00
Tim Edwards e675decfc0 Cleaned up a bunch of stuff around "magicdnull", starting with not
linking it to Tk or X11 graphics.  Added new command "display" which
returns the display type, which is good for finding out if the
display is "NULL".  Added code to allow the wrapper to be defined
for NULL graphics with the Tk console, the main necessities of which
are to remove the "openwrapper" command, and to return immediately
from a number of tag callback functions.
2022-03-30 10:55:08 -04:00
Tim Edwards a5e0de031c Corrected the "font measure" line in the wrapper Tcl code from
revision 131, as a Tk default font size less than 10 will round the
scaling factor down to zero and result in bad things happening.
2021-04-06 22:04:53 -04:00
Tim Edwards 2e9c554f2c Revised the wrapper script to use the Tk command "font measure"
to get the pixel size of the default font, and scale the window
glyphs and scrollbars to match, so that the display is automatically
adjusted for screen resolution and does not require manual intervention
to correct for high resolution displays.
2021-02-20 13:24:02 -05:00
Tim Edwards 581ad6041b Added new command option "box remove" that removes the cursor box
from the layout window.  The main reason for this is to keep the
box out of the image when doing "plot svg".  The "plot" command was
also modified to always do a plot of the entire cell in the active
layout window if the box is not present.
2020-10-08 13:50:14 -04:00
Tim Edwards 53a488989f Moved the read-in of the readspice script from the wrapper to the
startup file, since the script is not (and should not be) wrapper-
dependent.
2020-05-28 12:40:28 -04:00
Tim Edwards 626a6355ae Added a Tcl scripted command "readspice" that can be used to read
SPICE subcircuit definitions from a netlist file and apply the port
order in the netlist to the port labels in the corresponding cell
or cells in the magic database.  Also:  Corrected an error in the
bloat-all code introduced in a recent commit that can cause a
segfault.
2020-05-28 11:46:57 -04:00
Tim Edwards 2af38a4191 Updates from running the fix-ending-whitespace script. 2020-05-23 17:13:14 -04:00
Tim Edwards 612251b2b0 Changed the PNG bitmaps to GIF, because PNG is not supported in
Tcl/Tk 8.5, which is still installed and considered current/stable
on a lot of systems.
2020-02-26 10:10:55 -05:00
Tim Edwards 6049b7e00e Further dealing with retinal displays: The scrollbars and related glyphs
now scale with Opts(scale), which is a zoom scalefactor (default 1), and
Opts(toolscale) sets an independent sizing for the toolbar icons, which is
multiplied by the Opts(scale) scalefactor.  Also:  Added GR_LIBS to the
link options for magicexec and magicdnull, to avoid compile-time problems
on some systems (thank you to Charlene of OpenBSD for the patch!).
2020-02-17 16:51:30 -05:00
Tim Edwards 2572421162 Added new option setting Opts(toolsize) that makes the toolbar icons
scale with the given size (default 16).  This can be put in the site.def
or .magicrc file as, e.g., "set Opts(toolsize) 32".  This is the first
part of an attempt to get everything to scale properly on ultra-high-
resolution monitors.
2020-02-17 15:13:54 -05:00
Tim Edwards 715843ca2a Changed the script drc.tcl into two routines for DRC load and save,
and merged the contents into drcmgr.tcl, with a new button in the
DRC manager for saving the DRC contents.  Loading is somewhat less
useful since the DRC error tiles are interactive.  The DRC manager
still has the issue that every checked edge becomes a separate
entry;  this is an artifact of the way the DRC checker works, but
it creates large numbers of error areas, many of which are redundant.
2020-02-17 10:25:45 -05:00
Tim Edwards ed8117784e Corrected three annoying errors: (1) Select net method had been
changed to ignore labels below the top level of hierarchy.  This
turned out to be a bad idea.  However, the original behavior was
problematic due to confusion over what part of the hierarchy the
labels were in.  The new behavior prefixes each label with the
cell hierarchy, eliminating both problems.  (2) Corrected the
problem where the attachment box for rendered labels is not
displayed if the label name is not in the viewing area.  (3)
Corrected the problem where redirection of input from the layout
window to the console window with the ":" command gets inadvertently
canceled;  this turned out to be due to a missing "*bypass" in
front of the command that finds the output scale to display the
pointer coordinates, and this was happening whenever the mouse was
moved while typing in a command.
2020-02-14 09:36:30 -05:00
Tim Edwards e1783a42a9 Added a "DRC manager" window option. This allows DRC errors to be
categorized by error type and scrolled through conveniently.  However,
it needs work dealing with finding the actual error bounds.  The
"DRC count" counts tiles, which is tile-plane-geometry-specific, and
"DRC listall why" fractures errors both over tiles and over the square
areas that the interactive DRC splits the layout into, for performance.
The DRC error plane needs to be changed to hold different types for
each error class, so that errors can be scanned by boundary instead of
by tile (work to be done).
2019-11-15 10:26:04 -05:00
Tim Edwards bb0af34441 Corrected an obscure error that causes the background of the layout
window to change after hiding a layer using the toolbar and then
refreshing the layout.  Fixed by saving and restoring the graphics
state around the routine that configures the toolbar image.  Also
added a check to CifPaintCurrent to guard against using an unassigned
ClientData record as a pointer (causes a crash), and added braces
around "expr" values in the Tcl wrapper, which reportedly results in
faster execution of the expression.
2018-10-23 08:44:04 -04:00
Tim Edwards 088fc759c4 Set of changes updating version 8.2 to the level of 8.1, since 8.2
development had been halted since it was first created back in April.
Version 8.2 is now the official development version, with the first
development push to create a Cairo graphics interface.
2017-08-01 22:14:42 -04:00
Tim Edwards 231a299b16 Initial commit at Tue Apr 25 08:41:48 EDT 2017 by tim on stravinsky 2017-04-25 08:41:48 -04:00