From 75e1b07eea1cb27417ac560cf0bec51945790fed Mon Sep 17 00:00:00 2001 From: Fellippe Heitor Date: Sun, 19 Jan 2020 23:36:46 -0300 Subject: [PATCH] Begins updating help files for v1.4. [ci-skip] --- internal/help/$ASSERTS.txt | 45 + internal/help/$COLOR.txt | 39 + internal/help/$NOPREFIX.txt | 25 + internal/help/ABS.txt | 2 +- internal/help/ASCII.txt | 4 +- internal/help/Arrays.txt | 4 +- internal/help/BYVAL.txt | 66 +- internal/help/COLOR.txt | 4 +- internal/help/DECLARE_DYNAMIC_LIBRARY.txt | 2 +- internal/help/DECLARE_LIBRARY.txt | 32 - internal/help/FIELD.txt | 2 +- internal/help/INKEY$.txt | 4 +- internal/help/Keyboard_scancodes.txt | 4 +- .../help/Keyword_Reference_-_Alphabetical.txt | 32 +- .../help/Keyword_Reference_-_By_usage.txt | 20 +- internal/help/Mathematical_Operations.txt | 4 +- internal/help/PLAY.txt | 4 +- internal/help/PRINT_(TCP%2FIP_statement).txt | 5 +- internal/help/QB64_FAQ.txt | 958 ++---------------- internal/help/RSET.txt | 2 +- internal/help/SGN.txt | 4 +- internal/help/SUB.txt | 6 +- internal/help/_ASSERT.txt | 47 + internal/help/_CAPSLOCK.txt | 19 + internal/help/_CAPSLOCK_(function).txt | 19 + internal/help/_COPYIMAGE.txt | 2 +- internal/help/_DEFLATE$.txt | 48 + internal/help/_DONTBLEND.txt | 7 +- internal/help/_INFLATE$.txt | 46 + internal/help/_MAPTRIANGLE.txt | 8 +- internal/help/_NUMLOCK.txt | 19 + internal/help/_NUMLOCK_(function).txt | 19 + internal/help/_OS$.txt | 1 - internal/help/_PUTIMAGE.txt | 5 +- internal/help/_READBIT.txt | 57 ++ internal/help/_RESETBIT.txt | 46 + internal/help/_SCROLLLOCK.txt | 19 + internal/help/_SCROLLLOCK_(function).txt | 19 + internal/help/_SETBIT.txt | 43 + internal/help/_SHR.txt | 2 +- internal/help/_TOGGLEBIT.txt | 46 + internal/help/_TRIM$.txt | 38 + internal/help/_glTexImage2D.txt | 4 +- internal/help/links.bin | 198 +--- 44 files changed, 763 insertions(+), 1217 deletions(-) create mode 100644 internal/help/$ASSERTS.txt create mode 100644 internal/help/$COLOR.txt create mode 100644 internal/help/$NOPREFIX.txt create mode 100644 internal/help/_ASSERT.txt create mode 100644 internal/help/_CAPSLOCK.txt create mode 100644 internal/help/_CAPSLOCK_(function).txt create mode 100644 internal/help/_DEFLATE$.txt create mode 100644 internal/help/_INFLATE$.txt create mode 100644 internal/help/_NUMLOCK.txt create mode 100644 internal/help/_NUMLOCK_(function).txt create mode 100644 internal/help/_READBIT.txt create mode 100644 internal/help/_RESETBIT.txt create mode 100644 internal/help/_SCROLLLOCK.txt create mode 100644 internal/help/_SCROLLLOCK_(function).txt create mode 100644 internal/help/_SETBIT.txt create mode 100644 internal/help/_TOGGLEBIT.txt create mode 100644 internal/help/_TRIM$.txt diff --git a/internal/help/$ASSERTS.txt b/internal/help/$ASSERTS.txt new file mode 100644 index 000000000..89546426b --- /dev/null +++ b/internal/help/$ASSERTS.txt @@ -0,0 +1,45 @@ +The [[$ASSERTS]] metacommand enables debug tests with the [[_ASSERT]] macro. + + +{{PageSyntax}} +:[[$ASSERTS]] +:[[$ASSERTS]]:CONSOLE + + +{{PageDescription}} +* If an error message is passed to the [[_ASSERT]] statement, it is displayed in the console window if [[$ASSERTS|$ASSERTS:CONSOLE]] is used. + + +==Availability== +* '''Version 1.4 and up'''. + + +{{PageExamples}} +''Example:'' Adding test checks for parameter inputs in a function. +{{CodeStart}} +{{Cl|$ASSERTS}}:CONSOLE + +{{Cl|DO}} + a = {{Cl|INT}}({{Cl|RND}} * 10) + b$ = myFunc$(a) + {{Cl|PRINT}} a, , b$ + {{Cl|_LIMIT}} 3 +{{Cl|LOOP}} {{Cl|UNTIL}} {{Cl|_KEYHIT}} + +{{Cl|FUNCTION}} myFunc$ (value {{Cl|AS}} {{Cl|SINGLE}}) + {{Cl|_ASSERT}} value > 0, "Value cannot be zero" + {{Cl|_ASSERT}} value <= 10, "Value cannot exceed 10" + + {{Cl|IF}} value > 1 {{Cl|THEN}} plural$ = "s" + myFunc$ = {{Cl|STRING$}}(value, "*") + {{Cl|STR$}}(value) + " star" + plural$ + " :-)" +{{Cl|END}} {{Cl|FUNCTION}} +{{CodeEnd}} + + +{{PageSeeAlso}} +* [[_ASSERT]] +* [[$CHECKING]] +* [[Relational Operations]] + + +{{PageNavigation}} diff --git a/internal/help/$COLOR.txt b/internal/help/$COLOR.txt new file mode 100644 index 000000000..43b6869bb --- /dev/null +++ b/internal/help/$COLOR.txt @@ -0,0 +1,39 @@ +[[$COLOR]] is a metacommand that adds named color [[CONST|constants]] in a program. + + +{{PageSyntax}} +: [[$COLOR]]:0 +: [[$COLOR]]:32 + + +{{PageDescription}} +* [[$COLOR]]:0 adds [[CONST|constants]] for colors 0-15. The actual constant names can be found in the file '''source/utilities/color0.bi'''. +* [[$COLOR]]:32 adds [[CONST|constants]] for 32-bit colors, similar to HTML color names. The actual constant names can be found in the file '''source/utilities/color32.bi'''. +* [[$COLOR]] is a shorthand to manually using [[$INCLUDE]] pointing to the files listed above. + + +{{PageExamples}} +''Example 1:'' Adding named color constants for SCREEN 0: +{{CodeStart}} +{{Cl|$COLOR}}:0 +{{Cl|COLOR}} BrightWhite, Red +{{Cl|PRINT}} "Bright white on red." + {{CodeEnd}} + + +''Example 2:'' Adding named color constants for 32-bit modes: +{{CodeStart}} +{{Cl|SCREEN}} {{Cl|_NEWIMAGE}}(640, 400, 32) +{{Cl|$COLOR}}:32 +{{Cl|COLOR}} CrayolaGold, DarkCyan +{{Cl|PRINT}} "CrayolaGold on DarkCyan." + {{CodeEnd}} + + +{{PageSeeAlso}} +* [[COLOR]], [[SCREEN]] +* [[_NEWIMAGE]], [[$INCLUDE]] +* [[Metacommand]] + + +{{PageNavigation}} diff --git a/internal/help/$NOPREFIX.txt b/internal/help/$NOPREFIX.txt new file mode 100644 index 000000000..eda082ddb --- /dev/null +++ b/internal/help/$NOPREFIX.txt @@ -0,0 +1,25 @@ +The [[$NOPREFIX]] metacommand allows all QB64 functions and statements to be used without the leading underscore (_). + + +{{PageSyntax}} +:[[$NOPREFIX]] + + +{{PageDescription}} +* QB64-specific keywords are by default prefixed with an underscore, in order to differentiate them from legacy keywords inherited from QBasic/QuickBASIC 4.5. +* The convention exists in order to allow older code to be loaded and compiled in QB64 without naming conflicts with existing variables or constants. +* If you are writing new code with QB64, and not importing code from QBasic/QuickBASIC 4.5, [[$NOPREFIX]] allows you to reduce typing by not having to use underscores in modern keywords. +* When [[$NOPREFIX]] is used, QB64 keywords can be used both with or without the leading underscore, so that both [[_DISPLAY]] and [[_DISPLAY|DISPLAY]] are valid in the same program, for example. +* [[$NOPREFIX]] must be the first line in a program. + + +==Availability== +* '''Version 1.4 and up'''. + + +{{PageSeeAlso}} +* [[Keyword Reference - Alphabetical]] +* [[Metacommand]] + + +{{PageNavigation}} diff --git a/internal/help/ABS.txt b/internal/help/ABS.txt index cce9749aa..b76ae5e51 100644 --- a/internal/help/ABS.txt +++ b/internal/help/ABS.txt @@ -1,4 +1,4 @@ -The [[ABS]] function returns the the unsigned numerical value of a variable or literal value. +The [[ABS]] function returns the unsigned numerical value of a variable or literal value. {{PageSyntax}} diff --git a/internal/help/ASCII.txt b/internal/help/ASCII.txt index 2c428de56..24155fe08 100644 --- a/internal/help/ASCII.txt +++ b/internal/help/ASCII.txt @@ -235,9 +235,7 @@ DO {{WhiteStart}}' '''ASCII Keyboard Codes''' ' '''' Esc F1 F2 F3 F4 F5 F6 F7 F8 F9 F10 F11 F12 Sys ScL Pause''' -' 27 +59 +60 +61 +6 -4000 -2 +63 +64 +65 +66 +67 +68 +133 +134 - - - +' 27 +59 +60 +61 +62 +63 +64 +65 +66 +67 +68 +133 +134 - - - '''' `~ 1! 2@ 3# 4$ 5% 6^ 7& 8* 9( 0) -_ =+ BkSp Ins Hme PUp NumL / * -''' ' 126 33 64 35 36 37 94 38 42 40 41 95 43 8 +82 +71 +73 - 47 42 45 ''' 96 49 50 51 52 53 54 55 56 57 48 45 61'' diff --git a/internal/help/Arrays.txt b/internal/help/Arrays.txt index b857e5064..04395dc6b 100644 --- a/internal/help/Arrays.txt +++ b/internal/help/Arrays.txt @@ -253,9 +253,7 @@ Arrays can be sorted numerically or alphabetically using various sorting routine Since variables and arrays exist in memory, data is lost when a program closes. To preserve program data you must either create a permanent [[DATA]] field or save the data to files. -The next time a program is used, it can [[OPEN]] that file and quickly restore all of the array data using a loop or '''QB64''' can [[GET]] the entire file's data in one GET. Use [[LINE INPUT (file statement)|LINE INPUT]] # to set the array sizes by counting the number of data rows in a file if you used a [[WRITE]] '''CSV'''(comma separated values) or a [[PRINT (file statement)|PRINT]] # sequencial file. The number of records in a [[TYPE]] or [[FIELD]] defined [[RANDOM]] access file can be found by dividing the record size into the [[LOF]]. You may want -3640 - to make the array slightly larger for new entries. +The next time a program is used, it can [[OPEN]] that file and quickly restore all of the array data using a loop or '''QB64''' can [[GET]] the entire file's data in one GET. Use [[LINE INPUT (file statement)|LINE INPUT]] # to set the array sizes by counting the number of data rows in a file if you used a [[WRITE]] '''CSV'''(comma separated values) or a [[PRINT (file statement)|PRINT]] # sequencial file. The number of records in a [[TYPE]] or [[FIELD]] defined [[RANDOM]] access file can be found by dividing the record size into the [[LOF]]. You may want to make the array slightly larger for new entries. <center>[[#toc|Return to Top]]</center> diff --git a/internal/help/BYVAL.txt b/internal/help/BYVAL.txt index 0471db197..b276657e9 100644 --- a/internal/help/BYVAL.txt +++ b/internal/help/BYVAL.txt @@ -1,65 +1 @@ -The [[BYVAL]] statement is used to pass a numerical parameter's value with procedures made in other programming languages. - - -{{PageSyntax}} -: SUB ProcedureName ([[BYVAL]] {{Parameter|variable1}}, [[BYVAL]] {{Parameter|variable2}}) - - -{{PageDescription}} -* '''QB64''' can only use BYVAL in [[DECLARE LIBRARY]] procedures that add DLL or Operating System API functions. -* Supported with [[DECLARE LIBRARY]] [[SUB]] and [[FUNCTION]] procedure declarations when passing '''numerical values only'''. -* Passing numerical values BYVAL assures that the original numerical variable value is not changed by another procedure. -* Use [[parenthesis]] around program [[SUB]] or [[FUNCTION]] parameters passed '''by value'''. Ex: ''CALL Procedure ((x&), (y&))'' - - -{{PageErrors}} -* '''Do not use BYVAL before [[STRING]] or [[TYPE]] variables or in regular prograam [[SUB]] or [[FUNCTION]] parameters.''' -* '''NOTE: Many QBasic keywords can be used as variable names if they are created as [[STRING]]s using the suffix '''$'''. You cannot use them without the suffix, use a numerical suffix or use [[DIM]], [[REDIM]], [[_DEFINE]], [[BYVAL]] or [[TYPE]] variable [[AS]] statements.''' - - -==QBasic/QuickBASIC== -* QBasic versions below 7 do not use BYVAL unless the [[SUB]] program referred to is from a different programming language. -* PDS versions can use BYVAL as it is intended in any [[SUB]] or [[FUNCTION]] parameters. -* BYVAL could also be used with [[ABSOLUTE]] in QBasic. - - -{{PageExamples}} -''Example 1:'' BYVAL is used to preserve the values sent to an external procedure so they remain the same after they are used: -{{CodeStart}} '' '' -{{Cl|DECLARE LIBRARY}} "SDL" - {{Cl|SUB}} MouseMove {{Cl|ALIAS}} SDL_WarpMouse ({{Cl|BYVAL}} xoffset&, {{Cl|BYVAL}} yoffset&) -{{Cl|DECLARE LIBRARY|END DECLARE}} -{{CodeEnd}} -: ''Note:'' The DLL call above uses the SDL library, which was included with QB64 up to version 0.954. Won't work with '''version 1.000 and up'''. - - -''Example 2:'' Passing parameters "by value" using [[parenthesis|brackets]] when calling a [[SUB]] or [[FUNCTION]] in QBasic or QB64. -{{CodeStart}} '' '' -{{Cl|CALL}} MySUB (a%, (b%), (c%)) 'CALL SUB b and c stay 0 after sub - -MySUB a%, b%, (c%) 'call SUB again without CALL only c stays 0 after sub - -{{Cl|PRINT}} "After procedures: "; a%, b%, c% - -{{Cl|SUB}} MySUB (a%, b%, c%) -a% = a% + 1: b% = b% + 1: c% = c% + 1 -{{Cl|PRINT}} "Inside procedure: "; a%, b%, c% -{{Cl|END SUB}} '' '' -{{CodeEnd}} -{{OutputStart}} -Inside procedure: 1 1 1 -Inside procedure: 2 1 1 -After procedures: 2 1 0 -{{OutputEnd}} -:''Explanation:'' Both SUB calls pass just the '''values''' of b% and c% to the procedure. The first variable, a%, is passed by '''reference''' (the default) so the value was changed by the SUB procedure. Brackets can only be used in the [[CALL]] or function reference. - - -{{PageSeeAlso}} -* [[DECLARE LIBRARY]] -* [[SUB]], [[FUNCTION]] -* [[CALL]], [[ALIAS]] -* [[DECLARE]], [[DECLARE (non-BASIC statement)]] {{text|(not used by QB64)}} -* [[Libraries#C++_Variable_Types|C++ Variable Types]] - - -{{PageNavigation}} +#REDIRECT [[DECLARE LIBRARY]] diff --git a/internal/help/COLOR.txt b/internal/help/COLOR.txt index 891dea6ed..b8d3eb248 100644 --- a/internal/help/COLOR.txt +++ b/internal/help/COLOR.txt @@ -202,9 +202,7 @@ text$ = "HelloWorld" ''Example 8:'' Changing light gray text in [[SCREEN]] 0 to a 32 bit custom color using a [[LONG]] HTML hexadecimal value: -{{CodeStart -2b54 -}} '' '' +{{CodeStart}} '' '' {{Cl|COLOR}} 7 {{Cl|PRINT}} "Color 7 is gray" K$ = {{Cl|INPUT$}}(1) diff --git a/internal/help/DECLARE_DYNAMIC_LIBRARY.txt b/internal/help/DECLARE_DYNAMIC_LIBRARY.txt index 0430a3ed8..bdb2cbfa3 100644 --- a/internal/help/DECLARE_DYNAMIC_LIBRARY.txt +++ b/internal/help/DECLARE_DYNAMIC_LIBRARY.txt @@ -33,7 +33,7 @@ {{PageExamples}} -''Example 1:'' This example plays Midi files using the ''playmidi32.dll'' documented here: [http://libertybasicuniversity.com/lbnews/nl110/midi3.htm Liberty Basic University].                         Download the following DLL file to your main QB64 folder: [http://www.qb64.net/playmidi32.dll PlayMidi32.dll] +''Example 1:'' This example plays Midi files using the ''playmidi32.dll'' documented here: [http://libertybasicuniversity.com/lbnews/nl110/midi3.htm Liberty Basic University]. Download the following DLL file to your main QB64 folder: [https://www.qb64.org/resources/Playmidi32.dll PlayMidi32.dll] {{CodeStart}} '' '' {{Cl|DECLARE DYNAMIC LIBRARY}} "playmidi32" {{Cl|FUNCTION}} PlayMIDI& (filename {{Cl|AS}} {{Cl|STRING}}) diff --git a/internal/help/DECLARE_LIBRARY.txt b/internal/help/DECLARE_LIBRARY.txt index 6a7578b3f..24fc3861b 100644 --- a/internal/help/DECLARE_LIBRARY.txt +++ b/internal/help/DECLARE_LIBRARY.txt @@ -86,37 +86,6 @@ MouseMove 200, 200 '' '' : '''Note: What libraries are or aren't automatically used in the linking process is not formally defined, nor is it guaranteed to stay that way in future versions of QB64.''' -''Example 3:'' For this next example, download the file 'add.lib' and place it in you QB64 folder: http://www.qb64.net/add.lib -{{CodeStart}} '' '' -{{Cl|DECLARE LIBRARY}} "add" - {{Cl|FUNCTION}} addtwo& ({{Cl|BYVAL}} value&) -{{Cl|END}} DECLARE -PRINT addtwo(1) '' '' -{{CodeEnd}} -:''Explanation:'' Here, we tell QB64 to link to '''add.lib''' (QB64 searches for '''add.lib''', '''add.a''', and '''add.o''' in that order and uses the first that it finds). The function '''addtwo''' exists inside the library file '''add.lib''' but isn't defined anywhere else. QB64 creates the C definition for the function '''addtwo''' so that it can be called from our QB64 code. - -: '''Note: If the C function definition auto-created by QB64 does not exactly match the definition in the library file, it will not work. As a result of this it is often better to provide the C function definitions in the form of a C header file, such as in the following example.''' - - -''Example 4:'' NTport is a commercial library hosted at http://www.zealsoftstudio.com/ntport/, but it does provide an evaluation version (it has a 3 second wait pop-up window) which we will use here. You don't need to download NTport, just download the following 3 files and put them in your QB64 folder: -<center>[http://www.qb64.net/ntport/ntport.lib NTport.lib]            [http://www.qb64.net/ntport/ntport.h NTport.h]               [http://www.qb64.net/ntport/ntport.dll Ntport.dll]</center> -:'''IMPORTANT:''' The DLL is loaded automatically by the static library, we are not linking directly to the DLL, we are '''static linking''' (NOT directly or dynamically linking). This is an important concept to understand! -{{CodeStart}} -DECLARE LIBRARY "ntport" - FUNCTION GetLPTPortAddress% (BYVAL PortNo%) -END DECLARE -PRINT "&H" + HEX$(GetLPTPortAddress%(1)) -{{CodeEnd}} -:''Explanation:'' DECLARE LIBRARY also searches for C header files with a '''.h''' extension. So in this case it is using the header '''ntport.h''' and linking with '''ntport.lib''' just by specifying "NTPORT". The C function definitions are stored in '''ntport.h''' so even if our QB64 functions don't exactly match (eg. LONG instead of INTEGER) it will still work. - -:If you look inside ''''ntport.h'''' you'll find the following line containing the C function definition of the command we used: -{{TextStart}} WORD WINAPI GetLPTPortAddress(WORD PortNo); -{{TextEnd}} - - -<center>Galleon's '''OpenGL''' Library with demo program download: http://www.qb64.net/gl_package.zip</center> - - <center>'''QB64 version 1.000 and up produce standalone executables. External DLL files must be distributed with your program.'''</center> <center>'''Note: QB64 versions prior to 1.000 require all default DLL files to either be with the program or in the C:\WINDOWS\SYSTEM32 folder.'''</center> @@ -130,7 +99,6 @@ PRINT "&H" + HEX$(GetLPTPortAddress%(1)) * [[OpenGL Libraries]], [[SDL Libraries]] * [[SFML Libraries]] * [[SQL Client]] -* [http://www.qb64.net/forum/index.php?topic=11810.msg102081#msg102081 DECLARE LIBRARY and C++ Variable Types] {{PageNavigation}} diff --git a/internal/help/FIELD.txt b/internal/help/FIELD.txt index 14ad01d75..7d99cc3fd 100644 --- a/internal/help/FIELD.txt +++ b/internal/help/FIELD.txt @@ -2,7 +2,7 @@ The [[FIELD]] statement creates a [[STRING]] type definition for a [[RANDOM|rand {{PageSyntax}} -: [[FIELD]] [#]{{Parameter|fileNumber&}} {{Parameter|fieldWidth1%}} AS {{Parameter|variable1$}}[, {{Parameter|fieldWidthN%}} AS {{Parameter|variableN$}}] +: [[FIELD]] [#]{{Parameter|fileNumber&}}, {{Parameter|fieldWidth1%}} AS {{Parameter|variable1$}}[, {{Parameter|fieldWidthN%}} AS {{Parameter|variableN$}}] {{PageDescription}} diff --git a/internal/help/INKEY$.txt b/internal/help/INKEY$.txt index e01ac431d..3f4254e1f 100644 --- a/internal/help/INKEY$.txt +++ b/internal/help/INKEY$.txt @@ -198,9 +198,7 @@ DO ''Example 7:'' Creating upper [[ASCII]] characters in a QB program using '''Alt +''' three number keys: {{CodeStart}} DO - A$ = "": {{Cl| -2a79 -WHILE}} A$ = "": A$ = {{Cl|INKEY$}}: {{Cl|WEND}} + A$ = "": {{Cl|WHILE}} A$ = "": A$ = {{Cl|INKEY$}}: {{Cl|WEND}} {{Cl|IF...THEN|IF}} {{Cl|LEN}}(A$) = 2 {{Cl|THEN}} '2 byte INKEY$ return B$ = {{Cl|RIGHT$}}(A$, 1) 'read second byte b% = {{Cl|ASC}}(B$) 'read second byte code diff --git a/internal/help/Keyboard_scancodes.txt b/internal/help/Keyboard_scancodes.txt index bd4765886..235b896d9 100644 --- a/internal/help/Keyboard_scancodes.txt +++ b/internal/help/Keyboard_scancodes.txt @@ -144,9 +144,7 @@ ' '''CapL A S D F G H J K L ;: '" Enter 4/◄- 5 6/-► E''' ' 391 203 217 202 208 205 206 196 193 194 145 141 167 426 431 432 '''n''' ' '''Shift Z X C V B N M ,< .> /? Shift ▲ 1/End 2/▼ 3/PD t''' -' 390 212 222 201 224 204 200 199 -4000 - 130 136 133 389 443 427 428 432 '''e''' +' 390 212 222 201 224 204 200 199 130 136 133 389 443 427 428 432 '''e''' ' '''Ctrl Win Alt Spacebar Alt Win Menu Ctrl ◄- ▼ -► 0/Insert ./Del r''' ' 412 413 410 182 409 414 405 411 442 444 441 86 420 421 ' diff --git a/internal/help/Keyword_Reference_-_Alphabetical.txt b/internal/help/Keyword_Reference_-_Alphabetical.txt index 26c450765..4fba26604 100644 --- a/internal/help/Keyword_Reference_-_Alphabetical.txt +++ b/internal/help/Keyword_Reference_-_Alphabetical.txt @@ -1,5 +1,5 @@ __NOTOC__ -<div id="toc"><p style="text-align: center"><br> '''Alphabetical QB64 Keyword Listings''' <br><br>     '''QB 64:'''  [[#uA|_A]] [[#uB|_B]] [[#uC|_C]] [[#uD|_D]] [[#uE|_E]] [[#uF|_F]] [[#uG|_G]] [[#uH|_H]] [[#uI|_I]] [[#uK|_K]] [[#uL|_L]] [[#uM|_M]] [[#uN|_N]] [[#uO|_O]] [[#uP|_P]] [[#uR|_R]] [[#uS|_S]] [[#uT|_T]] [[#uU|_U]] [[#uV|_V]] [[#uW|_W]]                <br><br>'''QBasic:'''  [[#A|A]]   [[#B|B]]   [[#C|C]]   [[#D|D]]   [[#E|E]]    [[#F|F]]   [[#G|G]]   [[#H|H]]    [[#I| I]]    [[#K|K]]   [[#L|L]]   [[#M|M]]   [[#N|N]]    [[#O|O]]   [[#P|P]]    [[#R|R]]   [[#S|S]]    [[#T|T]]   [[#U|U]]   [[#V|V]]   [[#W|W]]   [[#X|X]]   <br><br>'''OpenGL:'''   [[#glA|A]]    [[#glB|B]]    [[#glC|C]]    [[#glD|D]]    [[#glE|E]]     [[#glF|F]]    [[#glG|G]]    [[#glH|H]]    [[#glI| I  ]]   [[#glL|L]]    [[#glM|M]]    [[#glN|N]]     [[#glO|O]]    [[#glP|P]]     [[#glR|R]]    [[#glS|S]]     [[#glT|T]]    [[#glV|V]]       <br><br> [[#symbols|Symbols]] '''   -   ''' [[#references|References]]<br><br>[[Full Story|{{small|Menu Created by Cyperium}} ]]</p></div> +<div id="toc"><p style="text-align: center"><br> '''Alphabetical QB64 Keyword Listings''' <br><br>     '''QB 64:'''  [[#uA|_A]] [[#uB|_B]] [[#uC|_C]] [[#uD|_D]] [[#uE|_E]] [[#uF|_F]] [[#uG|_G]] [[#uH|_H]] [[#uI|_I]] [[#uK|_K]] [[#uL|_L]] [[#uM|_M]] [[#uN|_N]] [[#uO|_O]] [[#uP|_P]] [[#uR|_R]] [[#uS|_S]] [[#uT|_T]] [[#uU|_U]] [[#uV|_V]] [[#uW|_W]]                <br><br>'''QBasic:'''  [[#A|A]]   [[#B|B]]   [[#C|C]]   [[#D|D]]   [[#E|E]]    [[#F|F]]   [[#G|G]]   [[#H|H]]    [[#I| I]]    [[#K|K]]   [[#L|L]]   [[#M|M]]   [[#N|N]]    [[#O|O]]   [[#P|P]]    [[#R|R]]   [[#S|S]]    [[#T|T]]   [[#U|U]]   [[#V|V]]   [[#W|W]]   [[#X|X]]   <br><br>'''OpenGL:'''   [[#glA|A]]    [[#glB|B]]    [[#glC|C]]    [[#glD|D]]    [[#glE|E]]     [[#glF|F]]    [[#glG|G]]    [[#glH|H]]    [[#glI| I  ]]   [[#glL|L]]    [[#glM|M]]    [[#glN|N]]     [[#glO|O]]    [[#glP|P]]     [[#glR|R]]    [[#glS|S]]     [[#glT|T]]    [[#glV|V]]       <br><br> [[#symbols|Symbols]] '''   -   ''' [[#references|References]]<br><br>{{small|Menu Created by Cyperium}}</p></div> @@ -41,6 +41,8 @@ __NOTOC__ * [[Mathematical_Operations|_ARCSEC]] (function) {{text|is the inverse function of the secant. http://mathworld.wolfram.com/InverseSecant.html}} * [[_ASIN]] (function) {{text|Returns the principal value of the arc sine of x, expressed in radians.}} * [[_ASINH]] (function) {{text|Returns the arc hyperbolic sine of x, expressed in radians.}} +* [[_ASSERT]] (statement) {{text|Performs debug tests.}} +* [[$ASSERTS]] (metacommand) {{text|Enables the [[_ASSERT]] macro}} * [[_ATAN2]] (function) {{text|Returns the principal value of the [[ATN|arc tangent]] of y/x, expressed in radians.}} * [[_ATANH]] (function) {{text|Returns the arc hyperbolic tangent of x, expressed in radians.}} * [[_AUTODISPLAY]] (statement) {{text|enables the automatic display of the screen image changes previously disabled by [[_DISPLAY]].}} @@ -69,6 +71,8 @@ __NOTOC__ <div id = "uC">_C</div> +* [[_CAPSLOCK (function)]] {{text|returns -1 when Caps Lock is on}} +* [[_CAPSLOCK]] (statement) {{text|sets Caps Lock key state}} * [[$CHECKING]] (QB64 C++ [[Metacommand]]) {{text|turns event error checking OFF or ON.}} * [[_CEIL]] (function) {{text|Rounds x upward, returning the smallest integral value that is not less than x.}} * [[_CLEARCOLOR (function)]] {{text|returns the current transparent color of an image.}} @@ -78,6 +82,7 @@ __NOTOC__ * [[_CLIPBOARD$ (statement)]] {{text|sets and overwrites the [[STRING]] value in the operating system's clipboard.}} * [[_CLIPBOARDIMAGE (function)]] {{text|pastes an image from the clipboard into a new QB64 image in memory.}} * [[_CLIPBOARDIMAGE]] {{text|(statement) copies a valid QB64 image to the clipboard.}} +* [[$COLOR]] (metacommand) {{text|includes named color constants in a program}} * [[_COMMANDCOUNT]] (function) {{text|returns the number of arguments passed to the compiled program from the command line.}} * [[_CONNECTED]] (function) {{text|returns the status of a TCP/IP connection handle.}} * [[_CONNECTIONADDRESS$]] (TCP/IP function) {{text|returns a connected user's STRING IP address value using the handle.}} @@ -109,6 +114,7 @@ __NOTOC__ * [[DECLARE DYNAMIC LIBRARY|DECLARE DYNAMIC LIBRARY (QB64 statement)]] {{text|declares DYNAMIC, CUSTOMTYPE or STATIC library (DLL) [[SUB]] or [[FUNCTION]].}} * [[_DEFAULTCOLOR]] (function) {{text|returns the current default text color for an image handle or page.}} * [[_DEFINE]] (statement) {{text|defines a range of variable names according to their first character as a data type.}} +* [[_DEFLATE$]] (function) {{text|compresses a string}} * [[_DELAY]] (statement) {{text|suspends program execution for a [[SINGLE]] number of seconds.}} * [[_DEPTHBUFFER]] (statement) {{text|enables, disables, locks or clears depth buffering.}} * [[_DESKTOPHEIGHT]] (function) {{text|returns the height of the desktop (not program window).}} @@ -131,9 +137,7 @@ __NOTOC__ ---- -<div id -4000 - = "uE">_E</div> +<div id = "uE">_E</div> * [[_ECHO]] (statement) {{text|used in conjunction with $IF for the precompiler.}} * [[$ELSE]] (Pre-Compiler [[Metacommand]]) {{text|used in conjunction with $IF for the precompiler.}} * [[$ELSEIF]] (Pre-Compiler [[Metacommand]]) {{text|used in conjunction with $IF for the precompiler.}} @@ -189,6 +193,7 @@ __NOTOC__ * [[_ICON]] (statement) {{text|designates a [[_LOADIMAGE]] image file handle to be used as the program's icon or loads the embedded icon (see [[$EXEICON]]).}} * [[_INCLERRORFILE$]] {function) {{text|returns the name of the original source code $INCLUDE module that caused the most recent error.}} * [[_INCLERRORLINE]] (function) {{text|returns the line number in an included file that caused the most recent error.}} +* [[_INFLATE$]] (function) {{text|decompresses a string}} * [[_INSTRREV]] (function) {{text|allows searching for a substring inside another string, but unlike [[INSTR]] it returns the last occurrence instead of the first one.}} * [[_INTEGER64]] (&& numerical type) {{text|can hold whole numerical values from -9223372036854775808 to 9223372036854775807.}} @@ -257,6 +262,9 @@ __NOTOC__ <div id = "uN">_N</div> * [[_NEWIMAGE]] (function) {{text|creates a designated size program [[SCREEN]] or page image and returns a handle value.}} +* [[$NOPREFIX]] (metacommand) {{text|allows QB64-specific keywords to be used without the underscore prefix.}} +* [[_NUMLOCK (function)]] {{text|returns -1 when Num Lock is on}} +* [[_NUMLOCK]] (statement) {{text|sets Num Lock key state}} <p style="text-align: center">([[#toc|Return to Table of Contents]])</p> @@ -299,6 +307,8 @@ __NOTOC__ * [[_R2G]] (function) {{text|converts radians to gradient angle values.}} * [[_RED]] (function) {{text|function returns the palette or the red component intensity of a 32-bit image color.}} * [[_RED32]] (function) {{text|returns the red component intensity of a 32-bit color value.}} +* [[_READBIT]] (function) {{text|returns the state of the specified bit of an integer variable.}} +* [[_RESETBIT]] (function) {{text|is used to set the specified bit of an integer variable to 0.}} * [[$RESIZE]] ([[Metacommand]]) {{text|used with ON allows a user to resize the program window where OFF does not.}} * [[_RESIZE]] (statement) {{text|sets resizing of the window ON or OFF and sets the method as _STRETCH or _SMOOTH.}} * [[_RESIZE (function)]] {{text|returns -1 when a program user wants to resize the program screen.}} @@ -331,8 +341,11 @@ __NOTOC__ * [[_SCREENSHOW]] (statement) {{text|displays the program window after it has been hidden by [[_SCREENHIDE]].}} * [[_SCREENX]] (function) {{text|returns the program window's upper left corner horizontal position on the desktop.}} * [[_SCREENY]] (function) {{text|returns the program window's upper left corner vertical position on the desktop.}} +* [[_SCROLLLOCK (function)]] {{text|returns -1 when Scroll Lock is on}} +* [[_SCROLLLOCK]] (statement) {{text|sets Scroll Lock key state}} * [[_SETALPHA]] (statement) {{text|sets the alpha channel transparency level of some or all of the pixels of an image.}} +* [[_SETBIT]] (function) {{text|is used to set the specified bit of an integer variable to 1.}} * [[_SHELLHIDE]] (function) {{text|returns the code sent by a program exit using [[END]] or [[SYSTEM]] followed by an [[INTEGER]] value.}} * [[_SHL]] (function) {{text|used to shift the bits of a numerical value to the left}} * [[_SHR]] (function) {{text|used to shift the bits of a numerical value to the right.}} @@ -375,6 +388,7 @@ __NOTOC__ * [[Mathematical_Operations|_TANH]] (function) {{text|Returns the hyperbolic tangent of x radians.}} * [[_TITLE]] (statement) {{text|sets the program title [[STRING|string]] value.}} * [[_TITLE$]] (function) {{text|gets the program title [[STRING|string]] value.}} +* [[_TOGGLEBIT]] (function) {{text|is used to toggle the specified bit of an integer variable from 1 to 0 or 0 to 1.}} * [[_TOTALDROPPEDFILES]] (function) {{text| returns the number of items (files or folders) dropped in a program's window after [[_ACCEPTFILEDROP]] is enabled.}} * [[_TRIM$]] (function) {{text|shorthand to [[LTRIM$]]([[RTRIM$]]("text"))}} @@ -590,9 +604,7 @@ __NOTOC__ <div id = "K">K</div> -* [[KEY n]] (statement) {{text|used with [[ON KEY(n)]] -4000 -events to assign a "softkey" string to a key or create a user defined key.}} +* [[KEY n]] (statement) {{text|used with [[ON KEY(n)]] events to assign a "softkey" string to a key or create a user defined key.}} * [[KEY(n)]] (statement) {{text|used with [[ON KEY(n)]] events to assign, enable, disable or suspend event trapping.}} * [[KEY LIST]] (statement) {{text|lists the 12 Function key soft key string assignments going down left side of screen.}} * [[KILL]] (statement) {{text|deletes the specified file without a warning. Remove empty folders with [[RMDIR]].}} @@ -818,8 +830,6 @@ events to assign a "softkey" string to a key or create a user defined key.}} <div id = "W">W</div> * [[WAIT]] (statement) {{text|waits until a vertical retrace is started or a [[SCREEN|screen]] draw ends.}} * [[WEND]] (statement) {{text|the bottom end of a [[WHILE...WEND]] loop.}} - -4000 * [[WHILE]] (condition) {{text|evaluates a [[DO...LOOP]] or [[WHILE...WEND]] condition until it is False.}} * [[WHILE...WEND]] (statement) {{text|sets a recursive procedure loop that can only be exited using the [[WHILE]] conditional argument.}} * [[WIDTH]] (statement) {{text|sets the text column and row sizes in several [[SCREEN]] modes.}} @@ -1139,9 +1149,7 @@ events to assign a "softkey" string to a key or create a user defined key.}} * [[_glRasterPos4dv]] (statement) {{text|OpenGL command}} <p style="text-align: center">([[#toc|Return to Table of Contents]])</p> * [[_glRasterPos4f]] (statement) {{text|OpenGL command}} -* [[_glRasterPos4fv] -4000 -] (statement) {{text|OpenGL command}} +* [[_glRasterPos4fv]] (statement) {{text|OpenGL command}} * [[_glRasterPos4i]] (statement) {{text|OpenGL command}} * [[_glRasterPos4iv]] (statement) {{text|OpenGL command}} * [[_glRasterPos4s]] (statement) {{text|OpenGL command}} diff --git a/internal/help/Keyword_Reference_-_By_usage.txt b/internal/help/Keyword_Reference_-_By_usage.txt index cfdf8dda3..b0ed29773 100644 --- a/internal/help/Keyword_Reference_-_By_usage.txt +++ b/internal/help/Keyword_Reference_-_By_usage.txt @@ -168,9 +168,7 @@ Keywords beginning with an _underscore can only be compiled in QB64. * [[DEFSTR]] (statement) {{text|defines undefined variable starting letters AS [[STRING]] variables instead of the [[SINGLE]] type default.}} * [[DIM]] {{text|defines a variable or size a [[$STATIC|static]] array and can define the type of value it returns.}} * [[DOUBLE]] {# numerical [[TYPE|type]]) {{text|an 8 byte floating decimal variable type with numerical values up to 15 decimal places.}} -* [[INTEGER]] {% numerical [[TYPE|type]]) {{text|a two byte variable type -4000 - with values from -32768 to 32767. [[_UNSIGNED|Unsigned]] to 65535.}} +* [[INTEGER]] {% numerical [[TYPE|type]]) {{text|a two byte variable type with values from -32768 to 32767. [[_UNSIGNED|Unsigned]] to 65535.}} * [[LONG]] {& numerical [[TYPE|type]]) {{text|Integer values can be from -2147483648 to 2147483647. [[_UNSIGNED]] values to 4294967295.}} * [[OPTION BASE]] (statement) {{text|sets the default starting index of an [[arrays|array]] to 0 or 1.}} * [[REDIM]] {{text|defines and sizes a [[$DYNAMIC|dynamic]](changeable) array and can define the type of value returned.}} @@ -424,9 +422,7 @@ The following table describes the error codes that are reported by the '''QB64'' * [[CLOSE]] (statement) {{text|closes a specified file or all open files.}} * [[EOF]] (file function) {{text|returns -1 when the end of a file has been read.}} * [[FIELD]] (statement) {{text|creates a [[STRING]] type definition for a random-access file buffer.}} -* [[FILEATTR]] (function) {{text|can return a file's current file mode o -4000 -r DOS handle number.}} +* [[FILEATTR]] (function) {{text|can return a file's current file mode or DOS handle number.}} * [[FILES]] (statement) {{text|displays a specified list of files.}} * [[FREEFILE]] (file function) {{text|returns a file access number that is currently not in use.}} * [[GET]] (file I/O statement) {{text|reads file data by byte or record positions.}} @@ -631,9 +627,7 @@ r DOS handle number.}} * [[DECLARE LIBRARY| END DECLARE]] (QB64 Only) {{text|required at the END of the block of Library declarations in QB64.}} -<center>'''QB64 also supports [[$INCLUDE]] text code file Libr -4000 -aries. QB64 does not support QLB Libraries or OBJ files.'''</center> +<center>'''QB64 also supports [[$INCLUDE]] text code file Libraries. QB64 does not support QLB Libraries or OBJ files.'''</center> <center>See also: [[Libraries#C++_Variable_Types|C++ Variable Types]]</center> @@ -871,9 +865,7 @@ aries. QB64 does not support QLB Libraries or OBJ files.'''</center> <p style="text-align: center">([[#toc|Return to Table of Contents]])</p> == Program Flow and Loops: == -* [[_CONTINUE]] (statement) {{text|skips the remaining lines in a control block (DO/LOOP, FOR/NE -4000 -XT or WHILE/WEND)}} +* [[_CONTINUE]] (statement) {{text|skips the remaining lines in a control block (DO/LOOP, FOR/NEXT or WHILE/WEND)}} * [[_DEST]] (statement) {{text|sets the current write image or page. All graphics will go to this image.}} * [[_DEST (function)]] {{text|returns the current write destination image or page.}} * [[_EXIT (function)]] {{text|prevents a user exit and indicates if a user has clicked the close X window button or CTRL + BREAK.}} @@ -1067,9 +1059,7 @@ XT or WHILE/WEND)}} * [[SCREEN]] (statement) {{text|sets the screen mode of a program. No statement defaults the program to SCREEN 0 text mode.}} * [[SCREEN (function)]] {{text|returns the [[ASCII]] code of a text character or the color attribute at a set text location on the screen.}} * [[SPACE$]] (function) {{text|returns a [[STRING|string]] consisting of a number of space characters.}} -* [[SPC]] ( -4000 -function) {{text|used in [[PRINT]] and [[LPRINT]] statements to print or output a number of space characters.}} +* [[SPC]] (function) {{text|used in [[PRINT]] and [[LPRINT]] statements to print or output a number of space characters.}} * [[STR$]] (function) {{text|returns the [[STRING]] representation of a numerical value.}} * [[STRING$]](function) {{text| returns a [[STRING]] consisting of a single character repeated a set number of times.}} * [[TAB]] (function) {{text|used in [[PRINT]] and [[LPRINT]] statements to move to a specified text column position.}} diff --git a/internal/help/Mathematical_Operations.txt b/internal/help/Mathematical_Operations.txt index 363d854a4..4cbdddf0f 100644 --- a/internal/help/Mathematical_Operations.txt +++ b/internal/help/Mathematical_Operations.txt @@ -287,9 +287,7 @@ END FUNCTION '' '' ARCSCH(x) = ARSINH(x) ^ -1 ARCOTH(x) = ARTANH(x) ^ -1 - -4000 - '''Hyperbolic sine and cosine satisfy the Pythagorean trig. identity:''' + '''Hyperbolic sine and cosine satisfy the Pythagorean trig. identity:''' (COSH(x) ^ 2) - (SINH(x) ^ 2) = 1 diff --git a/internal/help/PLAY.txt b/internal/help/PLAY.txt index 8619cf765..ea6ba5a67 100644 --- a/internal/help/PLAY.txt +++ b/internal/help/PLAY.txt @@ -276,9 +276,7 @@ pcolorp = gcolorp pcolorp = {{Cl|INSTR}}("0123456789abcdef", {{Cl|LCASE$}}({{Cl|MID$}}(p$, p, 1))) - 1 {{Cl|END SELECT}} {{Cl|IF...THEN|IF}} {{Cl|NOT}} pcolorp = -1 {{Cl|THEN}} - { -2b3c -{Cl|IF...THEN|IF}} gscalep > 1 {{Cl|THEN}} + {{Cl|IF...THEN|IF}} gscalep > 1 {{Cl|THEN}} {{Cl|LINE}} ((gposxp - 1) * gscalep, (gposyp - 1) * gscalep)-{{Cl|STEP}}(gscalep - 1, gscalep - 1), pcolorp, BF {{Cl|ELSE}}: {{Cl|PSET}} (gposxp, gposyp), pcolorp diff --git a/internal/help/PRINT_(TCP%2FIP_statement).txt b/internal/help/PRINT_(TCP%2FIP_statement).txt index 43b720c44..4075e285f 100644 --- a/internal/help/PRINT_(TCP%2FIP_statement).txt +++ b/internal/help/PRINT_(TCP%2FIP_statement).txt @@ -10,8 +10,9 @@ The '''PRINT #''' statement sends QB64 formatted data to an open connection hand * Always check connections to handles before sending data. -''Availability:'' -* Version 0.954 and older. For version 1.000 and up use [[PUT (TCP/IP statement)]] +==Availability== +* '''Version 0.954 and older'''. +** For version 1.000 and up use [[PUT (TCP/IP statement)]] :::::'''Communicating using QB64 Formatted messages:''' diff --git a/internal/help/QB64_FAQ.txt b/internal/help/QB64_FAQ.txt index a26718dcf..92276091a 100644 --- a/internal/help/QB64_FAQ.txt +++ b/internal/help/QB64_FAQ.txt @@ -3,52 +3,38 @@ |} -As with everything else, this list will be updated to correspond to new progress of QB64 so make sure that you are using the latest version of '''QB64 (version 1.1 released in 1/20/17)'''. Please note that it may take a short time to update this list. +As with everything else, this list will be updated to correspond to new progress of QB64 so make sure that you are using the latest version of '''QB64'''. Please note that it may take a short time to update this list. -<center>'''You may need Administrator rights to install or use QB64!'''</center> - -<center>'''{{text|It's a good idea to exclude "QB64.exe" (also the internal folder) from any real-time anti-virus scanning to prevent IDE Module Errors!|red}}'''</center> +<center>'''{{text|It's recommended to exclude (whitelist) "qb64.exe" (also the ''internal'' folder) from any real-time anti-virus scanning to prevent IDE Module Errors.|red}}'''</center> ==Q: What is QB64?== -A: '''QB64''' is a BASIC compatible Editor and C++ compiler that creates working Executable files from Qbasic BAS files that can be run on 32 or 64 bit PC's using '''WINDOWS'''(XP, Vista and newer), '''LINUX''' or '''macOS'''. The goal is to be 100% compatible with QuickBasic 4.5 plus add hundreds of new abilities such as program icons and custom sized windows and a great [[IDE|Editor]] with a new Help Menu. +A: '''QB64''' is a BASIC compatible Editor and C++ emitter that creates working Executable files from Qbasic BAS files that can be run on 32 or 64 bit PC's using '''Windows''' (XP to 10), '''Linux''' or '''macOS'''. The goal is to be 100% compatible with QuickBasic 4.5 plus add hundreds of new abilities such as program icons and custom sized windows and a great retro [[IDE|Editor]] with builtin help. The '''new keywords''' add some '''new features''' such as playing '''music or sound''' files and instant access to '''32 bit graphics''' file images. Also '''TCP/IP''' internet communication is available to '''download''' files, '''email''' messages over the web or play '''internet games'''. '''DLL Libraries''' can add more programming options and QB64 can access all of the new USB gaming '''controllers''' and '''printers'''. -QB is an abbreviation for '''QBasic''' or '''QuickBASIC''' which is an easy to learn language that grew very popular in the 90's. It uses simple syntax but holds great potential as there are methods to achieve nearly anything. '''QBasic is NOT DEAD thanks to QB64!''' +QB is an abbreviation for '''QBasic''' or '''QuickBASIC''' which is an easy to learn language that grew very popular in the 90's. It uses simple syntax but holds great potential as there are methods to achieve nearly anything. '''QBasic is more alive than ever with QB64!''' <p style="text-align: center">[[Keywords currently not supported by QB64]]</p> -<center>'''You may need Administrator rights to install or use QB64!'''</center> - ==Q: Does it have modern features? Do they HAVE to be used?== -A: QB64 has PLENTY of modern features, but they do not have to be used. You may just want to run some of your old favorites. -<center>'''QB64 was created to run your old Qbasic 4.5(or less) programs on newer Operating Systems without ANY changes!'''</center> -You could code using the original QuickBASIC syntax all the way through and it should work as you expect it to or even better. QB64 is often faster and has none of the memory limitations that plagued Qbasic in the past! Give it try! See for yourself. +A: QB64 has plenty of modern features, but they do not have to be used. You may just want to run some of your old favorites. +<center>'''QB64 was created to run your old QBasic 4.5 (or less) programs on newer Operating Systems without any changes.'''</center> +You could code using the original QuickBASIC syntax all the way through and it should work as you expect it to or even better. QB64 is often faster and has none of the memory limitations that plagued QBasic in the past. -<center> '''For incompatibility issues you can look in the QB64 "Discussion" board here:'''</center> +QB64 is not meant to run PDS (7.1) QBX code. Most GW Basic code will run with minor changes. + +The modern statements are designed to go along with the BASIC philosophy and expand QBasic into the future! -<center>[http://www.qb64.net/forum/index.php Visit the QB64 Community Forum]</center> - - -<center>'''Some members can still run QB4.5 programs so we can test problem code!'''</center> -<center>QB 4.5 code only! QB64 was not meant to run PDS (7.1) QBX code. Will run most GW Basic code too!</center> - - -<center>'''If your program(s) don't work correctly(check your code first) please feel free to post in the "Discussion" board.'''</center> - -Galleon is constantly working on pure compatibility. You don't have to set it up differently to use the modern features as they are made to work alongside original QB code seamlessly (unlike FreeBASIC and any other modern BASIC out there). The modern statements are designed to go along with the BASIC philosophy and expand Qbasic into the future! - - -<center>'''QB64 FEATURES INCLUDE...'''</center> +<center>'''QB64 FEATURES INCLUDE:'''</center> {{TextStart}} 1) Full graphic functions for [[_NEWIMAGE|images]] up to 32 bit color. [[_ALPHA|Alpha]] transparency supported. @@ -57,11 +43,11 @@ Galleon is constantly working on pure compatibility. You don't have to set it up 3) Supports [[_SNDOPEN|stereo sound]] files like WAV, OGG, MP3, speaker and volume control and more... - 4) Animation is easy to do using [[_DISPLAY]] instead of page flipping. NO SCREEN FLICKER! + 4) Animation is easy to do using [[_DISPLAY]] instead of page flipping, to achieve flicker-free graphics. 5) [[_CLIPBOARD$|Clipboard]] reading and writing support. - 6) Networking over [[TCP/IP Message Format]] and Email. + 6) Networking over TCP/IP and Email. 7) True type [[_FONT|font]] and [[Unicode]] support for many Languages. @@ -74,55 +60,40 @@ Galleon is constantly working on pure compatibility. You don't have to set it up ==Q: How do I install QB64 on Windows, Linux, macOS?== -A: If you have a relatively new computer you will probably be fine. QB64 supports the following Operating Systems in one download: +A: QB64 supports the following Operating Systems: - -<center>'''Windows NT(XP), Windows Vista, Windows 7, 8 or 10:'''</center> -:'''1)''' Click the following link and Windows box to download QB64: [http://www.qb64.net QB64 Windows Downloads] -:'''2)''' Unzip to any folder path you wish. The ZIP file will create a ''QB64'' folder for the program files. +<center>'''Windows NT (XP), Windows Vista, Windows 7, 8 or 10:'''</center> +:'''1)''' Download the appropriate package according to your system from [http://www.qb64.org QB64.org] +:'''2)''' Unpack the contents to any location on your computer. Avoid unpacking to Program Files or other system folders that may require administrative privileges. QB64 need to have full write permissions to its own folder. :* Executable programs are portable between like systems by copying the stand-alone executable file. -:* ''Versions of QB64 prior to 1.000 require that your binary is distributed with the DLL files that came bundled.'' -<center>'''You may need Administrator rights to install or use QB64.'''</center> - - -<center>'''Windows 2000 running QB64 versions .94 and Above'''</center> -: QB64 version .940 and above contain a full version of the Ming Compiler! This may create an entry point error in Windows 2K. - -:'''1)''' Click the following link and Windows box to download QB64: [http://www.qb64.net QB64 Windows Downloads] -:'''2)''' Unzip to any folder path you wish. The ZIP file will create a ''QB64'' folder for the program files. Check for ''MSVCRT.DLL'' errors! -:'''3)''' If there is an error, unzip the contents of the ZIP FIX file into the QB64 folder after QB64 has updated to the latest version. - -<center>[http://www.qbasicnews.com/dav/files/qb64v942-win2k-fix.zip Download ZIP FIX for Windows 2000 if QB64 does not run correctly!]</center> -<center>This download fix will be updated when necessary by Dav</center> ---- -<center>'''Most versions of LINUX 32 and 64 bit'''</center> -:'''1)''' Click on the following link and Linux box to download QB64: [http://www.qb64.net QB64 Linux Downloads] -:'''2)''' You will need the following installed: OpenGL developement libraries, ALSA development libraries, GNU C++ Compiler (g++) -:'''3)''' After extracting the downloaded package, run the installation batch/script called ''setup_lnx.sh'' in the main ''qb64'' folder to setup QB64. -:'''4)''' It is not advisable to install QB64 as root. +<center>'''Most distributions of Linux, both 32 and 64 bit'''</center> +:'''1)''' Download the appropriate package according to your system from [http://www.qb64.org QB64.org] +:'''2)''' After extracting the downloaded package, run the installation batch/script called ''./setup_lnx.sh'' in the main ''qb64'' folder to setup QB64. +:'''3)''' Most dependencies should be automatically downloaded by the setup script, but these are the ones you should look for if compilation fails: OpenGL developement libraries, ALSA development libraries, GNU C++ Compiler (g++) + <center>Executable programs are portable between like systems by copying the executable file.</center> -<center>'''The Linux 32bit & 64bit versions are combined as of the v 0.925 update'''</center> -<center>'''Note: Some QB64 keywords and procedures are not available as of this Linux release.'''</center> +<center>'''Note: Some QB64 keywords and procedures are not available for Linux.'''</center> <p style="text-align: center">([[#toc|Return to FAQ topics]])</p> ---- <center>'''macOS'''</center> -:'''1)''' You MUST install '''Xcode command line tools''' for C++ compilation from their website. In a terminal window, type the following command: '''xcode-select --install''' (more info here: [http://developer.apple.com/technologies/tools/xcode.html Xcode download]) -:     (you won't be using the Xcode interface, QB64 just needs to have access to the C++ compiler it installs) -:'''3)''' Click on the following link and MAC OSX box to download QB64 for macOS: [http://www.qb64.net QB64 MAC OSX Downloads] -:     Extract the downloaded package and run ''setup_osx.command'', found within the QB64 folder to install the QB64 compiler. +:'''1)''' You must install Apple's '''Xcode command line tools''' for C++ compilation from their website. The simplest way to do so is opening a terminal window and typing the following command: '''xcode-select --install''' (more info here: [http://developer.apple.com/technologies/tools/xcode.html Xcode download]) +:     (you won't be using the Xcode interface, QB64 just needs to have access to the C++ compiler and libraries it installs) +:'''3)''' Download the appropriate package according to your system from [http://www.qb64.org QB64.org] +:     Extract the downloaded package and run ''./setup_osx.command'', found within the QB64 folder to install the QB64 compiler. -<center>'''After installation you should run '''qb64_start_osx.command''' to run qb64.'''</center> +<center>'''After installation you should run '''./qb64''' or '''./qb64_start_osx.command''' to run qb64.'''</center> -:* Executable programs are portable between like OSX systems by copying the executable file. +:* Executable programs are portable between macOS systems by copying the executable file. :* To help launch executables without a console, a file called ''programname_start.command'' is created along with the program. -<center>'''Note: Some QB64 keywords and procedures are not available as of this MAC release.'''</center> +<center>'''Note: Some QB64 keywords and procedures are not available for macOS.'''</center> <center>[[Keywords_currently_not_supported_by_QB64#Keywords_Not_Supported_in_Linux_or_MAC_OSX_versions|Keywords Not Supported in Linux or MAC OSX versions]]</center> @@ -131,128 +102,28 @@ A: If you have a relatively new computer you will probably be fine. QB64 support ---- <p style="text-align: center">([[#toc|Return to FAQ topics]])</p> -==Q:The setup scripts don't work in Linux and macOS. How can I fix them?== -A: If you have problems running the install scripts under Linux (./setup_lnx.sh) or macOS (./setup_osx.command), run the following line in terminal, from your QB64 folder: - -===Linux=== -* <nowiki>find . -name '*.sh' -exec sed -i "s/\r//g" {} \;</nowiki> - -===macOS=== -* <nowiki>find . -name '*.command' -exec perl -pi -e 's/\r\n|\n|\r/\n/g' {} \;</nowiki> -* Don't forget you need to have Xcode command line utilites installed to use QB64. - -If you have any other issues, check out the Forum: - -* [http://www.qb64.net/forum/ QB64 Forum] -* [http://www.qb64.net/forum/index.php?topic=13359.msg115525#msg115525 Fixing setup scripts] - -==Q: How do I upgrade the 32 bit Windows version of QB64 to 64 bit functionality?== -A: The process has been simplified a lot recently. - -# Download the version of QB64 which you want to transform into a 64-bit version from THE QB64 OFFICIAL WEBSITE. -# Grab a pre-edited copy of the 64-bit mingw compiler. You can find it here, [https://www.dropbox.com/s/gapnz7m22yc0mlv/QB64%2064-bit%20mingw%20compiler%20%2808-01-2017%29%20PRE-EDITED.7z?dl=0 QB64 64-bit mingw compiler (08-01-2017) PRE-EDITED], stored permanently in [[User:SMcNeill |Steve McNeill]]'s Dropbox account. -# Extract the QB64 file wherever you want it to be on your system. -# Go into the folder where you installed QB64 and head to the '''internal/c/c_compiler''' folder. -# Delete everyone of those files and folders. -# Extract the mingw 64-bit compiler into that folder. You're looking to replace the old contents with the new contents. Watch for nesting a folder inside a folder by accident. -# Go into the main QB64 directory, look for setup_win.bat. If it's not there, grab the download for it from below and put it into the main folder. (I don't think the archives at qb64.net has the file included in it, though if you download from the repo directly, you can find it. It's kind of a developer tool, moreso than something an user needs cluttering up their directory structure.) -# Run that setup_win.bat file. If everything is extracted to the proper places, you should build and have a version of QB64 open up where the title screen now reads "QB64x64". Congrats!! You now have a working, 64-bit version of QB64. - -That's all it takes! - -{{small|Tip courtesy of Steve McNeill}} - - -<p style="text-align: center">([[#toc|Return to FAQ topics]])</p> ==Q: Why won't QB64 work on my computer?== QB64 currently supports Windows versions from XP to the latest version. Most Linux and macOS versions are also supported. +: '''Don't move QB64 executable out of the QB64 folder. The various sub-folders hold the C++ compiler files and libraries.''' -<center>'''Don't move QB64 executable out of the QB64 folder! The various sub-folders hold the C++ compiler files!'''</center> -<center>Versions of QB64 prior to 1.000 require the accompanying DLL files, which may be copied into the Windows ''System32'' or ''SysWOW64'' folder for program access outside of the QB64 folder. They can also be placed in a separate folder or download package with the EXE and program files.</center> - - -Does your Windows system have another version of the '''MinGW''' compiler? Does it have '''Fortran''' or '''GFortran'''? You can check your environmental values using the following batch file which will create the '''''settings.inf''''' text file in the batch folder: - -{{TextStart}}set >settings.inf '' '' {{TextEnd}} - - -: The '''settings.inf''' file should hold environmental values similar to those listed below: -{{TextStart}}ALLUSERSPROFILE=C:\Documents and Settings\All Users.WINDOWS -APPDATA=C:\Documents and Settings\User1\Application Data -CLIENTNAME=Console -CommonProgramFiles=C:\Program Files\Common Files -COMPUTERNAME=PC1 -ComSpec=C:\WINDOWS\system32\cmd.exe -FP_NO_HOST_CHECK=NO -HOMEDRIVE=C: -HOMEPATH=\Documents and Settings\User1 -'''LIBRARY_PATH={{text|\F\G77\Llib|red}}''' -LOGONSERVER=\\PC1 -NUMBER_OF_PROCESSORS=1 -4000 - -OS=Windows_NT -'''Path=C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;{{text|\F\G77\bin|red}}''' -PATHEXT=.COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH -PROCESSOR_ARCHITECTURE=x86 -PROCESSOR_IDENTIFIER=x86 Family 15 Model 1 Stepping 2, GenuineIntel -PROCESSOR_LEVEL=15 -PROCESSOR_REVISION=0102 -ProgramFiles=C:\Program Files -PROMPT=$P$G -SESSIONNAME=Console -SystemDrive=C: -SystemRoot=C:\WINDOWS -TEMP=C:\DOCUME~1\User1\LOCALS~1\Temp -TMP=C:\DOCUME~1\User1\LOCALS~1\Temp -{{TextEnd}} -: Environmental values in {{text|red|red}} above indicate where another C compiler has altered or added to the Windows settings. - - -<center>Environmental values to check and possibly clear are '''PATH=''', '''LIBRARY_PATH=''', '''LIB=''' or '''CPLUS_INCLUDE_PATH='''</center> - - -<center>'''QB64 does NOT alter computer settings! All required files are organized in the QB64 folder.'''</center> - - -: Try to run the following '''''TestQB64.bat''''' batch file from the QB64 folder only: -{{TextStart}}@echo off -REM set environmental values for QB64. Remove offending program paths from the values. -set Path=C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem -set LIBRARY_PATH= -REM start QB64 IDE. A BAS file can be dropped into this batch file to edit in IDE. -REM this batch file must be run from the QB64 folder! -Set QB64=%~dp0 -CD "%QB64%" -start qb64.exe %1 '' '' -{{TextEnd}} -{{small|Adapted from code by Michael Calkins}} -: 64 bit systems should use the ''PATH=C:\WINDOWS\[[SysWOW64]]'' folder in place of the ''C:\WINDOWS\system32'' parameter. - - -: If the batch file works, you can use it to edit and compile QB64 programs. You may want to uninstall the conflicting program. - - -<center>'''[[IDE#Compiler_Errors|IDE Compiler Errors]]</center> +: '''QB64 does not change any settings on your machine. All required files are in the QB64 folder.''' <p style="text-align: center">([[#toc|Return to FAQ topics]])</p> ==Q: Are there any known incompatibilities?== -A: There are some things that QB64 will not and NEVER was intended to do! The original concept was and is to provide a platform that allows older and NEW QBasic procedures and programs to run on the newer 32 and 64 bit personal computers. As you may have observed, this compatibility alone limits the access programs now have to DOS. - -'''[[DOS]] is not fully supported''', as this will require full DOS support to be emulated, however it will continually be updated to support more source code and more features, memory addresses, ports, etc. so that it always approaches 100%. If you don't use too many [[ABSOLUTE]], [[INTERRUPT]], [[PEEK]], [[POKE]] and [[OUT]] statements you probably won't notice any difference between QB 4.5 and QB64 (and if you do, report it as a bug in the forums, remember to check if the problem has been reported before please!), you can expect the most common addresses for interrupts, etc. to be functioning. Galleon has also received a comprehensive list of memory and port addresses so that even some less common addresses may work as well. If you are unsure, try them! +A: There are some things that QB64 cannot do, like direct hardware access, which makes older more advanced programs that make use of [[ABSOLUTE]], [[INTERRUPT]], [[PEEK]], [[POKE]] and [[OUT]] not work properly. Although some older functionality is emulated, if your program doesn't use such statements you probably won't notice any difference between QB 4.5 and QB64 (and if you do, report it as a bug in the forums). You can expect the most common addresses for interrupts, etc. to be functioning. -<p style="text-align: center">[[Keywords currently not supported by QB64]]</p> +See: [[Keywords currently not supported by QB64]] -'''Watch the CPU usage!''' QB64 is a lot faster than QBasic was and it does not have many of the size limitations that confined QBasic programming abilities. Having said that, '''care must be taken to assure that programs do not HOG resources!''' To do that, use speed limits when possible to keep the resources used to a minimum. '''Monitor Task Manager!''' It can tell you how much resources are being used in different parts of a program. The following keywords can lower the impact of your programs on those resources by releasing them to other programs: +You should be careful with '''CPU usage'''. QB64 is a lot faster than QBasic was and it does not have many of the size limitations that confined QBasic programming abilities. Having said that, '''care must be taken to assure that programs do not hog resources.''' To do that, use speed limits when possible to keep the resources used to a minimum. Also, '''Monitor Task Manager''' when your programs are running, as it can tell you how much or system resources are being used in different parts of a program. The following keywords can lower the impact of your programs on those resources by releasing them to other programs: -:::::* [[_LIMIT]]: Limits the loops per second in ANY loop and thus lowers the overall CPU usage. +:::::* [[_LIMIT]]: Limits the loops per second in any loop and thus lowers the overall CPU usage. :::::* [[_DELAY]]: Pauses a procedure and releases unused resources for other programs. @@ -261,347 +132,85 @@ A: There are some things that QB64 will not and NEVER was intended to do! The or :::::* [[INPUT]] and [[INPUT$]] stop program procedures until an entry or key press is given. -QB64 can be fast when you need it to be, but take the time to consider the impact of your program on other programs as people SELDOM have only ONE program running and the OS has tasks it MUST do too! The following programs have KNOWN issues with high CPU usage: - - -<center>'''[http://forums.winamp.com/showthread.php?threadid=166479 WINAMP (intermittent sound)]'''</center> - - -<center>'''Thank you for your support and happy programming!'''</center> - +QB64 can be fast when you need it to be, but take the time to consider the impact of your program on other programs as people seldom have only one program running and the OS has tasks it must do too. <p style="text-align: center">([[#toc|Return to FAQ topics]])</p> -==Q: Why won't my QB64 compiled programs run in folders other than the QB64 folder?== -A: Versions of QB64 prior to 1.000 required certain DLL files to be in the program folder or in the Windows system path. +==Q: How do I update the information in QB64's help system?== +A: The help provided in the QB64 IDE Help System fetches the pages from this wiki. Use the '''Update current page''' in the [[IDE]] Help menu selection to update a page. Use the '''Update all pages''' choice to update them all, but this may take longer. -<center>{{Text|C:\WINDOWS\SYSTEM32|green}}</center> - - -Copy each of the DLL files included with QB64 to the System32 or [[SysWOW64]] folder. You may need administrator rights to do this! - - -<center>[http://www.samlogic.net/articles/32-64-bit-windows-folder-x86-syswow64.htm SysWOW64 and Program Files(x86) folders on 64 bit Windows OS.]</center> - - -<center>'''[[QB64_FAQ#Q:_What_files_are_required_to_run_QB64_SDL_programs_in_Windows.3F|List of required QB64 DLL files for older versions (prior to 1.000)]]'''</center> - - -<p style="text-align: center">([[#toc|Return to FAQ topics]])</p> - -==Q: How do I find the current QB64 program path in Windows or Linux?== - -* With the [[_CWD$]] and [[_STARTDIR$]] commands you can get the current working path and the path from which your program was started, respectively. For older versions of QB64 in which these statements may not be available, use the procedures below. - - -:'''Windows path:''' -{{CodeStart}} '' '' -{{Cl|PRINT}} PATH$ -{{Cl|END}} - -{{Cl|FUNCTION}} PATH$ ' Get Current Directory -'Get path to executable in Windows -{{Cl|DECLARE LIBRARY}} 'Directory Information using KERNEL32 provided by Dav - {{Cl|FUNCTION}} GetModuleFileNameA ({{Cl|BYVAL}} Module {{Cl|AS}} {{Cl|LONG}}, FileName {{Cl|AS}} {{Cl|STRING}}, {{Cl|BYVAL}} nSize {{Cl|AS}} {{Cl|LONG}}) -{{Cl|DECLARE LIBRARY|END DECLARE}} - -FileName$ = {{Cl|SPACE$}}(400) ' Sometimes 256 characters for a full path name is not enough - -Result = GetModuleFileNameA(0, FileName$, {{Cl|LEN}}(FileName$)) '0 designates the current program -{{Cl|IF...THEN|IF}} Result {{Cl|THEN}} 'Result returns the length or bytes of the string information - PATH$ = {{Cl|LEFT$}}(FileName$, Result) - start = 1 - DO - posit = {{Cl|INSTR}}(start, PATH$, "\") - {{Cl|IF...THEN|IF}} posit {{Cl|THEN}} last = posit - start = posit + 1 - {{Cl|LOOP}} {{Cl|UNTIL}} posit = 0 - PATH$ = {{Cl|LEFT$}}(PATH$, last) -{{Cl|ELSE}} - PATH$ = "" -{{Cl|END IF}} -FileName$ = "" -{{Cl|END FUNCTION}} '' '' -{{CodeEnd}}{{small| Code by EricR}} - - -:'''Linux path:''' -{{CodeStart}} '' '' -{{Cl|PRINT}} path$ -{{Cl|END}} - -{{Cl|FUNCTION}} path$ -'Get path to executable and directory of said executable on Linux -'Public Domain code -{{Cl|DECLARE LIBRARY}} - {{Cl|FUNCTION}} readlink& (path$, buffer$, {{Cl|BYVAL}} bufsize&) -{{Cl|DECLARE LIBRARY|END DECLARE}} - -bufsize& = 500 'Initial size of the string to store the result in -DO - buffer$ = {{Cl|SPACE$}}(bufsize&) 'Create the buffer to put result in - ret& = readlink&("/proc/self/exe", buffer$, bufsize&) '/proc/self/exe is always a symlink to our executable file - {{Cl|IF...THEN|IF}} ret& < bufsize& {{Cl|THEN}} {{Cl|EXIT DO}} 'ret& is how many bytes were actually put in the buffer. If they are equal, we need to make the buffer bigger and try again - bufsize& = bufsize& + 500 -{{Cl|LOOP}} -exe$ = {{Cl|LEFT$}}(buffer$, ret&) -'exe$ is now the full path of the executable. - -'This code just chops off the filename to give us the directory: -{{Cl|FOR...NEXT|FOR}} i& = {{Cl|LEN}}(exe$) {{Cl|TO}} 1 {{Cl|STEP}} -1 - {{Cl|IF...THEN|IF}} {{Cl|MID$}}(exe$, i&, 1) = "/" {{Cl|THEN}} {{Cl|EXIT}} {{Cl|FOR...NEXT|FOR}} -{{Cl|NEXT}} i& -directory$ = {{Cl|LEFT$}}(exe$, i&) -path$ = directory$ -{{Cl|END FUNCTION}} '' '' -{{CodeEnd}}{{small|Code by Johny B}} - - - -<p style="text-align: center">([[#toc|Return to FAQ topics]])</p> - -==Q: How do I update the information in QB64 HELP?== - -A: The help provided in the QB64 IDE Help System fetches the pages from this wiki. Use the '''Update current page''' in the [[IDE]] Help menu selection to update a page. Use the '''Update all pages''' choice to update them all, but this may take longer. In general you may want to update monthly or a week after a new version release. - - -<center>[http://qb64.net/wiki/index.php?title=IDE#Help_Menu_.28Alt_.2B_H.29 QB64 IDE Help Menu]</center> ==Q: Can I use the same libraries with QB64 that I used with QB 4.5?== -A: If the libraries are pure QB 4.5 code then yes, otherwise no. QLB files are not supported but you can easily copy your favorite SUBs or FUNCTIONs to a text BI file and [[$INCLUDE]] them at the end of ANY program. Include them AFTER all SUB and FUNCTION code in the BAS file! +A: If the libraries are pure QB 4.5 code then yes, otherwise no. QLB files are not supported but you can easily copy your favorite SUBs or FUNCTIONs to a text BI file and [[$INCLUDE]] them at the end of any program. Include them after all SUB and FUNCTION code in the BAS file. -As of Dec 3, 2010 QB64 acquired [[DECLARE LIBRARY]] to allow users to reference C, Windows, OpenGL and other DLL libraries. If you find some functions that you like please share them with us at the forum! The following pages list working functions our members have found and tested: +[[DECLARE LIBRARY]] allows users to reference C, Windows, OpenGL and other DLL libraries. If you find some functions that you like please share them with us at the forum! The following pages list working functions our members have found and tested: <center>[[C Libraries]], [[DLL Libraries]], [[Windows Libraries]]</center> -*[[SDL Libraries]] ''(obsolete since version 1.000 - available here for historic purposes) - <p style="text-align: center">([[#toc|Return to FAQ topics]])</p> -==Q: I can't get my QB 4.5 sourcecode to work in QB64! Why?== +==Q: I can't get my QB 4.5 source code to work in QB64! Why?== -A: Perhaps that is because QB64 isn't 100% compatible yet, it is a work in progress. It is around 95-98% compatible right now, and that is a large number! The commands that haven't been implemented are either obsolete or are too obscure and have been replaced by modern functionality. Look at the [http://www.qb64.net/forum/index.php?board=15.0 Unimplemented Qbasic Commands Forum] for statements that are not available. - - -<p style="text-align: center">[[Keywords currently not supported by QB64]]</p> - - -'''Compiler errors''' are another subject. Always try to test the program in Qbasic BEFORE trying to run or compile it in QB64! You may find '''syntax or other code errors''' that the QB64 IDE may not find yet as a bonus! Always check the code before blaming QB64! - - -<center>'''You may need Administrator rights to install or use QB64.'''</center> +A: QB64 is 99% compatible with QB4.5 programs. The commands that haven't been implemented are either obsolete or are too obscure and have been replaced by modern functionality. +See: [[Keywords currently not supported by QB64]] <p style="text-align: center">([[#toc|Return to FAQ topics]])</p> ==Q: What files are required to run my QB64 compiled program in my Operating System?== -A: Programs compiled by QB64 (version 1.000 and up) are stand-alone so no external OpenGL DLL files are required to be with your program EXE file. +A: Programs compiled by QB64 (version 1.000 and up) are stand-alone so no external files are required to be with your program's EXE file. + <p style="text-align: center">([[#toc|Return to FAQ topics]])</p> -==Q: How are foreign languages and keyboards supported in QB64?== - -A: As of version 0.922 (October 20, 2010) QB64 supports foreign language keyboard characters. - -* Setting up a typing language in the QB64 [[IDE]]: -:Step 1: In the OPTIONS menu select DISPLAY, then check the CUSTOM FONT check-box. -:Step 2: In the OPTIONS menu select LANGUAGE, then select a Code Page (CP850 for example) and click OK. - -See the [[Unicode]] page to setup a language in a program you create. There are also links to the various [[Code Pages]] that are supported. Also there are four new keywords to work with keypresses and map them to ASCII key character codes: - -<center>[[_KEYHIT]], [[_KEYDOWN]] and [[_MAPUNICODE]]</center> - - -<center>'''You can now re-assign key codes to Unicode characters in programs you create using the [[_MAPUNICODE]] statement!'''</center> - - -If you have any problems, post in the discussion board. In the meantime you can use any of these recommended [[ASCII]] methods: - - -<center>'''Using ASCII Characters'''</center> -Perhaps you can use the [[ASCII]] character codes. Go to the [[ASCII]] character chart and look for the character(s) you need. If you find them, remember the code number and use either CHR$(code%) or the Alt-number pad key method to type them into literal strings(real strings with quotes) only. The following QB64 program displays the characters available on your PC: -{{CodeStart}} - -SCREEN _NEWIMAGE(800, 600, 256) -font$ = "C:\WINDOWS\Fonts\cour.ttf" 'TTF file in Windows -style$ = "monospace" 'font style -f& = _LOADFONT(font$, 22, style$) -_FONT f& -COLOR 11 -FOR c% = 1 TO 6: PRINT c%; CHR$(c%);: NEXT -FOR c% = 14 TO 27: PRINT c%; CHR$(c%);: NEXT -FOR c% = 32 TO 255: PRINT c%; CHR$(c%);: NEX -DO: SLEEP: LOOP UNTIL INKEY$ <> "" - -{{CodeEnd}} - - -'''The ALT Key Method:''' Hold the Alt key down and enter the code number using the Number Pad only. When you release the Alt key, the character should be in the IDE string you are making. Characters can be added (concatenated) using the + between the literal string and CHR$(code) or by using a semicolon as shown below: - -{{CodeStart}} - -PRINT {{Cl|CHR$}}(165) + "ormally I don't use these keys. Do You " + {{Cl|CHR$}}(168) 'concatenation - -PRINT {{Cl|CHR$}}(165); "ormally I don't use these keys. Do you"; {{Cl|CHR$}}(168) 'semicolons - -PRINT "Ñormally I don't use these keys. Do you¿" 'Alt-number pad method - -{{CodeEnd}} -{{OutputStart}} -Ñormally I don't use these keys. Do you¿ -{{OutputEnd}} - -:'''NOTE:''' You MUST use concatenation when defining a string variable using the CHR$ function character returns! - -<center>[[ASCII|Link to the ASCII Character Table]]</center> - -To cut down on typing CHR$(???) all day, define often used characters as string variables such as Q$ = CHR$(34) as shown below: -{{CodeStart}} - -{{Cl|DIM}} Q AS {{Cl|STRING}} * 1 'define as one byte string(get rid of $ type suffix too) -Q = {{Cl|CHR$}}(34) 'Q will now represent the elusive quotation mark in a string - -PRINT "This string uses "; Q; "quotation marks"; Q; " that might cause a syntax error!" - -{{CodeEnd}} -{{OutputStart}} -This string uses "quotation marks" that might cause a syntax error! -{{OutputEnd}} - - -:'''Warning! Do NOT use Notepad for special characters as it won't display them! It is best to enter them in the IDE.''' - -You can use ANY of the ASCII characters to add borders, arrows, and many other characters not available on the keyboard. Hopefully this information will cure your problem! - -<p style="text-align: center">([[#toc|Return to FAQ topics]])</p> - -==Q: MUST I copy or drag ALL of my program files to the QB64 folder?== - -A: You can instruct QB64 to save the resulting executable file to the same folder as your source code file so that all your project files can reside in a separate folder, for better organization. In the [[IDE]] of versions 1.000 and up, go to the Run menu and tick the option "Save EXE in the source folder". This way, next time you hit F5, Ctrl+F5 or even F11, QB64 will compile your .BAS file and the .EXE will be placed in the same folder. - - -For older versions of QB64, you can use a batch file, as instructed below: - -# Use a batch file or a command line as follows: QB64 -c ''yourfile.BAS'' -# Move the compiled EXE file back to the folder with the program files. -# Copy ALL of the QB64 DLL files from the QB64 folder to your new program's folder. -# Try the EXE file to see how it works. - - -<center>'''The Answer to the Question below will show you how to create a batch file and compile BAS files from ANY location.'''</center> - -<p style="text-align: center">([[#toc|Return to FAQ topics]])</p> ==Q: Is there a way to use the compiler without running my program or using the IDE?== -A: Yes! No other program files besides the BAS file are required! Use the following command to compile a program without running it: - +A: Yes! No other program files besides the BAS file are required. Use the following command to compile a program without running it: * '''QB64 -c yourfile.BAS''' * '''QB64 -x yourfile.BAS''' ''(compiles using the console only)'' * '''QB64 -c yourfile.BAS -o destination_path\destination executable_name.exe''' ''(compiles the .BAS file and outputs the executable to a separate folder)'' -''NOTE: Versions of QB64 prior to 1.000 require that the DLL libraries are copied along with your executable or installed in the System folder (Windows).'' - - -The batch file below can compile any BAS file from any location using drag and drop. The EXE will be created in the QB64 folder: -{{TextStart}} '' '' -@ECHO OFF - -Set QB64=%~dp0 -Echo. QB64 path: %QB64% - -REM The QB64 path must d -4000 -esignate the drive letter when compiling from another drive letter! -C: -CD\ -CD "%QB64%" - -cmd /c start /low QB64.exe -c %1 '' '' -{{TextEnd}} -<center>'''Place the BAT file in the QB64 folder!''' You will also be able to drag and drop BAS files onto the batchfile.</center> - - - -<center> '''Associating the batch file in the Right Click Open With pop-up menu'''</center> -You can associate the batch file to the Right Click Popup Menu's ''Open With'' dialogue choices when you right click ANY BAS file: - -::::1) Right click any BAS file and move to ''Open With'' and click ''Choose Program'' in the pop-up menu. - -::::2) Your batch file will not be in the program choices so select ''Browse''. - -::::3) Navigate to the batch file '''in the QB64 folder''' and click on it. - -::::4) '''Make sure that the ''Always use this program'' box is NOT checked!''' Then save your choice. - -<center>The compiled EXE file can be found in the QB64 folder!</center> - - -<center>'''You may need Administrator rights to install or use QB64.'''</center> - <p style="text-align: center">([[#toc|Return to FAQ topics]])</p> -==Q: How do I LINK modules or INCLUDE SUB procedures in QB64? == + +==Q: How do I link modules or include SUB procedures in QB64? == A: QB64 allows you to [[$INCLUDE]] code or BAS modules into one module when it is compiled. Text .BI files containing SUB or FUNCTION code or entire BAS modules can be included in one module that will be compiled. -After the EXE is compiled, you do not have to even use the added code anymore! The EXE will contain ALL of the program code as ONE stand-alone program! This also allows you to add SUB code to ANY program that you desire. Use the following syntax and rules: +After the EXE is compiled, you do not have to even use the added code anymore. The EXE will contain ALL of the program code as ONE stand-alone program. This also allows you to add SUB code to any program that you desire. -<center>''Syntax:'' REM $INCLUDE: 'filename.BI'</center> - - -:1) '''$INCLUDE [[TYPE]] definitions or [[DATA]] field code''' at the beginning of the module that will be compiled. Text code can be used, but must be renamed to .BI (cannot be a .TXT extension!) or kept as a .BAS module. SUB or FUNCTION code MUST be included at the end of the module code! - -:2) '''$INCLUDE [[SUB]] or [[FUNCTION]] code''' AFTER any SUB or FUNCTION code in the module that will be compiled to combine them. Otherwise QB64 will create an error stating that the INCLUDE statement cannot be placed there. - -:3) '''LINKING''' of program modules is accomplished by creating a NEW module and using an $INCLUDE statement for each module that is to be combined. - -After you have created the include files, you can add them to ANY other program that requires them! Thus you will end up with smaller BAS files and SUB procedures that can be used over and over like libraries. The files are only used during a compilation. - - -<center>[[LINKed or Merged Modules|Program to Convert LINKed or Merged multiple module programs into one QB64 Module]]</center> - +See: [[$INCLUDE]] <p style="text-align: center">([[#toc|Return to FAQ topics]])</p> -==Q: CHAIN doesn't work the way I'm used to...== - -A: CHAIN has been implemented in QB64 versions 0.851 up. Be sure to download the latest version of the compiler when available. - -<center>'''Note: QB64 will automatically compile the named BAS file if it does not find the EXE file.</center> - -The statement also can use [[COMMON]] or [[COMMON SHARED]] to pass program information. However QB64 uses files to pass the information. If your program moves to a location other than the EXE file's location, the file may be inaccessable! To avoid this problem, make sure that your program can refer to that location using a path. - - -There are minor differences from QBasic in that it doesn't open a program in the same window and does not retain the previous screen mode or format. - -<p style="text-align: center">([[#toc|Return to FAQ topics]])</p> ==Q: Some screens look small. Can I enlarge them or make them fullscreen?== * You can use the [[_FULLSCREEN]] statement to make your programs run fullscreen. -* [[$RESIZE]] can be added to a program so you can track window resize events. (version 1.000 and up) +* [[$RESIZE]] can be added to a program so you can track window resize events. * You can also create custom sized screens with page flipping and up to 32 bit colors using [[_NEWIMAGE]]. * Page flipping is available in most screens and the new [[_DISPLAY]] feature allows the images to be displayed when YOU desire. * Picture or image files such as BMP, PNG, JPEG and GIF are EASY to load using [[_LOADIMAGE]]. * Once images are loaded, all you have to do is use the image handle with any of the new statements and functions. -* [[_PUTIMAGE]] GETs and PUTs images fast in ONE call. It can even stretch or compress the image sizes! +* [[_PUTIMAGE]] GETs and PUTs images fast in ONE call. It can even stretch or compress the image sizes. <p style="text-align: center">([[#toc|Return to FAQ topics]])</p> + ==Q: Can I have background music as well as [[SOUND]], [[PLAY]] and [[BEEP]]?== -A: Yes, they are emulated to use the soundcard instead of the old boring monotone PC-speaker that is rapidly disappearing. +A: Yes, they are emulated to use the soundcard. -<center>'''There also are a bunch of new sound capabilities that allow the use of WAV, OGG, MP3 files and more.'''</center> +'''There also are a bunch of new sound capabilities that allow the use of WAV, OGG, MP3 files and more.''' Capabilities include: @@ -609,134 +218,36 @@ Capabilities include: # Volume and speaker control # Background music -<center>'''SOUND HAS RETURNED TO QBASIC!'''</center> +'''Get started with [[_SNDOPEN|music]]: -<center>'''Get started with [[_SNDOPEN|MUSIC]] NOW!</center> +: [[_SNDCLOSE]] (statement), [[_SNDCOPY]] (function), [[_SNDGETPOS]] (function), [[_SNDLEN]] (function), [[_SNDLIMIT]] (statement) -[[_SNDCLOSE]] (statement), [[_SNDCOPY]] (function), [[_SNDGETPOS]] (function), [[_SNDLEN]] (function), [[_SNDLIMIT]] (statement) +: [[_SNDLOOP]] (statement), [[_SNDOPEN]] (function), [[_SNDPAUSE]] (statement), [[_SNDPAUSED]] (function), [[_SNDPLAY]] (statement) -[[_SNDLOOP]] (statement), [[_SNDOPEN]] (function), [[_SNDPAUSE]] (statement), [[_SNDPAUSED]] (function), [[_SNDPLAY]] (statement) +: [[_SNDPLAYCOPY]] (statement), [[_SNDPLAYFILE]] (statement), [[_SNDPLAYING]] (function), [[_SNDSETPOS]] (statement) -[[_SNDPLAYCOPY]] (statement), [[_SNDPLAYFILE]] (statement), [[_SNDPLAYING]] (function), [[_SNDSETPOS]] (statement) - -<center>[[_SNDRAW]] (statement), [[_SNDSTOP]] (statement), [[_SNDVOL]] (statement)</center> +: [[_SNDRAW]] (statement), [[_SNDSTOP]] (statement), [[_SNDVOL]] (statement) <p style="text-align: center">([[#toc|Return to FAQ topics]])</p> -==Q: Can I use multiple monitors or Pole Monitors?== - -A: Yes, program windows can be moved to them automatically using [[_SCREENMOVE]] with horizontal pixel values that are negative for a secondary monitor on the left and greater than the screen resolution for secondary monitors on the right. - - -'''Note:''' If [[_FULLSCREEN]] is used the program will appear in the primary monitor only. Other running program windows may be pushed onto a secondary monitor on the right so a secondary monitor on the left is preferable in those circumstances. - - - -<p style="text-align: center">([[#toc|Return to FAQ topics]])</p> - -==Q: Why isn't the [[IDE]] always working as I would expect?== - -A: The [[IDE]] has many features shared with modern IDEs while retaining the retro look reminiscent of QuickBasic 4.5 and QBasic. You may request new features in the Discussion subforum and they will be analyzed for implementation, although no warranty of being added is made. - -You can also use QB64 as a compiler only, so that you can choose any alternate editor of your choice. - -<center>'''You may need Administrator rights to install or use QB64'''</center> - - -<center>'''Alternate Editors:''' [[PSPAD|PSPad Editor for Windows]] and [[GEDIT|Gedit Editor for Linux]]'''</center> - - -<center>[http://www.qb64.net/forum/index.php?board=21.0 Report missed Syntax Errors here!]</center> - - -<center>'''[[Known QB64 Issues]]'''</center> - - -<p style="text-align: center">([[#toc|Return to FAQ topics]])</p> ==Q: If QB64 creates Basic programs why is there no Immediate Window?== -A: Because there is no '''QB64''' interpreter. All C code has to be compiled before it can be run, but you can run more than one instance. - -'''QB64''' uses the Immediate window area to suggest syntax for keyword entries and give the compiler status when compiling. To run code snippets or do program calculations using QB64 just open up another instance of the [[IDE]]. Each new instance of QB64 will create a new numbered instance of Untitled(n).exe when compiled. If you want to save the test code for later use, Save it as a BAS file name before closing that instance of QB64. Ihe [[IDE]] will always ask if you want to save new or edited code. - - -Qbasic and Quickbasic allowed BAS programs to be run in an interpreter to test the code. The '''Run''' Menu in QB64 allows the following: - -{{TextStart}}'''{{text|S|white}}tart F5''' Compiles into EXE file and runs program(with code whiteout). -─────────────────────────── -'''Start ({{text|D|white}}etached) Ctrl+F5''' Compiles into EXE and runs program separately (no code whiteout). -'''Make E{{text|X|white}}E Only F11''' Compiles into EXE without program files if there are no errors. '' '' -─────────────────────────── -{{TextEnd}}{{small|Function keys compile without entering menu}} - - -<center> White letters indicate CTRL + letter shortcuts when inside Run menu</center> - - -<center>'''Associated text [[$INCLUDE]] code files, [[DECLARE LIBRARY|LIBRARY]] DLL files and C++ ''.h'' header files must be in the QB64 folder to compile.''' - -In QB64 versions prior to 1.000 the provided DLL files need to be included with the program ''EXE'' after it is compiled. - -(The compiler can find Windows DLL files in the System folder and C++ DLL files in the QB64 folder.) - -'''No additional program files need to be in the QB64 folder to Make EXE Only!''' - -The compiled EXE file can then be moved to a different folder holding the program files necessary when it is run.</center> +A: Because there is no '''QB64''' interpreter. All C code has to be compiled before it can be run. +'''QB64''' uses the Immediate window area to suggest syntax for keyword entries and give the compiler status when compiling. <p style="text-align: center">([[#toc|Return to FAQ topics]])</p> -==Q: How can I slow my program down and/or use less CPU resources?== - -Not by using FOR loops! It would take a lot of loops just to slow QB64 down! Try [[_LIMIT]] to slow your program down and run at the same frame rate every loop. The integer value you enter determines the loop rate whether it is a [[DO...LOOP]] or a [[FOR...NEXT]] loop. - - -[[_LIMIT]] also keeps the CPU memory usage lower when used correctly. Use Task Manager or another CPU manager to monitor the percentage of use if it is over 50% and it doesn't need to be. Some QB64 programs can take up over 90% of the memory needed! - - -Use [[SLEEP]] or [[INPUT$]] to wait for user entries, key presses or menu selections rather than using running [[INKEY$]] loops too. - - -<p style="text-align: center">([[#toc|Return to FAQ topics]])</p> - -==Q: Can I resize the QB64 Editor([[IDE]])? == - -A: Yes, drag the window border to resize it or use the ''Alt + Enter'' key combination to switch from windowed to full screen mode. This can also be used to resize a QB64 program screen (see [[$RESIZE]]). - -There is also a way to set the window size in the ''Options'' Menu. Select ''Display'' and change the size from 80 columns and 25 rows to a '''larger''' size. The size '''cannot be less than 80 by 25!''' The size denotes the TEXT column and rows only! DO NOT MAKE IT TOO LARGE! - -If there is ever a problem with an OPTION that you set, just Delete the '''.\internal\temp\options.txt''' file. Then restart QB64. You can find the program listed in the taskbar. Right click and select ''Close'' from the pop-up menu. - - -<center>'''See the [[IDE|IDE Page]] for more information.'''</center> - -==Q: The autoformatting doesn't work correctly in the [[IDE]]...== - -A: The autoformatting feature allows you to set a fixed number of spaces to indent your code. You can also choose to have keywords automatically changed to UPPERCASE as well as indenting the contents inside SUB/FUNCTION procedures. If you don't like the way it alters your code (both at load time and as you type it), just disable it. - -<center>'''Autoformatting and Updating can be turned off in the [[IDE]] using the [[IDE#Options_Menu_.28Alt_.2B_O.29:|Options Menu]]!</center> - -<p style="text-align: center">([[#toc|Return to FAQ topics]])</p> ==Q: Does it work on Windows 98 or any OS older than Windows 2000?== -A: No, it doesn't. QB64 is made to run on new systems (WinXP and up, Linux and macOS). The .exe files produced by QB64 should work in Windows 98 as long as the required DLL libraries, if any, are supported on that system. +A: No, it doesn't. QB64 is made to run on new systems (Windows XP and up, Linux and macOS). +enter> -<center>'''See the [[IDE|IDE Page]] for more information.'''</center> - -==Q: Can Line Numbers be removed from older program code?== - -A: Yes, you can use the Microsoft program below or the program on the following page to remove line numbers that are not required by Basic keywords such as [[GOTO]]. See: [[Line number|Removing line numbers]] - - -<center>'''[ftp://ftp.microsoft.com/services/technet/windows/msdos/RESKIT/SUPPDISK/REMLINE.BAS Microsoft's REMLINE.BAS program removes unnecessary line numbers]'''</center> - - -<p style="text-align: center">([[#toc|Return to FAQ topics]])</p> ==Q: Does QB64 support CURRENCY values from PDS or VB programs?== @@ -747,357 +258,24 @@ A: Not directly, but [[_FLOAT]] currency values up to 4 decimal places can be mu [[GET]] can read a [[_FLOAT]] CURRENCY value as an [[INTEGER64]] variable value divided by 10000. -<center>[[PDS(7.1)_Procedures#CURRENCY|See CURRENCY examples]]</center> - <p style="text-align: center">([[#toc|Return to FAQ topics]])</p> -==Q: What files are required to run older QB64 programs (version .954 and older) in Windows?== -A: Older versions of the QB64 compiler (.954 or older) and '''EVERY''' EXE file created by this version of the compiler are dependant on various DLL Library files to function properly. These files are found inside of the QB64 folder. This also explains why QB64 will create ALL EXE files in the QB64 folder no matter where the original BAS file is located on the computer. Your new program will require these files too, but you can move the DLL files to your shared SYSTEM32 folder to eliminate duplicates! - - -'''Note:''' QB64 produces stand-alone executable files from version 1.000 onward. - - -<center>'''Files required for executables created by older versions of QB64:'''</center> - - -<center>''The list of library files you need to include with your program(s) as of July 2010:''</center> - -{{TextStart}} - - jpeg.dll libfreetype-6.dll libgcc_s_sjlj-1.dll *(.95) libogg-0.dll - - libpng12-0.dll libstdc++-6.dll *(.95) libtiff-3.dll libvorbis-0.dll - -libvorbisfile-3.dll SDL.dll SDL_image.dll SDL_mixer.dll - - SDL_net.dll SDL_ttf.dll smpeg.dll zlib1.dll - - - * denotes DLL updated in (version) -{{TextEnd}} - -<center>'''Other Important Files:'''</center> -{{TextStart}} cyberbit.ttf (12.7 MB v 0.92, October 2010) -{{TextEnd}} -<center>'''NOTE:''' ''cyberbit.ttf'' file is a 12.7 megabyte font for rendering [[Unicode]] characters. Auto-update may be slow downloading this file!</center> -<center>This font is NOT required to be included with a program as QB64 can use other fonts when necessary.</center> - - -<center>It is suggested that frequent users copy the DLL files to the SYSTEM folder in Windows. The location should be: </center> -{{WhiteStart}} - ''C:\WINDOWS\SYSTEM32'' or ''C:\WINDOWS\[[SysWOW64]]'' -{{WhiteEnd}} -This will allow all of your programs to run in any location without copies of the DLL files inside of every program folder. Administrator rights may be necessary to move them there! The '''DATA''' folder files are integrated into the compiler itself in versions .91 and above. - - -<center>'''You may need Administrator rights to install or use QB64.'''</center> - - ----- - - -<center>'''The DATA folder and its contents ARE NO LONGER REQUIRED as of the 8/21/2010 version .91!'''</center> - -<center> ''Files inside of the older version DATA folder.''</center> - -{{TextStart}} - charset8.raw chrset16.raw qb64.pal qb64ega.pal qb64icon '' '' -{{TextEnd}} -<center>{{text|These files are no longer required and are no longer available except with older version downloads!|red}}</center> - -<p style="text-align: center">([[#toc|Return to FAQ topics]])</p> ==Q: Do you provide changelogs?== We do. Check below: * [[Version .9 changelog]] -* [[Version 1.000 changel -4000 -og]] +* [[Version 1.000 changelog]] * [[Version 1.1 changelog]] +* For more recent changelogs, check [http://www.qb64.org QB64.org] <p style="text-align: center">([[#toc|Return to FAQ topics]])</p> -==Q: Does a User licence come with QB64?== -A: Yes, as of version 0.85 a licence comes with QB64 released as freeware. Read the licence.txt that comes with the download package for more information. QB64 will always be free to use with the current library files and the licenses DO NOT LIMIT the use of those libraries! You are also allowed to sell software that you create with the following stipulations: - -{{TextStart}} '''QB64 SDL SOFTWARE LICENSE''' - -QB64 is currently released as freeware meaning that this download may be copied/distributed -free of charge. All rights to the programs you create using QB64 (in both their executable -and source form) belong to you. '''You are under no obligation to release the source code to''' -'''the programs you create. You can sell the programs you create for profit.''' You are under no -obligation to acknowledge that the programs you create were written in QB64 or reference -the QB64 website in any way. - -The dynamically linked libraries (the DLL files you must include with your programs) are -distributed under '''LGPL'''. Requirements for this can be found at the following URL: - - http://www.libsdl.org/license-lgpl.php - -QB64 and QB64 programs dynamically link to SDL (Simple DirectMedia Layer) libraries. SDL -libraries are made available under the '''GNU Lesser General Public License (LGPL)'''. Details of -the SDL license requirements can be found at the above URL. - - -Libraries are used in their 'standard'/unmodified versions and source code for these -libraries can be found at: - - http://www.libsdl.org - -The QB64 compiler generates C++ code which is compiled into executable form by the MINGW -GCC compiler. QB64 uses a version of the MINGW & GCC compilers found at the following URL: - - http://www.drangon.org/mingw/ - -The official version of MINGW GCC compiler can be found at the following URL: - - http://www.mingw.org/ '' '' -{{TextEnd}} - -:The choice of license makes a big difference: using the '''Lesser GPL''' permits use of the library in proprietary programs; using the ordinary GPL for a library makes it available only for free programs. - - -<Center>'''QB64 GL License found in the License folder with other licenses:'''</center> -{{TextStart}} - '''IMPORTANT LICENSING NOTE FOR QB64 GL PROGRAMMERS''' -All executables which perform any kind of sound operation are subject to the LGPL license -(due to incorporation of mpglibdll and OpenAL). -Other components are licensed under various permissive licences. -When sound components are included (thus the LGPL is in effect), the easiest way to meet -terms of the LGPL is to make your program's source code (.BAS) available. -'''If you are not using sound components, you do not need to release the program's source.''' -'''If you are using fonts, you are bound by the terms of FreeType's license.''' Somewhere -in your software package should include a notice that your program includes the FreeType -library (see licence_freetype_ftl.txt for details) -'''In all cases, you should distribute the LICENSE folder with your program.''' - -It should be noted that providing source code is not the only way to meet the conditions of -the LGPL (eg dynamic linking) but it is by far the easiest from a technical point of view at -this current time. - - -The license requirements for components of QB64 are as follows: - -Software/Library Name: QB64 (inclusive of all parts of this distribution not covered by -separate licence below) -Website(s): http://www.qb64.net, http://code.google.com/p/qb64/ -License: LGPL with static linking of code required for generated programs to run permitted -License Website: http://www.gnu.org/licenses/licenses.html#LGPL -License File: license/lgpl_2_1.txt - -Software/Library Name: MinGW 64 -Website: http://mingw-w64.sourceforge.net/ -License: (see below) -Each of the various packages, which is distributed by MinGW.org, is governed by its own -individual copyright and licensing terms. In summary, for the most commonly deployed -packages: -MinGW runtime: The MinGW base runtime package has been placed in the public domain, and -is not governed by copyright. This basically means that you can do what you like with the -code.w32api: You are free to use, modify and copy this package. No restrictions are imposed -on programs or object files linked with this library. You may not restrict the the usage of -this library. You may distribute this library as part of another package or as a modified -package if, and only if, you do not restrict the usage of the portions consisting of this -(optionally modified) library. If distributed as a modified package, then a copy of this -notice must be included. -This library is distributed in the hope that it will be useful, but WITHOUT WARRANTY OF -ANY KIND; without even the implied warranties of MERCHANTABILITY or of FITNESS FOR A -PARTICULAR PURPOSE. -MinGW profiling code: MinGW profiling code is distributed under the terms of the GNU General -Public License. -Binutils, GCC, GDB, GNU Make: All of the GNU development tools, such as GNU binutils, GCC, -GDB and GNU Make, are governed by the terms of the GNU General Public License. -License Website: http://www.gnu.org/licenses/licenses.html#GPL -License File: license_gnu_gpl_3.txt -Location in QB64 distribution: internal/c/c_compiler/ - -Software/Library Name: Opus Tools -Website: http://www.opus-codec.org/ -License: BSD 2-clause license -License Website: http://opensource.org/licenses/BSD-2-Clause -License File: license_opus.txt -Location in QB64 distribution: internal/c/parts/audio/conversion/ -OpusInfo, which is under a GPL licence, was included in Opus Tools but has been removed -from the QB64 distribution. - -Software/Library Name: mpglibdll -Website(s): -http://www.rz.uni-frankfurt.de/~pesch -http://www.mpg123.de -http://www.sulaco.org/mp3 -License: LGPL 2.1 -License Website: http://www.gnu.org/licenses/licenses.html#LGPL -License File: license_gnu_lgpl_2_1.txt -Location in QB64 distribution: internal/c/parts/audio/decode/mp3/ - -Software/Library Name: Ogg Vorbis I audio decoder version 1.05 -Website:http://nothings.org/stb_vorbis/ -Date:Written in April 2007 -Author:Sean Barrett, sponsored by RAD Game Tools -License: Placed in the public domain April 2007 by the author: no copyright is claimed, and -you may use it for any purpose you like. -License Website: N/A - public domain -License File: license_stbvorbis.txt -Location in QB64 distribution: internal/c/parts/audio/decode/ogg/ - -Software/Library Name: OpenAL-soft -Website:http://kcat.strangesoft.net/openal.html -License: LGPL 2 -License Website: http://www.gnu.org/licenses/licenses.html#LGPL -License File: license_gnu_lgpl_2.txt -Location in QB64 distribution: internal/c/parts/audio/out/ - -Software/Library Name: FreeGLUT -Website: http://freeglut.sourceforge.net/ -License: LGPL (note: website states LGPL, license file is not a copy of GNU LGPL) -License Website: http://www.gnu.org/licenses/licenses.html#LGPL -License File: license_freeglut.txt -Location in QB64 distribution: internal/c/parts/core/ - -Software/Library Name: FreeTYPE -Website: http://www.freetype.org/ -License: GPL or FreeTYPE's FTL (programs must abide by one of these licenses) -License Website(s): (see below) -http://www.freetype.org/license.html -http://www.gnu.org/licenses/licenses.html#GPL -License File(s): (see below) -license_freetype_ftl.txt -license_gnu_gpl_2.txt -Location in QB64 distribution: internal/c/parts/video/font/ttf/ - -Software/Library Name: NanoJPEG - KeyJ's Tiny Baseline JPEG Decoder -Author: Martin J. Fiedler <martin.fiedler@gmx.net> -License: (refer to license file) -License File: nanojpeg_license.txt -Location in QB64 distribution: internal/c/parts/video/image/decode/jpg - -Software/Library Name: NanoJPEG - KeyJ's Tiny Baseline JPEG Decoder -Author: Martin J. Fiedler <martin.fiedler@gmx.net> -License: (refer to license file) -License File: license_nanojpeg.txt -Location in QB64 distribution: internal/c/parts/video/image/decode/jpg - -Software/Library Name: LodePNG -License: (refer to license file) -License File: license_lodepng.txt -Location in QB64 distribution: internal/c/parts/video/image/decode/png -{{TextEnd}} - - -<center> '''The creator of QB64 is NOT responsible for any damages or the intended use of the software it creates!'''</center> - -<center>'''The user assumes all risk when they download or use the QB64 compiler!'''</center> - - -<p style="text-align: center">([[#toc|Return to FAQ topics]])</p> - -==Q: How can I find what caused a Compiler error?== - -A: Compiler errors are often actually coding errors that both you and the IDE don't notice! Often it is a syntax error such as forgetting a quotation mark in a PRINT. Look for syntax errors too. - -* You will find a script/batch file called '''recompile_win.bat''' (also '''recompile_osx.command''' or '''recompile_lnx.sh''', according to your operating system) inside the folder '''internal\temp''' (if you have more than one instance of the IDE open, look inside temp2, temp3, etc). -* Immediately after encountering a "C++ compilation failed" message, run this script to have a look at the error message returned by the gcc compiler. That usually helps track the issue. - - ----- - - -''For versions of QB64 below .954, the best way to get a clue to the problem is to run the following batch file IMMEDIATELY AFTER a compilation failure: '''CODE UPDATED 1/4/2011''''' - -<center>'''{{text|It's a good idea to exclude "QB64.exe" from any real-time anti-virus scanning to prevent IDE Module Errors!|red}}'''</center> - -<center>'''Displays errors in a DOS Console window'''</center> -{{TextStart}} '' '' -@echo off -ECHO. -ECHO Diagnosing Latest Compilation Error -ECHO. -ECHO Please wait... -ECHO. - -cd .\internal\c -.\bin\g -w -Wall -I.\i -I..\..\ -L.\l qbx.cpp libqbx.o -mwindows .\i686-w64-mingw32\lib\libimm32.a -lwinspool -lmingw32 -ln -lmix -limg -lttf -lmn -lSDL -o ..\..\test64.exe -cd ..\.. - -ECHO. -ECHO. -PAUSE '' '' -{{TextEnd}} -<center>'''Note: Make sure that ''test64.exe'' is at the end of the long code line when copying!'''</center> - - -<center>'''Places compiler errors into the ''0utput64.txt'' file'''</center> -{{TextStart}} '' '' -@echo off -ECHO. -ECHO Diagnosing Latest Compilation Error -ECHO. -ECHO Please wait... -ECHO. -cd .\internal\c -.\bin\g -w -Wall -I.\i -I..\..\ -L.\l qbx.cpp libqbx.o -mwindows .\i686-w64-mingw32\lib\libimm32.a -lwinspool -lmingw32 -ln -lmix -limg -lttf -lmn -lSDL -s -o ..\..\ >..\..\0utput64.txt 2>&1 -cd ..\.. - -ECHO. -ECHO 0utput64.txt created! -ECHO. -PAUSE '' '' -{{TextEnd}} -<center>'''Note: Make sure that ''0utput64.txt 2>&1'' is at the end of the long code line when copying!'''</center> - - -<center>'''To create the Batch file, copy code above to Notepad and save it as ''QB64ERR.BAT''. Save as type: ''All Files''.'''</center> - - -Look for the word '''error''' in the resulting information. The errors often have to do with syntax or code errors not found by the [[IDE]]. - -<center>'''Place the batch files into the QB64 folder to use.'''</center> - - -<p style="text-align: center">([[#toc|Return to FAQ topics]])</p> - -==Q: How do I use the QB64 code Repository?== - -A: QB64 is open source freeware and all the codebase is freely available on GitHub at [https://github.com/Galleondragon/qb64 this link]. You can fork it, develop your own modified version of it and '''most importantly: help improve the official version by making pull requests.''' If you are already familiar with code collaboration, versioning control using git and would like to help, become involved! Your contributions could end up becoming part of the QB64 project. - -<!-- You can find a video tutorial here: [http://www.qb64.net/qb64_repository_tutorial.mp4 Repository Video Tutorial] --> - - -:: '''I cannot stress enough that the QB64 repository is not an official QB64 release! Even though our contributors are individually appointed, I'm not responsible for the contributions of these other authors which could potentially be malicious. ''' - -::'''Galleon''' - - -<p style="text-align: center">([[#toc|Return to FAQ topics]])</p> - -==Q: Where I can view the C++ code before it gets compiled== +==Q: Where I can view the C++ code before it gets compiled?== Look in the QB64 '''internal\temp''' folder for '''main.txt''' to get the C code used to compile the latest program. -==Q: Where can I find information about a QB64 statement or function?== - - -<center>'''[[Known QB64 Issues]]'''</center> - - -<center>'''[http://www.qb64.net/forum/index.php QB64 Forum] ([[Forum Tips]])'''</center> - - -<center>'''[http://qb64.net/wiki/index.php?title=QB64_Tutorials QB64 Tutorials]''' - - -[[Main_Page#Appendix:|Appendix of QB64 Procedures]] - - -[http://qb64.net/wiki/index.php?title=Main_Page#Appendix: Information about Programming concepts]</center> - - -<p style="text-align: center">[[Keywords currently not supported by QB64]]</p> - -<center>[[Keywords_currently_not_supported_by_QB64#Keywords_Not_Supported_in_Linux_or_MAC_OSX_versions|Keywords Not Supported in Linux or MAC OSX versions]]</center> - {{PageNavigation}} diff --git a/internal/help/RSET.txt b/internal/help/RSET.txt index c265a0722..8777a7378 100644 --- a/internal/help/RSET.txt +++ b/internal/help/RSET.txt @@ -15,7 +15,7 @@ The '''RSET''' statement right-justifies a string according to length of the str {{CodeStart}} '' '' {{Cl|CLS}} {{Cl|DIM}} thestring {{Cl|AS}} {{Cl|STRING}} * 10 -{{Cl|PRINT}} "12345678901234567890 +{{Cl|PRINT}} "12345678901234567890" {{Cl|RSET}} thestring = "Hello!" {{Cl|PRINT}} thestring anystring$ = {{Cl|SPACE$}}(20) diff --git a/internal/help/SGN.txt b/internal/help/SGN.txt index 4f5ffbbb1..e6aa68534 100644 --- a/internal/help/SGN.txt +++ b/internal/help/SGN.txt @@ -7,8 +7,8 @@ The '''SGN''' function returns the sign of a number value. -* Returns -1 when a sign is negative, 0 when a value is zero or 1 when a value is positive. -* Used to hold the original sign of a number. +* Returns -1 when a sign is negative, 0 when a value is zero, or 1 when a value is positive. +* Function is used to store the original sign of a number. * '''QB64''' allows programs to return only [[_UNSIGNED]] variable values using a [[_DEFINE]] statement. diff --git a/internal/help/SUB.txt b/internal/help/SUB.txt index ee3a2a16c..4c64db8ec 100644 --- a/internal/help/SUB.txt +++ b/internal/help/SUB.txt @@ -48,16 +48,14 @@ Center 10, 15, "This text is centered." ' example module sub call {{Cl|DEFINT}} A-Z ' only code allowed before SUB line is a DEF statement or a comment {{Cl|SUB}} Center (Tclr, Trow, Text$) -{{Cl|DEF SEG}} = &H40 -Columns = {{Cl|PEEK}}(&H4A) -{{Cl|DEF SEG}} +Columns = {{Cl|_WIDTH}} / {{Cl|_FONTWIDTH}} 'Convert _WIDTH (in pixels) to width in characters Middle = (Columns \ 2) + 1 ' reads any screen mode width Tcol = Middle - ({{Cl|LEN}}(Text$) \ 2) {{Cl|COLOR}} Tclr: {{Cl|LOCATE}} Trow, Tcol: {{Cl|PRINT}} Text$; ' end semicolon prevents screen roll {{Cl|END SUB}} '' '' {{CodeEnd}} -:''Explanation:'' The procedure centers text printed to the screen. The parameters are the text color, row and the text itself as a string or string variable. The maximum width of the screenmode is found and divided in half to find the center point. The text string's length is also divided in half and subtracted from the screen's center position. The procedure will also work when the [[WIDTH]] statement has been used. When adding variables to Text$ use the + concatenation operator. Not semicolons! +:''Explanation:'' The procedure centers text printed to the screen. The parameters are the text color, row and the text itself as a string or string variable. The maximum width of the screen mode in characters is found and divided in half to find the center point. The text string's length is also divided in half and subtracted from the screen's center position. The procedure will also work when the [[WIDTH]] statement has been used. When adding variables to Text$ use the + concatenation operator. Not semicolons! ''Example 2:'' SUB and [[FUNCTION]] procedures always return to the place they were called in the main or other sub-procedures: diff --git a/internal/help/_ASSERT.txt b/internal/help/_ASSERT.txt new file mode 100644 index 000000000..15e0ec5bd --- /dev/null +++ b/internal/help/_ASSERT.txt @@ -0,0 +1,47 @@ +{{DISPLAYTITLE:_ASSERT}} +The [[_ASSERT]] statement can be used to perform tests in code that's in development, for debugging purposes. + + +{{PageSyntax}} +:[[_ASSERT]] {{Parameter|condition}}[, {{Parameter|errorMessage$}}] + + +{{PageDescription}} +* {{Parameter|condition}} is the condition that must be met in order to consider the _ASSERT valid. +* Optional {{Parameter|errorMessage$}} is the message to be displayed in the console window if [[$ASSERTS|$ASSERTS:CONSOLE]] is used. +* If the condition is not met (that is, if it evaluates to 0), an error occurs ("_ASSERT failed on line #") and program execution stops. + + +==Availability== +* '''Version 1.4 and up'''. + + +{{PageExamples}} +''Example:'' Adding test checks for parameter inputs in a function. +{{CodeStart}} +{{Cl|$ASSERTS}}:CONSOLE + +{{Cl|DO}} + a = {{Cl|INT}}({{Cl|RND}} * 10) + b$ = myFunc$(a) + {{Cl|PRINT}} a, , b$ + {{Cl|_LIMIT}} 3 +{{Cl|LOOP}} {{Cl|UNTIL}} {{Cl|_KEYHIT}} + +{{Cl|FUNCTION}} myFunc$ (value {{Cl|AS}} {{Cl|SINGLE}}) + {{Cl|_ASSERT}} value > 0, "Value cannot be zero" + {{Cl|_ASSERT}} value <= 10, "Value cannot exceed 10" + + {{Cl|IF}} value > 1 {{Cl|THEN}} plural$ = "s" + myFunc$ = {{Cl|STRING$}}(value, "*") + {{Cl|STR$}}(value) + " star" + plural$ + " :-)" +{{Cl|END}} {{Cl|FUNCTION}} +{{CodeEnd}} + + +{{PageSeeAlso}} +* [[$ASSERTS]] +* [[$CHECKING]] +* [[Relational Operations]] + + +{{PageNavigation}} diff --git a/internal/help/_CAPSLOCK.txt b/internal/help/_CAPSLOCK.txt new file mode 100644 index 000000000..c4487e9e2 --- /dev/null +++ b/internal/help/_CAPSLOCK.txt @@ -0,0 +1,19 @@ +{{DISPLAYTITLE:_CAPSLOCK}} +The [[_CAPSLOCK]] statement sets the state of the Caps Lock key. + + +{{PageSyntax}} +: [[_CAPSLOCK]] {ON|OFF|_TOGGLE} + + +==Availability== +* Version 1.4 and up. +* [[Keywords_currently_not_supported_by_QB64#Keywords_Not_Supported_in_Linux_or_MAC_OSX_versions|Not available in Linux or macOS]]. + + +{{PageSeeAlso}} +* [[_CAPSLOCK (function)]], [[_NUMLOCK (function)]], [[_SCROLLLOCK (function)]] +* [[_NUMLOCK]] (statement), [[_SCROLLLOCK]] (statement) + + +{{PageNavigation}} diff --git a/internal/help/_CAPSLOCK_(function).txt b/internal/help/_CAPSLOCK_(function).txt new file mode 100644 index 000000000..b80f898d6 --- /dev/null +++ b/internal/help/_CAPSLOCK_(function).txt @@ -0,0 +1,19 @@ +{{DISPLAYTITLE:_CAPSLOCK (function)}} +The [[_CAPSLOCK (function)| _CAPSLOCK]] function returns the current state of the Caps Lock key as on (-1) or off (0). + + +{{PageSyntax}} +: {{Parameter|keyStatus%%}} = [[_CAPSLOCK (function)| _CAPSLOCK]] + + +==Availability== +* Version 1.4 and up. +* [[Keywords_currently_not_supported_by_QB64#Keywords_Not_Supported_in_Linux_or_MAC_OSX_versions|Not available in Linux or macOS]]. + + +{{PageSeeAlso}} +* [[_NUMLOCK (function)]], [[_SCROLLLOCK (function)]] +* [[_CAPSLOCK]] (statement), [[_NUMLOCK]] (statement), [[_SCROLLLOCK]] (statement) + + +{{PageNavigation}} diff --git a/internal/help/_COPYIMAGE.txt b/internal/help/_COPYIMAGE.txt index f486faee3..fd9f4ce3c 100644 --- a/internal/help/_COPYIMAGE.txt +++ b/internal/help/_COPYIMAGE.txt @@ -3,7 +3,7 @@ The [[_COPYIMAGE]] function creates an identical designated image in memory with {{PageSyntax}} -: newhandle& = [[_COPYIMAGE]][({{Parameter|imageHandle&]][, {{Parameter|mode%]])]] +: newhandle& = [[_COPYIMAGE]][({{Parameter|imageHandle&}}[, {{Parameter|mode%}})]] {{Parameters}} diff --git a/internal/help/_DEFLATE$.txt b/internal/help/_DEFLATE$.txt new file mode 100644 index 000000000..dc3fde071 --- /dev/null +++ b/internal/help/_DEFLATE$.txt @@ -0,0 +1,48 @@ +{{DISPLAYTITLE:_DEFLATE$}} +The [[_DEFLATE$]] function compresses a [[STRING|string]]. + + +{{PageSyntax}} +:{{Parameter|result$}} = [[_DEFLATE$]]({{Parameter|stringToCompress$}}) + + +{{PageDescription}} +* {{Parameter|result$}} will contain the compressed version of {{Parameter|stringToCompress$}}. +* To decompress the resulting string, use [[_INFLATE$]]. + + +==Availability== +* '''Version 1.4 and up'''. + + +{{PageExamples}} +''Example 1:'' Compressing a long string of text. +{{CodeStart}} +a$ = "The quick brown fox jumps over the lazy dog. " +{{Cl|PRINT}} "Original string (a$): "; a$ +{{Cl|FOR}} i = 1 {{Cl|TO}} 15 + a$ = a$ + a$ +{{Cl|NEXT}} + +{{Cl|PRINT}} "After concatenating it into itself several times, LEN(a$) ="; {{Cl|LEN}}(a$) + +b$ = {{Cl|_DEFLATE$}}(a$) +{{Cl|PRINT}} "After using _DEFLATE$ to compress it, LEN ="; {{Cl|LEN}}(b$) +{{Cl|PRINT}} {{Cl|USING}} "(compressed size is #.###% of the original)"; (({{Cl|LEN}}(b$) * 100) / {{Cl|LEN}}(a$)) +c$ = {{Cl|_INFLATE$}}(b$) +PRINT "After using _INFLATE$ to decompress it, LEN ="; {{Cl|LEN}}(c$) + {{CodeEnd}} +{{OutputStart}} +Original string (a$): The quick brown fox jumps over the lazy dog +After concatenating it into itself several times, LEN(a$) = 1474560 +After using _DEFLATE$ to compress it, LEN = 4335 +(compressed size is 0.295% of the original) +After using _INFLATE$ to decompress it, LEN = 1474560 +{{OutputEnd}} + + +{{PageSeeAlso}} +* [[_INFLATE$]] + + +{{PageNavigation}} diff --git a/internal/help/_DONTBLEND.txt b/internal/help/_DONTBLEND.txt index f025fdca2..6032bfe57 100644 --- a/internal/help/_DONTBLEND.txt +++ b/internal/help/_DONTBLEND.txt @@ -12,9 +12,10 @@ The [[_DONTBLEND]] statement turns off 32 bit alpha blending for the current ima {{PageDescription}} * If {{Parameter|imageHandle&}} is not valid, an [[ERROR Codes|Invalid handle]] error will occur. -* [[_DONTBLEND]] is faster than the default [[_BLEND]] unless you really need to use it in 32 bit. +* [[_DONTBLEND]] is faster than the default [[_BLEND]]. '''You may want to disable it''', unless you really need to use it in 32 bit. * '''32 bit screen surface backgrounds (black) have zero [[_ALPHA]] so that they are transparent when placed over other surfaces.''' -* Use [[CLS]] or [[_DONTBLEND]] to make a new surface background [[_ALPHA]] 255 or opaque. +* Use [[CLS]] to make a new surface background [[_ALPHA]] 255 or opaque. +* Both [[_SOURCE]] and [[_DEST]] must have [[_BLEND]] enabled, or else colors will NOT blend. {{PageExamples}} @@ -41,7 +42,7 @@ SaveBackground& = {{Cl|_COPYIMAGE}}(0) {{Cl|END FUNCTION}} {{Cl|SUB}} RestoreBackground (Image {{Cl|AS}} {{Cl|LONG}}) -{{Cl|_PUTIMAGE}} (200, 200), Image, 0 +{{Cl|_PUTIMAGE}} , Image, 0 {{Cl|END SUB}} '' '' {{CodeEnd}} diff --git a/internal/help/_INFLATE$.txt b/internal/help/_INFLATE$.txt new file mode 100644 index 000000000..2f17ee0b5 --- /dev/null +++ b/internal/help/_INFLATE$.txt @@ -0,0 +1,46 @@ +{{DISPLAYTITLE:_INFLATE$}} +The [[_INFLATE$]] function decompresses a [[STRING|string]] compressed by the [[_DEFLATE$]] function. + + +{{PageSyntax}} +:{{Parameter|result$}} = [[_INFLATE$]]({{Parameter|stringToDecompress$}}) + + +{{PageDescription}} +* {{Parameter|result$}} will contain the original version of {{Parameter|stringToDecompress$}}. + + +==Availability== +* '''Version 1.4 and up'''. + + +{{PageExamples}} +''Example 1:'' Compressing a long string of text. +{{CodeStart}} +a$ = "The quick brown fox jumps over the lazy dog. " +{{Cl|PRINT}} "Original string (a$): "; a$ +{{Cl|FOR}} i = 1 {{Cl|TO}} 15 + a$ = a$ + a$ +{{Cl|NEXT}} + +{{Cl|PRINT}} "After concatenating it into itself several times, LEN(a$) ="; {{Cl|LEN}}(a$) + +b$ = {{Cl|_DEFLATE$}}(a$) +{{Cl|PRINT}} "After using _DEFLATE$ to compress it, LEN ="; {{Cl|LEN}}(b$) +{{Cl|PRINT}} {{Cl|USING}} "(compressed size is #.###% of the original)"; (({{Cl|LEN}}(b$) * 100) / {{Cl|LEN}}(a$)) +c$ = {{Cl|_INFLATE$}}(b$) +PRINT "After using _INFLATE$ to decompress it, LEN ="; {{Cl|LEN}}(c$) + {{CodeEnd}} +{{OutputStart}} +Original string (a$): The quick brown fox jumps over the lazy dog +After concatenating it into itself several times, LEN(a$) = 1474560 +After using _DEFLATE$ to compress it, LEN = 4335 +(compressed size is 0.295% of the original) +After using _INFLATE$ to decompress it, LEN = 1474560 +{{OutputEnd}} + +{{PageSeeAlso}} +* [[_DEFLATE$]] + + +{{PageNavigation}} diff --git a/internal/help/_MAPTRIANGLE.txt b/internal/help/_MAPTRIANGLE.txt index 660576b34..09ebf0b42 100644 --- a/internal/help/_MAPTRIANGLE.txt +++ b/internal/help/_MAPTRIANGLE.txt @@ -208,9 +208,7 @@ DO xx1% = DPLANE2D(0, 0): yy1% = DPLANE2D(0, 1) xx3% = DPLANE2D(2, 0): yy3% = DPLANE2D(2, 1) xx4% = DPLANE2D(3, 0): yy4% = DPLANE2D(3, 1) - {{Cl|_MAPTRIANGLE}} (0, 0 -4000 -)-(255, 255)-(255, 0), TextureImage& TO(xx3%, yy3%)-(xx1%, yy1%)-(xx4%, yy4%) + {{Cl|_MAPTRIANGLE}} (0, 0)-(255, 255)-(255, 0), TextureImage& TO(xx3%, yy3%)-(xx1%, yy1%)-(xx4%, yy4%) 'CALL DrawTriangle(xx1%, yy1%, xx3%, yy3%, xx4%, yy4%, col%) {{Cl|END IF}} {{Cl|NEXT}} @@ -636,9 +634,7 @@ DO y1% = y2% ydiff1% = y3% - y1% ydiff2% = y3% - y2% - {{Cl|IF... -2fb2 -THEN|IF}} ydiff1% <> 0 {{Cl|THEN}} + {{Cl|IF...THEN|IF}} ydiff1% <> 0 {{Cl|THEN}} slope1! = (x3% - x1%) / ydiff1% {{Cl|ELSE}} slope1! = 0 diff --git a/internal/help/_NUMLOCK.txt b/internal/help/_NUMLOCK.txt new file mode 100644 index 000000000..fc8cbbbbe --- /dev/null +++ b/internal/help/_NUMLOCK.txt @@ -0,0 +1,19 @@ +{{DISPLAYTITLE: _NUMLOCK}} +The [[_NUMLOCK]] statement sets the state of the Num Lock key. + + +{{PageSyntax}} +: [[_NUMLOCK]] {ON|OFF|_TOGGLE} + + +==Availability== +* Version 1.4 and up. +* [[Keywords_currently_not_supported_by_QB64#Keywords_Not_Supported_in_Linux_or_MAC_OSX_versions|Not available in Linux or macOS]]. + + +{{PageSeeAlso}} +* [[_CAPSLOCK (function)]], [[_NUMLOCK (function)]], [[_SCROLLLOCK (function)]] +* [[_CAPSLOCK]] (statement), [[_SCROLLLOCK]] (statement) + + +{{PageNavigation}} diff --git a/internal/help/_NUMLOCK_(function).txt b/internal/help/_NUMLOCK_(function).txt new file mode 100644 index 000000000..8849a5862 --- /dev/null +++ b/internal/help/_NUMLOCK_(function).txt @@ -0,0 +1,19 @@ +{{DISPLAYTITLE: _NUMLOCK (function)}} +The [[_NUMLOCK (function)| _NUMLOCK]] function returns the current state of the Num Lock key as on (-1) or off (0). + + +{{PageSyntax}} +: {{Parameter|keyStatus%%}} = [[_NUMLOCK (function)| _NUMLOCK]] + + +==Availability== +* Version 1.4 and up. +* [[Keywords_currently_not_supported_by_QB64#Keywords_Not_Supported_in_Linux_or_MAC_OSX_versions|Not available in Linux or macOS]]. + + +{{PageSeeAlso}} +* [[_CAPSLOCK (function)]], [[_SCROLLLOCK (function)]] +* [[_CAPSLOCK]] (statement), [[_NUMLOCK]] (statement), [[_SCROLLLOCK]] (statement) + + +{{PageNavigation}} diff --git a/internal/help/_OS$.txt b/internal/help/_OS$.txt index a64aa1eab..4b792d937 100644 --- a/internal/help/_OS$.txt +++ b/internal/help/_OS$.txt @@ -15,7 +15,6 @@ The [[_OS$]] function returns the operating system and QB64 compiler bit version {{PageSeeAlso}} * [[ENVIRON$]] -* [[QB64_FAQ#Q:_How_do_I_upgrade_the_32_bit_Windows_version_of_QB64_to_64_bit_functionality.3F|Upgrading QB64 to use a 64-bit compiler in Windows]] {{PageNavigation}} diff --git a/internal/help/_PUTIMAGE.txt b/internal/help/_PUTIMAGE.txt index 8429d2721..2c1aaf1ba 100644 --- a/internal/help/_PUTIMAGE.txt +++ b/internal/help/_PUTIMAGE.txt @@ -46,7 +46,6 @@ {{PageDescription}} * _PUTIMAGE can be used without any handle parameters if the [[_SOURCE]] and/or [[_DEST]] are already defined. -* '''The {{Parameter|sourceHandle&}} and {{Parameter|destHandle&}} cannot be the same or an [[ERROR Codes|Illegal Function Call]] error will occur.''' * If the area of the source is bigger or smaller than the area of the destination then the image is adjusted to fit that area. * Supports 32 bit alpha blending, color key transparency, true type fonts, stretching, mirroring/flipping, and a variety of graphics file formats including gif, png, bmp & jpg. '''32 bit screen surface backgrounds (black) have zero [[_ALPHA]] and are transparent when placed over other surfaces.''' Use [[CLS]] or [[_DONTBLEND]] to make a new surface background [[_ALPHA]] 255 or opaque. * All graphical surfaces, including screen pages, can be acted upon in the same manner, and are referred to as "images". @@ -158,9 +157,7 @@ DO {{Cl|CASE}} "6": x = x + 10: {{Cl|IF...THEN|IF}} x > 1280 {{Cl|THEN}} x = 1280 {{Cl|CASE}} "8": y = y - 10: {{Cl|IF...THEN|IF}} y < 0 {{Cl|THEN}} y = 0 {{Cl|CASE}} "2": y = y + 10: {{Cl|IF...THEN|IF}} y > 720 {{Cl|THEN}} y = 720 - {{Cl|CA -271a -SE}} {{Cl|CHR$}}(32): {{Cl|SYSTEM}} + {{Cl|CASE}} {{Cl|CHR$}}(32): {{Cl|SYSTEM}} {{Cl|END SELECT}} {{Cl|_DISPLAY}} {{Cl|LOOP}} '' '' diff --git a/internal/help/_READBIT.txt b/internal/help/_READBIT.txt new file mode 100644 index 000000000..55c7e3e73 --- /dev/null +++ b/internal/help/_READBIT.txt @@ -0,0 +1,57 @@ +{{DISPLAYTITLE:_READBIT}} +The [[_READBIT]] function is used to check the state of a specified bit of a integer value. + + +{{PageSyntax}} +:{{Parameter|result}} = [[_READBIT]]({{Parameter|numericalVariable}}, {{Parameter|numericalValue}}) + + +{{Parameters}} +* {{Parameter|numericalVariable}} is the variable to read the state of a bit of and can be of the following types: [[_BYTE]], [[INTEGER]], [[LONG]], or [[_INTEGER64]]. +* Integer values can be signed or [[_UNSIGNED]]. +* {{Parameter|numericalValue}} the number of the bit to be read. + + +{{PageDescription}} +* Used to check the current state of a bit in an integer value. +* Returns -1 if the bit is set(1), otherwise returns 0 if the bit is not set(0) +* Bits start at 0 (so a [[_BYTE]] has bits 0 to 7, [[INTEGER]] 0 to 15, and so on) + +==Availability== +* '''Version 1.4 and up'''. + + +{{PageExamples}} +''Example 1:'' +{{CodeStart}} +A~%% = {{Cl|_SETBIT}}(A~%%,4) +{{Cl|PRINT}} "Bit 4 is currently "; +IF {{Cl|_READBIT}}(A~%%,4) = -1 THEN {{Cl|PRINT}} "ON" ELSE {{Cl|PRINT}} "OFF" +{{Cl|PRINT}} "And bit 2 is currently "; +IF {{Cl|_READBIT}}(A~%%,2) = -1 THEN {{Cl|PRINT}} "ON" ELSE {{Cl|PRINT}} "OFF" +{{CodeEnd}} +{{OutputStart}} +Bit 4 is currently ON +And bit 2 is currently OFF +{{OutputEnd}} + +''Example 2:'' +{{CodeStart}} +B& = 12589575 +{{Cl|PRINT}} "B& ="; B& +FOR I%% = 31 TO 0 STEP -1 '32 bits for a {{Cl|LONG}} value + Binary$ = Binary$ + {{Cl|LTRIM$}}({{Cl|STR$}}({{Cl|ABS}}({{Cl|_READBIT}}(B&, I%%)))) +NEXT I%% +{{Cl|PRINT}} "B& in binary is: "; Binary${{CodeEnd}} +{{OutputStart}} +B& = 12589575 +B& in binary is: 00000000110000000001101000000111 +{{OutputEnd}} + + +{{PageSeeAlso}} +* [[_SHL]], [[_SHR]], [[INTEGER]], [[LONG]] +* [[_SETBIT]], [[_BYTE]], [[_INTEGER64]] +* [[_RESETBIT]], [[_TOGGLEBIT]] + +{{PageNavigation}} diff --git a/internal/help/_RESETBIT.txt b/internal/help/_RESETBIT.txt new file mode 100644 index 000000000..6dec11c87 --- /dev/null +++ b/internal/help/_RESETBIT.txt @@ -0,0 +1,46 @@ +{{DISPLAYTITLE:_RESETBIT}} +The [[_RESETBIT]] function is used to set a specified bit of a numerical value to 0 (OFF state). + + +{{PageSyntax}} +:{{Parameter|result}} = [[_RESETBIT]]({{Parameter|numericalVariable}}, {{Parameter|numericalValue}}) + + +{{Parameters}} +* {{Parameter|numericalVariable}} is the variable to set the bit of and can be of the following types: [[_BYTE]], [[INTEGER]], [[LONG]], or [[_INTEGER64]]. +* Integer values can be signed or [[_UNSIGNED]]. +* {{Parameter|numericalValue}} the number of the bit to be set. + + +{{PageDescription}} +* Can be used to manually manipulate individual bits of an integer value by setting them to 0 (OFF state). +* Resetting a bit that is already set to 0 will have no effect. +* Bits start at 0 (so a [[_BYTE]] has bits 0 to 7, [[INTEGER]] 0 to 15, and so on) + +==Availability== +* '''Version 1.4 and up'''. + + +{{PageExamples}} +''Example 1:'' +{{CodeStart}}A~%% = 0 '{{Cl|_UNSIGNED}} {{Cl|_BYTE}} +{{Cl|PRINT}} A~%% +A~%% = {{Cl|_SETBIT}}(A~%%,6) 'set the seventh bit of A~%% +{{Cl|PRINT}} A~%% +A~%% = {{Cl|_RESETBIT}}(A~%%,6) 'Reset the seventh bit of A~%% +{{Cl|PRINT}} A~%% +{{CodeEnd}} +{{OutputStart}} + 0 + 64 + 0 +{{OutputEnd}} + + + +{{PageSeeAlso}} +* [[_SHL]], [[_SHR]], [[INTEGER]], [[LONG]] +* [[_SETBIT]], [[_BYTE]], [[_INTEGER64]] +* [[_READBIT]], [[_TOGGLEBIT]] + +{{PageNavigation}} diff --git a/internal/help/_SCROLLLOCK.txt b/internal/help/_SCROLLLOCK.txt new file mode 100644 index 000000000..518b28d73 --- /dev/null +++ b/internal/help/_SCROLLLOCK.txt @@ -0,0 +1,19 @@ +{{DISPLAYTITLE: _SCROLLLOCK}} +The [[_SCROLLLOCK]] statement sets the state of the Scroll Lock key. + + +{{PageSyntax}} +: [[_SCROLLLOCK]] {ON|OFF|_TOGGLE} + + +==Availability== +* Version 1.4 and up. +* [[Keywords_currently_not_supported_by_QB64#Keywords_Not_Supported_in_Linux_or_MAC_OSX_versions|Not available in Linux or macOS]]. + + +{{PageSeeAlso}} +* [[_CAPSLOCK (function)]], [[_NUMLOCK (function)]], [[_SCROLLLOCK (function)]] +* [[_CAPSLOCK]] (statement), [[_NUMLOCK]] (statement) + + +{{PageNavigation}} diff --git a/internal/help/_SCROLLLOCK_(function).txt b/internal/help/_SCROLLLOCK_(function).txt new file mode 100644 index 000000000..512880cb8 --- /dev/null +++ b/internal/help/_SCROLLLOCK_(function).txt @@ -0,0 +1,19 @@ +{{DISPLAYTITLE: _SCROLLLOCK (function)}} +The [[_SCROLLLOCK (function)| _SCROLLLOCK]] function returns the current state of the Scroll Lock key as on (-1) or off (0). + + +{{PageSyntax}} +: {{Parameter|keyStatus%%}} = [[_SCROLLLOCK (function)| _SCROLLLOCK]] + + +==Availability== +* Version 1.4 and up. +* [[Keywords_currently_not_supported_by_QB64#Keywords_Not_Supported_in_Linux_or_MAC_OSX_versions|Not available in Linux or macOS]]. + + +{{PageSeeAlso}} +* [[_CAPSLOCK (function)]], [[_NUMLOCK (function)]] +* [[_CAPSLOCK]] (statement), [[_NUMLOCK]] (statement), [[_SCROLLLOCK]] (statement) + + +{{PageNavigation}} diff --git a/internal/help/_SETBIT.txt b/internal/help/_SETBIT.txt new file mode 100644 index 000000000..1dbb0c39b --- /dev/null +++ b/internal/help/_SETBIT.txt @@ -0,0 +1,43 @@ +{{DISPLAYTITLE:_SETBIT}} +The [[_SETBIT]] function is used to set a specified bit of a numerical value to 1 (on state). + + +{{PageSyntax}} +:{{Parameter|result}} = [[_SETBIT]]({{Parameter|numericalVariable}}, {{Parameter|numericalValue}}) + + +{{Parameters}} +* {{Parameter|numericalVariable}} is the variable to set the bit of and can be of the following types: [[_BYTE]], [[INTEGER]], [[LONG]], or [[_INTEGER64]]. +* Integer values can be signed or [[_UNSIGNED]]. +* {{Parameter|numericalValue}} the number of the bit to be set. + + +{{PageDescription}} +* Can be used to manually manipulate individual bits of an integer value by setting them to 1 (on state). +* Setting a bit that is already set to 1 will have no effect. +* Bits start at 0 (so a [[_BYTE]] has bits 0 to 7, [[INTEGER]] 0 to 15, and so on) + +==Availability== +* '''Version 1.4 and up'''. + + +{{PageExamples}} +''Example 1:'' +{{CodeStart}}A~%% = 0 '{{Cl|_UNSIGNED}} {{Cl|_BYTE}} +{{Cl|PRINT}} A~%% +A~%% = {{Cl|_SETBIT}}(A~%%,6) 'set the seventh bit of A~%% +{{Cl|PRINT}} A~%% +{{CodeEnd}} +{{OutputStart}} + 0 + 64 +{{OutputEnd}} + + + +{{PageSeeAlso}} +* [[_SHL]], [[_SHR]], [[INTEGER]], [[LONG]] +* [[_READBIT]], [[_BYTE]], [[_INTEGER64]] +* [[_RESETBIT]], [[_TOGGLEBIT]] + +{{PageNavigation}} diff --git a/internal/help/_SHR.txt b/internal/help/_SHR.txt index e5186af9a..c9b076554 100644 --- a/internal/help/_SHR.txt +++ b/internal/help/_SHR.txt @@ -17,7 +17,7 @@ The [[_SHR]] function is used to shift the bits of a numerical value to the righ * Allows for division of a value by 2 faster than normal division (see example 2 below). * Bits that reach the end of a variables bit count are dropped. * The type of variable used to store the results should match the type of the variable being shifted. - +* NOTE: When dealing with SIGNED variables, shifting the bits right will leave the sign bit set. This is due to how C++ deals with bit shifting under the hood. ==Availability== * '''Version 1.3 and up'''. diff --git a/internal/help/_TOGGLEBIT.txt b/internal/help/_TOGGLEBIT.txt new file mode 100644 index 000000000..e848e615a --- /dev/null +++ b/internal/help/_TOGGLEBIT.txt @@ -0,0 +1,46 @@ +{{DISPLAYTITLE:_TOGLEBIT}} +The [[_TOGGLEBIT]] function is used to toggle a specified bit of a numerical value. + + +{{PageSyntax}} +:{{Parameter|result}} = [[_TOGGLEBIT]]({{Parameter|numericalVariable}}, {{Parameter|numericalValue}}) + + +{{Parameters}} +* {{Parameter|numericalVariable}} is the variable to toggle the bit of and can be of the following types: [[_BYTE]], [[INTEGER]], [[LONG]], or [[_INTEGER64]]. +* Integer values can be signed or [[_UNSIGNED]]. +* {{Parameter|numericalValue}} the number of the bit to be set. + + +{{PageDescription}} +* Can be used to manually manipulate individual bits of an integer value by toggling their state. +* A bit set to 1 is changed to 0 and a bit set to 0 is changed to 1. +* Bits start at 0 (so a [[_BYTE]] has bits 0 to 7, [[INTEGER]] 0 to 15, and so on) + +==Availability== +* '''Version 1.4 and up'''. + + +{{PageExamples}} +''Example 1:'' +{{CodeStart}}A~%% = 0 '{{Cl|_UNSIGNED}} {{Cl|_BYTE}} +{{Cl|PRINT}} A~%% +A~%% = {{Cl|_TOGGLEBIT}}(A~%%,4) 'toggle the fourth bit of A~%% +{{Cl|PRINT}} A~%% +A~%% = {{Cl|_TOGGLEBIT}}(A~%%,4) 'toggle the fourth bit of A~%% +{{Cl|PRINT}} A~%% +{{CodeEnd}} +{{OutputStart}} + 0 + 16 + 0 +{{OutputEnd}} + + + +{{PageSeeAlso}} +* [[_SHL]], [[_SHR]], [[INTEGER]], [[LONG]] +* [[_SETBIT]], [[_BYTE]], [[_INTEGER64]] +* [[_RESETBIT]], [[_READBIT]] + +{{PageNavigation}} diff --git a/internal/help/_TRIM$.txt b/internal/help/_TRIM$.txt new file mode 100644 index 000000000..ddde0b1c2 --- /dev/null +++ b/internal/help/_TRIM$.txt @@ -0,0 +1,38 @@ +{{DISPLAYTITLE:_TRIM$}} +The [[_TRIM$]] function removes both leading and trailing space characters from a [[STRING]] value. + + +{{PageSyntax}} +:{{Parameter|return$}} = [[_TRIM$]]({{Parameter|text$}}) + + +{{PageDescription}} +* Shorthand to using [[LTRIM$]]([[RTRIM$]]("text")) +* {{Parameter|text$}} is the [[STRING]] value to trim. +* If {{Parameter|text$}} contains no leading or trailing space characters, it is returned unchanged. +* Convert fixed length [[STRING]] values by using a different {{parameter|return$}} variable. + + +{{PageExamples}} +''Example: Demonstrating how _TRIM$(text$) can replace LTRIM$(RTRIM$(text$)): +{{CodeStart}} +text$ = SPACE$(10) + "some text" + SPACE$(10) +{{Cl|PRINT}} "[" + text$ + "]" '' '' +{{Cl|PRINT}} "[" + {{Cl|RTRIM$}}(text$) + "]" '' '' +{{Cl|PRINT}} "[" + {{Cl|LTRIM$}}(text$) + "]" '' '' +{{Cl|PRINT}} "[" + {{Cl|LTRIM$}}({{Cl|RTRIM$}}(text$)) + "]" '' '' +{{Cl|PRINT}} "[" + {{Cl|_TRIM$}}(text$) + "]" '' '' +{{CodeEnd}} +{{OutputStart}}[ some text ] +[ some text] +[some text ] +[some text] +[some text] +{{OutputEnd}} + + +{{PageSeeAlso}} +* [[RTRIM$]], [[LTRIM$]] + + +{{PageNavigation}} diff --git a/internal/help/_glTexImage2D.txt b/internal/help/_glTexImage2D.txt index 74397bede..f4edc9d6a 100644 --- a/internal/help/_glTexImage2D.txt +++ b/internal/help/_glTexImage2D.txt @@ -118,9 +118,7 @@ The {{KW|_glPixelStore}} mode affects texture images. {{KW|_GL_INVALID_OPERATION}} is generated if {{Parameter|type}} is one of {{KW|_GL_UNSIGNED_BYTE_3_3_2}}, {{KW|_GL_UNSIGNED_BYTE_2_3_3_REV}}, {{KW|_GL_UNSIGNED_SHORT_5_6_5}}, {{KW|_GL_UNSIGNED_SHORT_5_6_5_REV}}, or {{KW|_GL_UNSIGNED_INT_10F_11F_11F_REV}}, and {{Parameter|format}} is not {{KW|_GL_RGB}}. -{{KW|_GL_INVALID_OPERATION}} is generated if {{Parameter|type}} is one of {{KW|_GL_UNSIGNED_SHORT_4_4_4_4}}, {{KW|_GL_UNSIGNED_SHORT_4_4_4_4_REV}}, {{KW -3528 -|_GL_UNSIGNED_SHORT_5_5_5_1}}, {{KW|_GL_UNSIGNED_SHORT_1_5_5_5_REV}}, {{KW|_GL_UNSIGNED_INT_8_8_8_8}}, {{KW|_GL_UNSIGNED_INT_8_8_8_8_REV}}, {{KW|_GL_UNSIGNED_INT_10_10_10_2}}, {{KW|_GL_UNSIGNED_INT_2_10_10_10_REV}}, or {{KW|_GL_UNSIGNED_INT_5_9_9_9_REV}}, and {{Parameter|format}} is neither {{KW|_GL_RGBA}} nor {{KW|_GL_BGRA}}. +{{KW|_GL_INVALID_OPERATION}} is generated if {{Parameter|type}} is one of {{KW|_GL_UNSIGNED_SHORT_4_4_4_4}}, {{KW|_GL_UNSIGNED_SHORT_4_4_4_4_REV}}, {{KW|_GL_UNSIGNED_SHORT_5_5_5_1}}, {{KW|_GL_UNSIGNED_SHORT_1_5_5_5_REV}}, {{KW|_GL_UNSIGNED_INT_8_8_8_8}}, {{KW|_GL_UNSIGNED_INT_8_8_8_8_REV}}, {{KW|_GL_UNSIGNED_INT_10_10_10_2}}, {{KW|_GL_UNSIGNED_INT_2_10_10_10_REV}}, or {{KW|_GL_UNSIGNED_INT_5_9_9_9_REV}}, and {{Parameter|format}} is neither {{KW|_GL_RGBA}} nor {{KW|_GL_BGRA}}. {{KW|_GL_INVALID_OPERATION}} is generated if {{Parameter|target}} is not {{KW|_GL_TEXTURE_2D}}, {{KW|_GL_PROXY_TEXTURE_2D}}, {{KW|_GL_TEXTURE_RECTANGLE}}, or {{KW|_GL_PROXY_TEXTURE_RECTANGLE}}, and {{Parameter|internalFormat}} is {{KW|_GL_DEPTH_COMPONENT}}, {{KW|_GL_DEPTH_COMPONENT16}}, {{KW|_GL_DEPTH_COMPONENT24}}, or {{KW|_GL_DEPTH_COMPONENT32F}}. diff --git a/internal/help/links.bin b/internal/help/links.bin index c0b0e7d90..180719ba3 100644 --- a/internal/help/links.bin +++ b/internal/help/links.bin @@ -9,6 +9,8 @@ _ARCCSC,Mathematical_Operations _ARCSEC,Mathematical_Operations _ASIN,_ASIN _ASINH,_ASINH +_ASSERT,_ASSERT +$ASSERTS,$ASSERTS _ATAN2,_ATAN2 _ATANH,_ATANH _AUTODISPLAY,_AUTODISPLAY @@ -25,6 +27,8 @@ _BLUE32,_BLUE32 _BUTTON,_BUTTON _BUTTONCHANGE,_BUTTONCHANGE _BYTE,_BYTE +_CAPSLOCK,_CAPSLOCK (function) +_CAPSLOCK,_CAPSLOCK $CHECKING,$CHECKING _CEIL,_CEIL _CLEARCOLOR,_CLEARCOLOR (function) @@ -34,6 +38,7 @@ _CLIPBOARD$,_CLIPBOARD$ _CLIPBOARD$,_CLIPBOARD$ (statement) _CLIPBOARDIMAGE,_CLIPBOARDIMAGE (function) _CLIPBOARDIMAGE,_CLIPBOARDIMAGE +$COLOR,$COLOR _COMMANDCOUNT,_COMMANDCOUNT _CONNECTED,_CONNECTED _CONNECTIONADDRESS$,_CONNECTIONADDRESS$ @@ -58,6 +63,7 @@ DECLARE,DECLARE LIBRARY DECLARE,DECLARE DYNAMIC LIBRARY _DEFAULTCOLOR,_DEFAULTCOLOR _DEFINE,_DEFINE +_DEFLATE$,_DEFLATE$ _DELAY,_DELAY _DEPTHBUFFER,_DEPTHBUFFER _DESKTOPHEIGHT,_DESKTOPHEIGHT @@ -105,6 +111,7 @@ $IF,$IF _ICON,_ICON _INCLERRORFILE$,_INCLERRORFILE$ _INCLERRORLINE,_INCLERRORLINE +_INFLATE$,_INFLATE$ _INSTRREV,_INSTRREV _INTEGER64,_INTEGER64 _KEYCLEAR,_KEYCLEAR @@ -147,6 +154,9 @@ _MOUSEWHEEL,_MOUSEWHEEL _MOUSEX,_MOUSEX _MOUSEY,_MOUSEY _NEWIMAGE,_NEWIMAGE +$NOPREFIX,$NOPREFIX +_NUMLOCK,_NUMLOCK (function) +_NUMLOCK,_NUMLOCK _OFFSET,_OFFSET (function) _OFFSET,_OFFSET _OPENCLIENT,_OPENCLIENT @@ -169,6 +179,8 @@ _R2D,_R2D _R2G,_R2G _RED,_RED _RED32,_RED32 +_READBIT,_READBIT +_RESETBIT,_RESETBIT $RESIZE,$RESIZE _RESIZE,_RESIZE _RESIZE,_RESIZE (function) @@ -192,7 +204,10 @@ $SCREENSHOW,$SCREENSHOW _SCREENSHOW,_SCREENSHOW _SCREENX,_SCREENX _SCREENY,_SCREENY +_SCROLLLOCK,_SCROLLLOCK (function) +_SCROLLLOCK,_SCROLLLOCK _SETALPHA,_SETALPHA +_SETBIT,_SETBIT _SHELLHIDE,_SHELLHIDE _SHL,_SHL _SHR,_SHR @@ -227,6 +242,7 @@ _STRICMP,_STRICMP _TANH,Mathematical_Operations _TITLE,_TITLE _TITLE$,_TITLE$ +_TOGGLEBIT,_TOGGLEBIT _TOTALDROPPEDFILES,_TOTALDROPPEDFILES _TRIM$,_TRIM$ _UNSIGNED,_UNSIGNED @@ -759,277 +775,157 @@ _glRasterPos3sv,_glRasterPos3sv _glRasterPos4d,_glRasterPos4d _glRasterPos4dv,_glRasterPos4dv _glRasterPos4f,_glRasterPos4f -_glRasterPos4fv],_glRasterPos4fv] -_glRasterPos4i, -, -_glRasterPos4iv,tatement) {{text -_glRasterPos4s,_glRasterPos4i +_glRasterPos4fv,_glRasterPos4fv _glRasterPos4i,_glRasterPos4i -_glRasterPos4sv,_glRasterPos4iv _glRasterPos4iv,_glRasterPos4iv -_glReadBuffer,_glRasterPos4s _glRasterPos4s,_glRasterPos4s -_glReadPixels,_glRasterPos4sv _glRasterPos4sv,_glRasterPos4sv -_glRectd,_glReadBuffer _glReadBuffer,_glReadBuffer -_glRectdv,_glReadPixels _glReadPixels,_glReadPixels -_glRectf,_glRectd _glRectd,_glRectd -_glRectfv,_glRectdv _glRectdv,_glRectdv -_glRecti,_glRectf _glRectf,_glRectf -_glRectiv,_glRectfv _glRectfv,_glRectfv -_glRects,_glRecti _glRecti,_glRecti -_glRectsv,_glRectiv _glRectiv,_glRectiv -_GLRENDER,_glRects _glRects,_glRects -_glRenderMode,_glRectsv _glRectsv,_glRectsv -_glRotated,_GLRENDER _GLRENDER,_GLRENDER -_glRotatef,_glRenderMode _glRenderMode,_glRenderMode -_glScaled,_glRotated _glRotated,_glRotated -_glScalef,_glRotatef _glRotatef,_glRotatef -_glScissor,_glScaled _glScaled,_glScaled -_glSelectBuffer,_glScalef _glScalef,_glScalef -_glShadeModel,_glScissor _glScissor,_glScissor -_glStencilFunc,_glSelectBuffer _glSelectBuffer,_glSelectBuffer -_glStencilMask,_glShadeModel _glShadeModel,_glShadeModel -_glStencilOp,_glStencilFunc _glStencilFunc,_glStencilFunc -_glTexCoord1d,_glStencilMask _glStencilMask,_glStencilMask -_glTexCoord1dv,_glStencilOp _glStencilOp,_glStencilOp -_glTexCoord1f,_glTexCoord1d _glTexCoord1d,_glTexCoord1d -_glTexCoord1fv,_glTexCoord1dv _glTexCoord1dv,_glTexCoord1dv -_glTexCoord1i,_glTexCoord1f _glTexCoord1f,_glTexCoord1f -_glTexCoord1iv,_glTexCoord1fv _glTexCoord1fv,_glTexCoord1fv -_glTexCoord1s,_glTexCoord1i _glTexCoord1i,_glTexCoord1i -_glTexCoord1sv,_glTexCoord1iv _glTexCoord1iv,_glTexCoord1iv -_glTexCoord2d,_glTexCoord1s _glTexCoord1s,_glTexCoord1s -_glTexCoord2dv,_glTexCoord1sv _glTexCoord1sv,_glTexCoord1sv -_glTexCoord2f,_glTexCoord2d _glTexCoord2d,_glTexCoord2d -_glTexCoord2fv,_glTexCoord2dv _glTexCoord2dv,_glTexCoord2dv -_glTexCoord2i,_glTexCoord2f _glTexCoord2f,_glTexCoord2f -_glTexCoord2iv,_glTexCoord2fv _glTexCoord2fv,_glTexCoord2fv -_glTexCoord2s,_glTexCoord2i _glTexCoord2i,_glTexCoord2i -_glTexCoord2sv,_glTexCoord2iv _glTexCoord2iv,_glTexCoord2iv -_glTexCoord3d,_glTexCoord2s _glTexCoord2s,_glTexCoord2s -_glTexCoord3dv,_glTexCoord2sv _glTexCoord2sv,_glTexCoord2sv -_glTexCoord3f,_glTexCoord3d _glTexCoord3d,_glTexCoord3d -_glTexCoord3fv,_glTexCoord3dv _glTexCoord3dv,_glTexCoord3dv -_glTexCoord3i,_glTexCoord3f _glTexCoord3f,_glTexCoord3f -_glTexCoord3iv,_glTexCoord3fv _glTexCoord3fv,_glTexCoord3fv -_glTexCoord3s,_glTexCoord3i _glTexCoord3i,_glTexCoord3i -_glTexCoord3sv,_glTexCoord3iv _glTexCoord3iv,_glTexCoord3iv -_glTexCoord4d,_glTexCoord3s _glTexCoord3s,_glTexCoord3s -_glTexCoord4dv,_glTexCoord3sv _glTexCoord3sv,_glTexCoord3sv -_glTexCoord4f,_glTexCoord4d _glTexCoord4d,_glTexCoord4d -_glTexCoord4fv,_glTexCoord4dv _glTexCoord4dv,_glTexCoord4dv -_glTexCoord4i,_glTexCoord4f _glTexCoord4f,_glTexCoord4f -_glTexCoord4iv,_glTexCoord4fv _glTexCoord4fv,_glTexCoord4fv -_glTexCoord4s,_glTexCoord4i _glTexCoord4i,_glTexCoord4i -_glTexCoord4sv,_glTexCoord4iv _glTexCoord4iv,_glTexCoord4iv -_glTexCoordPointer,_glTexCoord4s _glTexCoord4s,_glTexCoord4s -_glTexEnvf,_glTexCoord4sv _glTexCoord4sv,_glTexCoord4sv -_glTexEnvfv,_glTexCoordPointer _glTexCoordPointer,_glTexCoordPointer -_glTexEnvi,_glTexEnvf _glTexEnvf,_glTexEnvf -_glTexEnviv,_glTexEnvfv _glTexEnvfv,_glTexEnvfv -_glTexGend,_glTexEnvi _glTexEnvi,_glTexEnvi -_glTexGendv,_glTexEnviv _glTexEnviv,_glTexEnviv -_glTexGenf,_glTexGend _glTexGend,_glTexGend -_glTexGenfv,_glTexGendv _glTexGendv,_glTexGendv -_glTexGeni,_glTexGenf _glTexGenf,_glTexGenf -_glTexGeniv,_glTexGenfv _glTexGenfv,_glTexGenfv -_glTexImage1D,_glTexGeni _glTexGeni,_glTexGeni -_glTexImage2D,_glTexGeniv _glTexGeniv,_glTexGeniv -_glTexParameterf,_glTexImage1D _glTexImage1D,_glTexImage1D -_glTexParameterfv,_glTexImage2D _glTexImage2D,_glTexImage2D -_glTexParameteri,_glTexParameterf _glTexParameterf,_glTexParameterf -_glTexParameteriv,_glTexParameterfv _glTexParameterfv,_glTexParameterfv -_glTexSubImage1D,_glTexParameteri _glTexParameteri,_glTexParameteri -_glTexSubImage2D,_glTexParameteriv _glTexParameteriv,_glTexParameteriv -_glTranslated,_glTexSubImage1D _glTexSubImage1D,_glTexSubImage1D -_glTranslatef,_glTexSubImage2D _glTexSubImage2D,_glTexSubImage2D -_glVertex2d,_glTranslated _glTranslated,_glTranslated -_glVertex2dv,_glTranslatef _glTranslatef,_glTranslatef -_glVertex2f,_glVertex2d _glVertex2d,_glVertex2d -_glVertex2fv,_glVertex2dv _glVertex2dv,_glVertex2dv -_glVertex2i,_glVertex2f _glVertex2f,_glVertex2f -_glVertex2iv,_glVertex2fv _glVertex2fv,_glVertex2fv -_glVertex2s,_glVertex2i _glVertex2i,_glVertex2i -_glVertex2sv,_glVertex2iv _glVertex2iv,_glVertex2iv -_glVertex3d,_glVertex2s _glVertex2s,_glVertex2s -_glVertex3dv,_glVertex2sv _glVertex2sv,_glVertex2sv -_glVertex3f,_glVertex3d _glVertex3d,_glVertex3d -_glVertex3fv,_glVertex3dv _glVertex3dv,_glVertex3dv -_glVertex3i,_glVertex3f _glVertex3f,_glVertex3f -_glVertex3iv,_glVertex3fv _glVertex3fv,_glVertex3fv -_glVertex3s,_glVertex3i _glVertex3i,_glVertex3i -_glVertex3sv,_glVertex3iv _glVertex3iv,_glVertex3iv -_glVertex4d,_glVertex3s _glVertex3s,_glVertex3s -_glVertex4dv,_glVertex3sv _glVertex3sv,_glVertex3sv -_glVertex4f,_glVertex4d _glVertex4d,_glVertex4d -_glVertex4fv,_glVertex4dv _glVertex4dv,_glVertex4dv -_glVertex4i,_glVertex4f _glVertex4f,_glVertex4f -_glVertex4iv,_glVertex4fv _glVertex4fv,_glVertex4fv -_glVertex4s,_glVertex4i _glVertex4i,_glVertex4i -_glVertex4sv,_glVertex4iv _glVertex4iv,_glVertex4iv -_glVertexPointer,_glVertex4s _glVertex4s,_glVertex4s -_glViewport,_glVertex4sv _glVertex4sv,_glVertex4sv -;,_glVertexPointer _glVertexPointer,_glVertexPointer -",comma -?,INPUT -INPUT,INPUT -',Question mark -:,SUB -SUB,SUB -$,FUNCTION -FUNCTION,FUNCTION -,Dollar_Sign -+,SUB -SUB,SUB -",+ +_glViewport,_glViewport +;,Semicolon +",Quotation mark +?,Question mark +',Apostrophe +:,Colon +$,Dollar_Sign +,Parenthesis +,+ -_,CHR$ -CHR$,CHR$ +",Quotation mark +_,Underscore $,STRING STRING,STRING -!,Underscore -#,STRING -STRING,STRING -##,SINGLE +!,SINGLE SINGLE,SINGLE -~,DOUBLE +#,DOUBLE DOUBLE,DOUBLE -%,_UNSIGNED +##,_FLOAT +_FLOAT,_FLOAT +~,_UNSIGNED _UNSIGNED,_UNSIGNED -&,INTEGER +%,INTEGER INTEGER,INTEGER -&&,LONG +&,LONG LONG,LONG -`,_INTEGER64 +&&,_INTEGER64 _INTEGER64,_INTEGER64 -%%,INTEGER -INTEGER,INTEGER -%&,_BYTE +`,_BIT +_BIT,_BIT +%%,_BYTE _BYTE,_BYTE -&B,_OFFSET +%&,_OFFSET _OFFSET,_OFFSET -&O,INTEGER -INTEGER,INTEGER -&H,&B &B,&B -+,&H +&O,&O &H,&H --,Mathematical Operations -*,+ +,+ -/,- -,- -\,* *,* -^,/ /,/ -MOD,\ \,\ -=,MOD +^,^ MOD,MOD -<>,Relational Operations ->,Equal -<,Not_Equal ->=,Greater_Than -<=,Less_Than +=,Equal +<>,Not_Equal +>,Greater_Than +<,Less_Than +>=,Greater_Than_Or_Equal +<=,Less_Than_Or_Equal