Currently you can set Gnoga to use any html file you want with (which of
course can include and CSS, etc. etc.):

   Application.Multi_Connect.On_Connect_Handler
     (Event => On_BootJS_Demo_Page'Unrestricted_Access,
      Path  => "bootjs_demo.html");

In the html file you just need to have:
      <script src="/js/jquery.min.js"></script>
      <script src="/js/boot.js"></script>

Within your code you just do:

Main_Window.Disable_Auto_Set_View;
My_View.Create (Main_Window);
Gnoga.Client.Bind_Page.Bind_Page (My_View);

Now every element in bootjs_demo.html is available with:

My_View.Element ("id_name")

If you wanted more fine grain control and were binding things like forms
you can bind individual elements:

My_Form_Input.Create_With_Parent (Main_Window, "id_of_form");

The only thing I can see adding here is perhaps a way to load HTML
fragments from local file and post to an already existing Gnoga view, but
that is already easy:

declare
   My_HTML : String := Gnoga.Server.Template_Parser.Simple.Load_View
("some_html_file");
begin
   My_View.Put_HTML (My_HTML);
end;

Just make sure the fragment in My_HTML is with in a block, like a <div>.

You can then do again either Bind_Page (My_View) or bind to any element
with Create_With_Parent

--> Does this cover everything you described or you would imagine something
more?

BTW, As you can see above I am using the simple parser to load the HTML
fragment. It would be possible to use Gnoga's Python parser instead if more
was desired in terms of manipulating the HTML fragment first.

David Botton
------------------------------------------------------------------------------
Dive into the World of Parallel Programming. The Go Parallel Website,
sponsored by Intel and developed in partnership with Slashdot Media, is your
hub for all things parallel software development, from weekly thought
leadership blogs to news, videos, case studies, tutorials and more. Take a
look and join the conversation now. http://goparallel.sourceforge.net/
_______________________________________________
Gnoga-list mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/gnoga-list

Reply via email to