Compare commits
2 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 723426b1d6 | |||
| c8547ec45b |
@@ -681,7 +681,7 @@ namespace eval Editor {
|
||||
bind $txt <Control-Cyrillic_em> "Editor::SelectionPaste $txt"
|
||||
bind $txt <Control-l> "SearchVariable $txt; break"
|
||||
bind $txt <Control-Cyrillic_de> "SearchVariable $txt; break"
|
||||
bind $txt <Control-i> "ImageBase64Encode $txt"
|
||||
bind $txt <Control-i> "ImageBase64Encode"
|
||||
bind $txt <Control-Cyrillic_sha> "ImageBase64Encode $txt"
|
||||
bind $txt <Control-bracketleft> "Editor::InsertTabular $txt"
|
||||
bind $txt <Control-bracketright> "Editor::DeleteTabular $txt"
|
||||
@@ -702,6 +702,7 @@ namespace eval Editor {
|
||||
bind $txt <Alt-odiaeresis> "$txt delete {insert wordstart} {insert wordend}"
|
||||
bind $txt <Alt-Cyrillic_tse> "$txt delete {insert wordstart} {insert wordend}"
|
||||
bind $txt <Alt-r> "$txt delete {insert linestart} {insert lineend + 1char}"
|
||||
bind $txt <Alt-Cyrillic_ka> "$txt delete {insert linestart} {insert lineend + 1char}"
|
||||
bind $txt <Alt-ecircumflex> "$txt delete {insert linestart} {insert lineend + 1char}"
|
||||
bind $txt <Alt-Cyrillic_er> "$txt delete {insert linestart} {insert lineend + 1char}"
|
||||
bind $txt <Alt-b> "$txt delete {insert linestart} insert"
|
||||
@@ -876,9 +877,15 @@ namespace eval Editor {
|
||||
for {set lineNumber 0} {$lineNumber <= [$txt count -lines 0.0 end]} {incr lineNumber} {
|
||||
set line [$txt get $lineNumber.0 $lineNumber.end]
|
||||
# Выбираем процедуры (функции, классы и т.д.)
|
||||
# DebugPuts "Editor::RedaStructure: file type $fileType"
|
||||
|
||||
if {[dict exists $lexers $fileType procRegexpCommand] != 0 } {
|
||||
# regexp -nocase -all -line -- {^\s*(?:(\w+)\s+)+(\w+)\s*\((.*?)\)\s*(?:;|\{)} $line match returns procName params
|
||||
# regexp -nocase -all -line -lineanchor -linestop -- {^\s*(?:(\w+)\s+)+(\w+)\s*\((.*?)(,|\))} $line match v1 v2 v3 v4
|
||||
if {[eval [dict get $lexers $fileType procRegexpCommand]]} {
|
||||
DebugPuts "Editor::RedaStructure: regexp = [dict get $lexers $fileType procRegexpCommand]"
|
||||
set procName_ [string trim $procName]
|
||||
DebugPuts "Editor::RedaStructure: find the proc $procName_"
|
||||
if {$treeItemName ne ""} {
|
||||
Tree::InsertItem $tree $treeItemName $procName_ "procedure" "$procName_ ($params)"
|
||||
}
|
||||
|
||||
@@ -210,5 +210,24 @@ namespace eval Highlight {} {
|
||||
ctext::addHighlightClass $txt compile_errors #ff5050 {error Error ERROR invalid undefined cannot}
|
||||
ctext::addHighlightClassForRegexp $txt url lightblue {\w+://\w.+\w+}
|
||||
}
|
||||
|
||||
proc C {txt} {
|
||||
global lexers
|
||||
ctext::addHighlightClassForRegexp $txt flags orange {-+[a-zA-Z\-_]+}
|
||||
ctext::addHighlightClassForRegexp $txt arrows orange {(->)|(-<)}
|
||||
ctext::addHighlightClass $txt stackControl #19a2a6 [dict get $lexers C commands]
|
||||
ctext::addHighlightClass $txt types #7187d5 {string int int16 int32 int64 float bool byte size_t void char uint32_t uint32}
|
||||
ctext::addHighlightClassWithOnlyCharStart $txt vars #4471ca "\&"
|
||||
ctext::addHighlightClassWithOnlyCharStart $txt vars #4471ca "\*"
|
||||
# ctext::addHighlightClassForRegexp $txt vars_extended #4471ca {\$\{[a-zA-Z0-9\_\-:\./\$\{\}]+\}}
|
||||
ctext::addHighlightClass $txt variable_funcs gold {var type struct}
|
||||
ctext::addHighlightClassForSpecialChars $txt brackets green {[]{}()}
|
||||
ctext::addHighlightClassForRegexp $txt paths lightblue {\.[a-zA-Z0-9\_\-]+}
|
||||
ctext::addHighlightClassForRegexp $txt comments #666666 {(//|/\*)[^\n\r]*}
|
||||
ctext::addHighlightClassForSpecialChars $txt qoute #b84a0c {"'`}
|
||||
ctext::addHighlightClass $txt bool #3e803b {nil false true NULL TRUE FALSE}
|
||||
ctext::addHighlightClassForRegexp $txt qoute #b84a0c {("|'|`).*?("|'|`)}
|
||||
ctext::addHighlightClassForRegexp $txt macros #f88ffb {#\w+}
|
||||
ctext::addHighlightClassForRegexp $txt include #68ceff {<[\w./_-]+?>}
|
||||
}
|
||||
proc H {txt} {Highlight::C $txt}
|
||||
}
|
||||
|
||||
@@ -1947,3 +1947,24 @@ image create photo settings_24x24 -data {
|
||||
3W5MPksIPgdckHTF1XAMeCrpRXAexPT6yYSddEj6eKSJJmk3IcFGqWby51AbSvpeqr+KPjcKC7GT
|
||||
hfgXbteIc85F7RUAAAAASUVORK5CYII=
|
||||
}
|
||||
image create photo c_16x12 -data {
|
||||
iVBORw0KGgoAAAANSUhEUgAAAAsAAAANCAYAAAB/9ZQ7AAAAAXNSR0IB2cksfwAAAARnQU1BAACx
|
||||
jwv8YQUAAAAgY0hSTQAAeiYAAICEAAD6AAAAgOgAAHUwAADqYAAAOpgAABdwnLpRPAAAAAZiS0dE
|
||||
APgAjwD7QQHXygAAAAlwSFlzAAALEwAACxMBAJqcGAAAAAd0SU1FB+oCBg8YOxzsqLgAAABWSURB
|
||||
VCjPY2AgATDCGFeLi/+jS2r39jJiKIYp1O7tZUDSjKGBCYdtyCbCbWTB5T6oiShOYyHWT7icgRPg
|
||||
VHy1uPg/eggRY/J/YsMZRR0jLlNweZI2AAAzbhnP2WkKCAAAAABJRU5ErkJggg==
|
||||
}
|
||||
image create photo h_16x12 -data {
|
||||
iVBORw0KGgoAAAANSUhEUgAAAAsAAAANCAYAAAB/9ZQ7AAAAAXNSR0IB2cksfwAAAARnQU1BAACx
|
||||
jwv8YQUAAAAgY0hSTQAAeiYAAICEAAD6AAAAgOgAAHUwAADqYAAAOpgAABdwnLpRPAAAAAZiS0dE
|
||||
AAAAAAAA+UO7fwAAAAlwSFlzAAALEwAACxMBAJqcGAAAAAd0SU1FB+oCBg8iNd79W8YAAABJSURB
|
||||
VCjPY2AgB1wtLv5/tbj4Pz41TKQYSJJiRmRnYFOg3dvLSLTJyIawYDEJWSGM+Z+BgYGRCY/zGOkX
|
||||
GkwMFID/UExIjDAAAEu2FECKwea9AAAAAElFTkSuQmCC
|
||||
}
|
||||
image create photo cpp_16x12 -data {
|
||||
iVBORw0KGgoAAAANSUhEUgAAAAsAAAANCAMAAABIK2QJAAAAAXNSR0IB2cksfwAAAARnQU1BAACx
|
||||
jwv8YQUAAAAgY0hSTQAAeiYAAICEAAD6AAAAgOgAAHUwAADqYAAAOpgAABdwnLpRPAAAAA9QTFRF
|
||||
AAAAzAAAAAAA////////6rs+vwAAAAF0Uk5TAEDm2GYAAAABYktHRACIBR1IAAAACXBIWXMAAAsT
|
||||
AAALEwEAmpwYAAAAB3RJTUUH6gIGDxU21/OqSAAAADVJREFUCNd9jUEOACAIw7D7/58VmNF4sAco
|
||||
CbCIm5FsBTwsd+kmgVQu87p3OLfg/9AJJPFhAjDkAJmwKBolAAAAAElFTkSuQmCC
|
||||
}
|
||||
|
||||
@@ -104,5 +104,27 @@ dict set lexers LUA procFindString {function\s*?PROCNAME}
|
||||
dict set lexers LUA procRegexpCommand {regexp -nocase -all -- {^(local|)\s*?(function)\s([a-zA-Z0-9\-_:]+?)\s+\((.+?)\)} $line match v1 keyWord procName params}
|
||||
dict set lexers LUA varRegexpCommand {regexp -nocase -all -- {^(\s*?)([a-zA-Z0-9\-_\.]+)\s+=\s+(.+?)(\s*$|--)} $line match indent varName varValue lineEnd}
|
||||
|
||||
#--------------------------------------------------
|
||||
# C
|
||||
dict set lexers C commentSymbol {//}
|
||||
dict set lexers C commentMultilineSymbolBegin {/*}
|
||||
dict set lexers C commentMultilineSymbolEnd {*/}
|
||||
dict set lexers C procFindString {^\s*(?:(\w+)\s+)+(PROCNAME)\s*\((.*?)(,|\))}
|
||||
dict set lexers C procRegexpCommand {regexp -nocase -all -line -- {^(?:(\w+)\s+)+(\w+)\s*\((.*?)(,|\))} $line match returns procName params v4}
|
||||
# dict set lexers C procRegexpCommand {regexp -nocase -all -- {\s*?func\s*?(\(\w+\s*?\**?\w+\)|)\s*?(\w+)\((.*?)\)\s+?([a-zA-Z0-9\{\}\[\]\(\)-_.]*?|)\s*?\{} $line match linkName procName params returns}
|
||||
# dict set lexers C varRegexpCommand {regexp -nocase -all -line -- {^\s*?var\s+([a-zA-Z0-9\-_$]+)\s+(.+?)(\s*$)} $line match varName varType lineEnd}
|
||||
dict set lexers C commands {auto break case const continue default do else enum extern for goto if inline int long register restrict return signed sizeof static struct switch typedef typeof typeof_unqual union unsigned void volatile while}
|
||||
|
||||
#--------------------------------------------------
|
||||
# H
|
||||
dict set lexers C commentSymbol {//}
|
||||
dict set lexers C commentMultilineSymbolBegin {/*}
|
||||
dict set lexers C commentMultilineSymbolEnd {*/}
|
||||
dict set lexers C procFindString {^\s*(?:(\w+)\s+)+(PROCNAME)\s*\((.*?)(,|\))}
|
||||
dict set lexers C procRegexpCommand {regexp -nocase -all -line -- {^(?:(\w+)\s+)+(\w+)\s*\((.*?)(,|\))} $line match returns procName params v4}
|
||||
# dict set lexers C procRegexpCommand {regexp -nocase -all -- {\s*?func\s*?(\(\w+\s*?\**?\w+\)|)\s*?(\w+)\((.*?)\)\s+?([a-zA-Z0-9\{\}\[\]\(\)-_.]*?|)\s*?\{} $line match linkName procName params returns}
|
||||
# dict set lexers C varRegexpCommand {regexp -nocase -all -line -- {^\s*?var\s+([a-zA-Z0-9\-_$]+)\s+(.+?)(\s*$)} $line match varName varType lineEnd}
|
||||
dict set lexers C commands {auto break case const continue default do else enum extern for goto if inline int long register restrict return signed sizeof static struct switch typedef typeof typeof_unqual union unsigned void volatile while}
|
||||
|
||||
# -------------------------------------------------
|
||||
dict set lexers ALL varDirectory {variables vars group_vars host_vars defaults}
|
||||
|
||||
@@ -10,7 +10,7 @@ exec wish8.6 "$0" -- "$@"
|
||||
######################################################
|
||||
# Version: 2.0.0
|
||||
# Release: beta3
|
||||
# Build: 06022026135717
|
||||
# Build: 06022026152138
|
||||
######################################################
|
||||
|
||||
# определим текущую версию, релиз и т.д.
|
||||
|
||||
@@ -70,6 +70,9 @@ fi
|
||||
%{_iconsdir}/hicolor/48x48/apps/projman.png
|
||||
|
||||
%changelog
|
||||
* Fri Feb 6 2026 svk <svk@nuk-svk.ru> 2.0.0-beta3
|
||||
- Откорректировал сборку рпм
|
||||
|
||||
* Fri Feb 6 2026 svk <svk@nuk-svk.ru> 2.0.0-beta3
|
||||
- Добавил сборку rpm. Исправил changelog-и
|
||||
|
||||
@@ -225,3 +228,4 @@ fi
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user