move procedure in different place (before MAIN in xschem.tcl)

This commit is contained in:
stefan schippers 2025-09-26 00:25:31 +02:00
parent 477b4bb37e
commit 4767e5925e
1 changed files with 8 additions and 8 deletions

View File

@ -10064,6 +10064,14 @@ proc setup_tcp_bespice {} {
return 1
}
## this proc must be called for any created entry widgets
proc entry_replace_selection {w} {
global text_replace_selection OS
if {$text_replace_selection && $OS != "Windows"} {
bind $w <<Paste>> {if {[%W selection present]} {%W delete sel.first sel.last}}
}
}
###
### MAIN PROGRAM
###
@ -10160,14 +10168,6 @@ if { [info exists has_x] && [info tclversion] >= 8.6 } {
}
}
## this proc must be called for any created entry widgets
proc entry_replace_selection {w} {
global text_replace_selection OS
if {$text_replace_selection && $OS != "Windows"} {
bind $w <<Paste>> {if {[%W selection present]} {%W delete sel.first sel.last}}
}
}
# focus the schematic window if mouse goes over it, even if a dialog box is displayed,
# without needing to click. This allows to move/zoom/pan the schematic while editing attributes.
set_ne autofocus_mainwindow 0