mirror of
https://github.com/QB64Official/qb64.git
synced 2024-08-22 11:25:08 +00:00
Window's CONSOLE support has been extended so that: CSRLIN support added. POS(0) support added. LOCATE support added. (Works with optional parameters.) COLOR support added. SCREEN support added to get both character and color information of any point on the console. tab() glitch fixed. (Which could cause an endless loop when printing with comma spaced text/numbers.) _WIDTH support added. _HEIGHT support added. WIDTH support added, with 2 new parameters added so we can set the buffer width and buffer height also. CLS support semi-added. (Doesn't accept colored backgrounds; it clears the screen black. I'm getting tired of working up console stuff which I probably won't ever use myself...) SLEEP support added. END support added so we now end with any keypress and not just enter. _CONSOLEINPUT added, so we can tell the difference in mouse and keyboard input. _CINP(toggle) support added, which allows us to get single character keystrokes from the console. _CONSOLEFONT FontName, FontSize support added, which allows us to change the font and font size we use for the console. _CONSOLECURSOR _SHOW|_HIDE, cursorsize support added, which allows us to show or hide the cursor in the console, and to change its size (from 0 to 100), as desired. New keyboard commands added: _CAPSLOCK -- returns 1 if caps lock is on, 0 if it isn't. _NUMLOCK -- as above, but for num lock _SCROLLOCK -- as above, but for scroll lock _TOGGLE_CAPSLOCK -- toggles the caps lock state for us. _TOGGLE_NUMLOCK -- same, but for num lock _TOGGLE_SCROLLOCK -- same, but for scroll lock
137 lines
6.1 KiB
Text
137 lines
6.1 KiB
Text
int32 *_FUNC_TYPNAME2TYP_LONG_TYPNAME2TYP=NULL;
|
|
if(_FUNC_TYPNAME2TYP_LONG_TYPNAME2TYP==NULL){
|
|
_FUNC_TYPNAME2TYP_LONG_TYPNAME2TYP=(int32*)mem_static_malloc(4);
|
|
*_FUNC_TYPNAME2TYP_LONG_TYPNAME2TYP=0;
|
|
}
|
|
qbs*oldstr3035=NULL;
|
|
if(_FUNC_TYPNAME2TYP_STRING_T2->tmp||_FUNC_TYPNAME2TYP_STRING_T2->fixed||_FUNC_TYPNAME2TYP_STRING_T2->readonly){
|
|
oldstr3035=_FUNC_TYPNAME2TYP_STRING_T2;
|
|
if (oldstr3035->cmem_descriptor){
|
|
_FUNC_TYPNAME2TYP_STRING_T2=qbs_new_cmem(oldstr3035->len,0);
|
|
}else{
|
|
_FUNC_TYPNAME2TYP_STRING_T2=qbs_new(oldstr3035->len,0);
|
|
}
|
|
memcpy(_FUNC_TYPNAME2TYP_STRING_T2->chr,oldstr3035->chr,oldstr3035->len);
|
|
}
|
|
qbs *_FUNC_TYPNAME2TYP_STRING_T=NULL;
|
|
if (!_FUNC_TYPNAME2TYP_STRING_T)_FUNC_TYPNAME2TYP_STRING_T=qbs_new(0,0);
|
|
qbs *_FUNC_TYPNAME2TYP_STRING_TS=NULL;
|
|
if (!_FUNC_TYPNAME2TYP_STRING_TS)_FUNC_TYPNAME2TYP_STRING_TS=qbs_new(0,0);
|
|
qbs *_FUNC_TYPNAME2TYP_STRING_N=NULL;
|
|
if (!_FUNC_TYPNAME2TYP_STRING_N)_FUNC_TYPNAME2TYP_STRING_N=qbs_new(0,0);
|
|
byte_element_struct *byte_element_3036=NULL;
|
|
if (!byte_element_3036){
|
|
if ((mem_static_pointer+=12)<mem_static_limit) byte_element_3036=(byte_element_struct*)(mem_static_pointer-12); else byte_element_3036=(byte_element_struct*)mem_static_malloc(12);
|
|
}
|
|
int32 *_FUNC_TYPNAME2TYP_LONG_B=NULL;
|
|
if(_FUNC_TYPNAME2TYP_LONG_B==NULL){
|
|
_FUNC_TYPNAME2TYP_LONG_B=(int32*)mem_static_malloc(4);
|
|
*_FUNC_TYPNAME2TYP_LONG_B=0;
|
|
}
|
|
int32 *_FUNC_TYPNAME2TYP_LONG_UNSGN=NULL;
|
|
if(_FUNC_TYPNAME2TYP_LONG_UNSGN==NULL){
|
|
_FUNC_TYPNAME2TYP_LONG_UNSGN=(int32*)mem_static_malloc(4);
|
|
*_FUNC_TYPNAME2TYP_LONG_UNSGN=0;
|
|
}
|
|
byte_element_struct *byte_element_3037=NULL;
|
|
if (!byte_element_3037){
|
|
if ((mem_static_pointer+=12)<mem_static_limit) byte_element_3037=(byte_element_struct*)(mem_static_pointer-12); else byte_element_3037=(byte_element_struct*)mem_static_malloc(12);
|
|
}
|
|
byte_element_struct *byte_element_3038=NULL;
|
|
if (!byte_element_3038){
|
|
if ((mem_static_pointer+=12)<mem_static_limit) byte_element_3038=(byte_element_struct*)(mem_static_pointer-12); else byte_element_3038=(byte_element_struct*)mem_static_malloc(12);
|
|
}
|
|
int32 *_FUNC_TYPNAME2TYP_LONG_T=NULL;
|
|
if(_FUNC_TYPNAME2TYP_LONG_T==NULL){
|
|
_FUNC_TYPNAME2TYP_LONG_T=(int32*)mem_static_malloc(4);
|
|
*_FUNC_TYPNAME2TYP_LONG_T=0;
|
|
}
|
|
int32 *_FUNC_TYPNAME2TYP_LONG_I=NULL;
|
|
if(_FUNC_TYPNAME2TYP_LONG_I==NULL){
|
|
_FUNC_TYPNAME2TYP_LONG_I=(int32*)mem_static_malloc(4);
|
|
*_FUNC_TYPNAME2TYP_LONG_I=0;
|
|
}
|
|
int64 fornext_value3040;
|
|
int64 fornext_finalvalue3040;
|
|
int64 fornext_step3040;
|
|
uint8 fornext_step_negative3040;
|
|
byte_element_struct *byte_element_3041=NULL;
|
|
if (!byte_element_3041){
|
|
if ((mem_static_pointer+=12)<mem_static_limit) byte_element_3041=(byte_element_struct*)(mem_static_pointer-12); else byte_element_3041=(byte_element_struct*)mem_static_malloc(12);
|
|
}
|
|
byte_element_struct *byte_element_3042=NULL;
|
|
if (!byte_element_3042){
|
|
if ((mem_static_pointer+=12)<mem_static_limit) byte_element_3042=(byte_element_struct*)(mem_static_pointer-12); else byte_element_3042=(byte_element_struct*)mem_static_malloc(12);
|
|
}
|
|
int32 *_FUNC_TYPNAME2TYP_LONG_HASHFOUND=NULL;
|
|
if(_FUNC_TYPNAME2TYP_LONG_HASHFOUND==NULL){
|
|
_FUNC_TYPNAME2TYP_LONG_HASHFOUND=(int32*)mem_static_malloc(4);
|
|
*_FUNC_TYPNAME2TYP_LONG_HASHFOUND=0;
|
|
}
|
|
qbs *_FUNC_TYPNAME2TYP_STRING_HASHNAME=NULL;
|
|
if (!_FUNC_TYPNAME2TYP_STRING_HASHNAME)_FUNC_TYPNAME2TYP_STRING_HASHNAME=qbs_new(0,0);
|
|
int32 *_FUNC_TYPNAME2TYP_LONG_HASHCHKFLAGS=NULL;
|
|
if(_FUNC_TYPNAME2TYP_LONG_HASHCHKFLAGS==NULL){
|
|
_FUNC_TYPNAME2TYP_LONG_HASHCHKFLAGS=(int32*)mem_static_malloc(4);
|
|
*_FUNC_TYPNAME2TYP_LONG_HASHCHKFLAGS=0;
|
|
}
|
|
int32 *_FUNC_TYPNAME2TYP_LONG_HASHRES=NULL;
|
|
if(_FUNC_TYPNAME2TYP_LONG_HASHRES==NULL){
|
|
_FUNC_TYPNAME2TYP_LONG_HASHRES=(int32*)mem_static_malloc(4);
|
|
*_FUNC_TYPNAME2TYP_LONG_HASHRES=0;
|
|
}
|
|
int32 *_FUNC_TYPNAME2TYP_LONG_HASHRESFLAGS=NULL;
|
|
if(_FUNC_TYPNAME2TYP_LONG_HASHRESFLAGS==NULL){
|
|
_FUNC_TYPNAME2TYP_LONG_HASHRESFLAGS=(int32*)mem_static_malloc(4);
|
|
*_FUNC_TYPNAME2TYP_LONG_HASHRESFLAGS=0;
|
|
}
|
|
int32 *_FUNC_TYPNAME2TYP_LONG_HASHRESREF=NULL;
|
|
if(_FUNC_TYPNAME2TYP_LONG_HASHRESREF==NULL){
|
|
_FUNC_TYPNAME2TYP_LONG_HASHRESREF=(int32*)mem_static_malloc(4);
|
|
*_FUNC_TYPNAME2TYP_LONG_HASHRESREF=0;
|
|
}
|
|
int32 *_FUNC_TYPNAME2TYP_LONG_I2=NULL;
|
|
if(_FUNC_TYPNAME2TYP_LONG_I2==NULL){
|
|
_FUNC_TYPNAME2TYP_LONG_I2=(int32*)mem_static_malloc(4);
|
|
*_FUNC_TYPNAME2TYP_LONG_I2=0;
|
|
}
|
|
long double *_FUNC_TYPNAME2TYP_FLOAT_V=NULL;
|
|
if(_FUNC_TYPNAME2TYP_FLOAT_V==NULL){
|
|
_FUNC_TYPNAME2TYP_FLOAT_V=(long double*)mem_static_malloc(32);
|
|
*_FUNC_TYPNAME2TYP_FLOAT_V=0;
|
|
}
|
|
int64 *_FUNC_TYPNAME2TYP_INTEGER64_V=NULL;
|
|
if(_FUNC_TYPNAME2TYP_INTEGER64_V==NULL){
|
|
_FUNC_TYPNAME2TYP_INTEGER64_V=(int64*)mem_static_malloc(8);
|
|
*_FUNC_TYPNAME2TYP_INTEGER64_V=0;
|
|
}
|
|
uint64 *_FUNC_TYPNAME2TYP_UINTEGER64_V=NULL;
|
|
if(_FUNC_TYPNAME2TYP_UINTEGER64_V==NULL){
|
|
_FUNC_TYPNAME2TYP_UINTEGER64_V=(uint64*)mem_static_malloc(8);
|
|
*_FUNC_TYPNAME2TYP_UINTEGER64_V=0;
|
|
}
|
|
byte_element_struct *byte_element_3044=NULL;
|
|
if (!byte_element_3044){
|
|
if ((mem_static_pointer+=12)<mem_static_limit) byte_element_3044=(byte_element_struct*)(mem_static_pointer-12); else byte_element_3044=(byte_element_struct*)mem_static_malloc(12);
|
|
}
|
|
byte_element_struct *byte_element_3045=NULL;
|
|
if (!byte_element_3045){
|
|
if ((mem_static_pointer+=12)<mem_static_limit) byte_element_3045=(byte_element_struct*)(mem_static_pointer-12); else byte_element_3045=(byte_element_struct*)mem_static_malloc(12);
|
|
}
|
|
int32 *_FUNC_TYPNAME2TYP_LONG_U=NULL;
|
|
if(_FUNC_TYPNAME2TYP_LONG_U==NULL){
|
|
_FUNC_TYPNAME2TYP_LONG_U=(int32*)mem_static_malloc(4);
|
|
*_FUNC_TYPNAME2TYP_LONG_U=0;
|
|
}
|
|
byte_element_struct *byte_element_3046=NULL;
|
|
if (!byte_element_3046){
|
|
if ((mem_static_pointer+=12)<mem_static_limit) byte_element_3046=(byte_element_struct*)(mem_static_pointer-12); else byte_element_3046=(byte_element_struct*)mem_static_malloc(12);
|
|
}
|
|
byte_element_struct *byte_element_3047=NULL;
|
|
if (!byte_element_3047){
|
|
if ((mem_static_pointer+=12)<mem_static_limit) byte_element_3047=(byte_element_struct*)(mem_static_pointer-12); else byte_element_3047=(byte_element_struct*)mem_static_malloc(12);
|
|
}
|
|
int64 fornext_value3049;
|
|
int64 fornext_finalvalue3049;
|
|
int64 fornext_step3049;
|
|
uint8 fornext_step_negative3049;
|