April 30, 2017 17:26
THIS IS A BETA VERSION OF THE SOFTWARE. EXPECT BUGS !!!
Backup your data files and entire AmiBroker folder first!
INSTALLATION INSTRUCTIONS
First you need to have full version of AmiBroker 6.20 installed. Then just run the BETA installer and follow the instructions.
Then run AmiBroker. You should see "AmiBroker 6.22.0" written in the About box.
See CHANGE LOG below for detailed list of changes. Note that only changes that affect end-user directly are listed here. Internal code changes/refactoring is usually not mentioned.
UPGRADE POLICY: This version is a free upgrade for users who purchased AmiBroker license after April 30, 2015.
6.22 FEATURE HIGHLIGHT:
This version is experimental because we are migrating 64-bit version to brand new compiler (VC++ 2017). Such migrations pretty often brings some compatibility risks therefore backup is highly recommended (although you can always go back by just installing previous version). We needed to migrate not only the program itself but many internal libraries taking care not to break backward compatibility.
Note that migration does NOT affect 32-bit version. It is still compiled with old compiler.
Why do we migrate to new compiler with 64-bit version?
Why do we stay with old compiler in 32-bit version?
Exact performance improvement is function dependent and hardware dependent. Many functions are faster by 30-50% but in some cases such as Min()/Max() functions as large as 8x speed up can be observed in 64-bit version.
6.21 FEATURE HIGHLIGHT:
This version features preliminary support for native chart GUI (buttons and
edits at the moment). Please be resonable with Gui* functions and be aware
of Windows limits.
As all controls in Windows (buttons, edit boxes, etc) are actual Window objects
they are subject to Windows limitation.
And there is a limit of 10000 windows PER PROCESS. So don't try to create thousands
of buttons (like a button for every bar of data) because
first you will see huge performance decrease and next you will hit the limit
and run into problems (crash)
https://blogs.msdn.microsoft.com/oldnewthing/20070718-00/?p=25963
Best practice is to keep the number under 100-200.
If you need more consider using low-level graphics instead.
Here is a sample formula that shows basic usage of Gui* functions:
GuiButton( "Custom button", 1, 10, 40, 100, 30, 7 );
GuiButton( "Dynamic "+Date(), 2, 120, 40, 150, 30, 7 );
GuiButton( "System button", 3, 320, 40, 100, 30, 7 );
GuiEdit( 5, 450, 40, 100, 20, 31 );
GuiSetColors( 1, 3, 2, colorRed, colorBlack, colorRed, colorWhite, colorBlue, colorYellow, colorRed, colorBlack, colorYellow );
GuiSetColors( 3, 3, 0 ); //
default (system) look
editText = GuiGetText( 5 );
Title = "Text entered: " + editText + "\nLast
event: " + GuiGetEvent( 0, 2 );
id = GuiGetEvent( 0, 0 );
event = GuiGetEvent( 0, 1 );
if( id == 3 && event
== 1 ) GuiSetText("Button
clicked",5);
CHANGE LOG
CHANGES FOR VERSION 6.22.0 (as compared to 6.21.0)
CHANGES FOR VERSION 6.21.0 (as compared to 6.20.1)
notifyflags - decides which events fire execution of your formula, it can
be any combination of values below
1 - clicked (button)
2 - setfocus (all)
4 - killfocus (all)
8 - hit enter/return key (edit)
16 - edit change (edit)
notifyflags - decides which events fire execution of your formula, it can
be any combination of values below
1 - clicked (button)
2 - setfocus (all)
4 - killfocus (all)
8 - hit enter/return key (edit)
16 - edit change (edit)
num parameter defines the index of notification in the queue. 0 is first received (or "oldest") since last execution.
Usually there is zero (when formula execution was not triggered by UI event)
or one event in the queue but
note that there can be MORE than one event notification in the queue if your
formula is slow to process. To retrieve them all use increasing "num" parameter
as long as GuiGetEvent does not return zero (in what =0, =1 mode) or empty
string (what=2).
// read all pending events
for( i = 0; id = GuiGetEvent( i ); i++ )
{
code = GuiGetEvent( i, 1 );
text = GuiGetEvent( i, 2 );
}
clrText, clrBack, clrBorder - define colors of control text (fgcolor), background
(bgcolor) and border (if border width is > 0 ) in "default" control
state (unselected)
selectfgcolor. -1 means colorDefault and if all colors are set to default
then control uses SYSTEM (Windows) look
clrSelText, clrSelBack, clrSelBorder - define colors in selected state
clrHoverText, clrHoverBack, clrHoverBorder - define colors in hover (mouse
over) state
clrDisText, clrDisBack, clrDisBorder - define colors in disabled state
Please note that currently only buttons support custom colors and custom
border
As for v6.21 Edit fields always use system look
NOTE2: mouse move refreshes come "as fast as possible". if your code is fast you can get butter smooth animation (even 50fps)
Example:Plot( C, "Price", colorDefault );
GfxCircle( GetCursorXPosition(1), GetCursorYPosition(1), 7 );
RequestMouseMoveRefresh();
HOW TO REPORT BUGS
If you experience any problem with this beta version please send detailed description of the problem (especially the steps needed to reproduce it) to support at amibroker.com