Drawing simple objects in Django using canvas

903 views
Skip to first unread message

Nemanja Milosavljevic

unread,
May 29, 2016, 7:24:16 PM5/29/16
to Django users

I am trying to draw simple objects on HTML canvas with Django as my backend. Objects are simple geometrical shapes. I find a Fabric.js java script but it is complicated and I am trying to find something easier. Can someone help me with what I can use?


James Schneider

unread,
May 30, 2016, 2:19:12 AM5/30/16
to django...@googlegroups.com


On May 29, 2016 4:23 PM, "Nemanja Milosavljevic" <nemanj...@gmail.com> wrote:
>
>
>
> down votefavorite
>
> I am trying to draw simple objects on HTML canvas with Django as my backend. Objects are simple geometrical shapes. I find a Fabric.js java script but it is complicated and I am trying to find something easier. Can someone help me with what I can use?
>

Django would not be directly responsible for drawing the canvas. That's handled by Javascript (AFAIK, I've never specifically researched how HTML canvas apps work).

Django can provide the access to data structures and persistent storage (DB) needed for use within your JS framework. I suppose you could have Django generate the JS file(s) needed and populate then with the Django context, but that is not a common strategy. Normally data acquisition is handled by static JS files that would call back to a Django instance via AJAX for the required data.

-James

Derek

unread,
Jun 1, 2016, 6:21:58 AM6/1/16
to Django users
My sense is that javascript for this type of application *is* going to be complex; but if you need, you will have to learn it.

There's also go.js - e..g http://gojs.net/latest/learn/index.html
Reply all
Reply to author
Forward
0 new messages