---
title: "MetaTrader 5 Build 1495: Improvements in MQL5 for working with custom graphics - Release Notes"
description: "Added the CopyTicksRange function. Added improved anti-aliasing functions to CCanvas class: CircleWu EllipseWu LineWu PolygonWu... - Release Notes"
image: "https://www.metatrader5.com/i/logo_metatrader5.png"
---

# MetaTrader 5 Build 1495: Improvements in MQL5 for working with custom graphics

## Added the CopyTicksRange function. Added improved anti-aliasing functions to CCanvas class: CircleWu EllipseWu LineWu PolygonWu PolylineWu TriangleWu

9 December 2016

### MQL5

1. Added the [CopyTicksRange](https://www.mql5.com/en/docs/series/copyticksrange) function.
2. Added improved anti-aliasing functions to CCanvas class:
3. Added description of the [graphical library](https://www.mql5.com/en/docs/standardlibrary/graphics) to the MQL5 Reference. The library allows to quickly create histograms, distributions and line graphs right on the price charts.
4. Added the identifiers of the state of system keys to the list of constants of [Client Terminal Properties](https://www.mql5.com/en/docs/constants/environment_state/terminalstatus). A call to TerminalInfoInteger(TERMINAL_KEYSTATE_XXX) returns the same state code of a key as the [GetKeyState()](https://msdn.microsoft.com/en-us/library/windows/desktop/ms646301(v=vs.85).aspx) function in MSDN.
5. Disabled the support for casting of string type to bool. To check strings, one needs to use explicit conditions. For example, in the new build, compilation of the following code will result in an error:

   ```
   string str; ... if(str)                        // will result in "Cannot convert type 'string' to 'bool'" compilation error (no error would appear in the previous versions)    Print("str is true");
   ```

    One should use an explicit condition:

   ```
   string str; ... //--- check if the string is initialized if(str!=NULL)    Print("str is true"); or //--- check if the string value is "true" if(StringCompare(str,"true",false))    Print("str is true"); or //--- check if the string is integer and is not equal to zero if((int)str!=0)    Print("str is true");
   ```

Fixed errors reported in crash logs.

**Earlier publications:**

- [MetaTrader 5 Web Platform: Two-factor authentication and password change](https://www.metatrader5.com/en/releasenotes/terminal/1396)
- [MetaTrader 5 Build 1485: Additional testing mode and graphics in the Standard Library](https://www.metatrader5.com/en/releasenotes/terminal/1392)
- [MetaTrader 5 iOS build 1425](https://www.metatrader5.com/en/releasenotes/iphone/1391)
- [MetaTrader 5 Build 1455: Libraries of mathematical functions in MQL5](https://www.metatrader5.com/en/releasenotes/terminal/1384)
- [MetaTrader 5 web platform: Code optimization and new interface features](https://www.metatrader5.com/en/releasenotes/terminal/1382)
