Lugaru's Epsilon
Programmer's
Editor 14.04

Context:
Epsilon User's Manual and Reference
   Changes from Older Versions
      EEL Programming Changes in Epsilon 12
         EEL Changes for Unicode Support in Epsilon 12
            Converting Old EEL Code
         Other EEL Enhancements in Epsilon 12
         . . .

Previous   Up    Next
EEL Changes for Unicode Support in Epsilon 12  Changes from Older Versions   Other EEL Enhancements in Epsilon 12


Epsilon User's Manual and Reference > Changes from Older Versions > EEL Programming Changes in Epsilon 12 >

Converting Old EEL Code

Changes may be required in older EEL code that uses the call_dll( ) primitive to call Windows DLLs, since the EEL strings that will be passed are now wide 16-bit characters. Often, calling the wide instead of the ANSI (8-bit) version of an API function is all that's needed.

Old EEL code that uses the memset( ) primitive to initialize a character array should be changed to use the new set_chars( ) primitive. The former operates on 8-bit bytes, not 16-bit characters. Similarly, some uses of the memcmp( ) or memfcmp( ) primitives may need to be changed to use compare_chars( ). Uses of memcpy( ) should also be checked.

The ptrlen( ) primitive returns the accessible length of the pointer it's passed, in char units. If its new optional second argument is nonzero, it now returns its count in bytes instead.

Since keys are now 32 bits (type int, not type short), the get_keycode( ) primitive now returns an int * value, not a short * value. The stuff_macro( ), name_macro( ), and get_macro( ) functions have also changed their argument types or return values. To modify old EEL code that uses these functions so it works in older versions as well as current versions of Epsilon, use the key_t macro in places that refer to a key code, and #include the file oldkeys.h in your source file after eel.h. It defines compatibility functions. See Binding Primitives.

EEL code that wants to perform some operation on groups of keys can't simply use a loop like for (i = 0; i < MAXKEYS; i++) to do so; there are too many possible key codes for that to be practical. Instead, there are new primitives get_range( ), set_range( ), and find_next_entry( ) to do this. See Binding Primitives for details.



Previous   Up    Next
EEL Changes for Unicode Support in Epsilon 12  Changes from Older Versions   Other EEL Enhancements in Epsilon 12


Lugaru Epsilon Programmer's Editor 14.04 manual. Copyright (C) 1984, 2021 by Lugaru Software Ltd. All rights reserved.