Небольшие правки в подсказках по переменным

This commit is contained in:
svkalinin 2022-11-03 09:57:39 +03:00
parent 58f8e59236
commit c379f6d70b

View File

@ -510,6 +510,10 @@ namespace eval Editor {
unset lpos
$txt tag remove lightSelected 1.0 end
if {$cfgVariables(variableHelper) eq "true"} {
if { [winfo exists .varhelper] } { destroy .varhelper }
}
switch $k {
Return {
regexp {^(\s*)} [$txt get [expr $lineNum - 1].0 [expr $lineNum - 1].end] -> spaceStart
@ -529,6 +533,15 @@ namespace eval Editor {
Right {
return
}
Shift {
return
}
Controll {
return
}
Meta {
return
}
}
# set lineStart [$txt index "$pos linestart"]
# puts "$pos $lineStart"
@ -546,10 +559,11 @@ namespace eval Editor {
set _ [split $ind "."]
set ind [lindex $_ 0].[expr [lindex $_ 1] + 1]
set word [$txt get $ind $pos]
Editor::VarHelper $box_x $box_y $txt $word
} else {
} else {
# set ind [$txt search -backwards -regexp {^} $pos {insert linestart}]
set word [$txt get {insert linestart} $pos]
}
if {$word ne ""} {
Editor::VarHelper $box_x $box_y $txt $word
}
}