How to get current scale?

 
The screenshots function is documentated the following way
bool WindowScreenShot( string filename, int size_x, int size_y, int start_bar=-1, int chart_scale=-1, int chart_mode=-1)
but here I need to use the current scale of screenshoted window. So the question how to get it in the program this one of values between 0 and 5.
 
In help is explained:
chart_scale - Horizontal chart scale for screen shot. Can be in the range from 0 to 5. If no value or negative value has been set, the current chart scale will be used.



 

But realy it's only in help, when I set this parameter to -1 it makes 0 value scale and doesn't depend of the scale of window. What another thing do they mean saying the current chart scale I can't understand. Or may be the function doesn't work as it's documentated. Anyway I need this result that can't be forced using -1 here.

 
Fixed. Wait for next build.
Reason: