From ab9ba18e62a8f3fa988a7f3c11676ecc0a71f275 Mon Sep 17 00:00:00 2001 From: svkalinin Date: Tue, 22 Nov 2022 13:10:03 +0300 Subject: [PATCH] =?UTF-8?q?=D0=94=D0=BE=D0=B1=D0=B0=D0=B2=D0=BB=D0=B5?= =?UTF-8?q?=D0=BD=D0=BE=20=D0=BA=D0=BE=D0=BF=D0=B8=D1=80=D0=BE=D0=B2=D0=B0?= =?UTF-8?q?=D0=BD=D0=B8=D0=B5=20=D1=82=D0=B5=D0=BA=D1=83=D1=89=D0=B5=D0=B9?= =?UTF-8?q?=20=D1=81=D1=82=D1=80=D0=BE=D0=BA=D0=B8=20=D0=B2=20=D0=B1=D1=83?= =?UTF-8?q?=D1=84=D0=B5=D1=80=20=D0=BF=D0=BE=20Atl+Y?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- lib/editor.tcl | 20 +++++++++++++++----- projman.tcl | 2 +- 2 files changed, 16 insertions(+), 6 deletions(-) diff --git a/lib/editor.tcl b/lib/editor.tcl index 3bf1a58..702e66a 100644 --- a/lib/editor.tcl +++ b/lib/editor.tcl @@ -672,7 +672,7 @@ namespace eval Editor { } proc PressKey {k txt} { - # puts [Editor::Key $k] + # puts [Editor::Key $k ""] switch $k { apostrophe { QuotSelection $txt {'} @@ -719,7 +719,13 @@ namespace eval Editor { if {$key >= 79 && $key <= 91} {return "true"} if {$key == 63 || $key == 107 || $key == 108 || $key == 112} {return "true"} } - + proc TextCopy {txt} { + # $txt tag remove sel 1.0 end + $txt tag add sel {insert linestart} {insert lineend + 1char} + tk_textCopy $txt + $txt tag remove sel {insert linestart} {insert lineend + 1char} + return + } proc BindKeys {w txt fileType} { global cfgVariables # variable txt @@ -743,11 +749,15 @@ namespace eval Editor { bind $txt "Editor::SearchBrackets %W" bind $txt "catch {Editor::GoToFunction $txt}" bind $txt "catch {Editor::GoToFunction $txt}; break" - bind $txt "$txt delete {insert wordstart} {insert wordend}" - bind $txt "$txt delete {insert linestart} {insert lineend + 1char}" + bind $txt "$txt delete {insert wordstart} {insert wordend}" + bind $txt "$txt delete {insert wordstart} {insert wordend}" + bind $txt "$txt delete {insert linestart} {insert lineend + 1char}" + bind $txt "$txt delete {insert linestart} {insert lineend + 1char}" bind $txt "$txt delete {insert linestart} insert" bind $txt "$txt delete insert {insert lineend}" - bind $txt "Editor::SplitEditorH $w $fileType" + bind $txt "Editor::SplitEditorH $w $fileType" + bind $txt "Editor::SplitEditorH $w $fileType" + bind $txt "Editor::TextCopy $txt" bind $txt "Editor::GoToLineNumberDialog $txt" bind $txt "Editor::FindDialog $w" bind $txt "Editor::FindDialog $txt" diff --git a/projman.tcl b/projman.tcl index 9873d1e..1e86dc1 100755 --- a/projman.tcl +++ b/projman.tcl @@ -10,7 +10,7 @@ exec wish "$0" -- "$@" ###################################################### # Version: 2.0.0 # Release: alpha -# Build: 18112022164357 +# Build: 22112022130912 ###################################################### # определим текущую версию, релиз и т.д.