#include <stdio.h>#include <slang.h>#include <newt.h>Go to the source code of this file.
Defines | |
| #define | I SLANG_INT_TYPE |
| #define | S SLANG_STRING_TYPE |
Functions | |
| SLANG_MODULE (newt) | |
| static void | init (void) |
| static void | cls (void) |
| static void | draw_root_text (int *c, int *r, char *s) |
| static void | open_window (int *c, int *r, int *dc, int *dr, char *title) |
| static void | refresh (void) |
| static void | finished (void) |
| int | init_newt_module_ns (char *ns) |
| void | deinit_newt_module (void) |
Variables | |
| static int | Ok_To_Draw |
| static SLang_Intrin_Fun_Type | Module_Funs [] |
| static SLang_Intrin_Var_Type | Module_Variables [] |
| static SLang_IConstant_Type | Module_Constants [] |
|
|
Definition at line 47 of file newt-module.c. |
|
|
Definition at line 48 of file newt-module.c. Referenced by cputurn(), initgame(), and randomplace(). |
|
|
Definition at line 16 of file newt-module.c. References Ok_To_Draw. 00017 { 00018 if (Ok_To_Draw) 00019 newtCls (); 00020 }
|
|
|
Definition at line 88 of file newt-module.c. References finished(). 00089 { 00090 finished (); 00091 }
|
|
||||||||||||||||
|
Definition at line 22 of file newt-module.c. References Ok_To_Draw. 00023 { 00024 if (Ok_To_Draw) 00025 newtDrawRootText (*c, *r, s); 00026 }
|
|
|
Definition at line 40 of file newt-module.c. References Ok_To_Draw. Referenced by deinit_newt_module(), and init_newt_module_ns(). 00041 { 00042 if (Ok_To_Draw) 00043 newtFinished (); 00044 Ok_To_Draw = 0; 00045 }
|
|
|
Definition at line 10 of file newt-module.c. References Ok_To_Draw. Referenced by main(). 00011 { 00012 newtInit (); 00013 Ok_To_Draw = 1; 00014 }
|
|
|
Definition at line 73 of file newt-module.c. References finished(), Ok_To_Draw, SLang_add_cleanup_function(), SLns_add_iconstant_table(), SLns_add_intrin_fun_table(), and SLns_add_intrin_var_table(). 00074 { 00075 if ((-1 == SLns_add_intrin_fun_table (ns, Module_Funs, "__NEWT__")) 00076 || (-1 == SLns_add_intrin_var_table (ns, Module_Variables, NULL)) 00077 || (-1 == SLns_add_iconstant_table (ns, Module_Constants, NULL))) 00078 return -1; 00079 00080 Ok_To_Draw = 0; 00081 00082 (void) SLang_add_cleanup_function (finished); 00083 00084 return 0; 00085 }
|
|
||||||||||||||||||||||||
|
Definition at line 28 of file newt-module.c. References Ok_To_Draw. 00029 { 00030 if (Ok_To_Draw) 00031 newtOpenWindow (*c, *r, *dc, *dr, title); 00032 }
|
|
|
Definition at line 34 of file newt-module.c. References Ok_To_Draw. 00035 { 00036 if (Ok_To_Draw) 00037 newtRefresh (); 00038 }
|
|
|
|
|
|
Initial value:
{
SLANG_END_TABLE
}
Definition at line 67 of file newt-module.c. |
|
|
Initial value:
{
MAKE_INTRINSIC_0("newtInit", init, SLANG_VOID_TYPE),
MAKE_INTRINSIC_0("newtCls", cls, SLANG_VOID_TYPE),
MAKE_INTRINSIC_IIS("newtDrawRootText", draw_root_text, SLANG_VOID_TYPE),
MAKE_INTRINSIC_5("newtOpenWindow", open_window, SLANG_VOID_TYPE, I,I,I,I,S),
MAKE_INTRINSIC_0("newtRefresh", refresh, SLANG_VOID_TYPE),
MAKE_INTRINSIC_0("NewtFinished", finished, SLANG_VOID_TYPE),
SLANG_END_TABLE
}
Definition at line 50 of file newt-module.c. |
|
|
Initial value:
{
SLANG_END_TABLE
}
Definition at line 62 of file newt-module.c. |
|
|
Definition at line 8 of file newt-module.c. Referenced by cls(), draw_root_text(), finished(), init(), init_newt_module_ns(), open_window(), and refresh(). |