Re: [FlexJS] Drawing API

2014-09-11 Thread jude
Thanks Om. It looks much better in my opinion. But to be sure I wasn't imagining things I took screenshots of both and imported them into PS. I then created an animated gif showing both before and after. I'm going to try and attach it. ​ You'll notice the checkmark in the upper left hand corner

Re: [FlexJS] Drawing API

2014-09-10 Thread OmPrakash Muppirala
On Wed, Sep 10, 2014 at 12:54 PM, jude wrote: > FYI according to the article I linked to here [1] it is possible to > improve the rendering quality of vectors on the stage. I thought the > article I linked to was a different article posted by Thimbault > about drawWithQuality(). That means that d

Re: [FlexJS] Path API bug (Was Re: [FlexJS] Drawing API)

2014-09-10 Thread OmPrakash Muppirala
On Wed, Sep 10, 2014 at 7:45 AM, OmPrakash Muppirala wrote: > > On Sep 10, 2014 7:07 AM, "Peter Ent" wrote: > > > > I made a small modification to FlexJSTest_SVG: > > > > > > var path2:Path = new Path(); > > fill.color = 0x00FF00; > >

Re: [FlexJS] Path API bug (Was Re: [FlexJS] Drawing API)

2014-09-10 Thread Peter Ent
The one major change I had to make (aside from removing the Z from my LineChart path) was when the core/graphics element was added to its parent. I was creating the element (e.g., Rect), setting its properties, and then adding it as an element to the ChartDataGroup. This was fine on AS, but on the

Re: [FlexJS] Path API bug (Was Re: [FlexJS] Drawing API)

2014-09-10 Thread OmPrakash Muppirala
On Wed, Sep 10, 2014 at 1:21 PM, Peter Ent wrote: > More details emerged: On the JS side, I had created ChartDataGroup to hold > the chart graphics. Since this was going to be SVG, I had ChartDataGroup > create an SVG element. All of the itemRenderers I created simply added SVG > graphics to this

Re: [FlexJS] Path API bug (Was Re: [FlexJS] Drawing API)

2014-09-10 Thread Peter Ent
More details emerged: On the JS side, I had created ChartDataGroup to hold the chart graphics. Since this was going to be SVG, I had ChartDataGroup create an SVG element. All of the itemRenderers I created simply added SVG graphics to this element. Switching to Om's core/graphics library caused a

Re: [FlexJS] Drawing API

2014-09-10 Thread jude
FYI according to the article I linked to here [1] it is possible to improve the rendering quality of vectors on the stage. I thought the article I linked to was a different article posted by Thimbault about drawWithQuality(). That means that documentation here [2] appears to be incorrect or out of

Re: [FlexJS] Path API bug (Was Re: [FlexJS] Drawing API)

2014-09-10 Thread Peter Ent
I have the latest code; I didn't install it into my Apache FlexJS deployment. That last step always gets me. I did more research on Path and discovered that the presence of the Z is making the path closed (I thought a path string MUST end with a Z), so I believe I can proceed with converting the c

Alex's Legal Mental Model (was Re: [FlexJS] Drawing API)

2014-09-10 Thread Alex Harui
Apologies for not changing the subject sooner. I want to try to clear up some things in case someone actually does try to create a wiki page from these emails. Comments in-line... On 9/9/14 2:53 PM, "Justin Mclean" wrote: >Hi, > >>> -Every line of code was written by somebody, and therefore co

Re: [FlexJS] Path API bug (Was Re: [FlexJS] Drawing API)

2014-09-10 Thread OmPrakash Muppirala
On Sep 10, 2014 7:07 AM, "Peter Ent" wrote: > > I made a small modification to FlexJSTest_SVG: > > > var path2:Path = new Path(); > fill.color = 0x00FF00; > fill.alpha = 0.5; > // path2.fill = fill; >

Re: [FlexJS] Path API bug (Was Re: [FlexJS] Drawing API)

2014-09-10 Thread OmPrakash Muppirala
On Sep 10, 2014 7:12 AM, "Peter Ent" wrote: > > That last message was for the ActionScript side. When I build the sample > in JavaScript - with my change to remove the fill on path2, I get this > runtime error: > > TypeError: this.get_fill(...) is null > var color = Number(this.get_fill().get_colo

Re: [FlexJS] Path API bug (Was Re: [FlexJS] Drawing API)

2014-09-10 Thread Peter Ent
That last message was for the ActionScript side. When I build the sample in JavaScript - with my change to remove the fill on path2, I get this runtime error: TypeError: this.get_fill(...) is null var color = Number(this.get_fill().get_color()).toString(16); Here is the code from GraphicShape.j

Re: [FlexJS] Path API bug (Was Re: [FlexJS] Drawing API)

2014-09-10 Thread Peter Ent
I made a small modification to FlexJSTest_SVG: var path2:Path = new Path(); fill.color = 0x00FF00; fill.alpha = 0.5; // path2.fill = fill; stroke.color = 0xFF00FF;

Re: [FlexJS] Path API bug (Was Re: [FlexJS] Drawing API)

2014-09-10 Thread Peter Ent
I ran FlexJSTest_SVG without any issues from Flash Builder. I will look to see how each of these graphics elements are being used. Thanks, Peter Ent Adobe Systems On 9/9/14 8:47 PM, "OmPrakash Muppirala" wrote: >On Tue, Sep 9, 2014 at 2:26 PM, Peter Ent wrote: > >> I tried that and it did not

Drawing poly lines with Path API (Was: Re: [FlexJS] Drawing API)

2014-09-10 Thread OmPrakash Muppirala
On Mon, Sep 8, 2014 at 1:59 PM, Peter Ent wrote: > > Which brings me to the next issue. When drawing a series of connected > lines (for the LineChart), the first and last points are getting > connected, which I do not want. My loop to build the path looks like this, > below. point[0] != point[las

Re: [FlexJS] Drawing API

2014-09-09 Thread OmPrakash Muppirala
On Tue, Sep 9, 2014 at 6:24 PM, Greg Dove wrote: > As a former degrafa contributor, just a quick note to point out that the > svg path arc implementation is described by w3 here: > > http://www.w3.org/TR/SVG/implnote.html#ArcImplementationNotes > > this is what the code from degrafa was doing and

Re: [FlexJS] Drawing API

2014-09-09 Thread Greg Dove
As a former degrafa contributor, just a quick note to point out that the svg path arc implementation is described by w3 here: http://www.w3.org/TR/SVG/implnote.html#ArcImplementationNotes this is what the code from degrafa was doing and whatever variation of it was found in svgweb. Greg Dove D

Re: [FlexJS] Drawing API

2014-09-09 Thread Alex Harui
On 9/9/14 5:38 PM, "Justin Mclean" wrote: >Hi, > >>> or list where the code came form in another file, >> Our last instructions are to do so in the LICENSE file. > >For a binary file whose license wasn't immediately clear. Here we have a >source file with an Apache header, this is clearly cover

Re: [FlexJS] Path API bug (Was Re: [FlexJS] Drawing API)

2014-09-09 Thread OmPrakash Muppirala
On Tue, Sep 9, 2014 at 2:26 PM, Peter Ent wrote: > I tried that and it did not work (because the fill and stroke were not > set), so I changed my itemRenderer to create the Rect at the point of use: > > protected function drawBar():void > { > if (this.width > 0 && this.height >

Re: [FlexJS] Drawing API

2014-09-09 Thread Justin Mclean
Hi, >> or list where the code came form in another file, > Our last instructions are to do so in the LICENSE file. For a binary file whose license wasn't immediately clear. Here we have a source file with an Apache header, this is clearly covered by [1]. Thanks, Justin 1. http://www.apache.or

Re: [FlexJS] Drawing API

2014-09-09 Thread Alex Harui
I guess we've hit another disagreement. I'm not sure we need a ruling right away and since Justin says the topic is under debate in the incubator, I think we should go with our last instructions for now and get a final ruling later. On 9/9/14 4:13 PM, "Justin Mclean" wrote: > >Under the terms o

Re: [FlexJS] Drawing API

2014-09-09 Thread Justin Mclean
Hi, > I want to include the svgweb version since they have made all the > modifications that I want and hence easily plugs into the Path api. Probably what should of happened was text added to their NOTICE file when the header was changed and then we would of carried that over to our NOTICE file

Re: [FlexJS] Drawing API

2014-09-09 Thread Justin Mclean
Hi, > The second entry in the Installer LICENSE for the updater is not a binary. > Are you saying we did that wrong? I'd say it's not required. Having extra stuff in LICENSE is not a legal issue as the minimum requirements have been met, but they may not need to be there. > You are correct that

Re: [FlexJS] Drawing API

2014-09-09 Thread Alex Harui
The second entry in the Installer LICENSE for the updater is not a binary. Are you saying we did that wrong? You are correct that it isn't "legally required" by the AL. As I said in my email, it appears to be a convention, not even policy, and we started following that convention with the Instal

Re: [FlexJS] Drawing API

2014-09-09 Thread Justin Mclean
Hi, > Are you saying this change, which you advocated, was wrong? Was there a > reversal of the thread somewhere? Neither - see my other email and the original thread on legal. > Can you point me to a podling or two that got rejected for doing this for AL > 3rd party content? Off top of head

Re: [FlexJS] Drawing API

2014-09-09 Thread OmPrakash Muppirala
On Tue, Sep 9, 2014 at 3:21 PM, Alex Harui wrote: > Again, I am not an authority, but I believe permissive licenses like > Apache and MIT allow for re-licensing. The question is, which work do you > want to include? > I want to include the svgweb version since they have made all the modificatio

Re: [FlexJS] Drawing API

2014-09-09 Thread Justin Mclean
Hi, The issue with Open Sans font is different as it is a binary not a source file. It's Apache licensed but not obviously so. Most Apache licences software have source headers so you know how they were licensed, but a binary font file doesn't have a source header that's easily readable (the me

Re: [FlexJS] Drawing API

2014-09-09 Thread Alex Harui
Again, I am not an authority, but I believe permissive licenses like Apache and MIT allow for re-licensing. The question is, which work do you want to include? -Alex On 9/9/14 3:10 PM, "OmPrakash Muppirala" wrote: >Okay, time to reset this conversation. I was digging deeper and found a >comme

Re: [FlexJS] Drawing API

2014-09-09 Thread Alex Harui
On 9/9/14 2:57 PM, "Justin Mclean" wrote: >Hi, > >Please do not do this. There have been several incubator projects who's >release candidates have been rejected for including Apache licensed >software in LICENSE. If something is Apache licensed 3rd party or not >there is no need to add it to LIC

Re: [FlexJS] Drawing API

2014-09-09 Thread OmPrakash Muppirala
Okay, time to reset this conversation. I was digging deeper and found a comment on the class in svgweb that mentions that this code actually came from the Degrafa library [1] Degrafa is released under MIT license [2]. I guess this means that we still have to add this under the subcomponents area

Re: [FlexJS] Drawing API

2014-09-09 Thread Justin Mclean
Hi, Please do not do this. There have been several incubator projects who's release candidates have been rejected for including Apache licensed software in LICENSE. If something is Apache licensed 3rd party or not there is no need to add it to LICENSE. [1] > Yes. And we should make a note tha

Re: [FlexJS] Drawing API

2014-09-09 Thread Justin Mclean
Hi, >> -Every line of code was written by somebody, and therefore copyrighted by >> that somebody (or their employer). Depends on the actually LICENSE. If you look at [1] you see that it states: 2. Grant of Copyright License. Subject to the terms and conditions of this License, each Contributor

Re: [FlexJS] Path API bug (Was Re: [FlexJS] Drawing API)

2014-09-09 Thread Peter Ent
I tried that and it did not work (because the fill and stroke were not set), so I changed my itemRenderer to create the Rect at the point of use: protected function drawBar():void { if (this.width > 0 && this.height > 0) { if (filledRect == null) filledRect = new Rect();

Re: [FlexJS] Path API bug (Was Re: [FlexJS] Drawing API)

2014-09-09 Thread OmPrakash Muppirala
Ah, I see what's happening. My code expects the drawXXX() [drawRect, drawPath, etc.] to be called before adding it as an element to the parent. Try switching this.filledRect = new org.apache.flex.core.graphics.Rect(); this.addElement(this.filledRect); to this.filledRect = new org.apache.flex.c

Re: [FlexJS] Path API bug (Was Re: [FlexJS] Drawing API)

2014-09-09 Thread OmPrakash Muppirala
On Tue, Sep 9, 2014 at 1:15 PM, Peter Ent wrote: > I created a temporary item renderer to see how the x-compile would work. > Here is the code in my temporary item renderer that creates the Rect: > > org.apache.flex.charts.supportClasses.TempBoxRenderer.prototype.set_data = > function(value) { >

Re: [FlexJS] Path API bug (Was Re: [FlexJS] Drawing API)

2014-09-09 Thread Peter Ent
I created a temporary item renderer to see how the x-compile would work. Here is the code in my temporary item renderer that creates the Rect: org.apache.flex.charts.supportClasses.TempBoxRenderer.prototype.set_data = function(value) { org.apache.flex.charts.supportClasses.TempBoxRenderer.base

Re: [FlexJS] Drawing API

2014-09-09 Thread Alex Harui
On 9/9/14 11:39 AM, "Erik de Bruin" wrote: >Thanks Alex! The way you explain it helps me to (finally) understand how >this stuff fits together. > >Would you mind if I put that information in the Wiki, for future reference >and instruction? I suppose, but again, it isn't authoritative. Also, I

Re: [FlexJS] Drawing API

2014-09-09 Thread Alex Harui
On 9/9/14 11:18 AM, "OmPrakash Muppirala" wrote: >I will just bring that file as is with their headers and copyright info. >And make static calls to methods in that class. > >Just to be clear, is it okay to copy that file as is into our codebase? Yes. And we should make a note that it is third-

Re: [FlexJS] Drawing API

2014-09-09 Thread Erik de Bruin
Thanks Alex! The way you explain it helps me to (finally) understand how this stuff fits together. Would you mind if I put that information in the Wiki, for future reference and instruction? EdB On Tue, Sep 9, 2014 at 7:48 PM, Alex Harui wrote: > > > On 9/9/14 9:51 AM, "Erik de Bruin" wrote

[FlexJS] Path API bug (Was Re: [FlexJS] Drawing API)

2014-09-09 Thread OmPrakash Muppirala
On Tue, Sep 9, 2014 at 8:19 AM, Peter Ent wrote: > Have run into a problem on the JS side. Firebox is telling me that in this > code from GraphicShape.js: > > org.apache.flex.core.graphics.GraphicShape.prototype.addedToParent = > function() { > var bbox = this.element.getBBox(); > this.resize

Re: [FlexJS] Drawing API

2014-09-09 Thread OmPrakash Muppirala
On Tue, Sep 9, 2014 at 10:48 AM, Alex Harui wrote: > > > On 9/9/14 9:51 AM, "Erik de Bruin" wrote: > >Not to poke my nose to deep into what is shaping up to be one of those > >nice > >and informative legal threads, but I think I may have a relevant question: > >if some bit of code is AL, is ther

Re: [FlexJS] Drawing API

2014-09-09 Thread Alex Harui
On 9/9/14 9:51 AM, "Erik de Bruin" wrote: >Not to poke my nose to deep into what is shaping up to be one of those >nice >and informative legal threads, but I think I may have a relevant question: >if some bit of code is AL, is there a 'legal' way to rip it apart and put >it back together again,

Re: [FlexJS] Drawing API

2014-09-09 Thread Erik de Bruin
> > >> As part of this implementation, I borrowed the drawEllipicalArc() method > >> from the svgweb library(flash implementation of SVG) [1] The code is > >> Apache licensed. I have added the link to the original code as a > >>comment > >> in our code. Do I need to mention this in the NOTICE or

Re: [FlexJS] Drawing API

2014-09-09 Thread Alex Harui
On 9/9/14 1:30 AM, "Justin Mclean" wrote: >Hi, > >> As part of this implementation, I borrowed the drawEllipicalArc() method >> from the svgweb library(flash implementation of SVG) [1] The code is >> Apache licensed. I have added the link to the original code as a >>comment >> in our code. D

Re: [FlexJS] Drawing API

2014-09-09 Thread Peter Ent
Have run into a problem on the JS side. Firebox is telling me that in this code from GraphicShape.js: org.apache.flex.core.graphics.GraphicShape.prototype.addedToParent = function() { var bbox = this.element.getBBox(); this.resize(this.x_, this.y_, bbox.width + this.x_ * 2, bbox.height + this.

Re: [FlexJS] Drawing API

2014-09-09 Thread Peter Ent
The update to handle 'A' and 'a' works great! Thanks. Peter Ent Adobe Systems On 9/9/14 3:42 AM, "OmPrakash Muppirala" wrote: >On Mon, Sep 8, 2014 at 3:53 PM, OmPrakash Muppirala >wrote: > >> On Mon, Sep 8, 2014 at 1:59 PM, Peter Ent wrote: >> >>> I haven't tried the JS side - this is all Fla

Re: [FlexJS] Drawing API

2014-09-09 Thread Justin Mclean
Hi, > As part of this implementation, I borrowed the drawEllipicalArc() method > from the svgweb library(flash implementation of SVG) [1] The code is > Apache licensed. I have added the link to the original code as a comment > in our code. Do I need to mention this in the NOTICE or LICENSE file

Re: [FlexJS] Drawing API

2014-09-09 Thread OmPrakash Muppirala
On Mon, Sep 8, 2014 at 3:53 PM, OmPrakash Muppirala wrote: > On Mon, Sep 8, 2014 at 1:59 PM, Peter Ent wrote: > >> I haven't tried the JS side - this is all Flash. In SVG, the fill takes >> care of closing the path; I'm not using any line or border. >> >> > Yes, it looks like the A parameter is

Re: [FlexJS] Drawing API

2014-09-08 Thread OmPrakash Muppirala
On Mon, Sep 8, 2014 at 1:59 PM, Peter Ent wrote: > I haven't tried the JS side - this is all Flash. In SVG, the fill takes > care of closing the path; I'm not using any line or border. > > Yes, it looks like the A parameter is not supported. I will work on adding this support in Path. I took a

Re: [FlexJS] Drawing API

2014-09-08 Thread Justin Mclean
Or lineTo?

Re: [FlexJS] Drawing API

2014-09-08 Thread Justin Mclean
Off to of head think you want to use drawLine rather than drawPath

Re: [FlexJS] Drawing API

2014-09-08 Thread Peter Ent
I haven't tried the JS side - this is all Flash. In SVG, the fill takes care of closing the path; I'm not using any line or border. Which brings me to the next issue. When drawing a series of connected lines (for the LineChart), the first and last points are getting connected, which I do not want.

Re: [FlexJS] Drawing API

2014-09-08 Thread OmPrakash Muppirala
On Mon, Sep 8, 2014 at 12:48 PM, Peter Ent wrote: > I took care of the gjslint issues. > Thanks! Hope it was not too much trouble. > > Can you supply more information about Path and what is in the path string? > I have a path working in SVG to do the wedges for the pie chart, but that > same

Re: [FlexJS] Drawing API

2014-09-08 Thread Peter Ent
I took care of the gjslint issues. Can you supply more information about Path and what is in the path string? I have a path working in SVG to do the wedges for the pie chart, but that same string isn't working with core.graphics.Path. var pathString:String = 'M' + x + ' ' + y + ' L' + x1 + ' ' +

Re: [FlexJS] Drawing API

2014-09-08 Thread jude
Way to go! Looks great. At one point browsers couldn't do graphics at all. One thing I want to note is that the rendering in the browsers is getting better than that of Flash. I've attached a screen shot. ​ In the graphic (if it came through) Flash is on the left and HTML (Firefox Mac) on the r

Re: [FlexJS] Drawing API

2014-09-08 Thread Erik de Bruin
> > I'm wondering what kind of changes you would suggest. On a related note, > I'm not suggesting any changes, I was merely enquiring if this was in any shape to be (re)used in a different setting. I'm currently able to export 442 classes from 'playerglobal.swc' to JS, automatically, as stubs. B

Re: [FlexJS] Drawing API

2014-09-08 Thread Alex Harui
Erik, I'm wondering what kind of changes you would suggest. On a related note, I'm trying to port the FlexStore example to FlexJS. When I'm done with that I'm hoping to wrap some FlexJS components to make their APIs more Spark-like and see how porting to that feels and get a sense of how much mo

Re: [FlexJS] Drawing API

2014-09-08 Thread OmPrakash Muppirala
On Sep 8, 2014 1:04 AM, "Erik de Bruin" wrote: > > Om, awesome! > > As the developer of an alternative AS -> JS solution, I'm wondering if your > contribution (especially the JS side) might be implemented in a somewhat > less FlexJS dependent manner? It would be awesome if I could hook up the JS >

Re: [FlexJS] Drawing API

2014-09-08 Thread OmPrakash Muppirala
On Sep 8, 2014 8:22 AM, "Peter Ent" wrote: > > I'm going to see if I can use these for the graphics in the chart work > I've been doing. Might be very helpful there. That would be awesome! Let me know how I can help. I just realized that there might be a bug in how I size the svg element. I sh

Re: [FlexJS] Drawing API

2014-09-08 Thread OmPrakash Muppirala
On Sep 8, 2014 8:24 AM, "Peter Ent" wrote: > > I forgot to add that when I build flex-asjs, gjslint finds a number of > issues in the new JS graphics code (its usual, spaces at the end of lines, > sort of thing). I think I am using version 2.3.10 of gjslint but I'm not > 100% sure. Yeah, unfortun

Re: [FlexJS] Drawing API

2014-09-08 Thread Peter Ent
I forgot to add that when I build flex-asjs, gjslint finds a number of issues in the new JS graphics code (its usual, spaces at the end of lines, sort of thing). I think I am using version 2.3.10 of gjslint but I'm not 100% sure. Peter Ent Adobe Systems On 9/8/14 3:48 AM, "OmPrakash Muppirala" w

Re: [FlexJS] Drawing API

2014-09-08 Thread Peter Ent
I'm going to see if I can use these for the graphics in the chart work I've been doing. Might be very helpful there. Peter Ent Adobe Systems On 9/8/14 3:48 AM, "OmPrakash Muppirala" wrote: >FlexJS now supports a basic drawing API (Rect, Ellipse, Circle, Path, >SolidColor, SolidColorStroke) Her

RE: [FlexJS] Drawing API

2014-09-08 Thread Kessler CTR Mark J
] Drawing API FlexJS now supports a basic drawing API (Rect, Ellipse, Circle, Path, SolidColor, SolidColorStroke) Here are the AS3 [1] and JS [2] versions So far, the rendering fidelity between the Flash and SVG/HTML5 version is very very close. For sure, there are some pretty major things to be worked

Re: [FlexJS] Drawing API

2014-09-08 Thread Erik de Bruin
Om, awesome! As the developer of an alternative AS -> JS solution, I'm wondering if your contribution (especially the JS side) might be implemented in a somewhat less FlexJS dependent manner? It would be awesome if I could hook up the JS classes I'm currently auto-creating from 'playerglobal.swc'

[FlexJS] Drawing API

2014-09-08 Thread OmPrakash Muppirala
FlexJS now supports a basic drawing API (Rect, Ellipse, Circle, Path, SolidColor, SolidColorStroke) Here are the AS3 [1] and JS [2] versions So far, the rendering fidelity between the Flash and SVG/HTML5 version is very very close. For sure, there are some pretty major things to be worked out, b