When I display 2 diagrams, the values of d attributes in <path> tags are not the good ones. So all the lines are in the wrong place. I suppose that it's coming from the method addRenderingEdges because this is where the path tag is set up.
Kevin
----- Mail original -----
De: "Alexandre Bergel" alexandre.bergel@me.com À: "Moose-related development" moose-dev@iam.unibe.ch Envoyé: Mardi 7 Janvier 2014 19:13:43 Objet: [Moose-dev] Re: Cannot display 2 diagrams in the same webpage
It seems that the 'd' attribute in the method: ROHTMLExporter >> addRenderingEdges isn't correctly set. Do we have to change the js code to fix it ?
I am not sure to understand. The method is:
addRenderingEdges: fileStream
fileStream nextPutAll: '/***** RENDERING LINKS*****/ var links = dataset.links; var path = vis.selectAll("path") .data(links); path.enter().append("path") .attr("d", elbow) .attr("stroke", function(d) {return d.edgeColor});'; nextPutAll: ROPlatform current newLine.
What is wrong with it?
Alexandre
----- Mail original -----
De: "Kevin Lanvin" kevin.lanvin@inria.fr À: "Moose-related development" moose-dev@iam.unibe.ch Envoyé: Mardi 7 Janvier 2014 13:32:48 Objet: [Moose-dev] Re: Cannot display 2 diagrams in the same webpage
Vincent told me to look after another unique id selection during the svg initialization process but I didn't find any.
----- Mail original -----
De: "Kevin Lanvin" kevin.lanvin@inria.fr À: "Moose-related development" moose-dev@iam.unibe.ch Envoyé: Mardi 7 Janvier 2014 13:28:27 Objet: [Moose-dev] Re: Cannot display 2 diagrams in the same webpage
Hi, Now I can display 2 diagrams (I've changed the addSVGInitialization: method , I'll send it to alexandre). My new problem is: if I display 1 diagram, everything is ok, but if I display 2, the second one isn't displayed correctly. All the elements included in <path> tag are at the wrong place. I tried to display only the second one , and it's working perfectly so it's not coming from the diagram itself. I tried to invert the diagrams , and its exactly the same problem : the first one displayed is ok , not the second.
Thank you
----- Mail original -----
De: "Kevin Lanvin" kevin.lanvin@inria.fr À: "Moose-related development" moose-dev@iam.unibe.ch Envoyé: Mardi 7 Janvier 2014 10:33:37 Objet: [Moose-dev] Re: Cannot display 2 diagrams in the same webpage
Hello
In ROHTMLExporter>>addSVGInitialization , i've changed chart by chart1 and it's working , so the id is used at this place, you are right. Do you think it is possible to dynamically choose the id that you want to work with ?
Thank you
----- Mail original -----
De: "Vincent BLONDEAU" vincent.blondeau@polytech-lille.net À: "Moose-related development" moose-dev@iam.unibe.ch Envoyé: Lundi 6 Janvier 2014 17:42:06 Objet: [Moose-dev] Re: Cannot display 2 diagrams in the same webpage
-----Message d'origine----- De : moose-dev-bounces@iam.unibe.ch [mailto:moose-dev-bounces@iam.unibe.ch] De la part de Kevin Lanvin Envoyé : lundi 6 janvier 2014 17:25 À : Moose-related development Objet : [Moose-dev] Cannot display 2 diagrams in the same webpage
I have a question that could help me to understand: Why is the 'chart' division empty ?
The div 'chart' is just a placeholder to your graph.
How is this division used ?
As the id is unique, GraphET (with some JQuery functions) can retreive your div.
I've found a piece of code containing 'chart' in ROHTMLExporter >> addSVGInitialization but it's into javascript code so I don't know if it's the right place to fix it.
It's the only reference to 'chart' in the image. Set a breakpoint and try or modify it by 'chart1' for example.
----- Mail original ----- > De: "Kevin Lanvin" kevin.lanvin@inria.fr > À: "Moose-related development" moose-dev@iam.unibe.ch > Envoyé: Lundi 6 Janvier 2014 17:10:33 > Objet: [Moose-dev] Re: [Pharo-dev] Feature for request for > GraphET? > > It seems that 'chart' isn't even written in Graph-ET Package. > I didn't find anything interesting in extra files too. > I don't understand where this id is used. > I thought it was just for css , or just rendering axis and so > on > ... > > Thank you for helping > > ----- Mail original ----- >> De: "Vincent BLONDEAU" >> vincent.blondeau@polytech-lille.net >> À: "Moose-related development" moose-dev@iam.unibe.ch >> Envoyé: Lundi 6 Janvier 2014 16:54:25 >> Objet: [Moose-dev] Re: [Pharo-dev] Feature for request for >> GraphET? >> >> >> >> -----Message d'origine----- >> De : moose-dev-bounces@iam.unibe.ch >> [mailto:moose-dev-bounces@iam.unibe.ch] >> De la part de Kevin Lanvin >> Envoyé : lundi 6 janvier 2014 15:30 >> À : Moose-related development >> Objet : [Moose-dev] Re: [Pharo-dev] Feature for request for >> GraphET? >> >> Hello, >> I'm displaying a graph on the web , and it's working well, >> but >> then >> I want tu put a second diagram on my page. >> But diagrams are displayed in <div id="chart"></div> So i >> can't >> use >> a second division to display another one. >> Could it be possible to use class instead of id ? >> >> >> >> Hi Kevin, >> >> I think you can't use the class tag instead of id. >> The id tag has to be unique in the web page. >> Class tag is not unique and it's used mostly for the css >> tags. >> >> If you want to display two diagrams in the page, put the >> tag >> : >> <div >> id="chart1"></div> as a placeholder for the first and <div >> id="chart2"></div> for the second. >> You have to set also the controller (GraphET) to display >> the >> right >> chart in the right tag, by default, it seems to be set with >> "chart". >> >> I hope that it will help, >> >> Vincent Blondeau >> >> >> >> >> _______________________________________________ >> Moose-dev mailing list >> Moose-dev@iam.unibe.ch >> https://www.iam.unibe.ch/mailman/listinfo/moose-dev >> > > _______________________________________________ > Moose-dev mailing list > Moose-dev@iam.unibe.ch > https://www.iam.unibe.ch/mailman/listinfo/moose-dev >
Moose-dev mailing list Moose-dev@iam.unibe.ch https://www.iam.unibe.ch/mailman/listinfo/moose-dev
Moose-dev mailing list Moose-dev@iam.unibe.ch https://www.iam.unibe.ch/mailman/listinfo/moose-dev
Moose-dev mailing list Moose-dev@iam.unibe.ch https://www.iam.unibe.ch/mailman/listinfo/moose-dev
Moose-dev mailing list Moose-dev@iam.unibe.ch https://www.iam.unibe.ch/mailman/listinfo/moose-dev
Moose-dev mailing list Moose-dev@iam.unibe.ch https://www.iam.unibe.ch/mailman/listinfo/moose-dev
Moose-dev mailing list Moose-dev@iam.unibe.ch https://www.iam.unibe.ch/mailman/listinfo/moose-dev
-- _,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;: Alexandre Bergel http://www.bergel.eu ^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;.
Moose-dev mailing list Moose-dev@iam.unibe.ch https://www.iam.unibe.ch/mailman/listinfo/moose-dev