|
MIDletPascal supports the following features:
-
boolean, integer, character, string, array (multidimensional arrays are supported), record and image data types
-
most Pascal program flow-control statements: if-then-else statement, do-while loop, repeat-until loop, for loop, procedures and functions
- support for multiple source files and multiple build configurations.
-
defining constants and custom data types
-
graphics functions to access the mobile device display and to load and display PNG images
- integrated PNG image editor
-
functions to access the mobile device keypad
-
user-interface (forms) support
-
HTTP connectivity
-
SMS messaging
-
sound functions
-
record store support (record store is where you save data on the mobile phone)
-
date and time functions, string functions, random number generator functions
-
customizable syntax coloring editor
-
real (floating-point) numbers and math functions
-
compiler directly generates Java bytecode - fast compile and execute!
-
support for phone emulators
-
help, tutorial and function reference
Sample program:
The following MIDletPascal program will display a text on the screen that will fade out from black to white repeatedly.
var color : integer;
begin
color := 0;
setFont(FONT_FACE_SYSTEM, FONT_STYLE_BOLD, FONT_SIZE_LARGE);
repeat
setColor(color, color, color);
color := color + 8;
if (color > 255) then
color := 0;
drawText('Hello world!', 0, 0);
repaint;
delay(100)
until false
end.
|