X-Git-Url: https://git.sur5r.net/?a=blobdiff_plain;ds=sidebyside;f=doc%2Ffuncref.sgml;h=adbd7eeaa408d2c1d81e256c7ec4ac974044097c;hb=14030c08523a3493e03ecba82a0a378d50638cda;hp=75e3a2782384a181bd0b41dbc818405e0d320b13;hpb=f783f6d3c163bbc822056e17434b27e9c6d6118b;p=cc65 diff --git a/doc/funcref.sgml b/doc/funcref.sgml index 75e3a2782..adbd7eeaa 100644 --- a/doc/funcref.sgml +++ b/doc/funcref.sgml @@ -64,11 +64,23 @@ function.

+ +_dos_type + +rebootafterexit + -

+

-

+ +_dos_type + +rebootafterexit +textframe +textframexy + +

@@ -78,21 +90,62 @@ function. +

+ + + + + +(incomplete) + + +

+ +(incomplete) + +

- + +

+(incomplete) +

+ + + + + +

+ + + + + + + + + +

+ + + + + + + +

@@ -105,11 +158,11 @@ function. - - - - - + + + + + @@ -120,7 +173,7 @@ function. - + @@ -149,9 +202,13 @@ function.

+(incomplete) +

+(incomplete) +

@@ -159,9 +216,11 @@ function. + + @@ -169,6 +228,8 @@ function.

+(incomplete) +

@@ -181,9 +242,20 @@ function.

+(incomplete) +

+ + + + + + + + +

@@ -195,12 +267,45 @@ function.

+ + + + + + +

+ + + + + + + + + + + + + + + + + +(incomplete) +

+(incomplete) +

+The . +It does not declare any functions. +

@@ -214,15 +319,41 @@ function.

+(incomplete) +

+(incomplete) +

+ + +(incomplete) +

+ + + + +

@@ -234,9 +365,13 @@ function.

+(incomplete) +

+(incomplete) +

@@ -247,13 +382,62 @@ function.

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +(incomplete) +

+ + @@ -261,9 +445,9 @@ function. - + - + @@ -271,7 +455,8 @@ function. - + + @@ -283,9 +468,9 @@ function.

- + - + @@ -295,44 +480,87 @@ function. - - - + + + - - + + - - - - + + + + +(incomplete) +

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

- - + + + + + + + ---> + +(incomplete)

@@ -345,17 +573,21 @@ function. - + +(incomplete) +

+(incomplete) -

+

+(incomplete) Alphabetical function reference

@@ -371,10 +603,40 @@ function. The minimum blocksize that can be added is 6 bytes; the function will -ignore blocks with smaller sizes. +ignore smaller blocks. + +, +, +, +, +, +, + + + + + +_heapblocksize

+ + + +/ +/, / or /. + +Passing a pointer to a block that was is not the result of one of the +allocation functions, or that has been free'd will give unpredicable results. , , , , @@ -398,6 +660,7 @@ be allocated from the heap using /. , +, , , , @@ -427,6 +690,7 @@ id="malloc" name="malloc"> may still return , +, , , , @@ -437,6 +701,36 @@ id="malloc" name="malloc"> may still return +_poserror

+ + + +/ +/ with an +argument of +Since operating system specific error code are - you guessed it - +operating system specific, the value in The function is only available as fastcall function, so it may only +be used in presence of a prototype. + +, + + + + + _randomize

@@ -459,6 +753,30 @@ considered random to a certain degree. +_stroserror

+ + + +/ + +Since operating system specific error code are - you guessed it - +operating system specific, the parameter and the string returned depend on the +cc65 target. +The function is only available as fastcall function, so it may only be +used in presence of a prototype. + + + + + + _swap

@@ -538,8 +856,8 @@ is present. / The function is actually a macro. Disabling interrupts may lead to unexpected results. @@ -659,10 +977,11 @@ depend of the address expression used. / The function is actually a macro. +Disabling interrupts may lead to unexpected results. / Background colors are system dependent. The function may have no effect on systems where the background color cannot be changed. @@ -865,6 +1185,37 @@ be used in presence of a prototype. +bsearch

+ + + +/ + +The contents of the array must be sorted in ascending order according to +the compare function given. +If there are multiple members that match the key, the function will +return one of the members. +The function is only available as fastcall function, so it may only +be used in presence of a prototype. + + + + + + bzero

@@ -933,6 +1284,7 @@ be used in presence of a prototype. , +, , , , @@ -947,7 +1299,7 @@ be used in presence of a prototype. -/ -/ - +clearerr

+ + + +/ + +The function is only available as fastcall function, so it may only be +used in presence of a prototype. + +, + + + + + clrscr

@@ -1097,7 +1471,7 @@ reading the The function is only available as fastcall function, so it may only be used in presence of a prototype. -, @@ -1122,7 +1496,7 @@ associated with it. On error, -1 is returned and an error code is stored in The function is only available as fastcall function, so it may only be used in presence of a prototype. -, @@ -1131,6 +1505,141 @@ be used in presence of a prototype. +cprintf

+ + + +/ +/. --> + +Like all other +, +, +, +, + + + + + +cputc

+ + + +/ + +Like all other The function is only available as fastcall function, so it may only +be used in presence of a prototype. + +, +, +, +, + + + + + +cputcxy

+ + + +/ + +Like all other The function is only available as fastcall function, so it may only +be used in presence of a prototype. + +, +, +, +, + + + + + +cputs

+ + + +/ + +Like all other The function is only available as fastcall function, so it may only +be used in presence of a prototype. + +, +, +, +, + + + + + +cputsxy

+ + + +/ + +Like all other The function is only available as fastcall function, so it may only +be used in presence of a prototype. + +, +, +, +, + + + + + cursor

@@ -1206,6 +1715,28 @@ used in presence of a prototype. +div

+ + + +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. + + + + + em_commit

@@ -1295,7 +1826,33 @@ loaded. -em_load_driver

+em_install

+ + + +/ + +Not all drivers are able to detect if the supported hardware is really +present. +The function is only available as fastcall function, so it may only be +used in presence of a prototype. + +, +, + + + + + +em_load_driver

@@ -1332,7 +1889,7 @@ extended memory that should be supported. There is no autodetect capability. memory and returns a pointer to the page frame. Depending on the hardware and driver, the data is either mapped into the address space or transfered into a buffer. If you don't need the actual contents of the page (for example -because you're going to overwrite it completely, it is better to call +because you're going to overwrite it completely), it is better to call / instead. @@ -1375,13 +1932,40 @@ by the driver in 256 byte pages. +em_uninstall

+ + + +/ + +If the driver has been loaded using /, / +should be used instead of The function is only available as fastcall function, so it may only be +used in presence of a prototype. + +, +, + + + + + em_unload

/ - @@ -1470,7 +2054,81 @@ will nearly double the speed compared to slow mode. , - +, + + + + + +feof

+ + + +/ + +The indicator is set only after a read past the end of a file is +attempted. +The function is only available as fastcall function, so it may only be +used in presence of a prototype. + +, + + + + + +ferror

+ + + +/ + +The function is only available as fastcall function, so it may only be +used in presence of a prototype. + +, + + + + + +fileno

+ + + +/ + +The function is only available as fastcall function, so it may only be +used in presence of a prototype. +Mixing C file I/O functions and POSIX file I/O functions for the same +file may have unpredictable results. + +, + + + @@ -1497,6 +2155,7 @@ be used in presence of a prototype. , +, , , , @@ -1507,6 +2166,28 @@ be used in presence of a prototype. +get_ostype

+ + + +, +, / + +The function does not exist on all platforms. +The return codes are platform dependent. + + + + + getenv

@@ -1754,7 +2435,7 @@ fastcall function, so it may only be used in presence of a prototype. / When compiling with +joy_count

+ + + +/ + +A joystick driver must be loaded using before calling this function. +The function returns the number of joysticks supported by the driver. +There's no way to check for the number of actually connected joysticks. +The function is only available as fastcall function, so it may only be +used in presence of a prototype. + +, + + + + + +joy_install

+ + + +/ + +The function is only available as fastcall function, so it may only be +used in presence of a prototype. + +, +, + + + + + +joy_load_driver

+ + + +/ + +The function is only available as fastcall function, so it may only be +used in presence of a prototype. + +, +, + + + + + +joy_read

+ + + +/ +. + +A joystick driver must be loaded using before calling this function. +The function is only available as fastcall function, so it may only be +used in presence of a prototype. + +, +, + + + + + +joy_uninstall

+ + + +/ + +A joystick driver must be installed using before calling this function. +The function is only available as fastcall function, so it may only be +used in presence of a prototype. + +, +, + + + + + +joy_unload

+ + + +/ + +A joystick driver must be loaded using before calling this function. +The function is only available as fastcall function, so it may only be +used in presence of a prototype. + + + + + + kbhit

@@ -2253,6 +3084,33 @@ always be the same. +longjmp

+ + + +/ +/. Program execution continues as if the +call to / has just returned the value + +If the parameter The function is only available as fastcall function, so it may only +be used in presence of a prototype. + + + + + + malloc

@@ -2271,11 +3129,36 @@ be used in presence of a prototype. , +, , , , , - +, + + + + + +memchr

+ + + +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. + + @@ -2360,702 +3243,2547 @@ be used in presence of a prototype. -offsetof

+mod_free

-/ -/ +/ function. -The function is actually a macro. +The pointer passed as parameter is the pointer to the module memory, +not the pointer to the control structure. - -open

+mod_load

-/ -/ + + -POSIX specifies an additional The linker is needed to create +relocatable o65 modules for use with this function. -, - + -raise

+mouse_setbox

-/ -/ + -The function is only available as fastcall function, so it may only -be used in presence of a prototype. +The function does not check if the mouse cursor is currently within the +given rectangle. Placing the mouse cursor within the bounding box is the +responsibility of the programmer. +While the bounding box may be larger than the actual screen size, the +standard mouse cursor draw routines may fail to set the cursor to coordinates +outside of the screen area. Depending on the platform, you may have to supply +your own mouse cursor routines. +The function is only available as fastcall function, so it may only be +used in presence of a prototype. -, - +, + -rand

+mouse_getbox

-/ -/ + -Without using , always the same -flow of numbers is generated. +The function is only available as fastcall function, so it may only be +used in presence of a prototype. + +, + + + + + +mouse_buttons

+ + + +/ + +The function is only available as fastcall function, so it may only be +used in presence of a prototype. + +, + + + + + +mouse_geterrormsg

+ + + +/ + +The function will return "Unknown error" for invalid error codes. +The function is only available as fastcall function, so it may only be +used in presence of a prototype. + +, +, + + + + + +mouse_hide

+ + + +/ +/ and +/ to make the mouse cursor +visible. + +The function is only available as fastcall function, so it may only be +used in presence of a prototype. + + + + + + +mouse_info

+ + + +/ + +The / instead. +The function is only available as fastcall function, so it may only be +used in presence of a prototype. + +, + + + + + +mouse_install

+ + + +/ + +Not all drivers are able to detect if the supported hardware is really +present. +After installing a driver, the mouse cursor is hidden. +The function is only available as fastcall function, so it may only be +used in presence of a prototype. + +, +, + + + + + +mouse_ioctl

+ + + +/ + +Calling this function is non portable, because each driver may +implement different ioctl calls (or none at all). +The function is only available as fastcall function, so it may only be +used in presence of a prototype. + + + + + +mouse_load_driver

+ + + +/ + +The driver is loaded by name, so currently you must know the type of +mouse that should be supported. There is no autodetect capability. +Not all drivers are able to detect if the supported hardware is really +present. +After installing a driver, the mouse cursor is hidden. +The function is only available as fastcall function, so it may only be +used in presence of a prototype. + +, +, + + + + + +mouse_move

+ + + +/ + +The function does not check if the new position is within the bounding +box specified with /. +The function is only available as fastcall function, so it may only be +used in presence of a prototype. + +, + + + + + +mouse_pos

+ + + +/ + +The / instead. +The function is only available as fastcall function, so it may only be +used in presence of a prototype. + +, + + + + + +mouse_show

+ + + +/ +/ and +/. + +The function is only available as fastcall function, so it may only be +used in presence of a prototype. + + + + + + +mouse_uninstall

+ + + +/ + +If the driver has been loaded using /, / +should be used instead of The function is only available as fastcall function, so it may only be +used in presence of a prototype. + +, +, + + + + + +mouse_unload

+ + + +/ + +The function does nothing if no driver is loaded. + +, +, + + + + + +offsetof

+ + + +/ + +The function is actually a macro. + + + + + +open

+ + + +/ + +POSIX specifies an additional +, + + + + + +peekbsys

+ + + +/, +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. +This function may be a macro depending on the compiler options. The +actual function is accessible by #undef'ing the macro. + +, +, +, +, + + + + + +peekwsys

+ + + +/, +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. +The order in which the two bytes are read is undefined. + +, +, +, +, + + + + + +perror

+ + + +/ +/ with an argument of +The function is only available as fastcall function, so it may only +be used in presence of a prototype. + +, + + + + + +pokebsys

+ + + +/, +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. + +, +, +, +, + + + + + +pokewsys

+ + + +/, +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. +The order in which the two bytes are written is undefined. + +, +, +, +, + + + + + +qsort

+ + + +/ + +If there are multiple members with the same key, the order after calling +the function is undefined. +The function is only available as fastcall function, so it may only +be used in presence of a prototype. + + + + + + +raise

+ + + +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. + +, + + + + + +rand

+ + + +/ + +Without using , always the same +flow of numbers is generated. On startup, the function behaves as if had been used with an argument of 1. -, - +, + + + + + +realloc

+ + + +/ + +The part of the memory block that is returned will have its contents +unchanged. +This function is somewhat dangerous to use. Be careful to save the +pointer you're passing somewhere else, otherwise + + ptr = realloc (ptr, size); + +will loose your only copy of The function is only available as fastcall function, so it may only +be used in presence of a prototype. + +, +, +, +, +, +, + + + + + +remove

+ + + +/ + +This function is not available on all cc65 targets (depends on the +availability of file I/O). +The function is only available as fastcall function, so it may only +be used in presence of a prototype. + +, + + +#include <stdio.h> + +#define FILENAME "helloworld" + +if (remove (FILENAME) == 0) { + printf ("We deleted %s successfully\n", FILENAME); +} else { + printf ("There was a problem deleting %s\n", FILENAME); +} + + + + + +rename

+ + + +/ + +This function is not available on all cc65 targets (depends on the +capabilities of the storage devices). +The function is only available as fastcall function, so it may only +be used in presence of a prototype. + + + +#include <stdio.h> + +#define OLDNAME "textfile.txt" +#define NEWNAME "textfile.bak" + +if (rename (OLDNAME, NEWNAME) == 0) { + printf ("Renamed %s to %s\n", OLDNAME, NEWNAME); +} else { + printf ("Error renaming %s to %s\n", OLDNAME, NEWNAME); +} + + + + + +reset_brk

+ + + +/ + +Since / installs an exit handler, +it is not strictly necessary to call this function as part of the cleanup when +the program ends. + + + + + + +revers

+ + + +/ + +The function may not be supported by the hardware, in which case +the call is ignored. +The function is only available as fastcall function, so it may only +be used in presence of a prototype. + + + + + + +screensize

+ + + +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. + +, +, +, +, + + + + + +set_brk

+ + + +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. +The stub saves the zero page registers used by the C runtime and switches +to a small break handler stack. This means that it is safe to execute C code, +even if C code was interrupted. Be careful however not to use too many local +variables, and do not enable stack checks for the handler function or any other +function called from it. +The Since / as part of the cleanup when +the program terminates. + + + + + + +setjmp

+ + + +/ +/ function and +returns zero. + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. + + + + + + +setlocale

+ + + +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. +cc65 supports only the "C" locale, so calling this function to set a +different locale has no effect. + +, + + + + + + +signal

+ + + +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. + +, + + + + + +sleep

+ + + +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. + + + + + +slow

+ + + +/ + +The function is specific to the C128. + +, +, + + + + + +srand

+ + + +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. + +, + + + + + +strcasecmp

+ + + +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. +The function is not available in strict ANSI mode. + +, +, +, + + + + + + +strcat

+ + + +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. +If copying takes place between objects that overlap, the behaviour +is undefined. + +, +, + + + + + +strchr

+ + + +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. + +, + + + + + +strcmp

+ + + +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. + +, +, +, + + + + + + +strcoll

+ + + +/ +/. It returns a value that is less than zero if +The function is only available as fastcall function, so it may only +be used in presence of a prototype. + +, +, +, +, + + + + + + +strcpy

+ + + +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. +If copying takes place between objects that overlap, the behaviour +is undefined. + +, +, + + +#include <string.h> + +static char hello[14]; + +strcpy (hello, "Hello world!\n"); + + + + + +strcspn

+ + + +/ +not consist of +characters contained in the string +The function is only available as fastcall function, so it may only +be used in presence of a prototype. + +, +, + + + + + +strdup

+ + + +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. +It is up to the caller to free the allocated memory block. + +, + + + + + +strerror

+ + + +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. +While the return type of the function is a + + + + + +stricmp

+ + + +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. +The function is not available in strict ANSI mode. + +, +, +, + + + + + + +strlen

+ + + +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. +When compiling with + + + + + +strlower

+ + + +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. +The function prototype is unavailable when compiling in strict ANSI mode. +An alias name for this function is +, + + + + + +strlwr

+ + +See + + +strncat

+ + + +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. +If copying takes place between objects that overlap, the behaviour +is undefined. + +, +, + + + + + +strncmp

+ + + +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. + +, +, +, + + + + + + +strncpy

+ + + +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. If there is no null byte in the first If copying takes place between objects that overlap, the behaviour is +undefined. + +, +, + + +#include + +static char hello[6]; + +strcpy (hello, "Hello world!\n", sizeof (hello) - 1); +hello[5] = '\0'; + + + + + +strrchr

+ + + +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. + + + + + + +strspn

+ + + +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. + +, + + + + + +strstr

+ + + +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. + +, + + + + + +strtok

+ + + +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. + +, + + + + + +strxfrm

+ + + +/ + +If The function is only available as fastcall function, so it may only +be used in presence of a prototype. +Since cc65 doesn't support different charcter sets, . + +, +, +, + + + + +strupper

+ + + +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. +The function prototype is unavailable when compiling in strict ANSI mode. +An alias name for this function is + + + + + + +strupr

+ + +See + + +textcolor

+ + + +/ + +Text colors are system dependent. The function may have no effect +on systems where the text color cannot be changed. +The function is only available as fastcall function, so it may only +be used in presence of a prototype. + +, + + + + + +tgi_arc

+ + + +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. +The function behaves unexpectedly or may crash if the angles are out +of range. + +, +, +, +, + + +/* Draw the upper half of an ellipse */ +tgi_setcolor(TGI_COLOR_BLUE); +tgi_arc (50, 50, 40, 20, 0, 180); + + + + + +tgi_bar

+ + + +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. + + +tgi_setcolor(TGI_COLOR_GREEN); +tgi_bar(10, 10, 100, 60); + + + + + +tgi_circle

+ + + +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. + +, +, +, +, + + +tgi_setcolor(TGI_COLOR_BLACK); +tgi_circle(50, 40, 40); + + + + + +tgi_clear

+ + + +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. + + + + + +tgi_done

+ + + +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. + + + + + +tgi_ellipse

+ + + +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. + +, +, +, +, + + +tgi_setcolor(TGI_COLOR_RED); +tgi_ellipse (50, 40, 40, 20); + + + + + +tgi_getcolor

+ + + +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. + + +color = tgi_getcolor(); + + + + +tgi_getcolorcount

+ + + +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. + + +if (tgi_getcolorcount() == 2) { + printf("Only monochrome graphics is supported\n"); +} + + + + +tgi_getdefpalette

+ + + +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. + + - -realloc

+tgi_geterror

-/ - -The part of the memory block that is returned will have its contents -unchanged. -This function is somewhat dangerous to use. Be careful to save the -pointer you're passing somewhere else, otherwise - - ptr = realloc (ptr, size); - -will loose your only copy of / + The function is only available as fastcall function, so it may only be used in presence of a prototype. -, -, -, -, -, - + - -reset_brk

+tgi_geterrormsg

-/ - -Since / installs an exit handler, -it is not strictly necessary to call this function as part of the cleanup when -the program ends. +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. + +tgi_getmaxcolor

-revers

+ + +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. + + + + +tgi_getmaxx

-/ -/ + -The function may not be supported by the hardware, in which case -the call is ignored. The function is only available as fastcall function, so it may only be used in presence of a prototype. + +tgi_getmaxy

-screensize

+ + +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. + + + + +tgi_getpagecount

-/ -/ + The function is only available as fastcall function, so it may only be used in presence of a prototype. , -, -, -, - +, + +tgi_getpalette

-set_brk

+ + +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. + + + + +tgi_getpixel

-/ - +/ + The function is only available as fastcall function, so it may only be used in presence of a prototype. -The stub saves the zero page registers used by the C runtime and switches -to a small break handler stack. This means that it is safe to execute C code, -even if C code was interrupted. Be careful however not to use too many local -variables, and do not enable stack checks for the handler function or any other -function called from it. -The Since / as part of the cleanup when -the program terminates. + +tgi_getxres

-setlocale

+ + +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. + + + + +tgi_getyres

-/ - +/ + The function is only available as fastcall function, so it may only be used in presence of a prototype. -cc65 supports only the "C" locale, so calling this function to set a -different locale has no effect. -, - + +tgi_gotoxy

-signal

+ + +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. + + + + +tgi_init

-/ -/ + The function is only available as fastcall function, so it may only be used in presence of a prototype. - +extern char lynxtgi[]; //Include the driver statically instead of loading it. +tgi_install(&lynxtgi); +tgi_init(); //Set up the default palette and clear the screen. + + + + +tgi_install

+ + + +/ + +The function is only available as fastcall function, so it may only be +used in presence of a prototype. + +, - -, +, + + +extern char lynxtgi[]; //Include the driver statically instead of loading it. + +tgi_install(&lynxtgi); +tgi_init(); //Set up the default palette and clear the screen. + -sleep

+tgi_ioctl

-/ -/ + The function is only available as fastcall function, so it may only be used in presence of a prototype. +These functions are not easily portable to other cc65 platforms. - +#define tgi_sprite(spr) tgi_ioctl(0, (unsigned)(spr)) +#define tgi_flip() tgi_ioctl(1, 0) +#define tgi_setbgcolor(bgcol) tgi_ioctl(2, (unsigned)(bgcol)) +#define tgi_setframerate(rate) tgi_ioctl(3, (unsigned)(rate)) +#define tgi_busy() tgi_ioctl(4, 0) +#define tgi_updatedisplay() tgi_ioctl(4, 1) +if (!tgi_busy()) { + tgi_sprite(&background); + tgi_setcolor(TGI_COLOR_BLUE); + tgi_outttextxy(20,40,"Hello World"); + tgi_updatedisplay(); +} + -slow

+tgi_line

-/ -/ + -The function is specific to the C128. +The function is only available as fastcall function, so it may only +be used in presence of a prototype. -, - + -srand

+tgi_lineto

-/ -/ + The function is only available as fastcall function, so it may only be used in presence of a prototype. -, - + -strcasecmp

+tgi_load

-/ -/ + The function is only available as fastcall function, so it may only be used in presence of a prototype. -The function is not available in strict ANSI mode. , -, - + -strcat

+tgi_load_driver

-/ -/ + The function is only available as fastcall function, so it may only be used in presence of a prototype. -If copying takes place between objects that overlap, the behavior -is undefined. - - + -strchr

+tgi_outtext

-/ -/ + The function is only available as fastcall function, so it may only be used in presence of a prototype. - + -strcmp

+tgi_outtextxy

-/ -/ + The function is only available as fastcall function, so it may only be used in presence of a prototype. -, -, - + -strcoll

+tgi_pieslice

-/ -/. It returns a value that is less than zero if / + The function is only available as fastcall function, so it may only be used in presence of a prototype. +The function behaves unexpectedly or may crash if the angles are out +of range. -, -, -, - -, +, +, +, + + +/* Draw the closed upper half of an ellipse */ +tgi_setcolor(TGI_COLOR_BLUE); +tgi_pieslice (50, 50, 40, 20, 0, 180); + -strcpy

+tgi_setcolor

-/ -/ + The function is only available as fastcall function, so it may only be used in presence of a prototype. -If copying takes place between objects that overlap, the behavior -is undefined. - - - -#include - -static char hello[14]; - -strcpy (hello, "Hello world!\n"); + +tgi_setcolor(TGI_COLOR_BLACK); +tgi_bar(0,0,30,30); +tgi_setcolor(TGI_COLOR_WHITE); +tgi_bar(10,10,20,20); - -stricmp

+tgi_setdrawpage

-/ -/ + The function is only available as fastcall function, so it may only be used in presence of a prototype. -The function is not available in strict ANSI mode. , -, - - +tgi_setdrawpage(1); +tgi_outtextxy(10, 10, "Hello World"); +tgi_setviewpage(1); // Show page 1 +tgi_setdrawpage(0); +tgi_outtextxy(10, 10, "Creating next frame"); +... +tgi_setviewpage(0); // Show page 0 + - -strlen

+tgi_setpalette

-/ -/ + The function is only available as fastcall function, so it may only be used in presence of a prototype. -When compiling with - + - -strlower

+tgi_setpixel

-/ -/ + The function is only available as fastcall function, so it may only be used in presence of a prototype. -The function prototype is unavailable when compiling in strict ANSI mode. -An alias name for this function is - + - -strlwr

+tgi_setviewpage

-See +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. + + +tgi_setdrawpage(1); +tgi_outtextxy(10, 10, "Hello World"); +tgi_setviewpage(1); // Show page 1 +tgi_setdrawpage(0); +tgi_outtextxy(10, 10, "Creating next frame"); +... +tgi_setviewpage(0); // Show page 0 + + - -strncpy

+tgi_textheight

-/ -/ + The function is only available as fastcall function, so it may only -be used in presence of a prototype. If there is no null byte in the first If copying takes place between objects that overlap, the behavior is -undefined. +be used in presence of a prototype. - - - -#include - -static char hello[6]; - -strcpy (hello, "Hello world!\n", sizeof (hello) - 1); -hello[5] = '\0'; - + - -strrchr

+tgi_textstyle

-/ -/ + The function is only available as fastcall function, so it may only be used in presence of a prototype. - + - -strupper

+tgi_textwidth

-/ -/ +/ +/ The function is only available as fastcall function, so it may only be used in presence of a prototype. -The function prototype is unavailable when compiling in strict ANSI mode. -An alias name for this function is - + - -strupr

+tgi_uninstall

-See +/ + +The function is only available as fastcall function, so it may only +be used in presence of a prototype. + + - -textcolor

+tgi_unload

-/ -/ + -Text colors are system dependent. The function may have no effect -on systems where the text color cannot be changed. The function is only available as fastcall function, so it may only be used in presence of a prototype. , - + + + +time

+ + + +/ + +The function is only available as fastcall function, so it may +only be used in presence of a prototype. +Many platforms supported by cc65 do not have a realtime clock, so the +returned value may not be valid. + + @@ -3073,11 +5801,14 @@ old mode (cursor position, color and so on) are saved and restored together with the mode. The function is specific to the C128. +This function is deprecated. Please use instead! , - +, + @@ -3157,6 +5888,48 @@ used in presence of a prototype. +unlink

+ + + +/ + +The use of this function is discouraged. Please use / instead, which is a native ANSI C function and does the same. +This function is not available on all cc65 targets (depends on the +availability of file I/O). +The function is only available as fastcall function, so it may only +be used in presence of a prototype. +Instead of / should be +used, which has the same semantics, but is more portable, because it conforms +to the ISO C standard. + + + +#include <stdio.h> +#include <unistd.h> + +#define FILENAME "helloworld" + +if (unlink (FILENAME) == 0) { + printf ("We deleted %s successfully\n", FILENAME); +} else { + printf ("There was a problem deleting %s\n", FILENAME); +} + + + + + utoa

@@ -3185,6 +5958,63 @@ used in presence of a prototype. +vcprintf

+ + + +/ +/. --> + +Like all other The function is only available as fastcall function, so it may only be +used in presence of a prototype. + +, +, +, +, + + + + + +videomode

+ + + +, +/ + +The function is specific to the C128 and enhanced Apple //e. +This function replaces . +The function is only available as fastcall function, so it may only be +used in presence of a prototype. + +, +, + + + + + wherex

@@ -3226,5 +6056,3 @@ cursor. Zero is returned for the uppermost screen position. - -