PageSourceSearch

https://textexture.com/

html textexture.com collected 2026-09-25 21:00:59 UTC 30,633 bytes, 1,070 lines download raw bytes

1<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
2<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" >
3	<head>
4		<title>Visualize any Text as a Network - Textexture</title>
5		<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
6                <meta charset="UTF-8">
7                <meta property="fb:admins" content="655200751"/>
8                <meta property="og:title" content="Visualize any Text as a Network - Textexture"/>
9<meta property="og:url" content="http://textexture.com"/>
10<meta property="og:site_name" content="Textexture Text Network Visualization"/>
11<meta property="og:type" content="software"/>
12<meta property="fb:page_id" content="247159645351083"/>
13<meta property="fb:app_id" content="301949576509759"/>
14h
15
16<script src="js/sigma.min.js"></script>
vendor: 1 bytes, line 16
16
17<script src="js/sigma.parseGexf.js"></script>
vendor: 1 bytes, line 17
17
18<script src="js/sigma.forceatlas2.js"></script>
vendor: 1 bytes, line 18
18
19<script type='text/javascript' src='js/jquery.min.js'></script>
vendor: 1 bytes, line 19
19
20<script type='text/javascript' src='js/jquery.content-panel-switcher.js'></script>
20  
21<script type='text/javascript' src="js/jquery.highlight-3.js"></script>
vendor: 1 bytes, line 21
21
22<script type="text/javascript" src="js/jquery.qtip-1.0.0.min.js"></script>
22
23
24
25
26<script type='text/javascript'>
27$(document).ready(function() {
28	jcps.fader(300, '#switcher-panel', '.set1');
29});
30</script>
30
31
32<script type='text/javascript'>
33function prepareSubmit() {
34	 document.getElementById('textarea').value = document.getElementById('textdisplay').innerHTML;
35}
36</script>
vendor: 1 bytes, line 36
36
37<script type='text/javascript'>
38function prepareSubmit2() {
39	 document.getElementById('textarea2').value = document.getElementById('textdisplay2').innerHTML;
40}
41</script>
41
42
43<script type="text/javascript"> 
44function select_all()
45{
46var text_val=eval("document.embed.embed_code");
47text_val.focus();
48text_val.select();
49
50}
51</script>
51
52
53<script type="text/javascript"> 
54function select_all_u()
55{
56var text_val=eval("document.embed.url");
57text_val.focus();
58text_val.select();
59
60}
61</script>
61
62
63
64<script type="text/javascript">
65// Create the tooltips only on document load
66$(document).ready(function() 
67{
68   // Match all link elements with href attributes within the content div
69   $('#bookmarklet').qtip(
70   {
71     
72	  content: '<img src="templates/bookmarklet_help.png" border="0"><font size="-1" face="Helvetica, Arial"><br>&nbsp;<br>1. Make sure that your browser\'s bookmarks toolbar is visible (View > Always Show Bookmarks Bar in Chrome);<br>&nbsp;<br>2. Drag and drop the button into your browser\'s bookmarks toolbar;<br>&nbsp;<br>3. Next time you want to visualize any article you\'re reading or a YouTube video as a text network, just click on that button;<br>&nbsp;<br></font>',
73	   show: 'mouseover',
74   	hide: 'mouseout',
75	position: {
76      corner: {
77         target: 'bottomMiddle',
78         tooltip: 'topMiddle'
79      }
80   },
81   style: { 
82      border: {
83                     width: 3,
84                     radius: 10
85                  },
86      width: 580,
87      height: 380,
88      padding: 10,
89      tip: true,
90      name: 'cream' // Inherit from preset style
91	//  tip: true
92   },
93  	
94	
95   });
96});
97</script>
97
98
99
100<link rel="stylesheet" type="text/css" media="all" href="templates/styles.css" />
101<link rel="stylesheet" type="text/css" media="screen" href="js/jquery.content-panel-switcher.css" /> 
102
103
104<script language="javascript"> 
105function toggle() {
106	var ele = document.getElementById("graphhelp");
107	var text = document.getElementById("displayText");
108	if(ele.style.display == "block") {
109    		ele.style.display = "none";
110		text.innerHTML = "How to Use?";
111  	}
112	else {
113		ele.style.display = "block";
114		text.innerHTML = "Hide Tip";
115	}
116} 
117</script>
117
118
119<script language="javascript"> 
120function toggleios() {
121	var ele = document.getElementById("ioshelp");
122	var text = document.getElementById("displayios");
123	if(ele.style.display == "block") {
124    		ele.style.display = "none";
125		text.innerHTML = "iPad/iPhone";
126  	}
127	else {
128		ele.style.display = "block";
129		text.innerHTML = "hide";
130	}
131} 
132</script>
132
133
134
135
136
137
138</head>
139<body>
140<div id="page">
141<div id="header">
142
143<div id="logo">
144<a href="index.php"><img src="templates/logo.png" vspace="3"></a></div>
145<div id="search">
146     <form action="search.php" method="get">
147         <nobr>  <input size="30" name="search" id="search_form" value=""></input>&nbsp;&nbsp;&nbsp;&nbsp;<input type="submit" value="search" /></nobr>
148
149    </form>
150</div>
151
152<nav id="navigation">
153<div class="menu">&nbsp;<br><ul id="menu-main-menu"><li class="current_page_item"><a href="/">start</a></li>
154<li><a href="user.php">my account</a></li>            
155<li><a href="search.php?show_all=1">library</a>
156<ul class='children'>
157<li><a href="search.php?show_all=1">Your Texts</a></li>
158<li><a href="search.php?search=&public=1">Public Texts</a></li>
159<li><a href="index.php?text_id=603">Bible, Genesis 1:1</a></li>
160<li><a href="index.php?text_id=604">I Have a Dream by Martin Luther King</a></li>
161<li><a href="index.php?text_id=606">War and Peace, chapter 2 by Leo Tolstoy</a></li>
162<li><a href="index.php?text_id=711">Lolita by Vladimir Nabokov</a></li>
163<li><a href="index.php?text_id=605">Emancipated Spectator by Jacques Rancier</a></li>
164<li><a href="index.php?text_id=4">Magic and Happiness by Giorgio Agamben</a></li>
165<li><a href="index.php?text_id=8">Alice in Wonderland by Lewis Carroll</a></li>
166<li><a href="index.php?text_id=702">Julian Assange address in London 2012</a></li>
167<li><a href="index.php?text_id=429">Pussy Riot last court statement</a></li>
168</ul>
169</li>
170<li><a href="http://noduslabs.com/cases/textexture-non-linear-reading-machine/" target="_blank">methodology</a>
171<ul class='children'>
172<li><a href="http://noduslabs.com/cases/textexture-non-linear-reading-machine/" rel="nofollow" target="_blank">Basic Introduction to Textexture</a></li>
173<li><a href="http://noduslabs.com/research/pathways-meaning-circulation-text-network-analysis/" rel="nofollow" target="_blank">Text Network Analysis Paper</a></li>
174<li><a href="http://scholar.google.com/scholar?q=paranyushkin+text+network+analysis" rel="nofollow" target="_blank">Other Papers on Text Network Analysis</a></li>
175</ul>
176</li>
177<li><a href="http://noduslabs.com/services/text-network-analysis/" rel="nofollow" target="_blank">our services</a>
178<ul class='children'>
179<li><a href="http://infranodus.com/" rel="nofollow" target="_blank">Large Text Corpus Processing</a></li>
180<li><a rel="nofollow" href="http://noduslabs.com/cases/polysingularity-network-prints/" target="_blank">High Resolution Prints</a></li>
181</ul>
182</li>
183<li><a href="index.php?text_id=3">contacts</a>
184<ul class='children'>
185<li><a href="index.php?text_id=3" target="_blank">Contact Details</a></li>
186<li><a href="http://noduslabs.com/about/" rel="nofollow" target="_blank">Nodus Labs</a></li>
187</ul>
188</li>
189<li><a href="http://textatlas.tumblr.com" rel="nofollow" target="_blank">tumblr</a>
190<ul class='children'>
191<li><a href="http://textatlas.tumblr.com" rel="nofollow" target="_blank">Text Atlas</a></li>
192<li><a href="http://polysingularity.com" rel="nofollow" target="_blank">Polysingularity</a></li>
193</ul>
194</li>
195</ul></div>
196</nav>
197
198<div id="teaser">visualize any text as a network</div>
199
200</div>
201
202    
203<div id="content">
204
205<div class="source">
206
207
208
209
210<div class="text">
211<div class="caption">&nbsp;<br/>	
212<strong>If you would like to visualize a text as a network graph, please, use our new open source InfraNodus text network visualization tool. If you need to work with video using AI then you should definitely try <a href="https://www.aivideocut.com/free-ai-youtube-shorts-creator" target="_blank">YouTube Shorts Maker</a>.<br/><br>
213Textexture is outdated and is not supported any longer. Our new text visualization tool InfraNodus supports English, Russian, German, French and has advanced import, export, sharing, and filtering features:
214www.infranodus.com
215<br>&nbsp;<br>
216</strong>
217</div><br>&nbsp;<br>&nbsp;<br>
218
219				<div id="switcher-panel"></div>
220
221
222        
223               
224        
225        
226		
227		
228
229
230<div></br>
231
232
233</div>
234<div id="ioshelp" style="display: none">&nbsp;<br>
235 <ol>
236		            <li>Open this page from your iPad or iPhone.</li>
237		            <li>Click the action button (Square with Arrow on it) on your iPad / iPhone and choose "Add Bookmark".</li>
238		            <li>Edit the Title of the bookmark to say "Textexture" (or whatever you like).</li>
239		            <li>Save the bookmark</li>
240		            <li>Copy the code below. (Hold your finger down on it until the copy paste handles pop up, then select it all and copy it).
241
242                        <div style="width:350px;overflow:auto"><pre>javascript:var s='';s=document.getSelection().toString();if(s!=''){function postData(g,a,e){var h=document.createElement('iframe'),d=(+((''+Math.random()).substring(2))).toString(36);h.setAttribute('name',d);h.setAttribute('id',d);h.setAttribute('style','width:0;height:0;border:none;margin:none;padding:none;position:absolute;');document.body.appendChild(h);var c=window.frames[d],i=c.document,b=i.createElement('form'),j=i.createElement('textarea');j.setAttribute('name','text');j.appendChild(i.createTextNode(g));b.setAttribute('action',a);b.setAttribute('method','post');b.setAttribute('target','_blank');b.appendChild(j);i.body.appendChild(b);if(e){document.getElementById(d).onload=e}i.forms[0].submit()};postData(s,'http://textexture.com/')}else{void(window.open('http://textexture.com/?url='+encodeURIComponent(location.href)))}</pre></div>
243
244		            </li>
245		            <li>Open your bookmarks (tap the book symbol).</li>
246		            <li>Edit your bookmarks (tap the edit button).</li>
247		            <li>Choose the "Textexture" bookmark you just created.</li>
248		            <li>Click on the URL and delete it.</li>
249		            <li>Paste the code you copied in the earlier step (tap and hold your finger in the empty field until the Paste option a
249ppears).</li>
250		            <li>Return to the bookmarks, tap "Done" and you're finished.</li>
251		            <li>To use it, when you're on the page or youtube video you'd like to visualize as a network, open the Bookmarks folder (tap the book symbol) and tap the "Textexture" bookmark. You'll be able to edit any notes and save the link straight into Delicious.</li>
252	            </ol>
253</div>   
254
255<div class="caption">	
256&nbsp;<br>&nbsp;<br>
257See some examples of text network visualizations:<br />
258</div>
259<div class="samples"><a href="index.php?text_id=603"><img src="templates/thumbs/bible-genesis.jpg" vspace="3" width="200" height="150" border="0" /><br />
260  Bible, Genesis 1:1</a></div>
261                
262 <div class="samples"><a href="index.php?text_id=605"><img src="templates/thumbs/rancier-emancipated-spectator.jpg" vspace="3" width="200" height="150" border="0" /><br />
263  Emancipated Spectator by Jacques Rancier</a></div>
264
265<div class="samples"><a href="index.php?text_id=711"><img src="templates/thumbs/nabokov-lolita.jpg" width="200" vspace="3" height="150" border="0" /><br />
266  Lolita, chapter 1 by Vladimir Nabokov</a></div>
267  
268<div class="samples"><a href="index.php?text_id=702"><img src="templates/thumbs/julian-assange-ecuador-address.jpg" vspace="3" width="200" height="150" border="0" /><br />
269  Julian Assange address in London 2012</a></div>
270  
271  <div class="caption">
272                        <br>&nbsp;<br>
273                   </div>            
274
275
276</div>
277
278
279       
280</div>
281
282    
283
284<div class="graph">
285
286<nav class="folders">
287<div class="folder"><ul id="menu-main-menu"><li class="current_page_item"><a href="index.php?text_id=1&node_id=0">visual summary</a></li>
288<li><a href="index.php?text_id=1&node_id=0&view=polysingularity">polysingularity</a></li>
289</ul></div>
290</nav>
291
292
293<div class="span12 sigma-parent" id="sigma-example-parent">
294 	<div class="sigma-expand" id="sigma-example">
295            <div id="history"><div id="pins"></div><div id="save"></div></div>
296<div id="graphhelp" style="display: none">
297This is a graph of your text "Textextroduction". The colors designate distinct communities of words within this text that appear more often next to each other (clusters of meaning circulation). The bigger the node, the more different clusters of meaning it connects.<br /><br />
298<b>MOVE</b> &rarr; <br>click on the black space and drag<br/><br/>
299<b>ZOOM</b> &rarr; <br>scroll or swipe over the trackpad <br/><br/>
300<b>WORD'S CLUSTER</b> &rarr; <br>hover the cursor over the word node<br/><br/>
301<b>TO FIND WORD IN TEXT</b> &rarr; <br>click on the node<br/><br/>
302
303
304<br/>
305
306&nbsp;<br></div>            
307    
308            
309
310<div id="graphcontrol"><a id="displayText" href="javascript:toggle();">How to Use?</a>&nbsp;&nbsp;|&nbsp;&nbsp<a href="http://textexture.com/index.php?text_id=1&embed=1&fullscreen=1" rel="nofollow" target="_blank">Full Screen</a></div>
311</div>
312</div>
313    <br>&nbsp;</br>
314
315    
316    
317        
318
319      <div>
320    
321    <button id="stop-layout">Improve Layout</button>
322    
323    <button id="rescale-graph">Center Graph</button>
324    
325    <button id="reset-filters">Reset Filters</button>
326    
327  </div>
328    <br>&nbsp;<br>
329<div class='caption'><strong>NOTICE: Please, use our new open source <a href="https://infranodus.com" rel="nofollow">text network visualization and analysis tool InfraNodus</a>. Textexture is no longer supported.</strong>  <br>&nbsp;<br>&nbsp; </div>
330
331    <div>Nodes (Words): 17, Edges (Co-Occurrences): 51. Download <a href="files/gexf/processed/processed-1.gexf" target="_blank">processed GEXF file</a>.
332         &nbsp;
333    <br/>
334    </div>
335    
336    
337   
338    
339    
340    
341  </div>
342
343
344</div>
345<div id="footer">&nbsp;<br>
346
347
348&nbsp;<br>
3492012 &copy; Made by&nbsp;Nodus Labs, using open-source Gephi, sigma.js, and phpmorphy &nbsp;&nbsp;&nbsp;&nbsp;|&nbsp;&nbsp;&nbsp;&nbsp;<a href="http://github.com/deemeetree" rel="nofollow" target="_blank">git</a><br>
350Provided "as is" without warranty or liability of any kind, Textexture is still in its early beta.<br>
351<br>&nbsp;<br>
352<br>&nbsp;<br>/Total script running time: 0.0013811588287354        
353       
353<script type="text/javascript">
354
355  var _gaq = _gaq || [];
356  _gaq.push(['_setAccount', 'UA-27849174-5']);
357  _gaq.push(['_setDomainName', 'textexture.com']);
358  _gaq.push(['_setAllowLinker', true]);
359  _gaq.push(['_trackPageview']);
360
361  (function() {
362    var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
363    ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
364    var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
365  })();
366
367</script>
367
368
369<script type="text/javascript">
370    window._tpm = window._tpm || [];
371    window._tpm['paywallID'] = '90930708';
372    window._tpm['trackPageview'] = true;
373</script>
373
374
375
376</div>
377
378&nbsp;<br>
379  
380<script type="text/javascript">function init() {
381
382
383
384  /**
385   * This is the code to write the FishEye plugin :
386   */
387  
388  (function(){
389 
390    // First, let's write a FishEye class.
391    // There is no need to make this class global, since it is made to be used through
392    // the SigmaPublic object, that's why a local scope is used for the declaration.
393    // The parameter 'sig' represents a Sigma instance.
394    var FishEye = function(sig) { 
395      sigma.classes.Cascade.call(this);      // The Cascade class manages the chainable property
396                                             // edit/get function.
397 
398      var self = this;                       // Used to avoid any scope confusion.
399      var isActivated = false;               // Describes is the FishEye is activated.
400      
401      
402 
403      this.p = {                             // The object containing the properties accessible with
404        radius: 200,                         // the Cascade.config() method.
405        power: 2
406      };
407 
408      function applyFishEye(mouseX, mouseY) {   // This method will apply a formula relatively to
409                                                // the mouse position.
410        var newDist, newSize, xDist, yDist, dist,
411            radius   = self.p.radius,
412            power    = self.p.power,
413            powerExp = Math.exp(power);
414 
415        sig.graph.nodes.forEach(function(node) {
416          xDist = node.displayX - mouseX;
417          yDist = node.displayY - mouseY;
418          dist  = Math.sqrt(xDist*xDist + yDist*yDist);
419 
420          if(dist < radius){
421            newDist = powerExp/(powerExp-1)*radius*(1-Math.exp(-dist/radius*power));
422            newSize = powerExp/(powerExp-1)*radius*(1-Math.exp(-dist/radius*power));
423 
424            if(!node.isFixed){
425              node.displayX = mouseX + xDist*(newDist/dist*3/4 + 1/4);
426              node.displayY = mouseY + yDist*(newDist/dist*3/4 + 1/4);
427            }
428 
429            node.displaySize = Math.min(node.displaySize*newSize/dist,10*node.displaySize);
430          }
431        });
432      };
433 
434      // The method that will be triggered when Sigma's 'graphscaled' is dispatched.
435      function handler() {
436        applyFishEye(
437          sig.mousecaptor.mouseX,
438          sig.mousecaptor.mouseY
439        );
440      }
441 
442      this.handler = handler;
443 
444      // A public method to set/get the isActivated parameter.
445      this.activated = function(v) {
446        if(v==undefined){
447          return isActivated;
448        }else{
449          isActivated = v;
450          return this;
451        }
452      };
453 
454      // this.refresh() is just a helper to draw the graph.
455      this.refresh = function(){
456        sig.draw(2,2,2);
457      };
458    };
459 
460    // Then, let's add some public method to sigma.js instances :
461    sigma.publicPrototype.activateFishEye = function() {
462      if(!this.fisheye) {
463        var sigmaInstance = this;
464        var fe = new FishEye(sigmaInstance._core);
465        sigmaInstance.fisheye = fe;
466      }
467 
468      if(!this.fisheye.activated()){
469        this.fisheye.activated(true);
470        this._core.bind('graphscaled', this.fisheye.handler);
471        document.getElementById(
472          'sigma_mouse_'+this.getID()
473        ).addEventListener('mousemove',this.fisheye.refresh,true);
474      }
475 
476      return this;
477    };
478 
479    sigma.publicPrototype.desactivateFishEye = function() {
480      if(this.fisheye && this.fisheye.activated()){
481        this.fisheye.activated(false);
482        this._core.unbind('graphscaled', this.fisheye.handler);
483        document.getElementById(
484          'sigma_mouse_'+this.getID()
485        ).removeEventListener('mousemove',this.fisheye.refresh,true);
486      }
487 
488      return this;
489    };
490 
491    sigma.publicPrototype.fishEyeProperties = function(a1, a2) {
492      var res = this.fisheye.config(a1, a2);
493      return res == s ? this.fisheye : res;
494    };
495  })();
496
497
498  // Instanciate sigma.js and customize rendering :
499  var sigInst = sigma.init(document.getElementById('sigma-example')).drawingProperties({
500    defaultLabelColor: '#fff',
501    defaultLabelSize: 30,
502    defaultLabelBGColor: '#fff',
503    defaultLabelHoverColor: '#000',
504    labelThreshold: 4,
505    defaultEdgeType: 'curve'
506  }).graphProperties({
507    minNodeSize: 2,
508    maxNodeSize: 15,
509    minEdgeSize: 2,
510    maxEdgeSize: 4  }).mouseProperties({
511    maxRatio: 4
512  });
513  
514  
515  
516
517  // Parse a GEXF encoded file to fill the graph
518  // (requires "sigma.parseGexf.js" to be included)
519  sigInst.parseGexf('files/gexf/processed/processed-1.gexf');
520
521  
522
523
524  
525  
526  sigInst.startForceAtlas2();
527  
528  setTimeout(function() {
529      
530      sigInst.stopForceAtlas2();
531      
532   
533  
534},5000);
535  
536
537      var isVisible = true;
538      
539        var top_nodes = new Array();
540    
541    var top_modularity_nodes = new Array();
542    
543     var oldPin;
544     
545      var com_active = new Array();
546      var active_communities = 0;
547      var visible_nodes = new Array();
548    
549     
550       
551    top_modularity_nodes[0] = new Array(4);
552   top_modularity_nodes[0][0] = parseInt('4');
553
554      top_modularity_nodes[0][1] = parseInt('7');
555
556      top_modularity_nodes[0][2] = parseInt('6');
557
558      top_modularity_nodes[0][3] = parseInt('8');
559
560    
561    top_modularity_nodes[1] = new Array(4);
562   top_modularity_nodes[1][0] = parseInt('15');
563
564      top_modularity_nodes[1][1] = parseInt('13');
565
566      top_modularity_nodes[1][2] = parseInt('12');
567
568      top_modularity_nodes[1][3] = parseInt('11');
569
570    
571    top_modularity_nodes[2] = new Array(4);
572   top_modularity_nodes[2][0] = parseInt('3');
573
574      top_modularity_nodes[2][1] = parseInt('2');
575
576      top_modularity_nodes[2][2] = parseInt('1');
577
578      
579   
580  
581     
582     
583      top_nodes[0] = parseInt('4');
584      top_nodes[1] = parseInt('15');
585      top_nodes[2] = parseInt('13');
586      top_nodes[3] = parseInt('7');
587         
588
589$(".top_modularity").click(function () { 
590
591
592  
593
594  
595   var community = $(this).attr('idcode');
596   
597    com_active[community] = $(this).attr('active');
598    
599   
600    if (com_active[community] == 1) {
601      
602      active_communities -= 1;
603      
604      if (active_communities == 0) {
605          
606          sigInst.iterNodes(function(n){
607          
608           n.hidden = 0;
609           
610        }).draw(2,2,2);
611      }
612      
613      else {
614      sigInst.iterNodes(function(n){
615          
616            if ($.inArray(parseInt(n.id),top_modularity_nodes[community]) > -1) {
617                n.hidden = 1;
618                var index_visible = visible_nodes.indexOf(parseInt(n.id));
619                visible_nodes.splice(index_visible,1);
620            }
621            else {
622                if ($.inArray(parseInt(n.id),visible_nodes) <= -1) {
623               
624                n.hidden = 1;
625               
626                }
627                
628                
629            }
630        }).draw(2,2,2);
631     }    
632        $(this).attr('active',0);
633        $(this).text('off');
634        com_active[community] = 0;
635        
636       
637    }
638    else {
639        
640        
641       
642          
643           sigInst.iterNodes(function(n){
644     
645         
646           if ($.inArray(parseInt(n.id),top_modularity_nodes[community]) > -1) {
647               
648                n.hidden = 0;
649                visible_nodes.push(parseInt(n.id));
650                
651               
652                
653           }else{
654            
655                if ($.inArray(parseInt(n.id),visible_nodes) <= -1) {
656                
657                   n.hidden = 1; 
658                }
659            }
660                
661
662      
663    }).draw(2,2,2);
664           
665     
666       $(this).text('on');
667       $(this).attr('active',1);
668       com_active[community] = 1;
669       active_communities += 1;
670          
671       
672     }   
673   
674
675    return true;
676
677  
678}  );
679  
680  // Bind events :
681  sigInst.bind('overnodes',function(event){
682    var nodes = event.content;
683    var neighbors = {};
684    
685 
686   
687    
688    
689    sigInst.iterEdges(function(e){
690       
691      if(nodes.indexOf(e.source)>=0 || nodes.indexOf(e.target)>=0){
692        neighbors[e.source] = 1;
693        neighbors[e.target] = 1;
694       
695      }
696    }).iterNodes(function(n){
697      if(!neighbors[n.id]){
698        n.hidden = 1;
699      }else{
700        n.hidden = 0;
701      }
702    }).draw(2,2,2);
703  }).bind('outnodes',function(event){
704  
705   var nodes = event.content;
706  
707  if (isVisible && !isPinned) {
708  
709   if (active_communities > 0) {
710   sigInst.iterNodes(function(n){
711     
712      if($.inArray(parseInt(n.id),visible_nodes) > -1){
713        
714        n.hidden = 0;
715      }else{
716        
717        n.hidden = 1;
718      }
719    }).draw(2,2,2);
720   }
721   else {
722       sigInst.iterEdges(function(e){
723      e.hidden = 0;
724    }).iterNodes(function(n){
725      n.hidden = 0;
726    }).draw(2,2,2);
727   }
728      
729  } 
730  
731  
732  else if (!isVisible && !isPinned) {
733   sigInst.iterNodes(function(n){
734     
735      if($.inArray(parseInt(n.id),top_nodes) > -1){
736        
737        n.hidden = 0;
738      }else{
739        
740        n.hidden = 1;
741      }
742    }).draw(2,2,2);
743    
744  
745  } else if (nodes != oldPin) {
746        
747    
748       var neighbors = {};
749       
750       sigInst.iterEdges(function(e){
751       
752      if(oldPin.indexOf(e.source)>=0 || oldPin.indexOf(e.target)>=0){
753        neighbors[e.source] = 1;
754        neighbors[e.target] = 1;
755       
756      }
757    }).iterNodes(function(n){
758      if(!neighbors[n.id]){
759        n.hidden = 1;
760      }else{
761        n.hidden = 0;
762      }
763    }).draw(2,2,2);
764      
765  }
766 
767  
768 
769  
770  
771  });
772   
773  
774
775	// Mod Dmitry
776        var derived_id = 0;
777	var isPinned = false;
778        var text_raw = '';
779        var filter_nodes = '';
780        var is_derived = '';
781        var pinned_html_1 = '';
782        var virgin = 1;
783       
784	sigInst.bind('downnodes',function(event){
785        
786        
787           function filterText(text_id) {
788  
789
790    params = "?text_id=" + text_id + "&node_id=" + newPin;
791    request = new ajaxRequest()
792    request.overrideMimeType('text/xml')
793    request.open("GET","_aux/checktext.php" + params, true)
794    
795
796    
797request.onreadystatechange = function () {
798
799
800if (this.readyState == 4)
801    {
802        if (this.status == 200)
803        {
804            if (this.responseXML != null) {
805                
806                xmlDoc=this.responseXML;
807           
808                txt="";
809                xc=xmlDoc.getElementsByTagName("content");
810                text_raw = txt + xc[0].childNodes[0].nodeValue;
811               
812                
813                derived_id="";
814                yc=xmlDoc.getElementsByTagName("id");
815                derived_id = derived_id + yc[0].childNodes[0].nodeValue;
816                
817                
818                document.getElementById('textdisplay').innerHTML = text_raw;
819                
820                
821                
822                var texturl = ''
823
824                if (texturl.indexOf("youtube")!=-1) {
825
826
827                     var xfiles = document.getElementById('textdisplay').innerHTML.replace(/\[([^\]]*)\]/g, '<div class="timecode" contentEditable="false"><a href="&t=$1" target="_blank">['+ '$1]</a>&nbsp;</div>')
828    
829                     document.getElementById('textdisplay').innerHTML = xfiles
830
831
832
833                }
834                
835                
836                
837                // Mod - highlight text
838    var node;
839    sigInst.iterNodes(function(n){
840        node = n;
841      	},[event.content[0]]);
842    
843 
844    filter_nodes += ' '+node['label'];
845	
846    document.getElementById('search_form').value = filter_nodes; 
847    
848    var filter_nodes_array = new Array ();
849    filter_nodes_array = filter_nodes.split(" ");
850    
851 
852    
853    for (zcc in filter_nodes_array) {
854           
855            if (filter_nodes_array[zcc]) {
856            $('#textdisplay').highlight(filter_nodes_array[zcc]);
857            }
858
859    }
860    
861    if (filter_nodes && virgin == 1) {
862         document.getElementById('pins').innerHTML += 'reading path: &nbsp;'; 
863    }
864    document.getElementById('pins').innerHTML += node['label'] + " > ";
865    virgin = 0;
866    
867    document.getElementById('save').innerHTML = '&nbsp; <a href="index.php?text_id=' + derived_id + '">(save)</a>';
868    
869    
870    // Mod - highlight respective text
871                
872            }
873            
874            else alert("Ajax error: No data received")
875
876        }
877        else alert("Ajax error: " + this.statusText)
878        
879
880    }
881
882
883}
884request.send()
885document.getElementById('textdisplay').innerHTML = 'Loading text excerpts...<br><br><img src="templates/progress.gif" border=0>';
886
887}
888
889
890 
891    
892    
893
894function ajaxRequest() 
895
896{
897    try 
898    {
899        var request = new XMLHttpRequest()
900
901    }
902    catch(e1)
903    {
904        try
905        {
906            request = new ActiveXObject("Msxml2.XMLHTTP")
907        }
908        catch(e2)
909        {
910            try
911            {
912                request = new ActiveXObject("Microsoft.XMLHTTP")
913            }
914            catch(e3)
915            {
916                request = false
917            }
918        }
919    }
920    return request
921
922} 
923        
924        
925           var newPin = event.content;
926           if ((isPinned) && (newPin == oldPin)) {
927               isPinned = false;
928           } else {
929               isPinned = true;
930               oldPin = newPin;
931             
932             if (derived_id > 0) {
933                filterText(derived_id);  
934                 
935             } else {
936             filterText(1);
937            
938             }
939         
940             
941             
942             
943             
944           }  
945	});
946
947// Mod Dmitry
948
949  // Draw the graph :
950//  sigInst.draw();
951 
952 
953 
954var pinned_html = '<a href="index.php?text_id=1">original text</a> &nbsp;';
955document.getElementById('pins').innerHTML = pinned_html; 
956  
957if (is_derived) {
958    var filter_derived = new Array();
959    filter_derived = "".split(', ');
960    
961    var pinned_html_1 = '<a href="index.php?text_id=">original text</a> &nbsp;>&nbsp; ';
962    document.getElementById('pins').innerHTML = pinned_html_1;
963    
964    for (zcc in filter_derived) {
965           
966            if (filter_derived[zcc]) {
967            $('#textdisplay').highlight(filter_derived[zcc]);
968            document.getElementById('pins').innerHTML += filter_derived[zcc] + " > ";
969            }
970
971    }
972
973  /* sigInst.iterNodes(function(n){
974    
975    if(parseInt(n.id) == '0'){
976        
977        n.hidden = 0;
978        
979        
980      }else{
981        
982        n.hidden = 1;
983      }
984    }).draw(2,2,2);*/
985    
986    
987}  
988
989
990
991 sigInst.activateFishEye().draw();
992  
993   
994  var isRunning = false;
995    
996  document.getElementById('stop-layout').addEventListener('click',function(){
997    if(isRunning){
998      isRunning = false;
999      sigInst.stopForceAtlas2();
1000      document.getElementById('stop-layout').childNodes[0].nodeValue = 'Start Layout';
1001    }else{
1002      isRunning = true;
1003      sigInst.startForceAtlas2();
1004      document.getElementById('stop-layout').childNodes[0].nodeValue = 'Stop Layout';
1005    }
1006  },true);
1007  document.getElementById('rescale-graph').addEventListener('click',function(){
1008    sigInst.position(0,0,1).draw();
1009  },true);
1010  document.getElementById('reset-filters').addEventListener('click',function(){
1011     
1012     sigInst.iterNodes(function(n){
1013          
1014           n.hidden = 0;
1015           
1016        }).draw(2,2,2);  
1017      
1018      
1019    active_communities = 0;
1020    isVisible = true;
1021    isPinned = false;
1022    visible_nodes = new Array();
1023    $(".top_modularity").attr('active',0);
1024    $(".top_modularity").text('off');
1025    document.getElementById('top_nodes').innerHTML = "off";
1026    
1027    
1028  },true);
1029
1030
1031}
1032
1033if (document.addEventListener) {
1034  document.addEventListener("DOMContentLoaded", init, false);
1035} else {
1036  window.onload = init;
1037}
1038
1039var node_label = '';
1040
1041if (node_label != '') {
1042$('#textdisplay').highlight('');
1043document.getElementById('search_form').value += ' '+node_label; 
1044}
1045
1046
1047var texturl = ''
1048
1049if (texturl.indexOf("youtube")!=-1) {
1050
1051
1052    var xfiles = document.getElementById('textdisplay').innerHTML.replace(/\[([^\]]*)\]/g, '<div class="timecode" contentEditable="false"><a href="&t=$1" target="_blank">['+ '$1]</a>&nbsp;</div>')
1053    
1054    document.getElementById('textdisplay').innerHTML = xfiles
1055
1056
1057
1058}
1059
1060
1061
1062
1063</script>
1063
1064
1065
1066
1067
1068</div>
1069</body>
1070</html>

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.