Commit b7a565a7 authored by PkSM3's avatar PkSM3

panelinfo css bugfix

parent ecb87d35
......@@ -22,7 +22,7 @@ external="";
bridge["forFilteredQuery"] = external+"php/bridgeClientServer_filter.php";
bridge["forNormalQuery"] = external+"php/bridgeClientServer.php";
var clusters = [];
ircNick="";
......
......@@ -83,9 +83,11 @@ function sigmaLimits(){
altototal=$('#leftcolumn').height();
altofixtop=$('#dafixedtop').height()
altodeftop=$('#defaultop').height()
if((anchototal-sidebar)>0)
$('#sigma-example').width(anchototal-sidebar);
$('#sigma-example').height(altototal-altofixtop-altodeftop);
if((anchototal-sidebar)>0) {
if($('#leftcolumn').css('right')>0)
$('#sigma-example').width(anchototal-sidebar);
}
$('#sigma-example').height(altototal-altofixtop-altodeftop-10);
pw=$('#sigma-example').width();
ph=$('#sigma-example').height();
......
function draw1Circle(ctx , x , y , color) {
function draw1Circle(ctx , x , y , r , color) {
ctx.strokeStyle = '#000';
ctx.lineWidth = 1;
ctx.fillStyle = color;
ctx.globalAlpha = 0.5;
ctx.beginPath();
ctx.arc(x, y, 10, 0, Math.PI * 2, true);
ctx.arc(x, y, r, 0, Math.PI * 2, true);
ctx.closePath();
ctx.fill();
ctx.stroke();
......
......@@ -1120,6 +1120,11 @@ sigma.publicPrototype.startForceAtlas2 = function() {
var V = 10;
var E = 100;
// for(var c in clusters) {
// cid = ""+clusters[c]
// if(isUndef(getn("c"+cid)))
// partialGraph.dropNode("c"+cid)
// }
this.forceatlas2 = new sigma.forceatlas2.ForceAtlas2(this._core.graph , V, E);
this.forceatlas2.setAutoSettings();
this.forceatlas2.init();
......@@ -1172,8 +1177,58 @@ sigma.publicPrototype.stopForceAtlas2 = function() {
}
}
}
updateMap();
partialGraph.refresh();
if(minimap) $("#overviewzone").show();
// $.doTimeout(1000,function (){
// for(var c in clusters) {
// cid = ""+clusters[c]
// neighs = nodes1[cid].neighbours
// pr(cid)
// pr(neighs)
// var min_x=9999.0, max_x=-9999.0, min_y=9999.0, max_y=-9999.0;
// for(var n in neighs) {
// nid = neighs[n]+"";
// pr(nid)
// var x = partialGraph._core.graph.nodesIndex[nid].x
// var y = partialGraph._core.graph.nodesIndex[nid].y
// if(parseFloat(x) < parseFloat(min_x)) min_x= x;
// if(parseFloat(x) > parseFloat(max_x)) max_x= x;
// if(parseFloat(y) < parseFloat(min_y)) min_y= y;
// if(parseFloat(y) > parseFloat(max_y)) max_y= y;
// }
// pr("min_x: "+min_x + " | max_x: " + max_x + " | min_y: " + min_y + " | max_y: " + max_y)
// pr("")
// var Ox = (min_x+max_x)/2;
// var Oy = (min_y+max_y)/2;
// var Px = min_x;
// var Py = min_y;
// var R = Math.sqrt( Math.pow((Ox-Px), 2) + Math.pow((Oy-Py), 2) );
// R = R * 1.2;
// pr(hex2rga(colorList[c]))
// var node = ({
// id: "c"+cid ,
// label:"",
// size:R,
// x:getn(cid).x,
// y:getn(cid).y,
// color: colorList[c]
// }); // The graph node
// partialGraph.addNode("c"+cid,node);
// }
// });
partialGraph.draw()
};
......@@ -670,7 +670,10 @@ function parseSimpleJSON( data , seed ) {
size = (isUndef(nodesNodes[i].size))?1:nodesNodes[i].size;
group = (isUndef(nodesNodes[i].group))?1:nodesNodes[i].group;
iscluster = (isUndef(nodesNodes[i].hidden))?false:nodesNodes[i].hidden;
if (iscluster==1) iscluster=true;
if (iscluster==1) {
iscluster=true;
clusters.push(i)
}
var node = ({
id: i ,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment