diff --git a/doc/xschem_man/developer_info.html b/doc/xschem_man/developer_info.html
index bde10126..2aa1dc5e 100644
--- a/doc/xschem_man/developer_info.html
+++ b/doc/xschem_man/developer_info.html
@@ -1823,6 +1823,144 @@ C {verilog_timescale.sym} 1050 -100 0 0 {name=s1 timestep="1ns" precision="1ns"
+
SOME USEFUL SCRIPT EXAMPLES
+
+
+ The following examples show the xschem commands one by one. In general you should create small TCL procedures
+ to perform these tasks. This way you can optimize things, for example creating temporary variables holding the
+ output of the various xschem ... commands.
+
+
+
+
+
+ -
Instantiate a component and wire it up with specific nets on its terminals.
+
+
+ # Create a 5V Vvdd voltage source
+xschem instance vsource.sym 100 100 0 0 {name=Vvdd value=5}
+ |
+  |
+
+
+ # Attach labels, They will get the symbol pin labels
+xschem select instance vvdd
+xschem attach_labels
+
+ |
+  |
+
+
+ # Select labels, unselect vsource and change positive and negative terminal
+# labels to VCC and GND respectively
+# The first item in the selected_set list is the first vsource terminal
+# (the positive terminal), the second one is the negative terminal.
+# At the end unselect all
+xschem connected_nets
+xschem select instance Vvdd clear
+xschem setprop instance [lindex [xschem selected_set] 0] lab VCC
+xschem setprop instance [lindex [xschem selected_set] 1] lab GND
+xschem unselect_all
+
+ |
+  |
+
+
+
+ -
Disable a component in the schematic
+
+
+ # Add spice_ignore=true attribute
+# the component will be ignored in generated netlists.
+xschem setprop instance Vvdd spice_ignore true
+ |
+  |
+
+
+
+ -
Delete a component together with its attached nets
+
+
+ # select component, select attached nets and delete
+# this will also select wire segments if labels are attached to selected instance with wires.
+xschem select instance Vvdd
+xschem connected_nets
+ |
+  |
+
+
+ # Delete selection
+xschem delete
+ |
+  |
+
+
+
+ -
Delete dangling nets and labels
+
+
+ # If after some editing or deletions dangling nets are present
+# they can all be selected. Deletion may be done with a "xschem delete" command.
+xschem select_dangling_nets
+ |
+  |
+
+
+
+ -
Change attributes of a group of components
+
+
+ # From this situation we want to select all MOS elements with L=2
+# and modify L (gate length) to 3
+ |
+  |
+
+
+ # Do an exact search of elements with L=2
+xschem search exact 1 L 2
+# a more precise search to avoid selecting unwanted elements might be:
+# xschem search regex 1 propstring "L=2\[ \n\].*model=nfet"
+# the above command will do a regular expression search on the whole
+# instance property string (the special token propstring)
+foreach i [xschem selected_set] { xschem setprop instance $i L 3}
+xschem unselect_all
+ |
+  |
+
+
+
+
+ -
Copy a components with its wired terminals
+
+
+ # From this situation we want to copy Vvdd to a different location
+# and change the instance name, voltage value and its positive terminal net name
+ |
+  |
+
+
+ # select the desired instance
+xschem select instance Vvdd
+# select attached wires
+xschem connected_nets
+# Copy to clipboard
+xschem copy
+# Paste selection 150 x-axis units to the right
+xschem paste 150 0
+# First selected_set item is the voltage source (it was selected first)
+xschem setprop instance [lindex [xschem selected_set] 0] name Vvpp
+xschem setprop instance [lindex [xschem selected_set] 0] value 12
+# Following item is the net label attached to the first symbol pin
+xschem setprop instance [lindex [xschem selected_set] 1] lab VPP
+
+ |
+  |
+
+
+
+
+
+
diff --git a/doc/xschem_man/developer_info_08.png b/doc/xschem_man/developer_info_08.png
new file mode 100644
index 00000000..7d32b443
Binary files /dev/null and b/doc/xschem_man/developer_info_08.png differ
diff --git a/doc/xschem_man/developer_info_09.png b/doc/xschem_man/developer_info_09.png
new file mode 100644
index 00000000..025f5144
Binary files /dev/null and b/doc/xschem_man/developer_info_09.png differ
diff --git a/doc/xschem_man/developer_info_10.png b/doc/xschem_man/developer_info_10.png
new file mode 100644
index 00000000..7042bd6e
Binary files /dev/null and b/doc/xschem_man/developer_info_10.png differ
diff --git a/doc/xschem_man/developer_info_11.png b/doc/xschem_man/developer_info_11.png
new file mode 100644
index 00000000..3b2732e2
Binary files /dev/null and b/doc/xschem_man/developer_info_11.png differ
diff --git a/doc/xschem_man/developer_info_12.png b/doc/xschem_man/developer_info_12.png
new file mode 100644
index 00000000..dae9fcbc
Binary files /dev/null and b/doc/xschem_man/developer_info_12.png differ
diff --git a/doc/xschem_man/developer_info_13.png b/doc/xschem_man/developer_info_13.png
new file mode 100644
index 00000000..4ab4d65a
Binary files /dev/null and b/doc/xschem_man/developer_info_13.png differ
diff --git a/doc/xschem_man/developer_info_14.png b/doc/xschem_man/developer_info_14.png
new file mode 100644
index 00000000..730dbf97
Binary files /dev/null and b/doc/xschem_man/developer_info_14.png differ
diff --git a/doc/xschem_man/developer_info_15.png b/doc/xschem_man/developer_info_15.png
new file mode 100644
index 00000000..8734c66c
Binary files /dev/null and b/doc/xschem_man/developer_info_15.png differ
diff --git a/doc/xschem_man/developer_info_16.png b/doc/xschem_man/developer_info_16.png
new file mode 100644
index 00000000..0808e26f
Binary files /dev/null and b/doc/xschem_man/developer_info_16.png differ
diff --git a/doc/xschem_man/developer_info_17.png b/doc/xschem_man/developer_info_17.png
new file mode 100644
index 00000000..e252d168
Binary files /dev/null and b/doc/xschem_man/developer_info_17.png differ
diff --git a/doc/xschem_man/developer_info_18.png b/doc/xschem_man/developer_info_18.png
new file mode 100644
index 00000000..0d64f20e
Binary files /dev/null and b/doc/xschem_man/developer_info_18.png differ
diff --git a/src/xschem.tcl b/src/xschem.tcl
index e8d37277..a4f7a7b3 100644
--- a/src/xschem.tcl
+++ b/src/xschem.tcl
@@ -342,7 +342,7 @@ proc view_current_sim_output {} {
}
#### Scrollable frame
-proc scrollyview {container args} {
+proc sframeyview {container args} {
global ${container}_vpos ;# global to remember scrollbar position
set_ne ${container}_vpos 0
if {[lindex $args 0] eq {place}} {
@@ -366,7 +366,7 @@ proc scrollyview {container args} {
# scrollable frame constructor
proc sframe {container} {
frame $container.f
- scrollbar $container.vs -command "scrollyview $container" ;# scrollyview moveto commands
+ scrollbar $container.vs -command "sframeyview $container" ;# sframeyview moveto commands
frame $container.f.scrl
pack $container.f -expand yes -fill both -side left
pack $container.vs -expand yes -fill y
@@ -1226,13 +1226,13 @@ file manually.
wm geometry .sim "${simconf_default_geometry}"
}
- bind .sim.topf.f {scrollyview .sim.topf}
+ bind .sim.topf.f {sframeyview .sim.topf}
bind .sim {
set simconf_default_geometry [wm geometry .sim]
}
- bind .sim { scrollyview .sim.topf scroll -0.2}
- bind .sim { scrollyview .sim.topf scroll 0.2}
- scrollyview .sim.topf place
+ bind .sim { sframeyview .sim.topf scroll -0.2}
+ bind .sim { sframeyview .sim.topf scroll 0.2}
+ sframeyview .sim.topf place
set maxsize [expr {[winfo height ${scrollframe}] + [winfo height .sim.bottom]}]
wm maxsize .sim 9999 $maxsize
# tkwait window .sim