Commit Graph

754 Commits

Author SHA1 Message Date
Stefan Frederik f466ce5ad4 better menu text 2021-12-01 12:42:40 +01:00
Stefan Frederik d98c855135 remove calls to ngspice::resetdata in C code, done in ngspice annotator when reading a new file and in xinit.c when exiting the program. Some File menu item reordering 2021-12-01 00:35:52 +01:00
Stefan Frederik 6cf6c58841 add menu command to restore all colors to default, deleting "colors" config file 2021-11-30 00:38:02 +01:00
Stefan Frederik e2197844ca fix infowindow (wrong window path) 2021-11-29 19:14:24 +01:00
Stefan Frederik 40803e47c5 Add Dismiss button to infowindow 2021-11-29 18:41:13 +01:00
Stefan Frederik 053d06c0f6 use tclgetvar for XSCHEM_TMP_DIR 2021-11-29 18:26:52 +01:00
Stefan Frederik 1c18211894 use tclgetvar for XSCHEM_TMP_DIR 2021-11-29 18:26:20 +01:00
Stefan Frederik 0ebe36bc8f avoid quitting the program for some serious but non fatal errors, add some error reporting, some documentation updates (faq.html) 2021-11-29 17:29:09 +01:00
Stefan Frederik d4fb14a0bb store server socket descriptors so they can be closed at will 2021-11-29 14:56:34 +01:00
Stefan Frederik 887c546d00 more consistent naming for some xschem subcommands, added and updated "xschem help" command (still wip) 2021-11-29 14:37:39 +01:00
Stefan Frederik fe549c0f5c readable function pointer call syntax 2021-11-29 11:52:32 +01:00
Stefan Frederik d3ef2038ed "xschem change_colors" to "xschem build_colors" in tcl command language for consistency 2021-11-29 11:27:11 +01:00
Stefan Frederik 1963669c3f xschemrc update (undo_type) 2021-11-29 04:14:35 +01:00
Stefan Frederik 2442a3dfc0 runtime menu option to set undo stack on disk or in memory 2021-11-29 02:47:37 +01:00
Stefan Frederik 03f973e203 use undo function pointers 2021-11-28 14:35:55 +01:00
Stefan Frederik 88b00fd546 add undo function pointers 2021-11-28 13:29:13 +01:00
Stefan Frederik 01b3401e43 in memory undo now saves / restores all symbol definitions, so no re-link to instances operation is needed 2021-11-28 13:16:01 +01:00
Stefan Frederik 1cbfc16cd9 better simconf help text 2021-11-27 03:49:39 +01:00
Stefan Frederik 965d2f3ec1 Restore default (delete simrc file) button in simulation configuration dialog 2021-11-27 03:37:36 +01:00
Stefan Frederik 551bbcec0c Windows does not recognize XPending, fix typo for verilog_format`s port name: g instead of f 2021-11-26 13:16:52 +01:00
Stefan Frederik f9b6389942 cosmetic changes ([xschem get version] print format) 2021-11-25 19:26:43 +01:00
Stefan Frederik 39a27e856e fix pcb_current_protection_embed.sch with up to date embedded symbols (previous had very old symbols with errors), fix pmos.sym (make pin names and verilog_format string consistent). All other schematics with embedded symbols updated with current library symbol. Some code in place for saving/restoring symbols in in-memory undo. This code is not compiled so does not affect xschem operation at all. 2021-11-25 04:00:01 +01:00
Stefan Frederik f67ec47f82 added some comments, commented out xctx->prep_* = 0 in save_schematic() 2021-11-24 13:52:59 +01:00
Stefan Frederik 9d38cb3823 removed debug messages 2021-11-24 04:19:32 +01:00
Stefan Frederik e7aa7b9d04 fix netlisting errors on schematics with embedded symbols. When purging unused symbols schematic was re-linked with library symbols instead of embedded symbols, leading to errors if the symbols differ. Fixed popping schematic from undo stack instead of calling link_symbols_to_instances() 2021-11-24 03:47:04 +01:00
Stefan Frederik 364c2f1f3a moved functions containing X calls: now only callback.c, xinit.c and draw.c contain xorg-specific function calls. 2021-11-24 01:07:33 +01:00
Stefan Frederik e77b72df9c old_winpath[] removed from globals, put as static string into callback(), fix ngspice::annotate netlist_dir fetching. 2021-11-23 23:20:10 +01:00
Stefan Frederik 9f33230f44 removed unneeded tcl global "simulate_bg" 2021-11-23 17:16:21 +01:00
Stefan Frederik 78934d363f removed duplicate netlist_dir global var in C code, use tcl netlist_dir variable, some widgets now display on top of current schematic window instead of xschem`s master window (use [xschem get topwindow] instead of ".") 2021-11-23 17:02:36 +01:00
Stefan Frederik d03147dce1 more consistent naming convention for hash table functions 2021-11-23 15:03:51 +01:00
Stefan Frederik d6d3ab502c some comments in the code, avoid potential memory leak in netlisting code 2021-11-23 01:14:49 +01:00
Stefan Frederik 88d64136a6 fix remove_symbols() not first deleting instance .node[] fields on instances 2021-11-22 21:47:13 +01:00
Stefan Frederik 14e94eb615 remove_symbols() and remove_symbol(): some symbol fields were not correctly cleared when removing all symbols. Ensure inst[].name and sym[].name are not strdup`ed as NULLs 2021-11-22 12:42:33 +01:00
Stefan Frederik 4c17e2251e undriven net warning has higher priority over open net 2021-11-22 01:32:49 +01:00
Stefan Frederik 9bca5b3f5b fix descend_symbol regression due to previous commit 2021-11-22 00:42:53 +01:00
Stefan Frederik 1c37e7eeee when descending from a modified schematic with highlight nets and not saving schematic before descending, clear highlights to avoid inconsistent state when returning back. save() and save_schematic() have more decent return values 2021-11-22 00:26:49 +01:00
Stefan Frederik fddd3f84fb avoid force-saving changed schematic before doing netlist (use push/pop undo instead of load_schematic() to restore circuit after traversing hierarchy) 2021-11-21 23:04:48 +01:00
Stefan Frederik 7f9ee9fc2a add "xschem check_symbols" and "xschem reload_symbols" for future checking of symbols that are newer wrt to schematic. set mtime of newly created schematic (that does not exist on disk) to current time. Add verilog attributes to devices/pmos4.sym 2021-11-21 12:28:36 +01:00
Stefan Frederik 608912078f fix "untitled" window title setting 2021-11-21 02:08:27 +01:00
Stefan Frederik 4b228737f4 fix long standing typo in file selector right listbox (-selectmode browse) 2021-11-21 01:56:54 +01:00
Stefan Frederik 10114ec838 add missing braces in update recent file submenu, fix file selector improperly setting main window title, added logic/test_mos_verilog.sch depletion mode verilog example 2021-11-20 23:44:19 +01:00
Stefan Frederik e4f4c75e9a fix stat missing arg 2021-11-20 13:47:25 +01:00
Stefan Frederik a495ada2ed When saving a schematic issue a warning if disk file has been changed since opening 2021-11-20 13:33:40 +01:00
Stefan Frederik 9ceb25716e auditing of static in-function variables, remove unnecessary, add notes for allowed ones 2021-11-20 02:37:56 +01:00
Stefan Frederik 83746efbe9 some other static data eliminated from functions (edit symbol_property), in_memory undo structure moved into schematic context 2021-11-19 23:22:54 +01:00
Stefan Frederik 4cb0a12d64 resolve a race condition between Configure event delivery, window creation, and wm hints setting for icon 2021-11-18 03:06:22 +01:00
Stefan Frederik bbba3b9c02 check for max number of subwindows, better way to set icons for windows 2021-11-18 03:01:28 +01:00
Stefan Frederik d1a922643d Bunch of function static variables moved into xctx struct for safety 2021-11-18 01:55:01 +01:00
Stefan Frederik eecc81437c flat_netlist and only_probes moved into xctx struct 2021-11-17 23:12:17 +01:00
Stefan Frederik daf90b0645 fix icon pixmap on child schematic windows 2021-11-17 22:15:36 +01:00
Stefan Frederik dcae02e8c4 remove dbg messages 2021-11-17 17:56:32 +01:00
Stefan Frederik e27c5dc21a separate pack_widgets and set_bindings 2021-11-17 17:53:18 +01:00
Stefan Frederik 1ce2d71e95 add File menu to open new recent schematic windows 2021-11-17 16:02:29 +01:00
Stefan Frederik 043e83e18f fix correct drawing of new schematic window if schematic not found 2021-11-17 13:32:32 +01:00
Stefan Frederik 7fcda987c0 proc new_window add abs_sym_path so full path is resolved if necessary 2021-11-17 11:47:12 +01:00
Stefan Frederik 59fccdee14 proc new_window remove file normalize as it messes up symlinks 2021-11-17 11:34:58 +01:00
Stefan Frederik ed87f28b23 fix typo in proc edit_vi_prop 2021-11-17 11:08:25 +01:00
Stefan Frederik 2604db125a fix typo in proc edit_vi_prop 2021-11-17 11:01:44 +01:00
Stefan Frederik f7fa39a975 track_memory.awk: option to disable source line display 2021-11-17 04:06:36 +01:00
Stefan Frederik dfc8031786 add File menu to open another schematic window in same xschem process 2021-11-17 03:49:32 +01:00
Stefan Frederik 937261807b fix setting snap and grid values in statusbar 2021-11-17 01:30:37 +01:00
Stefan Frederik bd626427fd fix status bar info correctly swicthing when focusing multiple xschem child windows; multiple schematic window handling within one xschem instance is now working 2021-11-17 01:12:55 +01:00
Stefan Frederik ad05513838 some parameter checks in xschem commands, global var removal in simulation help window - No use for production yet 2021-11-16 22:28:10 +01:00
Stefan Frederik 290fc3c793 fix missing escaping of "[" and "]" in tcl command bound to simulate button. Thanks to Mayank Gupta for pointing out the issue 2021-11-14 11:49:12 +01:00
Stefan Frederik dfb4821ef8 2 more global window declarations removed 2021-11-10 14:11:27 +01:00
Stefan Frederik 59198f2dda removed a whole bunch of global UI-related variables and tcl/C redundancies 2021-11-10 13:43:08 +01:00
Stefan Frederik c3c1b39cb5 (2) full widget creation for xschem new windows, code cleanup, removed old stuff 2021-11-09 19:05:56 +01:00
Stefan Frederik c6a6d1b1dc Motion and Enter events regain focus even it toolbar is displayed and user pressed "Tab" to focus a button; toolbar button focus ordering matches display ordering 2021-11-08 16:27:07 +01:00
Stefan Schippers b1f7a7a277 update bindkey description ("\" fullscreen) 2021-11-07 18:41:30 +01:00
Stefan Frederik fce2c9a292 more consistent ctx menu label texts 2021-11-07 12:57:02 +01:00
Stefan Frederik 05b8447846 better copy/paste button images 2021-11-07 12:54:15 +01:00
Stefan Frederik b175050843 gif toolbar images now with transparent background 2021-11-07 12:07:13 +01:00
Stefan Frederik 9fd56b8f91 fix waves toolbar image 2021-11-07 02:24:33 +01:00
Stefan Frederik 1b8920f3f0 more comments in resources.tcl 2021-11-07 01:32:03 +01:00
Stefan Frederik bb8ccce4d1 comments in resources.tcl, license info 2021-11-07 01:26:31 +01:00
Stefan Frederik f96ff46afc better ctx menu font on old 8.4 tcl-tk 2021-11-07 01:12:04 +01:00
Stefan Frederik 9e10a67fd1 yet another 2 pngs converted to gifs 2021-11-07 01:04:14 +01:00
Stefan Frederik e3b440f237 toolbar image data converted to gif89a. since older tcl-tk dont support png. 2021-11-07 00:59:19 +01:00
Stefan Frederik b62f8b57f7 removed useless assignments xctx->m[xy]_save = m[xy] in contexts where its unnecessary 2021-11-06 03:34:14 +01:00
Stefan Frederik 7985e8d22c fix some positioning glithes in UI when placing text via bindkey or menu or context menu 2021-11-06 03:24:45 +01:00
Stefan Frederik 173450edde fix wrong toolbar "Push schematic" action 2021-11-06 02:09:32 +01:00
Stefan Frederik 7efc446dae Escape key (instead of Simulation menu entry, now removed) stops ongoing xschem internal simulator engine if running 2021-11-04 23:52:24 +01:00
Stefan Frederik 4908152d99 break.awk: chop trailing white space on lines 2021-11-04 23:31:15 +01:00
Stefan Frederik 8281c67aed fix some UI glitches (place text/symbol and aborting operation during move will now delete placed objects) 2021-11-04 15:08:54 +01:00
Stefan Frederik 7490c80a9c fix UI bug when placing text and immediately deleting it (did not delete) 2021-11-04 13:30:50 +01:00
Stefan Frederik 966ebdc26e fix deletion of ctxmenu if user keeps right button pressed and exits window, icons in ctxmenu 2021-11-04 12:57:41 +01:00
Stefan Frederik fdf198d71e remove commented toolbar items in list 2021-11-04 09:30:43 +01:00
Stefan Frederik f5f6b681e2 removed rarely used toolbar buttons, added Abort context menu command 2021-11-04 02:07:41 +01:00
Stefan Frederik aadc37c2a8 More consistent context menu texts 2021-11-04 01:50:18 +01:00
Stefan Frederik 6ab004ec4b More consistent context menu texts 2021-11-04 01:43:43 +01:00
Stefan Frederik b720423eb3 comment typos 2021-11-04 01:23:40 +01:00
Stefan Frederik e85559efec context menu added in drawing area (right mouse button) 2021-11-04 01:13:44 +01:00
Stefan Frederik 5482cd0c2a redesign search toolbar button 2021-11-03 17:16:57 +01:00
Stefan Frederik c74e7fdb40 redesign of some toolbar buttons 2021-11-03 17:10:13 +01:00
Stefan Frederik 4dcb2c61a1 redesign of some toolbar buttons 2021-11-03 17:02:52 +01:00
Stefan Frederik 3ec3add6c0 redundant code elimination in new_schematic(), fixed a memory leak in update_symbol() 2021-11-03 00:31:08 +01:00
Stefan Frederik 6dbd952910 code cleanup in new_schematic(), error checks to make new window creation safe and simpler (proc new_window what path filename) 2021-11-02 02:23:45 +01:00
Stefan Frederik afa8a2d2d7 simpler yet better hash function 2021-10-31 23:38:52 +01:00
Stefan Frederik c8f6b66fdd new string hash function 2021-10-31 22:34:31 +01:00
Stefan Frederik 52c508423e eliminated duplicated string hash functions 2021-10-31 13:35:06 +01:00
Stefan Frederik 1fa2486e44 remove dbg messages in propagate_logic() 2021-10-30 21:33:12 +02:00
Stefan Frederik ebf0f0cf95 fixed simulation engine, no more bidirectional devices allowed 2021-10-30 03:12:06 +02:00
Stefan Frederik 8dbe8b7771 simplified simdata struct 2021-10-28 10:36:23 +02:00
Stefan Frederik e7d28947c1 removed redundant "valid" member in simdata struct 2021-10-27 22:56:33 +02:00
Stefan Frederik 45a567a405 fix compiler warnings (unused return value check on some function calls, missing %s on non literal string printf args) 2021-10-27 10:12:16 +02:00
Stefan Frederik fe5d2efc59 fix false positive in double-free detection, reported by updated track_memory.awk; fix missing free on allocated string 2021-10-26 01:18:16 +02:00
Stefan Frederik 04e670b3cf fine tuning of previous commit 2021-10-26 00:04:13 +02:00
Stefan Frederik b81325ea00 code cleanup, comments, more globals in Xctx context structure 2021-10-25 17:05:43 +02:00
Stefan Frederik 19f8939347 scconfig test for dup2() availability 2021-10-25 01:53:00 +02:00
Stefan Frederik 3f9e255a90 added symbols xnor2_1.sym, xor3_1.sym, xor4_1.sym in xschem_library/xschem_simulator 2021-10-24 01:41:01 +02:00
Stefan Frederik 0070498eb4 avoid printing "**** end_element" in spice netlist if current instance is skipped (no format or spice_ignore set); spice_probe_vdiff.sym will print .save v(n1) v(n2) instead of .save v(n1,n2) since this is how ngspice saves nodes (no differential voltage is saved) 2021-10-21 00:00:54 +02:00
Stefan Frederik 6223698b0b eliminated usage of flatten_savenodes.awk in spice netlist generation as hierarchical node saving (from inside subcircuits) is now a working feature of ngspice. 2021-10-20 01:50:26 +02:00
Stefan Frederik 18e78a754c token prefix for LCC embedded schematics changed from $ to %. LCC schematics saved with embedded symbols should need to be edited (replace $ with %) 2021-10-17 22:31:07 +02:00
Stefan Frederik 95c0ad1572 better identify commented pieces of code 2021-10-17 22:05:55 +02:00
Stefan Frederik a2779fab3c misc fixes in gschemtoxschem.awk 2021-10-14 02:35:43 +02:00
Stefan Frederik 2f47dfaaab updated gschem conversions, add tutorial documentation about geda translation to xschem 2021-10-12 18:03:39 +02:00
Stefan Frederik 0791a99165 updated geda translation, some additional allowed syntax in parselabel.l 2021-10-12 15:03:23 +02:00
Stefan Frederik 41419350ac gschemtoxschem.awk: make backslash insertion in gsub commands portable across awk implementations 2021-10-12 11:53:13 +02:00
Stefan Frederik fa3be90aa3 added comments in gschemtoxschem.awk converter; recognize "clk" pintype pin direction; parselabel.l: do not complain on U? refdes labels. 2021-10-12 10:52:48 +02:00
Stefan Frederik 04eee411f3 better implementation of prevous commit 2021-10-10 00:44:01 +02:00
Stefan Frederik 86dcb4cafa Do the update (process pending X events) only if a filename is given on cmdline, to avoid losing an Expose event if no file given 2021-10-09 13:30:44 +02:00
Stefan Frederik 4f8120cd2d add "update" after binding creation in xinit.c, to avoid incomplete initialization of event binding if xschem called with non-existent file 2021-10-09 10:25:24 +02:00
Stefan Frederik 205bda387a Add File menu commands to open empty schematic or symbol in new window 2021-10-09 00:41:39 +02:00
Stefan Frederik 813f80e955 renamed --batch option to --detach as it is more appropriate. Short option -b remains unchanged 2021-10-05 22:24:38 +02:00
Stefan Frederik 945368db9c xschem simulation doc updates 2021-09-27 16:41:32 +02:00
Stefan Frederik e8e56aa025 mux simulation operator: set "X" instead of "Z" if select not "0" or "1" 2021-09-27 10:56:23 +02:00
Stefan Frederik 42de7dcf1f comments 2021-09-27 10:50:03 +02:00
Stefan Frederik 22715bf505 change mux behavior to avoid simulation deadlocks 2021-09-27 03:01:59 +02:00
Stefan Frederik 72b356df3c some simulation fixes in eval_logic_expr() 2021-09-27 02:47:23 +02:00
Stefan Frederik f00b27d97d interrupting xschem digital simulation with "Simulation->Forced stop tcl scripts" was leaving "tclstop" variable set, causing following simulation to produce erroneousr results. Any new sim resets the flag to 0. 2021-09-25 16:16:30 +02:00
Stefan Frederik fbe18fe279 some refactoring/cleanups in move.c 2021-09-24 10:20:23 +02:00
Stefan Frederik 3573fcdafb redraw / update all nodes that might change in copy/move operations if net_name=true 2021-09-24 00:39:56 +02:00
Stefan Frederik 6210f60232 fix erroneous removal of get_tok_size initialization to 0 in get_tok_value() (thanks to Joanne Low) 2021-09-23 21:06:14 +02:00
Stefan Frederik 2d054898f0 better remove rubber drawing garbage after copy/move 2021-09-23 11:47:02 +02:00
Stefan Frederik efef711d32 reverted last accidental change 2021-09-23 11:19:28 +02:00
Stefan Frederik 3ebb9566ec removed drawing redundancies in move/copy operations 2021-09-23 11:15:21 +02:00
Stefan Frederik 44f27ce79f removed drawing redundancies in move/copy operations 2021-09-23 11:13:56 +02:00
Stefan Frederik 5113b5727c fix garbage on screen when copying components that dinamically change their bbox after copy (example: net annotator ngspice_probe symbols, same fix as already done for move operation). 2021-09-22 23:33:50 +02:00
Stefan Frederik 08b5a3c87a fix tcleval(...) evaluation in spice netlist. it was disabled 2021-09-22 09:49:59 +02:00
Stefan Frederik 83c3814aa1 brace all remaining tcl "expr"essions for performance and security 2021-09-21 10:31:08 +02:00
Stefan Frederik 240cbfa935 do not call tcl_hook2() in "xschem get_tok" calls in xschem.tcl 2021-09-20 18:43:29 +02:00
Stefan Frederik f9ef05eabe execute tcleval(...) wrapped attributes in global tcl context, fix a bug (chopped newlines) in tclpropeval2 tcl proc 2021-09-20 12:08:24 +02:00
Stefan Frederik 46f5f9356a fix print_spice_element() for correct netlisting when tcleval(...) is used in some component attributes 2021-09-20 02:36:25 +02:00
Stefan Frederik 434e0f012b Any attribute embedded in a tcleval(....) construct will be passed by get_tok_value() down to tcl for evaluation. This generalizes what was done for the "schematic" attribute in 20210617 2021-09-20 00:55:33 +02:00
Stefan Frederik 090cc5052e added xschem X-probe to bespice (from Analog flavor) waveform viewer. Works with eval version too. 2021-09-19 00:21:20 +02:00
Stefan Frederik ccbd77b9d6 edit text label 2021-09-16 18:19:24 +02:00
Stefan Frederik 8e4a6250ac added spice waveform template configuration for Analog Flavor`s bespice wave (bspwave) 2021-09-16 18:07:12 +02:00
Stefan Frederik f574539e21 bump version to 3.0.0; prepare for 3.0.0 release 2021-09-11 07:53:11 +02:00
Stefan Frederik 113f25a19b commented empty assignments of xschem_libs and noprint_libs in xschemrc since by default they are empty anyway 2021-09-02 22:42:16 +02:00
Stefan Frederik 771123550e added "place=header" (in addition to "place=end" attribuite value) to print code block as a header in spice netlists 2021-09-02 10:24:30 +02:00