New in version 8.0.1


  • Fixed

    • BitmapMask copying constructor access invalid pointer when copying undestructable bitmaps.
    • BitmapMask clearing another bitmap in moving constructor.
    • BitmapMask copying assignment operator access invalid pointer when copying undestructable bitmaps.
    • Incorrect StrikeOut property convertion in VariantToFont() function.
    • Missing Type property storing and loading in GradientToVariant() and VariantToGradient() functions.
    • Incorrect Y component convertion to string in String ToString(const PointD &value) function.
    • Missing Type property exporting in form prototype header file in CPropertyGradient and CPropertyGradientState() property implementations.
    • Not quite correct double type conversion to source code in String AsSourceCode(const double a) function.
    • Function ExtractFileName() returns specified path if no path or drive separator found in it. Before it returned empty string in such case.
    • Function StringToUInt() didn't throw exception if argument was out of range of unsigned int and was silently converting it to required data type. Now it throws exception if value specified in string is valid number but is out of range of unsigned int data type.
    • Function StringToUInt64() didn't throw exception if argument was negative and was silently converting it to required data type. Now it throws exception if value specified in string is negative.
    • If search argument is empty, no replace take place any longer in functions Replace(), ReplaceDirect(), ReplaceAll(), and ReplaceAllDirect().
    • Multiple replace in ReplaceAll() functions.
    • Method setModal() of CControl didn't remove modal state from control if false was passed.
    • Methods MoveControl() and MoveListItem() didn't always returned false if there were no actual moving.
    • CDateTime adding and subtracting operators.
    • CDateTime's getDayOfWeek() method.
    • CForm's isEnabled() method returned visibility state instead of enableability when form has no real system window.
    • CForm's getClientRect() method returned shifted by position rectangle when form has no real system window.
    • CForm's setCaret() method returned false if both form's and caret's renderers were nullptr. From now on it returns true.
    • CForm's UnregisterHotkeys() method now return true only if there were hotkeys. Before it returned true always.
    • CFormService's UnregisterHotkeys(IComponent*) and UnregisterHotkeys(IControl*) methods now return true only if there were hotkeys. Before they returned true always.
    • Pointer value is converted to integer in json_encode() function. It was converted to hexadecimal integer before.
    • Missing copying of item's name in Copy() method of CListItem class.
    • Added missing usage of item position in getItem(const PointF &position) method of CListItem class.
    • InsertItem() method of CListItem class did not insert item before last one and added it after the last one instead.
    • Added missing include in Math helper header file.
    • Added exporting missing prefix in Export() method of all *State properties when exporting properties with empty control name specified.
    • Added missing enum prefix in Export() methods of CPropertyEnumState class which manage enum type properties for Form Builder.
    • Added missing exporting of font Monospace property in Export() methods of CPropertyFont and CPropertyFontState classes which manage font type properties for Form Builder.
    • Copy() method of CPropertyImageList was not working if there were any images.
    • Copy() method of CPropertyImageListState was not working if there were any images.
    • Loading mask state property in Load() method of CPropertyMaskState class.
    • Saving, loading, and exporting of style information in CPropertyStyle and CPropertyStyleState classes which handles styles in property editor of Form Builder.
  • Removed

    • Function BitmapRowToBin() as it was not used anywhere anymore.
    • Overloaded functions Extend() as there are already another functions with absolutely same behaviour.
    • time_point type definition from CDateTime class.
  • Replaced

  • Renamed

    • ICaret's method getVisible() has been renamed to isVisible() accordingly to the framework naming standards. Caret implementation in CCaret class has been changed accordingly.
    • IWindow::CREATE_PARAMS has been moved outside of IWindow interface and is now CREATE_PARAMS standalone structure. It also has got comparison operators.
  • Added

    • Function GradientTypeToString() for converting gradient's type into string representation.
    • New argument drive_separator to ExtractFileName() function.
    • New argument replacer to UTF8ToAnsi() function.
    • Default implementation of bool DeleteItem(IListItem *item) method to CControlItemList class.
    • Operator << for CDateTime class to output datetime object to terminal in human readable form.
    • Operator operator long long() for CInterval class to convert interval to seconds.
    • Constructor CInterval(const long long seconds) for CInterval class to create interval with specified seconds which will be converted to usual years, months, days, hours, minutes, and seconds.
    • Helper functions Hex(), HexAnsi(), HexCompact(), and HexAnsiCompact() for converting integer values into hexadecimal string representations.
    • IsEqual() and IsNotEqual() overloaded helper functions to compare float arrays.
  • Improved

    • Formatting of produced source code in function AsSourceCode() with arguments std::vector<bool>, std::vector<int>, std::vector<float>, std::vector<Color>, and Gradient.
    • Functions BinToNumber(), OctToNumber(), and HexToNumber() from now on return -1 in case of invalid value specified. They returned 0 before.
    • Functions BinToInt64(), OctToInt64(), and HexToInt64() from now on return -1 in case of invalid value specified. They returned different values before.
    • Improved speed and resource usage of PadRight() and PadRightDirect() functions.
    • Removed data type conversion and size limit on 64-bit platforms in TrimRight(), TrimRightDirect(), Trim(), and TrimDirect() functions.
    • Child control alignment of forms and controls now uses requested control size instead of actual one.
    • When changing control's alignment to alNone control's size becomes its requested size.
    • Zero year cannot be set in CDateTime class anymore.
    • Conversion CDateTime to/from long long algorithm.
    • Operator << of TRANSFORM structure outputs transform in better form now.
    • CFont's ShadowRadius property cannot be set to zero anymore. It was possible to set zero value by calling setShadowRadius() method directly.
    • Gradient's << operator output format.
    • Showing and hiding intervals comparison with zero values are now handled better in CHint's methods Show() and Hide().
    • Template class CHistory has got following improvements.
      • All int data types in methods has been replaced with size_t data type.
      • Added new method getSize() which returns currently used storage size.
      • Methods setLimitCount(), setLimitSize(), and setPosition() returns false if nothing has been changed. Previously they always returned true.
      • LimitCount equal to zero now means no limit by item count. Before you have to specify non-zero limit before using the template.
    • Added one more escapable symbol to DecodeEscapeSearch and DecodeEscapeReplace constants for Scripting module for better decoding strings with escape sequences.
    • Method hasItem() of IListItem should return false if instance of the same object is passed as argument. Before it returned true in such a case. Now its implementations return false.
    • Method InsertControl() of CControlService now do not use loops and works faster.
    • Added check if there is assigned property list and property list's entity in Export() method of all *State properties before accessing these entities. The cases when those entities are not assigned are actually can happen only if using properties incorrectly or in some special cases, like unit testing, when those assigned entities are not required.
    • prefix argument of constructors of all *State properties can now be specified as space string to prevent automatical prefixing of state names in exporting in form prototype header file.
    • Preview value of BoolArray, ColorArray, IntegerArray, and FloatArray properties in property editor of Form Builder.
    • Matrices are now stored in Variant representation more efficiently. Overloaded helper functions with Matrix argument ToVariant() and FromVariant() were changed.

Migration from previous version

Due to incomplete gradient storing and exporting in previous versions you need to re-setup all gradients of your forms(*.nfr files), which have gradients, and re-save those forms.

Instead of removed functions TryAnsiToInt(), TryAnsiToUInt(), TryAnsiToInt64(), TryAnsiToUInt64(), TryAnsiToFloat(), TryAnsiToDouble() use overloaded functions TryStringToInt(), TryStringToUInt(), TryStringToInt64(), TryStringToUInt64(), TryStringToFloat(), TryStringToDouble() respectively.

Instead of removed functions Extend() use overloaded functions PadRight().

Instead of removed time_point definition of CDateTime class use long long fundamental data type.

Whereever you use IWindow::CREATE_PARAMS structure just drop IWindow:: part.

When using hasItem() method of IListItem please note that from now on item->hasItem(item) returns false. Previously it returned true.

As the format of storing matrices in the Nitisa Form Resource(*.nfr) files has been changed you need either to load your form files where you customized matrices, resetup such matrices and save forms again or change *.nfr files directly in any text editor. As you might know such files are just a text files in JSON format. For instance, in the form files you have matrices encoded as following:

{
    "Data": [
        [
            1,
            0,
            0,
            0
        ],
        [
            0,
            1,
            0,
            0
        ],
        [
            0,
            0,
            1,
            0
        ],
        [
            1,
            2,
            3,
            1
        ]
    ]
}

You have to change it to this:
[
    [
        1,
        0,
        0,
        0
    ],
    [
        0,
        1,
        0,
        0
    ],
    [
        0,
        0,
        1,
        0
    ],
    [
        1,
        2,
        3,
        1
    ]
]

So, instead of having object with member "Data", you should have just an array.