Syntax Notation Conventions

From wiki
Jump to: navigation, search

Syntax Notation Conventions used in this WIKI Upper Case = _KEYWORD Italics = parameter or expression Brackets = [optional parameter or argument] Braces = {choice1|choice2} Bold = Required syntax, (parameters) and punctuation

Syntax Descriptions
These DOS syntax conventions apply to all KEYWORD syntaxes in this WIKI:
  • Items in uppercase indicate BASIC or QB64 program KEYWORDs except for the Interrupt or Absolute built in statements.
  • Items in lowercase italics are variable parameters used by the keyword. Example: LEN(filename$)
  • Items in square brackets [ ] are optional KEYWORDs or parameters that do not have to be used in the statement.
  • Items in braces { } indicate a choice between two or more items separated by the pipe | character.
  • Three dots in a syntax indicate that an optional list of arguments can be continued indefinitely: argument1[, ...]
  • Block statements or loops are indicated when three dots are used horizontally or vertically to designate internal code lines: DO...LOOP


NOTE: Qbasic allows many keywords to be used as STRING variable names. Numerical variable names are limited!
The only QB64 limitation is that underscores cannot prefix a variable or user defined sub-procedure name.
The underscore prefix assures compatibility with most user defined variable and sub-procedure names.

Programming Acronyms and Terminology

  • 1 bit color: uses one bit to determine if a pixel is white or black on monochrome images with no transparency.
  • 4 bit color: uses a half byte to store 16 color palette attribute values. Color intensities are predefined with no transparency.
  • 8 bit color: uses one byte to store 256 palette attribute values. Palette color intensities are predefined with no transparency.
  • 24 bit color: uses one byte to hold each RGB color intensity value for 16 million colors with no transparency.
  • 32 bit color: uses one byte for _ALPHA transparency as well as one byte for each RGB color intensity for 16 million colors.
  • algorithm: A programming formula or procedure that can return a particular result or solve a problem.
  • brackets: parenthesis are used to enclose FUNCTION or SUB parameters or to pass values in a call by value.
  • compiler: Converts text code written in a programming language into machine language that can do various program tasks.
  • console window: can be used to display program variable values in a window separate from the program window.
  • constant: a name that holds a constant string or numerical value which does not change throughout the program.
  • DLL: stands for Dynamic Library Link files that perform certain tasks. The files are required to run programs in QB64.
  • DOS stands for a Disk Operating System that uses a command line instead of a Graphic User Interface.
  • exponent: a superscript numerical value to the right of the base number that raises the base value to a certain power. 23 = 8
  • expression: a value or calculation that can be used in a program keyword statement or FUNCTION.
  • FTP: File Transfer Protocol is a standard network protocol used to copy a file from one host to another over a TCP network.
  • FUNCTION: returns one calculated value to a programming procedure through its name.
  • GEDIT: A text editor that can be used in Linux to create QB64 programs with color coded keywords.
  • GUI: Graphic User Interface that uses icon symbols and a mouse instead of a command line.
  • handle: a reference value for a screen surface, image, sound or font stored in memory. Handles should be freed when no longer used!
  • header files: reusable C++ .h text library files that allow QB64 programmers to add extra code elements to a program.
  • Hexadecimal: base 16 numbering system used to designate numerical values in computers. Digits 0 to 9 and A to F are used.
  • HTM(L): Hypertext Markup Language is the predominant markup language for web pages. WARNING: Files can be infected!
  • HTTP(S): Hypertext Transfer Protocol (Secure) provide encrypted communication and secure identification of network servers.
  • IDE: Integrated Development Environment or text programming editor used to create programs of a particular type.
  • library: A text file that contains sub procedures or functions that are reusable by a programmer.
  • line number: designates a code line reference or label used by GOTO or GOSUB. Line numbers are not required in QB64.
  • literal: A literal value is a real number or text string value enclosed in quotation marks.
  • module: An uncompiled program file using the BAS extension in Qbasic, QB64 and Visual Basic.
  • Octal base 8 numbering system used to designate numerical values in computers. Digits 0 to 7 only can be used.
  • offset: refers to the offset position of data in memory. QB64 can use the _OFFSET function to return the data position.
  • OS: the Operating System used by the computer. QB64 can be used on Windows, Linux or Mac OSX systems.
  • page or screen page: Refers to an image surface stored in memory using _NEWIMAGE. SCREEN can be used to display it.
  • parameter: refers to a literal or variable value passed to a SUB or FUNCTION. Functions and CALL require them in brackets.
  • radian: A unit of measurement based on a 360 degree rotation expressed as radians. See: radians
  • screen: Refers to the visible program screen image area or page image surface displayed using _PUTIMAGE or SCREEN.
  • segment: refers to a memory segment address that holds computer data.
  • shell: Statement used to reference a command line statement in DOS or other command interfaces.
  • shortcut: A LNK or PIF file that opens a program using a designated path. See: Creating Windows shortcuts with VB Script
  • snippet: A code sample that shows how to accomplish something in a program.
  • square root: of a number is the numerical value that can be multiplied by itself to create that numerical value. See: SQR
  • statement is a SUB procedure used by the programming language to perform an operation.
  • system32 folder is used on 32 bit Windows to hold 32 bit program system and DLL files. Holds 64 bit files on 64 bit computers.
  • SysWOW64 folder is used on 64 bit Windows computers to hold 32 bit program system and DLL files.
  • TCP/IP defines the protocol(rules) that computers must follow to communicate with each other over the internet.
  • Type: refers to the type of variable to be used in a program designated by a DIM statement or with a variable type suffix.
  • UDT: User Defined Type is a variable type with a combination of variable types values held inside of it.
  • variable: a name that holds a string or numerical value in a program procedure which can change throughout a program.
  • WGET: GNU procedure that retrieves files from HTTP, HTTPS and FTP network site connections.

Go to Keyword Reference - Alphabetical
Go to Keyword Reference - By usage
Go to Main WIKI Page