Page 20 of 30

Re: SpiderBasic 1.00 alpha 3

Posted: Wed Feb 05, 2014 11:01 am
by useful

Code: Select all

Procedure DesktopWidth()
    ;
    ; Returns the width of the browser area
    ;
    !var width;
    !require(["dojo/window"], function(win){
    !  width = win.getBox().w;
    !});
    !return width;
EndProcedure

Procedure DesktopHeight()
    ;
    ; Returns the height of the browser area
    ;
    !var height;
    !require(["dojo/window"], function(win){
    !  height = win.getBox().h;
    !});
    !return height;
EndProcedure
I missed? Where mentioned about the syntax of inline javascript [ ! ] ?
Аnd this is also true for HTML?

Re: SpiderBasic 1.00 alpha 3

Posted: Wed Feb 05, 2014 11:12 am
by Danilo
useful wrote:I missed? Where mentioned about the syntax of inline javascript [ ! ] ?
Look in the help for topic "Inline x86 ASM". ;)

In PureBasic it is !DirectASM, in SpiderBasic it is !DirectJS
useful wrote:Аnd this is also true for HTML?
Don't know, yet.

Would also be nice to include own JavaScript files. Something like

Code: Select all

IncludeJS "/my.js"
ImportJS "/my.js"
would generate

Code: Select all

<script type="text/javascript" src="/my.js"></script>
in the final HTML at the beginning.

I also noticed that SpiderBasic removes the ending ';' from my !DirectJS lines (because this are SB comments).
Would be nice if lines starting with '!' would be inserted completely untouched to prevent any issues.

Re: SpiderBasic 1.00 alpha 3

Posted: Thu Feb 06, 2014 9:26 am
by useful
The <iframe> <=> webgadget planned? :wink:

And really want to understand the roadmap dates alpha, beta, release (albeit very roughly)

Re: SpiderBasic 1.00 alpha 3

Posted: Thu Feb 06, 2014 9:32 am
by netmaestro
alpha to beta: when it happens
beta to release: Fred says approx. end of 2014
A project of this scope is just too large to make accurate predictions.

Re: SpiderBasic 1.00 alpha 3

Posted: Thu Feb 06, 2014 12:44 pm
by karu
if i use

Code: Select all

 WindowBounds(#win, 800, 600, #PB_Ignore, #PB_Ignore)
and trying to resize window, window will be about 10 points width or height.

Re: SpiderBasic 1.00 alpha 3

Posted: Thu Feb 06, 2014 1:44 pm
by Fred
karu wrote:if i use

Code: Select all

 WindowBounds(#win, 800, 600, #PB_Ignore, #PB_Ignore)
and trying to resize window, window will be about 10 points width or height.
Please use the right forum section, thanks: http://www.purebasic.fr/english/viewforum.php?f=41

Re: SpiderBasic 1.00 alpha 3

Posted: Thu Feb 06, 2014 6:50 pm
by useful
Can create a partition Tricks 'n' Tips (SpiderBasic) for such

Code: Select all

Procedure DesktopWidth()
    ;
    ; Returns the width of the browser area
    ;
    !var width;
    !require(["dojo/window"], function(win){
    !  width = win.getBox().w;
    !});
    !return width;
EndProcedure

Procedure DesktopHeight()
    ;
    ; Returns the height of the browser area
    ;
    !var height;
    !require(["dojo/window"], function(win){
    !  height = win.getBox().h;
    !});
    !return height;
EndProcedure
; (c) Danilo

Re: SpiderBasic 1.00 alpha 3

Posted: Thu Feb 06, 2014 7:19 pm
by Paul
Well, after messing around with alpha3 for a bit I was able to port an app I made in PureBasic back in 2003.
It functions pretty close to the original after making a number of tweeks.
In my opinion its not to bad for an Alpha version of a new product :)

http://reelmedia.org/spiderbasic/spideroids.html

All are welcome to give it a try.

Re: SpiderBasic 1.00 alpha 3

Posted: Thu Feb 06, 2014 7:20 pm
by karu
Fred wrote:
karu wrote:if i use

Code: Select all

 WindowBounds(#win, 800, 600, #PB_Ignore, #PB_Ignore)
and trying to resize window, window will be about 10 points width or height.
Please use the right forum section, thanks: http://www.purebasic.fr/english/viewforum.php?f=41
My mistake.

Re: SpiderBasic 1.00 alpha 3

Posted: Thu Feb 06, 2014 7:34 pm
by srod
Paul wrote:Well, after messing around with alpha3 for a bit I was able to port an app I made in PureBasic back in 2003.
It functions pretty close to the original after making a number of tweeks.
In my opinion its not to bad for an Alpha version of a new product :)

http://reelmedia.org/spiderbasic/spideroids.html

All are welcome to give it a try.
That is pretty cool. :)

Re: SpiderBasic 1.00 alpha 3

Posted: Thu Feb 06, 2014 7:57 pm
by fastbit66
COOL COOL COOL 8)

Waiting for the Linux version!

Re: SpiderBasic 1.00 alpha 3

Posted: Thu Feb 06, 2014 8:01 pm
by luis
@paul

Very nice, it would make a nice demo if it were possible to ship the source with the final product.

Re: SpiderBasic 1.00 alpha 3

Posted: Thu Feb 06, 2014 10:57 pm
by davido
@Paul

Very nice demo - remarkable!

Re: SpiderBasic 1.00 alpha 3

Posted: Fri Feb 07, 2014 5:13 am
by Paul
Here's another just for fun...
http://reelmedia.org/spiderbasic/spiderpong.html

Enjoy :D
(press spacebar to start)

Re: SpiderBasic 1.00 alpha 3

Posted: Fri Feb 07, 2014 5:35 am
by PB
> http://reelmedia.org/spiderbasic/spideroids.html

WOW! :shock: Very nice example of an alpha product indeed!

Question: it is a tad slow here... is that perhaps just my Firefox,
or just the way it's coded, or indicative of SpiderBasic's speed?