1
1
Fork 0
mirror of https://github.com/QB64Official/qb64.git synced 2024-07-01 10:20:42 +00:00
Commit graph

58 commits

Author SHA1 Message Date
Roland Heyder ce3c459dad Implements the _Bin$ function
Usage is analog to the legacy OCT$ and HEX$ functions.
2021-10-14 00:17:35 +02:00
Fellippe Heitor 84571d8900 Fix order of duplicate GET/PUT subs in id list 2021-09-30 09:57:15 -03:00
FellippeHeitor edb4d40ffa Fixes var=function assignment without parameters (recursion).
As reported at https://www.qb64.org/forum/index.php?topic=704.msg5775#msg5775
2021-09-25 00:34:55 -03:00
Fellippe Heitor f512ace544 Missing quotes. 2021-07-28 23:44:01 -03:00
Fellippe Heitor 345991a08c Missing quote. 2021-07-28 23:38:51 -03:00
Fellippe Heitor ee4b611056 Adds _EnvironCount 2021-07-17 12:15:00 -03:00
Fellippe Heitor b59aa4d7af Begins prototyping a $DEBUG metacommand. 2021-07-09 08:08:49 -03:00
Fellippe Heitor 6181fe54e4 Adds "quick reference" look up for the IDE.
Shows a quick syntax reference once it detects what command one is 
trying to use
2021-06-20 00:04:08 -03:00
Fellippe Heitor fff40a315e Extra touches to CamelCase (NOT, AND, etc). 2021-01-31 14:45:58 -03:00
Fellippe Heitor 59155c4481 Adds the ability to have CamelCase for internal keywords. 2021-01-31 03:44:38 -03:00
Luke Ceddia d244d45c92
$ERROR highlight 2021-01-27 22:36:50 +11:00
FellippeHeitor 46b3e05380 Separates the list of keywords to highlight from ide_globals. 2021-01-17 12:03:31 -03:00
Luke Ceddia c62568008d
Add _ERRORMESSAGE$ 2021-01-17 23:54:15 +11:00
FellippeHeitor bd54eb0f39 Attempts at implementing _MEMSOUND 2020-12-31 01:40:54 -03:00
FellippeHeitor 3e474f2f0b Fixes SUB calls like SHELL _HIDE command$ for $NOPREFIX use. Also:
- Fixes incorrect resolution of _BIT in variable declarations.
2020-01-06 04:46:29 -03:00
FellippeHeitor 2ebaeab3c6 Initial implementation of $NOPREFIX
Allows QB64-specific keywords to be called without the leading underscore.

Per user and per project; affects nothing globally.

Allows prefixed keywords to be used even when it's set.
2020-01-04 16:13:13 -03:00
FellippeHeitor 7c9eafbadb Replaces _TOGGLE_(KEY)LOCK with _(KEY)LOCK ON/OFF/_TOGGLE. Also:
- Changes CFont to sub__consolefont and func_CInp to func_cinp, in alignment with the rest of libqb/qbx.
- Adds stubs to all new console functionality, so we can still ship for other OSes with no bigger issues.
- Adds new keywords to syntax highlighter.
2020-01-02 19:55:58 -03:00
FellippeHeitor d7f77cd2af Removes inexistent sub/function declarations. 2020-01-02 19:49:29 -03:00
FellippeHeitor 49f265f1c2 Adds $ASSERTS, $ASSERTS:CONSOLE and _ASSERT condition[, message$] 2020-01-01 18:20:30 -03:00
QB64Cobalt 68831584b8
Update subs_functions.bas 2019-12-05 07:10:31 -08:00
QB64Cobalt 036385e20a
Update subs_functions.bas 2019-11-16 16:21:51 -08:00
SteveMcNeill eba05938bb Pushed changes to enhance the Windows Console Experience
Window's CONSOLE support has been extended so that:

CSRLIN support added.
POS(0) support added.
LOCATE support added. (Works with optional parameters.)
COLOR support added.
SCREEN support added to get both character and color information of any point on the console.
tab() glitch fixed. (Which could cause an endless loop when printing with comma spaced text/numbers.)
_WIDTH support added.
_HEIGHT support added.
WIDTH support added, with 2 new parameters added so we can set the buffer width and buffer height also.
CLS support semi-added.  (Doesn't accept colored backgrounds; it clears the screen black.  I'm getting tired of working up console stuff which I probably won't ever use myself...)
SLEEP support added.
END support added so we now end with any keypress and not just enter.

_CONSOLEINPUT added, so we can tell the difference in mouse and keyboard input.
_CINP(toggle) support added, which allows us to get single character keystrokes from the console.
_CONSOLEFONT FontName, FontSize support added, which allows us to change the font and font size we use for the console.
_CONSOLECURSOR _SHOW|_HIDE, cursorsize support added, which allows us to show or hide the cursor in the console, and to change its size (from 0 to 100), as desired.

New keyboard commands added:

_CAPSLOCK -- returns 1 if caps lock is on, 0 if it isn't.
_NUMLOCK -- as above, but for num lock
_SCROLLOCK -- as above, but for scroll lock

_TOGGLE_CAPSLOCK -- toggles the caps lock state for us.
_TOGGLE_NUMLOCK -- same, but for num lock
_TOGGLE_SCROLLOCK -- same, but for scroll lock
2019-08-27 19:52:02 -04:00
SteveMcNeill 449bdecacd Adding ZLIB into the QB64 parts system for windows.
Two new keywords added:
FUNCTION _INFLATE$ (text$)
FUNCTION _DEFLATE$ (text$)

Use of these commands can compress and decompress strings using the ZLIB library.
2019-08-27 18:22:07 -04:00
FellippeHeitor 3918db63cc Removes dead Qloud references. 2019-04-14 14:42:49 -03:00
FellippeHeitor 369d522a98 Applies common naming convention and makes _SHL/_SHR functions inline. 2018-10-30 00:32:12 -03:00
Kobolticus 761c34a7f6
Added support for _SHR\_SHL functions 2018-10-29 22:53:36 -04:00
SteveMcNeill e2c250a42f Change to _WINDOWSHANDLE to return 64-bit offsets 2018-10-29 08:09:30 -04:00
FellippeHeitor 5e0ff36205 Adds _ACCEPTFILEDROP as a function to return true (-1) if active/enabled.
Returns 0 otherwise.
2018-07-31 22:23:34 -03:00
FellippeHeitor 975408e2ef _DROPPEDFILE$ now takes an optional index parameter.
- Allows using _DROPPEDFILE as an array ranging from 1 TO _TOTALDROPPEDFILES.
- Using _DROPPEDFILE as an array doesn't reset _TOTALDROPPEDFILES (unlike when reading _DROPPEDFILE$ sequentially with no parameter), so it's necessary to call _FINISHDROP after working with the list of dropped files so it'll be reset.
2018-07-31 10:24:52 -03:00
FellippeHeitor c83b15eb95 Implements Drag/Drop of files onto a program's window (Windows-only).
New statement:
    _ACCEPTFILEDROP [{ON|OFF}]
    Enables a program to accept files being dropped from a folder.

New functions:
    _TOTALDROPPEDFILES
    Returns the number of files that have been received via drag/drop.

    _DROPPEDFILE$
    Returns the list of files that have been dropped. The function sequentially returns the file list and decreases _TOTALDROPPEDFILES with every read.
2018-07-31 00:23:36 -03:00
FellippeHeitor ed28f453f0 Adds _TRIM$ (both left and right TRIM). 2018-07-17 02:35:17 -03:00
FellippeHeitor 024f27a5b5 Indentation work (.bas files). No actual code changes. 2018-07-17 00:01:23 -03:00
FellippeHeitor bc6b427a99 Implements _INSTRREV, to search for the last occurence of a substring.
The statement works as INSTR does but starts from the end of the passed string (or from the specified position) and looks for the passed substring while moving backards.

Takes after VBScript's InStrRev: https://www.w3schools.com/asp/func_instrrev.asp

Closes #51
2018-07-15 16:43:12 -03:00
Fellippe Heitor a846fdbc4d
OFF/_OFF allowed for _FULLSCREEN and _ALLOWFULLSCREEN (#50)
Closes #49
2018-07-13 18:03:00 -03:00
FellippeHeitor 19fda93caf Adds .overloaded and .minargs to idstruct.
Allows more functions to be overloaded in the future, like _RGB32.
2018-07-03 00:33:37 -03:00
FellippeHeitor 6ee70f1afa Makes _RGB32 more flexible and powerful.
Existing syntax:
colour~& = _RGB32(red, green, blue)

New possible uses:
- Instead of passing identical rgb values to achieve a shade of gray, pass only 1 parameter for all color components:

    colour~& = _RGB32(51) 'same as _RGB32(51, 51, 51)

- _RGB32 can now take an optional alpha parameter, which makes _RGBA32 obsolete (although it still exists for retrocompatibility):

    colour~& = _RGB32(255, 0, 255, 30) 'same as _RGBA32(255, 0, 255, 30)

- If you want a shade of gray and also to specify the alpha level, you can pass just two parameters:

    colour~& = _RGB32(51, 30) 'same as _RGBA32(51, 51, 51, 30)

In summary:

    - 1 parameter  = red, green and blue simultaneously set.
    - 2 parameters = red, green and blue simultaneously set plus alpha level.
    - 3 parameters = red, green and blue as usual.
    - 4 parameters = red, green and blue plus alpha level (same as _RGBA32).
2018-07-01 21:46:08 -03:00
FellippeHeitor 4264666130 Adds _SMOOTH function to return current fullscreen antialiasing setting.
Returns true (-1) if enabled.
2018-06-30 17:09:29 -03:00
FellippeHeitor d911e3d01e Implements _ALLOWFULLSCREEN to set how ALT+ENTER behaves. Closes #22.
Syntax:
    _ALLOWFULLSCREEN [{_STRETCH|_SQUAREPIXELS|_OFF|_ALL}][,{_SMOOTH|_OFF|_ALL}]

Existing _FULLSCREEN statement is not bound by _ALLOWFULLSCREEN's settings, only the ALT+ENTER key combo.
2018-06-29 11:30:14 -03:00
FellippeHeitor 688e31c0f3 Introduces _ECHO, which will output a string to the console.
_ECHO is more of a macro than a new statement, as it'll perform the following actions:

1- Save current _DEST;
2- Switch to _CONSOLE;
3- Print the passed string (only strings accepted);
4- Switch back to previous _DEST.

None of the PRINT features such as USING, numeric variables, retaining the cursor are implemented/planned for this statement.

Closes #29
2018-06-27 23:51:09 -03:00
Ashish Kushwaha 4624cb942d
Fixed a typo in opengl_methods.bas 2018-05-22 19:36:49 +05:30
FellippeHeitor 89f2e12cc8 Remove references to DEPENDENCY_USER_MODS from subs_functions.bas. 2017-09-27 22:04:40 -03:00
Luke Ceddia bdc3250b89 Resolved the issue of user mods not working for $console:only programs 2017-09-25 21:56:24 +10:00
SteveMcNeill 4f23fd9b7b Add function _AUTODISPLAY so user can get display/autodisplay staus 2017-09-24 18:41:00 -04:00
FellippeHeitor 5922d112bf Adds _WINDOWHANDLE, _WINDOWHASFOCUS and _TITLE$ (function).
- _WINDOWHANDLE exposes the current window's handle (Windows-only).
- _WINDOWHASFOCUS returns true (-1) when the program is the foremost window (Windows-only). Always returns -1 in other OSes.
- _TITLE$ (function) returns the last title set using the _TITLE statement.
2017-09-24 08:12:13 -03:00
SteveMcNeill d3a2424b73 Added right and middle button support for _SCREENCLICK with Windows 2017-09-24 01:08:29 -04:00
FellippeHeitor 8fe5804fa2 Sets the proper dependency (DEPENDENCY_SCREENIMAGE) for clipboard features.
Using $CONSOLE:ONLY without the above causes compilation fails.
2017-09-11 10:29:45 -03:00
FellippeHeitor e3bb55da1a Add _CLIPBOARDIMAGE (statement and function)
- Fetch an image from the clipboard with handle& = _CLIPBOARDIMAGE
    - If there isn't an image in the clipboard, handle& will be -1.

- Copy a valid image to the clipboard (All screen modes, except 0) with _CLIPBOARDIMAGE = handle&
2017-09-06 11:19:54 -03:00
FellippeHeitor 2f217fce6b Function _BLINK returns -1 if blinking is enabled; 0 if disabled. 2017-08-16 00:40:37 -03:00
FellippeHeitor 2c153b3db0 Adds _BLINK {ON|OFF} to disable blinking in SCREEN 0 for colors 16-31.
Thanks to _vince for finding the right spots where blinking was set. Or flashing, you choose the naming.
2017-08-16 00:11:31 -03:00
Luke Ceddia 2089a95b8b Separate left/right audio channels for stereo audio files.
No _SNDRAW or PLAY yet. Also removed need for sound capability strings.
2017-08-10 22:05:16 +10:00