Author Topic: QB64-Steves v0.954c1/d3  (Read 1681 times)

SMcNeill

  • Hero Member
  • *****
  • Posts: 2414
    • Email
QB64-Steves v0.954c1/d3
« on: January 02, 2013, 06:04:45 AM »
As requested by OlDosLover here:

Quote from: OlDosLover on January 02, 2013, 05:13:04 AM
I think these tweaks should all be in one place for consolidation purposes. I also think you should make a copy of the source available for download for people that dont wish to delve into modifying the source themsleves and would rather use the finished product.

So, I'm doing as requested and uploading everything all prepackaged, for those who aren't that interested in changing the source code themselves...

So, what does this do for us that the latest QB64 SDL doesn't do?

* It fixes the WRITE bug that can eat your code.
* It makes fixed length strings available for use with _MEM.
* It makes fixed length string arrays available for use with _MEM.
* It expands the CONST command so that we can now use it with _RGB values.   (As discussed here: http://www.qb64.net/forum/index.php?topic=10244.0)
* It strips out portions of the QB64 source into component modules, to make moving around and editing inside them a bit easier, and to start us in the direction of an eventual modularized version of QB64.

* version 954a2 fixes the bug that was causing PRINT USING to sometimes display wrong results as discussed here: http://www.qb64.net/forum/index.php?topic=10350.0

*version 954a3 fixes the FOR-NEXT bug inside $CHECKING:OFF as described by Galleon here: http://www.qb64.net/forum/index.php?topic=10353.msg85694#msg85694
* It adds support for a new _MATH sub-function for use only inside CONST.  _MATH allows us to use COS, SIN, TAN, ATN, LOG, SQR, CSC, SEC, COT, PI inside our CONST.  Usage will be explained better a few posts lower.   http://www.qb64.net/forum/index.php?topic=10251.msg85768#msg85768

*version 954a4 credit goes completely to DSMan195276.  Everyone give Matt a big old "Thank You!" for this expansion.   What did he do for us?   He went in and expanded the _math function which we could use with our constants so that it would work recursively with itself.   Before CONST x = _math(COS(30)) would work, but CONST x = _math(COS(COS(30))) would not.   Now, that's fixed.   We can now use our functions inside our functions, with no problems.  Even things like Const x = _math(1) works now, where before it needed one of our functions for it to work.   Many thanks Matt!

*version 954a5 adds multiple variable support on the lines that use _RGB with CONST now.   If you use _MATH with CONST, **KEEP** math for a single variable until use for it can be expanded upon as well.  :)

*version 954b now finally allows us to use multiple variables with the _MATH function as well.   No more worrying over 1 per line, and you can mix and match them up.  CONST x = _math(cos(30)), a = 14, b = _RGB32(255,255,0)  will all work on a single line now and generate proper results for all the variables in the mix.  (Or should I say all the constants in the mix.  :P)

*version 964c now allows us to generate our own quick insertion codes, to reduce typing and repetitive stress injuries on our fingers and knuckles. 

Just download, extract in the original Qb64 (SDL version) directory (nothing overwrites existing files), and then use the exe here to write and compile your programs, and you're all set to take advantage of these tweaks and modifications.   It's that simple.  :)
« Last Edit: February 07, 2013, 10:29:11 PM by SMcNeill »
http://bit.ly/TextImage -- Library of QB64 code to manipulate text and images, as a BM library.
http://bit.ly/Color32 -- A set of color CONST for use in 32 bit mode, as a BI library.

http://bit.ly/DataToDrive - A set of routines to quickly and easily get data to and from the disk.  BI and BM files

OlDosLover

  • Hero Member
  • *****
  • Posts: 3860
  • OlDosLover
    • Email
Re: QB64-Steves v0.954a
« Reply #1 on: January 02, 2013, 06:15:19 AM »
Hi all,
    Thank you!!!
 Thank you!!!, Thank you!!!, Im sure you get the message!!! Seriously thank you again , for listening and for your efforts.
OlDosLover.

SMcNeill

  • Hero Member
  • *****
  • Posts: 2414
    • Email
Re: QB64-Steves v0.954a
« Reply #2 on: January 02, 2013, 06:31:49 AM »
Quote from: OlDosLover on January 02, 2013, 06:15:19 AM
Hi all,
    Thank you!!!
 Thank you!!!, Thank you!!!, Im sure you get the message!!! Seriously thank you again , for listening and for your efforts.
OlDosLover.

Dang it!  Just when I think I'm getting close to regaining God status, I go and perform a boneheaded action...

You'll need to redownload OlDos, if you want the source.   When I uploaded before, I clicked on the wrong file and simply uploaded the exe (which is all you need to run it, actually), and not the rar file that held all the source and such.   

My apologies.   

The full download is now in the proper place, and you can get it if you want, instead of just the exe....   ;)


One advantage:  Since it's compressed, the whole thing is actually smaller than the exe you downloaded before, so it'll use very little bandwith to get. 
http://bit.ly/TextImage -- Library of QB64 code to manipulate text and images, as a BM library.
http://bit.ly/Color32 -- A set of color CONST for use in 32 bit mode, as a BI library.

http://bit.ly/DataToDrive - A set of routines to quickly and easily get data to and from the disk.  BI and BM files

OlDosLover

  • Hero Member
  • *****
  • Posts: 3860
  • OlDosLover
    • Email
Re: QB64-Steves v0.954a
« Reply #3 on: January 02, 2013, 06:46:46 AM »
Hi all,
    Once again i thank you!
OlDosLover.

Clippy

  • Hero Member
  • *****
  • Posts: 16440
  • I LOVE π = 4 * ATN(1)    Use the QB64 WIKI >>>
    • Pete's Qbasic Site
    • Email
Re: QB64-Steves v0.954a
« Reply #4 on: January 02, 2013, 09:53:02 AM »
That's how he started his printing business. He used to call himself Zerox...  ;)
QB64 WIKI: Main Page
Download Q-Basics Code Demo: Q-Basics.zip
Download QB64 BAT, IconAdder and VBS shortcuts: QB64BAT.zip
Download QB64 DLL files in a ZIP: Program64.zip

SMcNeill

  • Hero Member
  • *****
  • Posts: 2414
    • Email
Re: QB64-Steves v0.954a1
« Reply #5 on: January 03, 2013, 12:33:44 PM »
Version 0.954a1 is now up.

This version allows for the use of CONST PI = 4 * ATN(1), as per Clippy's request.   

I also added in a very simple CONST PI = PI for myself, as I'm even lazier than Clippy...   :P

Simply type in either command and QB64 will use the proper value of PI for PI, so you'll be able to use the variable just as freely as if you'd remembered and typed in PI = 3.1415926538....
http://bit.ly/TextImage -- Library of QB64 code to manipulate text and images, as a BM library.
http://bit.ly/Color32 -- A set of color CONST for use in 32 bit mode, as a BI library.

http://bit.ly/DataToDrive - A set of routines to quickly and easily get data to and from the disk.  BI and BM files

Omega

  • Sr. Member
  • ****
  • Posts: 377
    • Recall site..
    • Email
Re: QB64-Steves v0.954a1
« Reply #6 on: January 04, 2013, 01:39:29 AM »
Sweet handy stuff

OlDosLover

  • Hero Member
  • *****
  • Posts: 3860
  • OlDosLover
    • Email
Re: QB64-Steves v0.954a1
« Reply #7 on: January 04, 2013, 02:07:44 AM »
Hi all,
    Great , thank you.
Quote
Version 0.954a1 is now up.
OlDosLover.

fatman2021

  • Hero Member
  • *****
  • Posts: 978
  • Lord Jesus Christ, Son of God, have mercy on us.
    • Email
Re: QB64-Steves v0.954a1
« Reply #8 on: January 04, 2013, 05:47:13 PM »
Could you include all the required libraries in the next release?
Woe to those who call evil good, and good evil;
Who put darkness for light, and light for darkness;
Who put bitter for sweet, and sweet for bitter!

Isaiah 5:20

iamdenteddisk

  • Hero Member
  • *****
  • Posts: 2737
    • Email
Re: QB64-Steves v0.954a1
« Reply #9 on: January 04, 2013, 06:19:40 PM »
that would be a bad step fat man, because what about when those library's are updated?

fatman2021

  • Hero Member
  • *****
  • Posts: 978
  • Lord Jesus Christ, Son of God, have mercy on us.
    • Email
Re: QB64-Steves v0.954a1
« Reply #10 on: January 04, 2013, 06:24:25 PM »
QB64-Steves v0.945a1 generates a 698.6KB executable that displays "Hello World" using the SDL version of QB64. QB64-Steves v0.945a1 gives me a compiler error when using QB64-GL.
 
Quote
qbx.cpp: In function ‘void sub_chain(qbs*)’:
qbx.cpp:1021:5: error: ‘cloud_app’ was not declared in this scope
In file included from qbx.cpp:2674:0:
../temp/main.txt: In function ‘void QBMAIN(void*)’:
../temp/main.txt:14:8: error: return-statement with a value, in function returning 'void' [-fpermissive]
Woe to those who call evil good, and good evil;
Who put darkness for light, and light for darkness;
Who put bitter for sweet, and sweet for bitter!

Isaiah 5:20

SMcNeill

  • Hero Member
  • *****
  • Posts: 2414
    • Email
Re: QB64-Steves v0.954a1
« Reply #11 on: January 04, 2013, 07:49:07 PM »
If you have 0.954 SDL, then you have all that's needed for this.  This is simply a modified version of the SDL version of QB64 that Galleon isn't supporting or updating anymore.  I'm not surprised that it refused to compile under GL.  I can't imagine the current SDL version would compile under GL either, as the purpose of the GL library is to not be SDL dependent, which this is.

Everything we do here can be easily accomplished by also altering the QB64 SDL source as discussed elsewhere on the forums and found with a few quick searches.  For most of the changes, I've even posted how to make them in the GL source if you're interested, but I haven't bothered to try and assemble the changes into the GL version myself as Galleon still supports and updates it officially.

It'll be up to him to decide if he likes these changes, if the community likes them enough, and if he's willing, to make the adjustments to the official GL version himself.  I'm not trying to replace, undermine, or undo any of Galleon's hard work.  I just wanted to tweak a few bug fixes out and add some minor flexibility in to make programming in QB64 a little faster and easier for me.

If others like these little tweaks, that's fine too.  If not, I understand.  After all, this isn't an official release, just a hack job by a poor farmer....  ;D

Compile it just as you would with any SDL version of QB64 and it'll work.  I don't expect it'll EVER compile properly under the GL version.   :)
http://bit.ly/TextImage -- Library of QB64 code to manipulate text and images, as a BM library.
http://bit.ly/Color32 -- A set of color CONST for use in 32 bit mode, as a BI library.

http://bit.ly/DataToDrive - A set of routines to quickly and easily get data to and from the disk.  BI and BM files

SMcNeill

  • Hero Member
  • *****
  • Posts: 2414
    • Email
Re: QB64-Steves v0.954a2
« Reply #12 on: January 11, 2013, 10:48:54 PM »
UPDATE .0954a2:

Added in the fix for the bug that caused PRINT USING to sometimes display false results as discussed here: http://www.qb64.net/forum/index.php?topic=10350.0. 

That's it.  :)
http://bit.ly/TextImage -- Library of QB64 code to manipulate text and images, as a BM library.
http://bit.ly/Color32 -- A set of color CONST for use in 32 bit mode, as a BI library.

http://bit.ly/DataToDrive - A set of routines to quickly and easily get data to and from the disk.  BI and BM files

OlDosLover

  • Hero Member
  • *****
  • Posts: 3860
  • OlDosLover
    • Email
Re: QB64-Steves v0.954a2
« Reply #13 on: January 11, 2013, 11:05:44 PM »
Hi all,
    Really good detective work fellas. Thanks.
OlDosLover.

Galleon

  • Administrator
  • Hero Member
  • *****
  • Posts: 4664
  • QB Forever
    • Email
Re: QB64-Steves v0.954a2
« Reply #14 on: January 12, 2013, 05:49:50 AM »
Quote
This version allows for the use of CONST PI = 4 * ATN(1), as per Clippy's request.
I'd like to welcome you to QB64, SMcNeill, not as a member, user or programmer, but as a developer. Did/Will you add support for any other functions to constants?
Something old... Something new... Something borrowed... Something blue...