[top] [up] New
features in R3A
New features and changes in R3B
The new features of R3B
- The compiler has been extended to support DCG notation for
grammar rules.
- The import/, import/2, import_module/1, import_module/2, export/1and export/2 clauses were added
for creating large programs that consist of multiple modules. With these predicates it is
possible to specify per module which clauses it imports from other modules and which
predicates are exported for other modules.
- 59 new built-in predicates: add_callback/3, asserta/2, assertz/2, abolish/2, atom_integers/2, base64_decode_file/2, base64_encode_file/2
, close_console/0, create_module/2, del_env/1, dynamic/2, get/1, get/2, get0/1,
get0/2, get_env/2, get_term/2, is_alpha/1, is_alphanum/1, is_ascii/1, is_cntrl/1, is_digit/1, is_graph/1, is_lower/1, is_upper/1, is_space/1, ispresent_callback/3, module/3, module_name/2, number_integers/2, prolog_version/3, put/1, put/2, remove_callback/3, replace/3, retract/2, round/2, see/1, seeing/1,
seen/0, seentold/0, setof_reverse/3, set_env/2, set_stream_property/2, telling/1, this_module/3, time_elapsed/1, to_lower/1, to_prolog/1, to_string/1, to_upper/1, told/0, trim/1, triml/1,
trimr/1, write_list/1, write_list/2, write_list_goal/2 and write_list_goal/3.
- Four reserved variable names were added: __FILE__, __HOST__, __LINE__ and __MODULE__. These can be useful for debugging purposes because
occurences of these variables are replaced while compiling a source file.
- Windows shortcuts to files are automatically detected, read
and followed by Trinc-Prolog while loading a file for compiliation.
- It is possible to determine how integers and floating-point numbers are written to a
stream with the number_format_string property of a stream. This
is very useful for financial applications.
- A list of open-options can be the third argument of consult/3, open_module_search/3 and open_module/3. An
open-option called 'not_active' has been added.
- 7 new predicates in the datetime module: age/7,
monday_of_week/5, next_week/4, num_weeks_in_year/2, prev_week/4, start_of_week/3 and first_week/2. The documentation of datetime module was changed and integrated with the
built-in predicates documentation.
- 4 new predicates in the list module: largest_number/2,
smallest_number/2, sum_list/2 and sum_list_integer/2. The documentation of
the list module was changed.
- A new simpeler method to send an asynchronous
event from an extension library to Trinc-Prolog.
- Argument indexing of predicates to increase the speed of program execution.
- With the compile directive not_redo/1 is it possible to
specify that for certain goals only 1 solution may be found.
- The new predicate add_callback/3 makes it possible to send
events of instances to a normal Prolog clause and not just to destination instances like
with add_callback/4.
- The database class can now use persistent database
connections.
- The query class has 3 new methods to iterate through a result
set with a fail driven loop:
- The TPWin collection of classes has been extended with a numberEdit,
treeView and line control classes.
- The following methods were added to make visual controls more suitable for database
applications:
- control::putProperties/2, control::properties/2, control::putIntegerProperty/1, control::integerProperty/1, control::putStringProperty/1, control::stringProperty/1 and control::clearProperties/0
- comboBox::add/3, comboBox::add/4,
comboBox::insert/4, comboBox::putProperties/3, comboBox::findAndSelectId/2, comboBox::findAndSelectExtraText/2, comboBox::give/5 and comboBox::onSelectionChangeEx/2.
- listBox::add/3, listBox::add/4,
listBox::insert/4, listBox::putProperties/3,
listBox::give/5 listBox::findAndSelectId/2,
listBox::findAndSelectExtraText/2, listBox::firstSelectedString/4 and listBox::onSelectionChangeEx/2.
- grid::appendRow/3, grid::cellProperties/5, grid::cellText/6, grid::putCellText/5,
grid::putRowProperties/4, grid::rowProperties/5.
- New methods of TPWIN classes:
- application::putENTERSameAsTab/1 and application::isENTERSameAsTab/1.
- canvas::drawColoredLine/5, canvas::drawColoredLine/6, canvas::drawFillRect/2 and canvas::drawFillRect/5.
- comboBox::currentText/1, comboBox::currentText/4 and comboBox:clearSelection/0.
- control::ctrl3DLook/1 and control::putCtrl3DLook/1.
- grid::putFixedFont/3, grid::putFixedFont/7, grid::putNormalFont/3, grid::putNormalFont/7, grid::putMayAskForData/1, grid::mayAskForData/1, grid::scroll/2,
grid::heightAvailable/1, grid::heightAvailableNormalRows/1, grid::numberOfDefaultRowsVisible/1 and
the grid control also has two new events: grid::onAfterMove/5
and grid::onMoreData/3.
- imageButton::putRepeatOnClickIfPressed/1
and imageButton::repeatOnClickIfPressed/1.
- listBox::deleteText/2.
- maskEdit::textWithoutMask/4, maskEdit::putAlwaysDisplayMask/1 and maskEdit::checkAlwaysDisplayMask/1.
- menu::enableItemAtPos/2.
- panel::backgroundColor/3, panel::putBackgroundColor/3, panel::addTreeView/6, panel::addTreeView/7, panel::addLine/6,
panel::addLine/7, panel::addMaskEditPassword/8 and panel::addMaskEditPassword/9.
- raisedLabel::noBorder/1, raisedLabel::putNoBorder/2, raisedLabel::centerText_X/1, raisedLabel:putCenterText_X/2, raisedLabel::centerText_Y/1, raisedLabel::putCenterText_Y/2, raisedLabel::transparent/1 and raisedLabel::putTransparent/2.
- system::putTextBeamCursor/0, system::putDragDropCursor/0, system::changeWaitCursor/1, system::changeDefaultCursor/1, system::changeHandCursor/1, system::changeTextBeamCursor/1, system::changeDragDropCursor/1, system::putCursorPos/1, system::playSound/3, system::stopPlaySound/1, system::widthThumbHorScroll/1 and system::heightThumbVerScroll/1.
- tabBook::putBackgroundColor/2 and tabBoook::backgroundColor/3.
- window::putName/1, window::name/1,
window::findWindow/2, window::updateSize/0, window::backgroundColor/3, window::putSizeScrollThumb/3 and window::sizeScrollThumb/2.
Changes in R3B
- About 50% less memory is used and the speed of the Prolog inference engine has been
increased by 30%.
- The project manager translates
absolute paths to relative paths, all filepaths are now relative to the location of the
project file.
- When a file is compiled the default access property of all clauses is public and clauses
asserted to a module are automatically made public clauses. It
is now allowed to assert non-existent clauses, i.e. if there are no user-defined
procedures for it. This all complies with the ISO Prolog standard.
- The built-in predicate this/1 now throws 'type_error(instance,
Argument)' exceptions instead of 'type_error(variable, Argument)'.
- The default value of the prolog flag num_digits has
been increased from 7 to 15 to make working with very large floating-point numbers easier.
- The maximum size of an atom is now 2.147.483.647 bytes. If an atom is equal or larger
than that number of bytes the compiler generates an error.
- With a second backslash character is it possible to signal the end of an escape sequence.
- It is possible to use relative path names in the predicates consult/1,
consult/3, open_module/1 and open_module/3.
- The compiler now reports a syntax error when it detects an AND operator as the main
operator of a Prolog clause, an example of such an incorrect clause is: 'a, b, c.'
- The is_string/2 operator can now be used with null atoms.
- An exception is thrown if an atom with arguments in the right expression of is_string/2 is encountered that is not a built-in predicate.
- In the dialog for replaying a test an option has been added for
ignoring the identifiers of empty variables.
- The console window can be resized while it is asking the user
for data.
- The debugger does not show more than 2000 characters of a veriable value in the watch-
and popup hint windows.
- The maximum length of a line in the text editor was increased from 1000 to 2048
characters.
- The declaration of the file class was moved to the file os.txt
in the modules folder of Trinc-Prolog.
- All reported bugs have been fixed, these are: 20001228-00, 20001229-00, 20010103-00, 20010107-00, 20010213-00, 20010213-01, 20010213-02, 20010213-03, 20010223-01
We welcome any idea for further improving and extending Trinc-Prolog, please use the wishlist forum for
posting your ideas.
[top] [up] New
features in R3A
info@trinc-prolog.com