Simple graphics in web-browser

Discussion in 'JavaScript and AJAX' started by Typr451, Apr 21, 2009.

  1. Typr451

    Typr451 New Member

    Joined:
    Apr 11, 2009
    Messages:
    11
    Likes Received:
    0
    Trophy Points:
    0
    Hi! I'm going to make a graphical thing for the content of a database for this cource. For example if there's a table with a many-to-many relation I want to print out the entires with lines to the other entires like they're related to display a nice tree.

    I've been thinking about a way to do this. I've never done anything in ActionScript so I've been leaning a lot towards learning it. I've done some work in OpenGL and I've programmed for some years so I'm not afraid of ActionScript :)

    Anyway, I've been thinking, there are basically two reasons I'm thinking about picking ActionScript. The first being I want to learn it, but other than that I just want to draw the lines between the entires. I was reading up on graphics in JavaScript and someone had done a library by using div-tags as pixles, then I thought I could probably pretty easily draw the lines with divs. I'm thinking it'll print out like this:

    Parent
    |-------|--------|
    Child Child Child

    So it's basically pretty straight lines. I understand Flash is very nice for animation, but I don't think I'll need that. My question I think is this: Is it uneccessary hard in ActionScript to make things like an expanding box around text (like a table-tag), with something like a gradient overlay background expanding with it? Also just drawing lines to a position relative to the table? What I've seen about ActionScript have been a friend's project linking animations to triggers and making a really nice game. I'm not sure how good it is to draw dynamic tables though.

    The thing is just if I print my database and just use div- or even table-tags, I can format them a little and have a nice background (just repeat to fill the entire table). The tables will expand with the text print-out and the only thing are the lines which I'm hoping carfully adjusted length of divs will make ok. It's supose to be nice though so if I can't get the lines exact I'll give it up completly.

    But I do want to learn ActionScript, and if I do I would probably add some quick animations so it doesn't look like I did the whole thing with divs :) However I'm afraid to start learning it if it's that hard or even impossible to make this simple thing, it's a cource afterall and it needs to be completed.
     
  2. Typr451

    Typr451 New Member

    Joined:
    Apr 11, 2009
    Messages:
    11
    Likes Received:
    0
    Trophy Points:
    0
    Never mind, in case anyone looks for the same answer: I read some tutorials on actionscript.org and read the Adove live docs a little and it was no biggie doing anything I hoped to do.
     

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice