Apologies for taking so long to get back to you on your questions. To provide an app, JHS needs to have the script that implements the app loaded. This is done fro you automatically when you run studio demos. The other part of running an app is to load the page in your browser. This can be done by entering the URL and for something you'll do often you'll want to bookmark that URL.
Following is a sketch of what to do to run jdemo2 as an app called rollem: 1. copy the demo/jdemo2.ijs script to your app folder as rollem.ijs 2. edit rollem.ijs coclass to be rollem instead of jdemo2 3. start JHS and load the rollem.ijs script (you can automate this) 4. browse to page localhost:65001/rollem 5. bookmark that page to make it easier to run that app *** Look at the ~addons/ide/jhs/jijs.ijs script to see how it adds lines to include the codemirror javascript code. Add your jquery script load to the front of HBS definition in your app to make the jquery routines avaiable. With luck a JHS release the end of this week or early next week will include the jquery min scripts and an example of how they work. This will make it a bit easier to use jquery, but you can also roll your own right now. On Fri, Sep 13, 2013 at 6:51 AM, Brian Schott <[email protected]> wrote: > Is there an example or a Lab of a *standalone* JHS app like jdemo2 -- named > rollem, not jdemo2, for example -- which shows how the app can be launched > either directly or from jijx and not as a demo? > > Also, I would like to add the following to the <head> part of the app > without having to alter `utilh.ijs`. How can such be done? [I suspect that > jdemo9.ijs is a model for this request using the scripts for `jev_get` and > `html`, but could use some guidance.] > > <script type="text/javascript" src=" > http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js"></script> > <script type="text/javascipt"> $(document).ready(function() { > }); > </script> > > Thanks, > > > On Wed, Sep 11, 2013 at 4:30 PM, Eric Iverson <[email protected]>wrote: > >> There is no such thing as JHS canvas. HTML5 has an element type of >> canvas on which drawing primitives work. >> >> On Wed, Sep 11, 2013 at 3:47 PM, Brian Schott <[email protected]> >> wrote: >> > The book by Rob Hawkes shows the javascript and css code for 2 simple >> > "games" (one is like bowling with the mouse and the other is like >> avoiding >> > astroids with keystrokes). I am asking if the canvas that html5 needs >> > replaces the canvas for JHS or if the JHS canvas can be used directly. >> > >> > >> > On Wed, Sep 11, 2013 at 3:36 PM, Eric Iverson <[email protected] >> >wrote: >> > >> >> Work starting with the simpler demos (not the grid!). The hard part >> >> will be learning enough javascript to make things happen on the client >> >> side. The J coding is not that different than that required for wd. >> >> The big addition is CSS, HTML5, and javascript. That is a lot of stuff >> >> to swallow, but it is powerful and is going to be part of the >> >> developers landscape for some time to come. >> >> >> >> On Wed, Sep 11, 2013 at 3:30 PM, Brian Schott <[email protected]> >> >> wrote: >> >> > Do you mean actually doing things fundamental like are done in >> utilh.ijs >> >> > and utiljs.ijs or do you mean just learning how the demo's work >> already? >> >> > Having looked at your code for core.ijs and utilh.ijs and utiljs.ijs, >> I >> >> > wonder if that level of coding is within my reach. You are a master at >> >> > that. But mortals like myself are not. >> >> > >> >> > >> >> > On Wed, Sep 11, 2013 at 3:23 PM, Eric Iverson < >> [email protected] >> >> >wrote: >> >> > >> >> >> You would have to invest a bit of effort to provide a game framework >> >> >> for a JHS app/page. This could include all the HTML5 stuff including >> >> >> canvas. >> >> >> >> >> >> On Wed, Sep 11, 2013 at 3:12 PM, Brian Schott < >> [email protected]> >> >> >> wrote: >> >> >> > Right. I forgot about utilh.ijs and utiljs.ijs. Thanks. >> >> >> > >> >> >> > I just finished an inspiring book by Rob Hawkes entitled, >> Foundation >> >> >> HTML5 >> >> >> > Canvas (for games and entertainment). He shows how javascript and >> >> canvas >> >> >> > can be used to build simple graphical games in browsers. >> >> >> > http://html5test.com tells me that my 3 browsers all have 2D >> canvas >> >> >> > capabilities, and I wonder if JHS could be used as a sort of >> backend >> >> to >> >> >> > create and feed 3D graphics to the 2D canvas. My motivation comes >> >> from my >> >> >> > grandson's fascination with games and his wish to create his own. I >> >> >> wonder >> >> >> > if JHS would be less of an obstacle to entry than are iOS and >> Android >> >> >> > coding for him and like kids? >> >> >> > >> >> >> > Comments? >> >> >> > >> >> >> > >> >> >> > -- >> >> >> > (B=) >> >> >> > >> ---------------------------------------------------------------------- >> >> >> > For information about J forums see >> >> http://www.jsoftware.com/forums.htm >> >> >> >> ---------------------------------------------------------------------- >> >> >> For information about J forums see >> http://www.jsoftware.com/forums.htm >> >> >> >> >> > >> >> > >> >> > >> >> > -- >> >> > (B=) <-----my sig >> >> > Brian Schott >> >> > ---------------------------------------------------------------------- >> >> > For information about J forums see >> http://www.jsoftware.com/forums.htm >> >> ---------------------------------------------------------------------- >> >> For information about J forums see http://www.jsoftware.com/forums.htm >> >> >> > >> > >> > >> > -- >> > (B=) <-----my sig >> > Brian Schott >> > ---------------------------------------------------------------------- >> > For information about J forums see http://www.jsoftware.com/forums.htm >> ---------------------------------------------------------------------- >> For information about J forums see http://www.jsoftware.com/forums.htm >> > > > > -- > (B=) <-----my sig > Brian Schott > ---------------------------------------------------------------------- > For information about J forums see http://www.jsoftware.com/forums.htm ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm
