table_widget2 (library)
Author(s): Isabel Martín García.In addition to the features explained in the introduction, predicates exported by this module display tables in which the font weight for the elements placed in the first row is bold. The remaining elements are in medium weight font.
If the arguments are not in a correct format the exception error8 will be thrown.
Usage and interface
- Library usage:
:- use_module(library(table_widget2)). - Exports:
- Predicates:
tablewidget2/4, tablewidget2/5.
- Predicates:
- Imports:
- System library modules:
chartlib/genbar1, chartlib/bltclass, chartlib/table_widget1, chartlib/test_format, chartlib/install_utils, lists. - Packages:
prelude, nonpure, assertions, regtypes, isomodes.
- System library modules:
Documentation on exports
PREDICATE
tablewidget2(Title,Header,ElementTable,Footer)
Shows a regular table in a window. The system sets a default background image for the widget.
Example:
tablewidget2('COM Features', 'Extracted from "Inside COM" book ', [['Feature','Rich people','Bean Plants','C++','COM'], ['Edible','Yes','Yes','No','No'], ['Supports inheritance','Yes','Yes','Yes','Yes and No'], ['Can run for President','Yes','No','No','No']], 'What do you think about COM?').
Usage:
- The following properties should hold at call time:
(genbar1:title/1)Title is a text (an atom) to be used as label, usually not very long.
(genbar1:header/1)Header is a text (an atom) describing the header of the graph.
(table_widget1:table/1)table_widget1:table(ElementTable)
(genbar1:footer/1)Footer is a text (an atom) describing the footer of the graph.
PREDICATE
tablewidget2(Title,Header,ElementTable,Footer,BackgroundImage)
This predicate and tablewidget2/4 are quite similar, except that in the already one defined you must set the background image.
Example:
tablewidget2('COM Features', 'Extracted from "Inside COM" book ', [['Feature','Rich people','Bean Plants','C++','COM'], ['Edible','Yes','Yes','No','No'], ['Supports inheritance','Yes','Yes','Yes','Yes and No'], ['Can run for President','Yes','No','No','No']], 'What do you think about COM?', './images/rain.gif').
Usage:
- The following properties should hold at call time:
(genbar1:title/1)Title is a text (an atom) to be used as label, usually not very long.
(genbar1:header/1)Header is a text (an atom) describing the header of the graph.
(table_widget1:table/1)table_widget1:table(ElementTable)
(genbar1:footer/1)Footer is a text (an atom) describing the footer of the graph.
(table_widget1:image/1)table_widget1:image(BackgroundImage)