| SciTE Ru-Board Kernel Changes

Documentation FAQ Regular Expressions LUA SciTE Director SciTE and Scintilla Commands Ru-Board Pack SciTE-Ru Kernel Shell SciTE Helper History

# Text editor SciTE RU-Board 1.78 .64

All modifications of original SciTE editor has been developed by persons from Ru-Board community.
This document described all changes and extensions from original version of editor.
All modifications in source code marked by special tags to allow apply it to original separately.
You can examine updated editor with all of his expanded characteristics by downloading the package SciTE-Ru

List of modifications split in three parts to be more sense:

- Interface
- Extensions
- Bug fix

### Interface

##### new [find.fillout] (Authors: Frank Wunderlich, VladVRO)

New property find.fillout is to define how will be filled input field in find dialog on start:
0 (default) - if a selection exists and it hasn't got line breaks then fill field with the selection otherwise fill field with a word near cursor (as it was),
1 - fill field with selection, if there is no selection then leave field blank,
2 - never fill search field.

##### new [MoreRecentFiles] (Author: Daniel Cardenas)

Recent files list can be expanded up to 30 items by new property:
save.recent.max=30

##### [save.session.multibuffers.only] (Author: VladVRO)

New variable in properties files to deny of saving session on exit if opened one buffer only:
save.session.multibuffers.only=1

##### [session.close.buffers.onload] (Author: VladVRO)

New variable in properties files session.close.buffers.onload for define should opened files be closed or not on load session.
For example to define do not close opened files:
session.close.buffers.onload=0
by default all opened files should be closed on load session.

##### [ReadOnlyTabMarker] (Authors: Midas, VladVRO)

Added possibility to show Readonly status by additional symbols in tab name, which can be setup by property tabbar.readonly.marker, for example:
tabbar.readonly.marker= R/O

##### [HighlightCurrFolder] (Author: VladVRO)

Added a highlighting of current folding on fold margin.
New property for setup highlight color:
fold.highlight.colour=#0099FF
if color is not set then highlighting is off.

##### [TrueTextSelMargin] (Author: VladVRO)

Changed cursor image over left margin (line number, marker and fold margins).
Cursor is set as inverse arrow when we realy can to select text otherwise used default cursor.

##### [SubMenu] (Author: HSolo, Updated by: Dmitry Maslov)

User's commands in menu Tools separated from other commands now by line.
And you can insert separator between any new commands in menu Tools.
For example, command.separator.34.*=1 adding separator before command 34.
Added possibility of a set check before command item of the menu.
For example: command.checked.34.*=1.
Added possibility of creation submenu in Tools menu.
All submenu items located on top of menu and separated by line from other.
For define submenu you should set up name first:
command.submenu.name.2.*=Insert from Text
If it is part of another menu then you should setup parent's menu number:
command.submenu.parent.2.*=4
And next for all subitems of this menu you should setup parent's menu number:
command.parent.6.*=2
command.name.6.*=Date and Time
All menu items text can be localized same as other menu command by file locale.properties.

##### [ToolsMax] (Authors: Moon_aka_Sun, VladVRO)

Extended amount of line in Tools menu till 300.
For creation of the user commands in user.context.menu it is necessary to use the formula:
User command = 9000 + number of this command in menu Tools

##### updated [ExtendedContextMenu] (Author: Dmitry Maslov, VladVRO)

You can setup each context menu now by using new parameters in .properties file:
user.context.menu.* - editor context menu
user.tabcontext.menu.* - tabbar context menu
user.outputcontext.menu.* - output context menu
And you can create submenus there by using tags POPUPBEGIN and POPUPEND!
Format:
user.context.menu.*=\
Command name1|IDM_COMMAND1|\
Command name2|IDM_COMMAND2|...
you can add separator by leaving both fields empty:
user.context.menu.*=\
Command name1|IDM_COMMAND1|\
||\
Command name2|IDM_COMMAND2|...
If parameter absent or empty then context menu will standard.

##### updated [user.toolbar] (Author: Dmitry Maslov, VladVRO)

You can setup toolbar now by using new parameter user.toolbar.* in .properties file:
Format:
user.toolbar.*=\
Hint1|IDM_COMMAND1|icon number1|\
Hint2|IDM_COMMAND2|icon number2|...
you can add separator by leaving fields empty:
user.toolbar.*=\
Hint1|IDM_COMMAND1|icon number1|\
|||\
Hint2|IDM_COMMAND2|icon number2|...
If parameter absent or empty then toolbar will standard.
New property for setup user library with icons: user.toolbar.iconlib.*=$(SciteUserHome)\gnome.dll

##### new [ToolbarButtonPressed] (Authors: UR4LTZ, VladVRO)

Toolbar buttons can display status on/off now based on the current state of parameter that switched by the button.
For example state of such parameters as wrap, read.only, view.whitespace displayed now by status pressed/released of related buttons IDM_WRAP, IDM_READONLY, IDM_VIEWSPACE.

##### [FindResultListStyle] (Authors: VladVRO, Dmitry Maslov)

Internal search (Ctrl+Shift+F) result text looks more better now:
- file path in each line is minimized to the relative from search path.
- all tabs in result replaced by spaces, start spaces removed, double spaces replaced by single.
- searched string can be highlighted by setup new style parameter in properties:
style.errorlist.30=fore:#000000 ,bold
You can switch off this feature by setup new parameter in properties:
lexer.errorlist.findliststyle=0
And now you can highlight searched string in result of external search. You can setup format of title of the external search by two new properties lexer.errorlist.findtitle.begin and lexer.errorlist.findtitle.end.

##### [close.find.window] (Author: Dmitry Maslov)

New variable in properties files
find.replace.closefind=<number value>
Set to 0 to prevent the Find dialog from closing when "Find" pressed.

##### [find.bookmark.disable] (Author: dB6)

New variable in properties files
find.bookmark.disable=1
If 1, then pressing the button "Mark all" do not sets the bookmarks.

##### [NewFind-MarkerDeleteAll] (Author: Dmitry Maslov)

New variable in properties files
find.mark.delete=1
If 1, then pressing the button "Mark all" removed any earlier bookmarks.

##### [TabsMoving] (Authors: VladVRO, Dmitry Maslov)

You can move tabs now. In editor added two new commands IDM_MOVETABLEFT and IDM_MOVETABRIGHT for shift current tab left or right and added identical commands in menu Buffers.
And also you can move tab by mouse now.

##### [TabbarTitleMaxLength] (Author: VladVRO)

New variable in properties files
tabbar.title.maxlength=<number value>
set limit of tab text length (file name). If text length greater than setup value then text will cut off and finalized with "…"

##### [NewBufferPosition] (Author: VladVRO)

New variable in properties files
buffers.new.position=<number value>
0 - new tab should be opened at last position in buffers list (default), 1 - next the current tab, 2 - first in list.

##### [warning.couldnotopenfile.disable] (Author: mozers)

New variable in properties files
warning.couldnotopenfile.disable=1
1 - removes warning "Could not open file", which is shown at opening a nonexistent file. The new buffer with the set name will be silently created.

##### [ZorderSwitchingOnClose] (Author: VladVRO)

Modification variable in properties files
buffers.zorder.switching=1
if option is present then after closing buffer current buffer will be next in buffers stack.

##### [new_on_dbl_clk] (Author: Dmitry Maslov)

You can open new buffer now by double click on empty space on right of tabs (a-la FireFox).

##### [close_on_dbl_clk] (Author: Dmitry Maslov, Moon_aka_Sun, VladVRO)

You can close current buffer now by double click on tabs.

##### [SetBookmark] (Author: Midas)

You can set bookmark by single click on Bookmark's bar now.
And you can switch off this feature by setup new parameter in .properties:
margin.bookmark.by.single.click=0

##### [output.caret] (Author: VladVRO)

New variables in properties files
output.caret.fore
output.caret.line.back
output.caret.line.back.alpha
Sets caret style of the output window.

##### [NewIcons] (Author: VladVRO)

New icons for the files associated with SciTE and for sessions files.

##### [AbbrevRefactoring] (Author: VladVRO)

Using of char '|' identical for Insert Abbreviation (Ctrl+Shift+R) and for Expand Abbreviation (Ctrl+B).

##### [VarAbbrev] (Authors: mimir, VladVRO)

It is possible to add user variables into list of abbreviation (abbrev).
- %SEL% - selected text
- %CLP% - text from clipboard
- %[var_name]% - value of internal variable SciTE (for example , CurrentSelection, FileNameExt, SciteDefaultHome etc.)
- %GUID% - unique GUID of new object (suggested by codewarlock1101)
For example, add that string into abbrev file:
<a+=<a href="%CLP%" title="|">%SEL%</a>
Copy string "http://scite.net.ru/" to clipboard (Ctrl+C)
Type '<a+My Site' and select 'My Site'. Then pushing Ctrl+B - have got a completed construction:
<a href="http://scite.net.ru/" title="|">My Site</a>
and caret have position of first meeting of '|'.
The same action: Type 'My Site' and select 'My Site'. Then press Ctrl+Shift+R and to choose "<a+" from a drop-down list.
New variable in properties files
abbrev.preserve.selection=1
allows to insert selected text without using %SEL% variable.
In this case selected text is inserted instead of last char '|'.

##### [abbrev.always.update] (Author: mimir)

If there is only one abbreviation file in use, without
abbrev.always.update=1
it will be renewed after Scite restart only.

##### [AbbrevExpandIncremental] (Author: VladVRO)

New variable in properties files
abbrev.expand.incremental=1
Changing expanding method to incremental for expand abbreviation by Ctrl+B, in other words new method to expand abbreviation is taking one char first, then two and so on.

##### [AbbrevMaxLength] (Author: VladVRO)

New variable in properties files
abbrev.maximum.length=[value]
Set value of length limit for expand abbreviation by Ctrl+B, in other words it is the maximum length of text for comparing with abbreviations set

##### [import] (Author: mimir, VladVRO)

Changed rules for import file in properties files. In first case trying to load file with name as is, if file not found then adding extension ".properties" and repeat trying to open file.
It is possible to use import instruction in *.abbrev files.

##### [selection.hide.on.deactivate] (Author: mozers)

The parameter selection.hide.on.deactivate=0 allows to not hide selection from the text when window SciTE loses focus.

##### [scite.userhome] (Authors: gansA, mozers, VladVRO)

New variable in properties files
scite.userhome let you assign path to directory $SciteUserHome for user data saving. (SciTE.recent, SciTE.ses, SciTEUser.properties)
Possible to use in the path internal variables of SciTE, for instance:
scite.userhome=$(SciteDefaultHome)\home

##### [IncrementalSearch.AddHotkeys] (Author: Midas)

Add on "Incremental Search" (Ctrl+Alt+I) Hotkeys:
- Enter or F3 - Find Next
- Shift+Enter or Shift+F3 - Find Previous

##### [WarningMessage] (Author: VladVRO)

Now can to set up alert with warning message for each warning type:
warning.findwrapped.message=alert's text
warning.notfound.message=alert's text
warning.wrongfile.message=alert's text
warning.executeok.message=alert's text
warning.executeko.message=alert's text
warning.nootherbookmark.message=alert's text

##### [AutoComplete] (Author: mimir, VladVRO)

Autocomplete function (Ctrl+I, Ctrl+Space) takes variants of end of a word not only from appropriate ".api" a file (as in original SciTE), but also from the edited text.

##### [oem2ansi] (Author: gansA)

Parameter output.code.page.oem2ansi=1 turn on console output text encoding from OEM to ANSI.
It let to edit script in win1251 codepage and see it output in console in dos866 codepage without switching codepages.

##### [caret] (Author: mimir)

Added possibility to customize the width and the color of cursor for every lexer individually, i.e. like this:
caret.fore.$(file.patterns.cpp)=#FF0000
caret.width.$(file.patterns.cpp)=3
It is not convenient when there are different colors and backgrounds for different languages but there is only one color for cursor.

##### [BetterCalltips] (Author: chupakabra)

New variable in properties files
calltip.lexer.automatic
calltip.*.automatic
Setting this option to 0 disables automatic calltip popup display but leaves user with possibility to invoke calltip manually. The * form is used if there is no lexer specific setting.
calltip.lexer.show.per.page
calltip.*.show.per.page
This option specifies number of definitions displayed per page in calltip window (default 1). Use arrow buttons to switch to next/previous page. The * form is used if there is no lexer specific setting.
calltip.lexer.word.wrap
calltip.*.word.wrap
This option enables word wrapping of calltip lines. Specify maximum number of characters allowed per line. Specify 0 to disable this feature (default). The * form is used if there is no lexer specific setting.
Calltip horizontal position is adjusted to maximize amount of information displayed. This is useful when cursor is located closely to right window border for example.
New Scintilla commands to support several highlight regions inside calltip window (SCI_CALLTIPADDHLT, SCI_CALLTIPCLEARHLT, SCI_CALLTIPUPDATEHLT).

##### [TextSizeMax for Dialog] (Author: dB6)

Increased buffer size for dialog box text conversions up to 1024.

##### [ignore_overstrike_change] (Author: Dmitry Maslov)

New variable in properties files
change.overwrite.enable=0 includes a mode of ignoring of switching of a mode INS/OVR.
At 1 or absence of this parameter the mode by default operates.
It is possible to set this parameter through SCI_SETOVERTYPE
0 - insert mode (default)
1 - overstrike mode
2 - ignoring of switching of a mode
3 - no ignoring of switching of a mode (default)

### Extensions

##### new [IndicatorsFillAlpha] (Author: VladVRO)

Changed values range of parameter for setup filling alpha of indicators (marks) with style ROUNDBOX, that can be from 0 to 255 on Windows OS.
For access to parameter was made new property in editor API - editor.IndicAlpha[num].

##### [ForthImprovement] (Author: VladVRO)

Lexers Forth and Crontab was improved. There was implemented folding and some new keywords sets.
In the Forth lexer was fixed algorithm for finding the closing tag of string [ ].

##### [BatchLexerImprovement] (Author: VladVRO)

Lexer batch was greatly improved (used for processing of batch files *.bat, *.cmd, *.nt).
Processing of left parenthesis was fixed.
Parentheses is highlighted by style SCE_BAT_OPERATOR now and folding was made at them.
Three new styles were added:
- SCE_BAT_ENVIRONMENT for highlight environment variables like %variable%,
- SCE_BAT_EXPANSION for highlight environment variables like !variable!,
new property lexer.batch.enabledelayedexpansion=1 is setup this highlight on, by default it is off.
- SCE_BAT_CLABEL for highlight links to the labels like :name,
For more information look at Issue 96.

##### [LocalizationFromLua] (Author: VladVRO)

In SciTE Lua Scripting Extension added new command:
scite.GetTranslation(s, [retainIfNotFound]), it returns translation of the sentance s,
retainIfNotFound - (by default is true) should return the input value if translation was not found.
Translations are taken from the file locale.properties.

##### [OnFinalise] (Author: VladVRO)

Added new SciTE event in Lua API OnFinalise(). Event arises on exit from editor.

##### [ABAP] (Author: VladVRO)

Added new lexer for ABAP/4 language.

##### [EditorUnicodeMode] (Author: VladVRO)

Added new property editor.unicode.mode for editor unicode mode which has been assigned by editor and can be one from next states: IDM_ENCODING_DEFAULT, IDM_ENCODING_UCS2BE, IDM_ENCODING_UCS2LE, IDM_ENCODING_UTF8, IDM_ENCODING_UCOOKIE.

##### [macro] (Author: VladVRO)

Support of record and play macro using LUA.

##### [OnMenuCommand] (Author: VladVRO)

Added new SciTE event - OnMenuCommand (msg, source)
msg - function id (SCI_constant)
source - input parameter of editor's internal function MenuCommand.
It can be equal to IDM_SRCWIN (350) - editor's window, or IDM_RUNWIN (351) - output window, or something else where the focus is.

##### [OnSendEditor] (Author: VladVRO)

Added new event to SciTE - OnSendEditor (msg, wp, lp)
Parameters the same as SendEditor.
msg - function id (SCI_constant)
wp and lp - input parameters, wp - numeric, lp - string. According to function they can be used or not.
OnSendEditor called for command that available for macro recording only and for SCI_SETREADONLY.
Example of letter case changing macro:
function OnSendEditor (msg)
if msg == SCI_UPPERCASE then
ChangeCase("U")
elseif msg == SCI_LOWERCASE then
ChangeCase("L")
end
end

##### [OnClick] (Author: Dmitry Maslov)

Added new event to SciTE OnClick(). Event arises from a single click on the mouse left button in the editing pane or the output pane.
Receives the state of key modifiers (Shift, Ctrl, Alt):
function OnClick(shift, ctrl, alt)

##### [OnDoubleClick] (Author: mimir, Dmitry Maslov)

Event OnDoubleClick() is expanded, now it is returned to the state of key modifiers (Shift, Ctrl, Alt):
function OnDoubleClick(shift, ctrl, alt)

##### [OnKey] (Author: Dmitry Maslov)

Function OnKey is expanded, now in it the pressed symbol is passed also:
function OnKey(key, shift, ctrl, alt, char)

##### [OnMouseButtonUp] (Author: VladVRO)

Added new event to SciTE OnMouseButtonUp(). Event arises from a mouse button up in the editing pane or the output pane.
Receives the state of Ctrl:
function OnMouseButtonUp(ctrl)

##### [MouseClickHandled] (Author: VladVRO)

Added new message SCI_SETMOUSECAPTURE to the Scintilla for change mouse cuptured state.
This message let to inform the Scintilla that mouse click handled.
Example: SendEditor(SCI_SETMOUSECAPTURE, 0)
And this message will be sent if OnClick() or OnDoubleClick() returns true.

##### [Perform] (Author: VladVRO)

In SciTE Lua Scripting Extension added new command
scite.Perform(actionList) - execute commands SciTE Director Interface
with actionList - one or several commands separated by a symbol of a new line.

##### [ReloadStartupScript] (Author: VladVRO)

In SciTE Lua Scripting Extension added new command
scite.ReloadStartupScript() - this function initializes Lua startup script reloading.

##### [GetLexerLanguage] (Author: Dmitry Maslov)

Added Scitilla message allowing to receive a name current lexers:
Now editor.LexerLanguage - allows both to set lexer, and to receive current

##### new [GetWordChars] (Àâòîð: Dmitry Maslov, VladVRO)

Added Scitilla message allowing to receive a name current word chars:
Now editor.WordChars - allows both to set word chars, and to receive current

##### [GetAPIPath] (Author: dB6)

APIPath - new SciTE environment variable. Contains a meaning full path of the current api file.

##### [GetAbbrevPath] (Author: dB6)

AbbrevPath - new SciTE environment variable. Contains a meaning full path of the current abbrev file.

##### [BufferNumber] (Author: VladVRO)

BufferNumber - new SciTE environment variable. Contains number of the current buffer.

##### [AbbrevRefactoring] (Author: Dmitry Maslov)

In SciTE Lua Scripting Extension added new command
InsertAbbreviation(string)
where "string" - is a text, on a format similar to abbreviation, for example:
scite.InsertAbbreviation("<a href="|" title="">%SEL%</a>")

##### [ParametersDialogFromLua] (Author: VladVRO)

In SciTE Lua Scripting Extension added new command for show "Parameters" dialog (Shift+F8)
scite.ShowParametersDialog(text)
text - short comment for window.
Return false if the user has refused (has pressed a Cancel or Escape) differently true.
Sample:
function Dialog()
props["1"]=props["CurrentSelection"]
props["2"]=props["SciteDefaultHome"]
if scite.ShowParametersDialog("Please set params") then
print ("1="..props["1"].."\n2="..props["2"].."\n3="..props["3"].."\n4="..props["4"])
else
print ("Cancel")
end
end

##### [FileAttr in PROPS] (Author: Midas)

Now accessible from scripts additional file properties
FileAttr, FileTime, FileDate.

##### [CalltipBreaks] (Author: Mitchell Foral)

Long bubble helps can be carried on the next line (by adding symbol \n at appropriate line in api-file)

##### [Euphoria] (Author: M Duffy, Midas)

Add new lexer Euphoria

##### [C_Word] (Author: mimir)

Added 3 new classes for LexCpp's keywords (i.e. now you can set up to 4 additional vocabularies with different highlight)

##### [PropsKeysSets] (Author: VladVRO)

Added 4 classes for LexProps's keywords (i.e. now you can set up to 4 additional vocabularies with different highlight)
And words can contain symbol ~, meaning a random set of characters. For example block.start.~ or braces.~.style

##### [PropsKeywords] (Author: VladVRO)

Added colorizing for "import" and "if" keywords in properties file.

##### [GetApplicationProps] (Author: VladVRO)

New function SciTEBase::GetProps() (for developers) allows to get access to properties of the editor in any place of a code of the editor.

##### [Zoom] (Author: Dmitry Maslov)

Now OnSendEditor can trace event SCI_SETZOOM arising at change of the size of a font.

### Bug fix

##### new [Reloads if old time] (Author: UR4LTZ)

If the edited file has been replaced with the initial (earlier) version then SciTE did not noticed substitution, despite of setting load.on.activate=1

##### [ExtensionThreadFix] (Author: qvaclav)

Fixed incorrect cloning of running Lua script.

##### [PropsColouriseFix] (Author: VladVRO)

Fixed coloring of syntax in properties files for long lines (more then 1024 chars) and for lines with division of words.

##### [LuaLexerImprovement] (Author: VladVRO)

Changed lexer for language Lua.
Simbols ":" and "." processed as separator for object now. You can setup lexer keywords as string.sub or editor:append as before and you can setup object function or property as :GetText or .Cursor now.

##### [GoMessageImprovement] (Author: VladVRO)

Made the editor window focused after uses double-click in console on message with file name and line number.
For implementation used [OnMouseButtonUp] improvement.

##### [fix_invalid_codepage] (Author: Dmitry Maslov)

Bug fixed at which switching in the "Code Page Property" did not work if the props code.page has been set incorrectly. (details)

##### [English_KeyCode] (Author: Dmitry Maslov)

Bug fixed at which keyboard shortcut ceased to work after switching keyboard layout. (details)

##### [InputErr] (Author: mimir)

Bug fixed in deadlock of SciTE on using command.input.
If user forget to select text before running script it cause deadlock.

##### [SelectionErr] (Author: mimir)

Bug fixed in text output on command.input and $(CurrentSelection) in UTF-8 code page only.
It prevent from transfer Russian text into external script or program.

##### [StyleDefault] (Authors: VladVRO, Dmitry Maslov)

Are removed default values of symbols color (black) and a background (white), that allows to not set them obviously in files of adjustment in all styles for set of a corresponding background at export of a file.
If the style.*.32 do not raised characters and the background color, these parameters are collected from your Windows, i.e. equal system Window Text/Background.

##### [LowerUpperCase] (Author: Midas, VladVRO)

Correct working with national characters
- for Make Lower / Upper Case,
- for Search without match case,
- for Search with Regular expression

##### [FindInFiles] (Author: dB6)

Selected text inserted into FindInFiles dialog solely in the UTF-8, thus Russian letter turned out unreadable.

##### [find_in_files_no_empty] (Author: Dmitry Maslov)

"Find in Files" now is not started if into a input box "Find what:" have entered nothing. (Issue 52).

##### [FileReaderUnlimitedLen] (Author: VladVRO)

Removed the restriction on the length of lines in the internal Find in Files. Earlier in long lines only to find worked 1,001 characters, the rest ignored.

##### [AbbrevFixCaretPos] (Author: VladVRO)

Fixed positioning of caret in insert abbreviation action.
Bug was in case when abbreviation body has one simbol '|' and in action was not selection text.

##### [no_wornings] (Author: Dmitry Maslov)

Added compatibility with the compiler Visual C++ 6.0
Eliminated some of warnings in the compilation of Visual C++ 6.0
warning C4702: unreachable code

##### [SQLcase] (Author: mimir)

The word "case" added into LexSQL to start folding