This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Add the function to the public prototype : | |
*/ | |
sigma.publicPrototype.outDegreeToSize = function() { | |
this.iterNodes(function(node){ | |
node.size = node.outDegree; | |
}).draw(); | |
}; | |
/* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- Button to generate random graphs --> | |
<button id="random" type="button" onclick="feedSiGMa();">Click to generate a random graph</button> | |
<!-- SiGMa --> | |
<div id="SiGMa-container" style="height:400px;width:100%;"> | |
<object id="SiGMa-client" style="width:100%;height:98%;border:1px #866 solid;"> | |
<param name="movie" value="/static/sigma-random/sigma.swf?configPath=/static/sigma-random/config.json"/> | |
<param name="allowScriptAccess" value="always"/> | |
<embed src="/static/sigma-random/sigma.swf?configPath=/static/sigma-random/config.json" allowScriptAccess="always"> | |
</embed> | |
</object> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- Button to generate random graphs --> | |
<button id="random" type="button" onclick="feedSiGMa();">Click to generate a random graph</button> | |
<!-- SiGMa --> | |
<div id="SiGMa-container" style="height:400px;width:100%;"> | |
<object id="SiGMa-client" style="width:100%;height:98%;border:1px #866 solid;"> | |
<param name="movie" value="/static/sigma-random/sigma.swf?configPath=/static/sigma-random/config.json"/> | |
<param name="allowScriptAccess" value="always"/> | |
<embed src="/static/sigma-random/sigma.swf?configPath=/static/sigma-random/config.json" allowScriptAccess="always"> | |
</embed> | |
</object> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* | |
* SiGMa, the Simple Graph Mapper | |
* Copyright (C) 2010, Alexis Jacomy | |
* | |
* This program is free software: you can redistribute it and/or modify | |
* it under the terms of the GNU General Public License as published by | |
* the Free Software Foundation, either version 3 of the License, or | |
* (at your option) any later version. | |
* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8" standalone="no"?> | |
<actionScriptProperties mainApplicationPath="SiGMa.mxml" projectUUID="efe51f0a-aca3-48c8-aee8-d6dd5e308dbc" version="6"> | |
<compiler additionalCompilerArguments="-use-network=false" autoRSLOrdering="true" copyDependentFiles="true" fteInMXComponents="false" generateAccessible="true" htmlExpressInstall="true" htmlGenerate="true" htmlHistoryManagement="true" htmlPlayerVersionCheck="true" includeNetmonSwc="false" outputFolderPath="bin-debug" sourceFolderPath="src" strict="true" targetPlayerVersion="0.0.0" useApolloConfig="false" useDebugRSLSwfs="true" verifyDigests="true" warn="true"> | |
<compilerSourcePath/> | |
<libraryPath defaultLinkType="0"> | |
<libraryPathEntry kind="4" path=""> | |
<excludedEntries> | |
<libraryPathEntry kind="3" linkType="1" path="${PROJECT_FRAMEWORKS}/libs/flex.swc" useDefaultLinkType="false"/> | |
</excludedEntries> | |
</libraryPathEntry> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<head> | |
<style> | |
*{ | |
margin: 0; | |
padding: 0; | |
font-family: Helvetica; | |
font-size: 8pt; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// To react a node clicking, you have to listen to the | |
// event InteractionControler.CLICK_NODES: | |
InteractionControler.addEventListener(InteractionControler.CLICK_NODES,onClickNodes); | |
function onClickNodes(e:ContentEvent):void{ | |
// e is a ContentEvent, with an array containing the | |
// IDs of each node under the mouse cursor during the | |
// click: | |
var clickedNodeIDs:Array = e.content; | |
NewerOlder