Welcome to TiddlyWiki created by Jeremy Ruston, Copyright © 2007 UnaMesa Association
This website is a derivative work based on:
* http://tiddlywiki.com
* http://TiddlyWiki.bidix.info
* http://tiddlytools.com
I had never worked on CSS, Javascript before this web site so please be tolerant to any loose ends and do drop me an email if you find a bug(or a typo or just a grammatical mistake).
{{justifyfull{
This website began as an exploratory project into the tiddly world when I was introduced to it at an [[SVLUG|http://www.svlug.org/]] installfest. I have always been handicapped when it comes to frontend/GUI development and prospect of an all javascript website sounded alot more interesting than spending hours on dreamweaver/quanta/bluefish/frontpage etc etc just to get the "right" look, only to find a crash on some browser a month later. Tweaking a few ''if'' and ''for'' statements was all I needed to get the right look (and some occasional ''div'' tweaks).
}}}
The floating head on the right was generated using [[inkscape|http://www.inkscape.org/]] on a self-portrait.
{{justifyfull{
The RSS feed is actually a union of feeds from [[del.icio.us|http://del.icio.us/public/sridharv]], [[my blog|http://codeyman.blogspot.com]] and [[flickr|http://flickr.com/photos/sridhar]]. I used [[Yahoo Pipes|http://pipes.yahoo.com/pipes/person.info?eyuid=6xujP5cgumoGQaAAh_Gn98LwRx1t]] to do all the dirty work, which involved fixing titles & snipping extra items off. Later this was passed through [[feedburner|http://www.feedburner.com]] to clean it up a bit and add few fancy footers.
}}}
!!License:
<html>
<a rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/us/">
<img alt="Creative Commons License" style="border-width:0" src="http://creativecommons.org/images/public/somerights20.png" />
</a>
This work is licensed under a
<a rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/us/">Creative Commons Attribution-Share Alike 3.0 United States License</a></html>
/%
|Name|AnimationEffectsSample|
|Source|http://www.TiddlyTools.com/#AnimationEffectsSample|
|Version|1.1.0|
|Author|Eric Shulman - ELS Design Studios|
|License|http://www.TiddlyTools.com/#LegalStatements <br>and [[Creative Commons Attribution-ShareAlike 2.5 License|http://creativecommons.org/licenses/by-sa/2.5/]]|
|~CoreVersion|2.1|
|Type|script|
|Requires|AnimationEffectsPlugin, StyleSheetShortcuts|
|Optional|InlineJavascriptPlugin, HideTiddlerTags, HideTiddlerBackground, HideTiddlerSubtitle, CloseOtherTiddlers, RefreshTiddler, ReplaceTiddlerTitle, TextAreaPlugin|
|Overrides||
|Description|demonstrates techniques for animating wiki-formatted content|
SET SPEED MULTIPLIER (global variable) [0:00]
%/<<tiddler {{
window.sec=config.options.txtAnimationEffectsRate||1000; // global abbreviation/default multiplier
config.options.txtAnimationEffectsRate=window.sec; // user option value initialization
""; // return blank tiddlername so macro doesn't produce output
}}>>/%
%/{{floatleft bold italic{/%
%/<<animate "H" fontSize %0% 100 400 {{0*sec}} {{.5*sec}} 2>>/%
%/<<animate "e" fontSize %0% 90 350 {{.5*sec}} {{.5*sec}} 2>>/%
%/<<animate "l" fontSize %0% 90 300 {{1*sec}} {{.5*sec}} 2>>/%
%/<<animate "l" fontSize %0% 90 300 {{1.5*sec}} {{.5*sec}} 2>>/%
%/<<animate "o" fontSize %0% 90 300 {{2*sec}} {{.5*sec}} 2>>/%
%/}}}/%
Recent feeds from my [[blog|http://codeyman.blogspot.com]]
<script>
if (document.location.protocol=="http:")
return "<<rssReader asHtml proxy.php?url=http://feedproxy.feedburner.com/codeyman>>"
else
return "<<rssReader asHtml http://feedproxy.feedburner.com/codeyman>>"
</script>
<html><div align="center">
<iframe src="http://www.google.com/calendar/embed?showTitle=0&mode=WEEK&height=600&wkst=1&bgcolor=%23EEFFFF&src=lp0vf1mhl6lm9nhon1sg2presg%40group.calendar.google.com&color=%23A32929&ctz=America%2FLos_Angeles" style=" border-width:0 " width="99%" height="600" frameborder="0" scrolling="no"></iframe>
</div></html>
/***
|''Name:''|CryptoFunctionsPlugin|
|''Description:''|Support for cryptographic functions|
***/
//{{{
if(!version.extensions.CryptoFunctionsPlugin) {
version.extensions.CryptoFunctionsPlugin = {installed:true};
//--
//-- Crypto functions and associated conversion routines
//--
// Crypto "namespace"
function Crypto() {}
// Convert a string to an array of big-endian 32-bit words
Crypto.strToBe32s = function(str)
{
var be = Array();
var len = Math.floor(str.length/4);
var i, j;
for(i=0, j=0; i<len; i++, j+=4) {
be[i] = ((str.charCodeAt(j)&0xff) << 24)|((str.charCodeAt(j+1)&0xff) << 16)|((str.charCodeAt(j+2)&0xff) << 8)|(str.charCodeAt(j+3)&0xff);
}
while (j<str.length) {
be[j>>2] |= (str.charCodeAt(j)&0xff)<<(24-(j*8)%32);
j++;
}
return be;
};
// Convert an array of big-endian 32-bit words to a string
Crypto.be32sToStr = function(be)
{
var str = "";
for(var i=0;i<be.length*32;i+=8)
str += String.fromCharCode((be[i>>5]>>>(24-i%32)) & 0xff);
return str;
};
// Convert an array of big-endian 32-bit words to a hex string
Crypto.be32sToHex = function(be)
{
var hex = "0123456789ABCDEF";
var str = "";
for(var i=0;i<be.length*4;i++)
str += hex.charAt((be[i>>2]>>((3-i%4)*8+4))&0xF) + hex.charAt((be[i>>2]>>((3-i%4)*8))&0xF);
return str;
};
// Return, in hex, the SHA-1 hash of a string
Crypto.hexSha1Str = function(str)
{
return Crypto.be32sToHex(Crypto.sha1Str(str));
};
// Return the SHA-1 hash of a string
Crypto.sha1Str = function(str)
{
return Crypto.sha1(Crypto.strToBe32s(str),str.length);
};
// Calculate the SHA-1 hash of an array of blen bytes of big-endian 32-bit words
Crypto.sha1 = function(x,blen)
{
// Add 32-bit integers, wrapping at 32 bits
add32 = function(a,b)
{
var lsw = (a&0xFFFF)+(b&0xFFFF);
var msw = (a>>16)+(b>>16)+(lsw>>16);
return (msw<<16)|(lsw&0xFFFF);
};
// Add five 32-bit integers, wrapping at 32 bits
add32x5 = function(a,b,c,d,e)
{
var lsw = (a&0xFFFF)+(b&0xFFFF)+(c&0xFFFF)+(d&0xFFFF)+(e&0xFFFF);
var msw = (a>>16)+(b>>16)+(c>>16)+(d>>16)+(e>>16)+(lsw>>16);
return (msw<<16)|(lsw&0xFFFF);
};
// Bitwise rotate left a 32-bit integer by 1 bit
rol32 = function(n)
{
return (n>>>31)|(n<<1);
};
var len = blen*8;
// Append padding so length in bits is 448 mod 512
x[len>>5] |= 0x80 << (24-len%32);
// Append length
x[((len+64>>9)<<4)+15] = len;
var w = Array(80);
var k1 = 0x5A827999;
var k2 = 0x6ED9EBA1;
var k3 = 0x8F1BBCDC;
var k4 = 0xCA62C1D6;
var h0 = 0x67452301;
var h1 = 0xEFCDAB89;
var h2 = 0x98BADCFE;
var h3 = 0x10325476;
var h4 = 0xC3D2E1F0;
for(var i=0;i<x.length;i+=16) {
var j,t;
var a = h0;
var b = h1;
var c = h2;
var d = h3;
var e = h4;
for(j = 0;j<16;j++) {
w[j] = x[i+j];
t = add32x5(e,(a>>>27)|(a<<5),d^(b&(c^d)),w[j],k1);
e=d; d=c; c=(b>>>2)|(b<<30); b=a; a = t;
}
for(j=16;j<20;j++) {
w[j] = rol32(w[j-3]^w[j-8]^w[j-14]^w[j-16]);
t = add32x5(e,(a>>>27)|(a<<5),d^(b&(c^d)),w[j],k1);
e=d; d=c; c=(b>>>2)|(b<<30); b=a; a = t;
}
for(j=20;j<40;j++) {
w[j] = rol32(w[j-3]^w[j-8]^w[j-14]^w[j-16]);
t = add32x5(e,(a>>>27)|(a<<5),b^c^d,w[j],k2);
e=d; d=c; c=(b>>>2)|(b<<30); b=a; a = t;
}
for(j=40;j<60;j++) {
w[j] = rol32(w[j-3]^w[j-8]^w[j-14]^w[j-16]);
t = add32x5(e,(a>>>27)|(a<<5),(b&c)|(d&(b|c)),w[j],k3);
e=d; d=c; c=(b>>>2)|(b<<30); b=a; a = t;
}
for(j=60;j<80;j++) {
w[j] = rol32(w[j-3]^w[j-8]^w[j-14]^w[j-16]);
t = add32x5(e,(a>>>27)|(a<<5),b^c^d,w[j],k4);
e=d; d=c; c=(b>>>2)|(b<<30); b=a; a = t;
}
h0 = add32(h0,a);
h1 = add32(h1,b);
h2 = add32(h2,c);
h3 = add32(h3,d);
h4 = add32(h4,e);
}
return Array(h0,h1,h2,h3,h4);
};
}
//}}}
/***
|''Name:''|DeprecatedFunctionsPlugin|
|''Description:''|Support for deprecated functions removed from core|
***/
//{{{
if(!version.extensions.DeprecatedFunctionsPlugin) {
version.extensions.DeprecatedFunctionsPlugin = {installed:true};
//--
//-- Deprecated code
//--
// @Deprecated: Use createElementAndWikify and this.termRegExp instead
config.formatterHelpers.charFormatHelper = function(w)
{
w.subWikify(createTiddlyElement(w.output,this.element),this.terminator);
};
// @Deprecated: Use enclosedTextHelper and this.lookaheadRegExp instead
config.formatterHelpers.monospacedByLineHelper = function(w)
{
var lookaheadRegExp = new RegExp(this.lookahead,"mg");
lookaheadRegExp.lastIndex = w.matchStart;
var lookaheadMatch = lookaheadRegExp.exec(w.source);
if(lookaheadMatch && lookaheadMatch.index == w.matchStart) {
var text = lookaheadMatch[1];
if(config.browser.isIE)
text = text.replace(/\n/g,"\r");
createTiddlyElement(w.output,"pre",null,null,text);
w.nextMatch = lookaheadRegExp.lastIndex;
}
};
// @Deprecated: Use <br> or <br /> instead of <<br>>
config.macros.br = {};
config.macros.br.handler = function(place)
{
createTiddlyElement(place,"br");
};
// Find an entry in an array. Returns the array index or null
// @Deprecated: Use indexOf instead
Array.prototype.find = function(item)
{
var i = this.indexOf(item);
return i == -1 ? null : i;
};
// Load a tiddler from an HTML DIV. The caller should make sure to later call Tiddler.changed()
// @Deprecated: Use store.getLoader().internalizeTiddler instead
Tiddler.prototype.loadFromDiv = function(divRef,title)
{
return store.getLoader().internalizeTiddler(store,this,title,divRef);
};
// Format the text for storage in an HTML DIV
// @Deprecated Use store.getSaver().externalizeTiddler instead.
Tiddler.prototype.saveToDiv = function()
{
return store.getSaver().externalizeTiddler(store,this);
};
// @Deprecated: Use store.allTiddlersAsHtml() instead
function allTiddlersAsHtml()
{
return store.allTiddlersAsHtml();
}
// @Deprecated: Use refreshPageTemplate instead
function applyPageTemplate(title)
{
refreshPageTemplate(title);
}
// @Deprecated: Use story.displayTiddlers instead
function displayTiddlers(srcElement,titles,template,unused1,unused2,animate,unused3)
{
story.displayTiddlers(srcElement,titles,template,animate);
}
// @Deprecated: Use story.displayTiddler instead
function displayTiddler(srcElement,title,template,unused1,unused2,animate,unused3)
{
story.displayTiddler(srcElement,title,template,animate);
}
// @Deprecated: Use functions on right hand side directly instead
var createTiddlerPopup = Popup.create;
var scrollToTiddlerPopup = Popup.show;
var hideTiddlerPopup = Popup.remove;
// @Deprecated: Use right hand side directly instead
var regexpBackSlashEn = new RegExp("\\\\n","mg");
var regexpBackSlash = new RegExp("\\\\","mg");
var regexpBackSlashEss = new RegExp("\\\\s","mg");
var regexpNewLine = new RegExp("\n","mg");
var regexpCarriageReturn = new RegExp("\r","mg");
}
//}}}
{{justifyfull{
Lets see if I can compress my life in a page... If I succeed in doing so then you would think that I have led a shallow life and If I don't then you will doubt my writing skills. To be on the safe side.. here's what my HR manager knows about me:
}}}
{{justifyfull{
I was born and brought up in Kanpur,India, got an undergraduate degree in engineering from SJCIT, Chickaballapur(think Bangalore), India and graduate degree in Computer & Information Science from [[Syracuse University|http://www.syr.edu]]. I am currently working as a software engineer at [[Cisco|http://www.cisco.com]].
}}}
{{justifyfull{
Technology and computers are my life, occasionally I dig into sciencific journals too. I like to think of myself as a versatile technologist.. and have my fads.. currently I'm in love with what I do, that is work on the l2 forwarding for Cisco's N5K switches. I'm also donating some of my sleep cycles to a project called Bigtop, through which I wish to research application centric switching, currently used by Google.
Have also worked in email security at [[Mailshell|http://mailshell.com]] for about 3 years and used to research computer/internet security at [[SU|http://www.cis.syr.edu/~wedu/seed/index.html]].. and long long ago before that was actually doing software modelling for simulating models for short term memory at [[Memlab|http://memory.syr.edu]].
}}}
{{justifyfull{
I enjoy blogging but hardly get any time to update my blog. I consider myself a semi-pro photographer and love landscape and still life photography.. however event photography is what pays the bill (i.e. when I need to raise money for charity). I ran and completed the [[Portland marathon|http://www.portlandmarathon.org/]] in Oct'2011 with [[Team in Training|http://pages.teamintraining.org/sj/portland11/siyerp]] and intend to run again with them in coming seasons.
}}}
/***
|Name|InlineJavascriptPlugin|
|Source|http://www.TiddlyTools.com/#InlineJavascriptPlugin|
|Documentation|http://www.TiddlyTools.com/#InlineJavascriptPluginInfo|
|Version|1.8.0|
|Author|Eric Shulman - ELS Design Studios|
|License|http://www.TiddlyTools.com/#LegalStatements <br>and [[Creative Commons Attribution-ShareAlike 2.5 License|http://creativecommons.org/licenses/by-sa/2.5/]]|
|~CoreVersion|2.1|
|Type|plugin|
|Requires||
|Overrides||
|Description|Insert Javascript executable code directly into your tiddler content.|
''Call directly into TW core utility routines, define new functions, calculate values, add dynamically-generated TiddlyWiki-formatted output'' into tiddler content, or perform any other programmatic actions each time the tiddler is rendered.
!!!!!Documentation
>see [[InlineJavascriptPluginInfo]]
!!!!!Revision History
<<<
''2008.01.08 [*.*.*]'' plugin size reduction: documentation moved to ...Info and ...History tiddlers
''2007.12.28 [1.8.0]'' added support for key="X" syntax to specify custom access key definitions
|please see [[InlineJavascriptPluginHistory]] for additional revision details|
''2005.11.08 [1.0.0]'' initial release
<<<
!!!!!Code
***/
//{{{
version.extensions.inlineJavascript= {major: 1, minor: 8, revision: 0, date: new Date(2007,12,28)};
config.formatters.push( {
name: "inlineJavascript",
match: "\\<script",
lookahead: "\\<script(?: src=\\\"((?:.|\\n)*?)\\\")?(?: label=\\\"((?:.|\\n)*?)\\\")?(?: title=\\\"((?:.|\\n)*?)\\\")?(?: key=\\\"((?:.|\\n)*?)\\\")?( show)?\\>((?:.|\\n)*?)\\</script\\>",
handler: function(w) {
var lookaheadRegExp = new RegExp(this.lookahead,"mg");
lookaheadRegExp.lastIndex = w.matchStart;
var lookaheadMatch = lookaheadRegExp.exec(w.source)
if(lookaheadMatch && lookaheadMatch.index == w.matchStart) {
var src=lookaheadMatch[1];
var label=lookaheadMatch[2];
var tip=lookaheadMatch[3];
var key=lookaheadMatch[4];
var show=lookaheadMatch[5];
var code=lookaheadMatch[6];
if (src) { // load a script library
// make script tag, set src, add to body to execute, then remove for cleanup
var script = document.createElement("script"); script.src = src;
document.body.appendChild(script); document.body.removeChild(script);
}
if (code) { // there is script code
if (show) // show inline script code in tiddler output
wikify("{{{\n"+lookaheadMatch[0]+"\n}}}\n",w.output);
if (label) { // create a link to an 'onclick' script
// add a link, define click handler, save code in link (pass 'place'), set link attributes
var link=createTiddlyElement(w.output,"a",null,"tiddlyLinkExisting",wikifyPlainText(label));
link.onclick=function(){try{return(eval(this.code))}catch(e){alert(e.description||e.toString())}}
var fixup=code.replace(/document.write\s*\(/gi,'place.innerHTML+=(');
link.code="function _out(place){"+fixup+"\n};_out(this);"
link.setAttribute("title",tip||"");
var URIcode='javascript:void(eval(decodeURIComponent(%22(function(){try{';
URIcode+=encodeURIComponent(encodeURIComponent(code.replace(/\n/g,' ')));
URIcode+='}catch(e){alert(e.description||e.toString())}})()%22)))';
link.setAttribute("href",URIcode);
link.style.cursor="pointer";
if (key) link.accessKey=key.substr(0,1); // single character only
}
else { // run inline script code
var fixup=code.replace(/document.write\s*\(/gi,'place.innerHTML+=(');
var code="function _out(place){"+fixup+"\n};_out(w.output);"
try { var out=eval(code); } catch(e) { out=e.description?e.description:e.toString(); }
if (out && out.length) wikify(out,w.output,w.highlightRegExp,w.tiddler);
}
}
w.nextMatch = lookaheadMatch.index + lookaheadMatch[0].length;
}
}
} )
//}}}
/***
|''Name:''|LegacyStrikeThroughPlugin|
|''Description:''|Support for legacy (pre 2.1) strike through formatting|
|''Version:''|1.0.2|
|''Date:''|Jul 21, 2006|
|''Source:''|http://www.tiddlywiki.com/#LegacyStrikeThroughPlugin|
|''Author:''|MartinBudden (mjbudden (at) gmail (dot) com)|
|''License:''|[[BSD open source license]]|
|''CoreVersion:''|2.1.0|
***/
//{{{
// Ensure that the LegacyStrikeThrough Plugin is only installed once.
if(!version.extensions.LegacyStrikeThroughPlugin) {
version.extensions.LegacyStrikeThroughPlugin = {installed:true};
config.formatters.push(
{
name: "legacyStrikeByChar",
match: "==",
termRegExp: /(==)/mg,
element: "strike",
handler: config.formatterHelpers.createElementAndWikify
});
} //# end of "install only once"
//}}}
Recently bookmarked links from my [[del.icio.us|http://del.icio.us/sridharv]]
<script>
if (document.location.protocol=="http:")
return "<<rssReader noDesc proxy.php?url=http://feeds.delicious.com/rss/sridharv>>"
else
return "<<rssReader noDesc http://feeds.delicious.com/rss/sridharv>>"
</script>
/***
|''Name:''|LoadRemoteFileThroughProxy (previous LoadRemoteFileHijack)|
|''Description:''|When the TiddlyWiki file is located on the web (view over http) the content of [[SiteProxy]] tiddler is added in front of the file url. If [[SiteProxy]] does not exist "/proxy/" is added. |
|''Version:''|1.1.0|
|''Date:''|mar 17, 2007|
|''Source:''|http://tiddlywiki.bidix.info/#LoadRemoteFileHijack|
|''Author:''|BidiX (BidiX (at) bidix (dot) info)|
|''License:''|[[BSD open source license|http://tiddlywiki.bidix.info/#%5B%5BBSD%20open%20source%20license%5D%5D ]]|
|''~CoreVersion:''|2.2.0|
***/
//{{{
version.extensions.LoadRemoteFileThroughProxy = {
major: 1, minor: 1, revision: 0,
date: new Date("mar 17, 2007"),
source: "http://tiddlywiki.bidix.info/#LoadRemoteFileThroughProxy"};
if (!window.bidix) window.bidix = {}; // bidix namespace
if (!bidix.core) bidix.core = {};
bidix.core.loadRemoteFile = loadRemoteFile;
loadRemoteFile = function(url,callback,params)
{
if ((document.location.toString().substr(0,4) == "http") && (url.substr(0,4) == "http")){
url = store.getTiddlerText("SiteProxy", "/proxy/") + url;
}
return bidix.core.loadRemoteFile(url,callback,params);
}
//}}}
*[[Home]]
*[[Resume]]
*[[Projects]]
*[[Blog]]
*[[Photos]]
*[[Links]]
*[[Calendar]]
*[[About]]
<!--{{{-->
<link rel='alternate' type='application/rss+xml' title='RSS' href='http://feeds.feedburner.com/sridharv'/>
<link rel='shortcut icon' href='http://sridharv.net/favicon.ico' type='image/x-icon'>
<!--}}}-->
Type the text for 'New Tiddler'
Recent pics from [[Flickr|http://www.flickr.com/photos/sridhar]]
<html>
<div align='center'>
<iframe align="center" src="http://www.flickr.com/slideShow/index.gne?
user_id=53592147@N00" frameBorder="0" "width=500" height="500" scrolling="no"></iframe></div>
</html>
*''[[This|index.html]] webpage'': This is an adaptation of [[tiddlywiki|http://www.tiddlywiki.com]]. To save this page, right click on the link and select //save link as// from the popup menu (Do not use your browser's save option). (Feb 08)
*''Patch for Real Player on Linux'': Wrote a patch to fix a bug in real player on Linux(based
on Helix player).
!!Academic Projects:
*''Compiler for PL language'':Designed a compiler for PL language for ~CIS631(Compiler Design) under Prof Per Brinch Hansen.(May 07)
*''Encrypted File System on Minix3.1.2a'':Designed and implemented an Encrypted File System on Minix3. This system was not a hacker's implementation on top of other file system but rather a completely new file system written from scratch(well.. modified version of older file systems). Everything from the inode structure to the super block was modified to give a unified and transparent feel to the end user. It proposed a new solution to solve the group access problem inherent in commercially available EFS. EFS is helpful in case of physical compromise of the storage media.(Feb 07)
*''~IPSec on Minix3.1.2a'':Designed and implemented a VPN implementation on Minix3. This involved modifying the IP layerand inserting code for encryption and decryption. Key management issues were take care. Manual key management was implemented rather than IKE. Separate keys for each communication channel was supported, i.e for a TCP connection one could use two different keys for sending and receiving.(Dec 06)
*''Attacks on TCP'':Tested transport layer protocols for vulnerability. (Oct 06)
*''ARP, IP, ICMP attacks'':Tested Minix3 and Linux 2.6.15 for various vulnerabilities.(Sep 06)
*''[[FRAMOF - FRAmework for MOdel Fitting|http://sourceforge.net/projects/framof]]'':A C based model fitting framework, designed primarily to fit cognitive models. Uses GAUL(Genetic Algorithm Utility Library) and libxml2 for xml aprsing. Currently it supports only genetic algorithm but will soon be expanded to incorporate other mathematical models too.(Sep 06)
*''Final Free Recall Modelling'':Modelling the probability of free recall for interlist and intralist data using [[TCM|http://memory.syr.edu/research.html]].(Aug 06)
*''Intrusion Modelling'':Modelling the recall intrusion data for Temporal Contextual Model.(Aug 06)
*''Capability Implementation'':Implemented Capabilities in Minix2.0.4 (Aug 06)
*''Directory Synchronizer'':Provides facility to synchronize directory across various machines.(Aug 06)
*''Profiler Framework'':Made an extensible framework for profiling source code. The system was tested with two profilers: call coverage and function timing.(Aug 06)
*''Set ~Random-UID'':Implemented a sandboxing mechanism on Minix, allowing users to run program with the least privileges possible.(Mar 06)
*''XML Dom Parser'':Implemented an XML DOM parser in native C++.(Mar 06)
*''PAM: Pluggable Authentication Modules (Linux)''Hardened the system using PAM in order to avoid hard coding the security policy in the program itself.(Feb 06)
*''~Set-UID vulnerability tracking'':Exploited set-UID programs to get root privilege and discovered security principles that need to be followed while developing an application to avoid getting exploited itself.(Feb 06)
*''File Annotator'':Wrote a C++ application to automate the annotation process. It automatically adds documentation and comments where ever needed.(Feb 06)
*''Dynamic Loader, glibc 2.3.2'':Improved the loader by decreasing the access time for loading shared libraries. The project was implemented on Linux 2.4.20(Dec 05)
*''FIFO Page Replacer'':Changed the page replacement algorithm of ~FreeBSD 4.1 from LRU to FIFO. Also changed the page replacement schema.(Nov 2005)
*''Remote Test Bed'':Built a remote test server for testing and building C# programs. Written in C#.NET using .NET sockets.(Nov 2005)
*''Fairshare Process Scheduler'': Wrote a process scheduler for ~FreeBSD 4.1
*''~CodeGen'':Used for generating broilerplate code for C# programs. Written in C#.NET
*''DB Monitoring Tool'':Worked at the database backend to make it more robust. Developed on Solaris 10.(Jun 05 at Aztec Software and Technology services.)
*''Policy Driven Application Manager'':A complete robust framework and technological solution for automated scaling of servers. Exploited the concept of ~J2EE to the maximum to achieve automatic scaling of servers.(Feb 05)
*''Lancer, A LAN Search Utility'':A project which searches the LAN for a particular file and helps the user download the required file using peer to peer communication. It was implemented on Linux using BSD sockets. Qt designer was used for the front end designing.(Jan 05)
*''~LTaMe, Linux Task Manager'': A user friendly task manager for Linux, with interface similar to the task manager provided in ~WindowsXP. Developed on Red Hat Linux 9 using Qt 3.3 as a front end tool.(Dec 04)
*''Linux Text Editor'':A mini project (text editor) made on Linux platform using Ncurses library in C++.(Jan 04)
/***
|''Name:''|RSSReaderPlugin|
|''Description:''|This plugin provides a RSSReader for TiddlyWiki|
|''Version:''|1.1.1|
|''Date:''|Apr 21, 2007|
|''Source:''|http://tiddlywiki.bidix.info/#RSSReaderPlugin|
|''Documentation:''|http://tiddlywiki.bidix.info/#RSSReaderPluginDoc|
|''Modder:''|Sridhar V Iyer (truncated the number of displayed entries to 10 and removed the ugly update button)|
|''Original Author:''|BidiX (BidiX (at) bidix (dot) info)|
|''Credit:''|BramChen for RssNewsMacro|
|''License:''|[[BSD open source license|http://tiddlywiki.bidix.info/#%5B%5BBSD%20open%20source%20license%5D%5D ]]|
|''~CoreVersion:''|2.2.0|
|''OptionalRequires:''|http://www.tiddlytools.com/#NestedSlidersPlugin|
***/
//{{{
version.extensions.RSSReaderPlugin = {
major: 1, minor: 1, revision: 1,
date: new Date("Apr 21, 2007"),
source: "http://TiddlyWiki.bidix.info/#RSSReaderPlugin",
author: "BidiX",
coreVersion: '2.2.0'
};
config.macros.rssReader = {
dateFormat: "DDD, DD MMM YYYY",
itemStyle: "display: block;border: 1px solid black;padding: 5px;margin: 5px;", //useed '@@'+itemStyle+itemText+'@@'
msg:{
permissionDenied: "Permission to read preferences was denied.",
noRSSFeed: "No RSS Feed at this address %0",
urlNotAccessible: " Access to %0 is not allowed"
},
cache: [], // url => XMLHttpRequest.responseXML
desc: "noDesc",
handler: function(place,macroName,params,wikifier,paramString,tiddler) {
var desc = params[0];
var feedURL = params[1];
var toFilter = (params[2] ? true : false);
var filterString = (toFilter?(params[2].substr(0,1) == ' '? tiddler.title:params[2]):'');
var place = createTiddlyElement(place, "div", "RSSReader");
//wikify("^^<<rssFeedUpdate "+feedURL+" [[" + tiddler.title + "]]>>^^\n",place);
if (this.cache[feedURL]) {
this.displayRssFeed(this.cache[feedURL], feedURL, place, desc, toFilter, filterString);
}
else {
var r = loadRemoteFile(feedURL,config.macros.rssReader.processResponse, [place, desc, toFilter, filterString]);
if (typeof r == "string")
displayMessage(r);
}
},
// callback for loadRemoteFile
// params : [place, desc, toFilter, filterString]
processResponse: function(status, params, responseText, url, xhr) { // feedURL, place, desc, toFilter, filterString) {
if (window.netscape){
try {
if (document.location.protocol.indexOf("http") == -1) {
netscape.security.PrivilegeManager.enablePrivilege("UniversalBrowserRead");
}
}
catch (e) { displayMessage(e.description?e.description:e.toString()); }
}
if (xhr.status == httpStatus.NotFound)
{
displayMessage(config.macros.rssReader.noRSSFeed.format([url]));
return;
}
if (!status)
{
displayMessage(config.macros.rssReader.noRSSFeed.format([url]));
return;
}
if (xhr.responseXML) {
// response is interpreted as XML
config.macros.rssReader.cache[url] = xhr.responseXML;
config.macros.rssReader.displayRssFeed(xhr.responseXML, params[0], url, params[1], params[2], params[3]);
}
else {
if (responseText.substr(0,5) == "<?xml") {
// response exists but not return as XML -> try to parse it
var dom = (new DOMParser()).parseFromString(responseText, "text/xml");
if (dom) {
// parsing successful so use it
config.macros.rssReader.cache[url] = dom;
config.macros.rssReader.displayRssFeed(dom, params[0], url, params[1], params[2], params[3]);
return;
}
}
// no XML display as html
wikify("<html>" + responseText + "</html>", params[0]);
displayMessage(config.macros.rssReader.msg.noRSSFeed.format([url]));
}
},
// explore down the DOM tree
displayRssFeed: function(xml, place, feedURL, desc, toFilter, filterString){
// Channel
var chanelNode = xml.getElementsByTagName('channel').item(0);
var chanelTitleElement = (chanelNode ? chanelNode.getElementsByTagName('title').item(0) : null);
var chanelTitle = "";
if ((chanelTitleElement) && (chanelTitleElement.firstChild))
chanelTitle = chanelTitleElement.firstChild.nodeValue;
var chanelLinkElement = (chanelNode ? chanelNode.getElementsByTagName('link').item(0) : null);
var chanelLink = "";
if (chanelLinkElement)
chanelLink = chanelLinkElement.firstChild.nodeValue;
var titleTxt = "!![["+chanelTitle+"|"+chanelLink+"]]\n";
var title = createTiddlyElement(place,"div",null,"ChanelTitle",null);
wikify(titleTxt,title);
// ItemList
var itemList = xml.getElementsByTagName('item');
var article = createTiddlyElement(place,"ul",null,null,null);
var lastDate;
var re;
if (toFilter)
re = new RegExp(filterString.escapeRegExp());
for (var i=0; i<itemList.length && i<10; i++){
var titleElm = itemList[i].getElementsByTagName('title').item(0);
var titleText = (titleElm ? titleElm.firstChild.nodeValue : '');
if (toFilter && ! titleText.match(re)) {
continue;
}
var descText = '';
descElem = itemList[i].getElementsByTagName('description').item(0);
if (descElem){
try{
for (var ii=0; ii<descElem.childNodes.length; ii++) {
descText += descElem.childNodes[ii].nodeValue;
}
}
catch(e){}
descText = descText.replace(/<br \/>/g,'\n');
if (desc == "asHtml")
descText = "<html>"+descText+"</html>";
}
var linkElm = itemList[i].getElementsByTagName("link").item(0);
var linkURL = linkElm.firstChild.nodeValue;
var pubElm = itemList[i].getElementsByTagName('pubDate').item(0);
var pubDate;
if (!pubElm) {
pubElm = itemList[i].getElementsByTagName('date').item(0); // for del.icio.us
if (pubElm) {
pubDate = pubElm.firstChild.nodeValue;
pubDate = this.formatDateString(this.dateFormat, pubDate);
}
else {
pubDate = '0';
}
}
else {
pubDate = (pubElm ? pubElm.firstChild.nodeValue : 0);
pubDate = this.formatDate(this.dateFormat, pubDate);
}
titleText = titleText.replace(/\[|\]/g,'');
var rssText = '*'+'[[' + titleText + '|' + linkURL + ']]' + '' ;
if ((desc != "noDesc") && descText){
rssText = rssText.replace(/\n/g,' ');
descText = '@@'+this.itemStyle+descText + '@@\n';
if (version.extensions.nestedSliders){
descText = '+++[...]' + descText + '===';
}
rssText = rssText + descText;
}
var story;
if ((lastDate != pubDate) && ( pubDate != '0')) {
story = createTiddlyElement(article,"li",null,"RSSItem",pubDate);
lastDate = pubDate;
}
else {
lastDate = pubDate;
}
story = createTiddlyElement(article,"div",null,"RSSItem",null);
wikify(rssText,story);
}
},
formatDate: function(template, date){
var dateString = new Date(date);
// template = template.replace(/hh|mm|ss/g,'');
return dateString.formatString(template);
},
formatDateString: function(template, date){
var dateString = new Date(date.substr(0,4), date.substr(5,2) - 1, date.substr(8,2)
);
return dateString.formatString(template);
}
};
config.macros.rssFeedUpdate = {
label: "Update",
prompt: "Clear the cache and redisplay this RssFeed",
handler: function(place,macroName,params) {
var feedURL = params[0];
var tiddlerTitle = params[1];
createTiddlyButton(place, this.label, this.prompt,
function () {
if (config.macros.rssReader.cache[feedURL]) {
config.macros.rssReader.cache[feedURL] = null;
}
story.refreshTiddler(tiddlerTitle,null, true);
return false;});
}
};
//}}}
[[news.php]] is an RSSFeed reader. It accesses an RSS 2.0 file and displays the feed in a page using a CSS.
The full syntax is :
>news.php[?[rss=<rssfile>[&css=<cssfile>]]
with :
*<rssfile>: a RSSFeed (default index.xml)
*<cssfile>: a CssFile (default embeded css)
Some examples :
*http://tiddlylab.bidix.info/news.php
*http://tiddlylab.bidix.info/news.php?rss=http://www.tiddlywiki.com/index.xml
*http://tiddlylab.bidix.info/news.php?rss=http://tw.lewcid.org/index.xml
*http://tiddlylab.bidix.info/news.php?rss=http://www.tiddlywiki.com/beta/index.xml&css=news.css (But links are not correct due to http://www.tiddlywiki.com/beta/#SiteUrl )
*http://tiddlylab.bidix.info/news.php?css=news.css
*http://tiddlylab.bidix.info/news.php?rss=http://news.com.com/2547-1_3-0-20.xml
*http://tiddlylab.bidix.info/news.php?rss=http://www.liberation.fr/rss.php
----
@@font-size(1.5em):''Sridhar.V.Iyer''@@
iyer [at] sridharv [dot] net
315-560-4566
!!''Education''
''[[Syracuse University|http://www.syr.edu]]'', L.C Smith College of Engineering & Computer Science, Syracuse, NY
May'07
M.S. in Computer and Information Science.
GPA: 3.77
''S.J.C Institute of Technology'', Chickballapur, Karnataka, India
May'05
B.E. in Computer Science and Engineering
!!''Related Work Experience''
''[[Cisco Systems Inc.|http://cisco.com]]'', San Jose, CA
August’10 - Current
Software Engineer
*Develop and maintain the l2 layer of the forwarding plane on Cisco's n5000 series of switches.
*Developed and maintained various authentication/authorization/monitoring modules on n5000 switches like SNMP, AAA, TACACS, RADIUS etc.
''[[Mailshell Inc.|http://mailshell.com]]'', Santa Clara, CA
June’07 - July’10
Software Engineer
*Designed, wrote and maintained tools used for anti-spam analysis.
*Enhanced the existing proprietary SDK and develop other tools required by the clients.
*Managed an offshore outsourced team.
''[[Department of Computer and Information Science|http://www.cis.syr.edu/~wedu/seed/index.html]]'', Syracuse University, NY
August’06 - May’07
Research Assistant under Dr Wenliang Du
*Developed Instructional Laboratory projects for Computer Security Education. These projects are used by the faculties and students (undergraduate and graduate) at various universities as laboratory exercises for computer system security education.
*Developed Encrypted File System and ASLR (Address space layout randomization) on Minix3.1.2a. This ensures data safety even when the hard disk is physically compromised.
*Designed SQL injection, ~LD_PRELOAD, buffer overflow attack, return-to-libc attack and race condition attack labs.
*Project funded by National Science Foundation ($451,682, 01/2007-12/2010. Grant No. 0618680).
''[[Department Of Psychology|http://memory.syr.edu]]'', Syracuse University, Syracuse, NY
September’05 - August’06
Research Assistant under Dr Marc Howard
*Designed, wrote and maintained tools to aid related scientific research, now being used for faculty research at Syracuse University.
*Did an Independent study on //Multidimensional Function Minimization using Genetic Algorithms//.
*Simulated cognitive models (based on Temporal Context Model developed by Dr Marc Howard and Dr Michael Kahana), most of them on Beowulf cluster housing 72 hyper-threaded 3.06GHz Xeon processors. These simulations are used to prove the correctness of the neural networked model of the short term memory under various hypothetical situations. Standard C++ was used for implementation.
''Aztec Software and Technology Services, Bangalore'', Karnataka, India
February’05 - August’05
Software Engineering Intern
*DB Monitoring Tool: Developed a monitoring tool for ~PostgreSQL8 on Solaris 10 using Dtrace and Qt, thereby enabling fine tuning the database.
*Policy Driven Application Manager: Developed an orchestrator in Java for automated scaling of servers using CLI scripts exposed by the underlying architecture.
!!Related Projects
*''Compiler for PL''
April'07
Implemented a compiler for PL (an educational programming language) in Java under Dr Per Brinch Hansen. The compiler generated machine code for a virtual computer.
*''~IPSec on Minix 3''
Dec'06
Implemented ~IPSec, ESP tunneling with authentication, on Minix 3.1.2a. This system involved adding encryption/decryption functionality at the IP layer. The implementation was done according to RFC standards and involved key management module for using different keys for different communication channels.
*''~XMLDom parser''
Mar'06
Developed a XML DOM parser on VC++ 8.0. The project consisted of two main modules: Graph processor and XML processor. The system made extensive use of advanced C++ constructs such as smart pointers and partial template specialization.
!!Other Academic Projects
*''System Security'': TCP Vulnerability testing, ARP/IP/ICMP Vulnerability testing, Format String Vulnerability testing, Buffer Flow exploits, Race Condition Exploits, Set ~Random-UID, Return to libc attack and Encrypted File System etc.(extensive use of C and GDB)
*''OS Design'': Hashed Dynamic Loader (Linux), FIFO page replacer(~FreeBSD4.1), ASLR and Capability (Minix3.1.2a). Fair Share Process Scheduler (~FreeBSD).
*''Scientific Computing'': FRAMOF: Framework for Model Fitting (GA), Simulated various cognitive models at Memlab (Dept of Psychology, Syracuse University). (C/C++/Ruby/Perl/Bash)
*''Application Software'': Profiler Framework (C++), File Annotator (C++), Remote Test Bed(C#), Lancer: A LAN Search Utility (Qt), Remote Directory Synchronizer(VC++ 8.0)
!!Technical skills and interests
*''Hardware'': IBM compatible ~PCs, ~UltraSPARC, IBM Blade servers, Beowulf clusters, Crossbow ~MicaZ motes.
*''Operating Systems'': Microsoft Windows 9x-XP, ~MS-DOS, Linux, Solaris, ~FreeBSD, Minix & ~TinyOS.
*''Languages'': C, C++, Python, Java, C#.NET, x86 Assembly.
*''Databases'': Oracle8i, ~PostgreSQL
*''Miscellaneous'': ~JBoss, JMX, ~J2EE, XML, ~ArgoUML, Rational Rose, Bash Shell programming, ~LaTeX, GDB, Lex, Yacc, HTML, CVS, MS Office suite, GRI etc.
!!Accomplishments
*Member of [[Phi Beta Delta|http://www.phibetadelta.org/]].
*Stood third in the ~TopCoder’s Collegiate Challenge held at Syracuse University.
*Won 1st Prize in iTalent-2004, a paper presentation contest, organized by [[CII|http://www.ciionline.org/]]: Confederation Of Indian Industries , Chennai.
*Academically first in my undergraduate college with an aggregate of 79.6% and was awarded a Gold Medal for excellence in academics.
/***
|Name|SinglePageModePlugin|
|Source|http://www.TiddlyTools.com/#SinglePageModePlugin|
|Version|2.5.3|
|Author|Eric Shulman - ELS Design Studios|
|License|http://www.TiddlyTools.com/#LegalStatements <br>and [[Creative Commons Attribution-ShareAlike 2.5 License|http://creativecommons.org/licenses/by-sa/2.5/]]|
|~CoreVersion|2.1|
|Type|plugin|
|Requires||
|Overrides|Story.prototype.displayTiddler(), Story.prototype.displayTiddlers()|
|Description|Show tiddlers one at a time with automatic permalink, or always open tiddlers at top/bottom of page.|
Normally, as you click on the links in TiddlyWiki, more and more tiddlers are displayed on the page. The order of this tiddler display depends upon when and where you have clicked. Some people like this non-linear method of reading the document, while others have reported that when many tiddlers have been opened, it can get somewhat confusing. SinglePageModePlugin allows you to configure TiddlyWiki to navigate more like a traditional multipage web site with only one item displayed at a time.
!!!!!Usage
<<<
When the plugin is enabled, only one tiddler will be displayed at a time and the browser window's titlebar is updated to include the current tiddler title. The browser's location URL is also updated with a 'permalink' for the current tiddler so that it is easier to create a browser 'bookmark' for the current tiddler. Alternatively, even when displaying multiple tiddlers //is// permitted, you can still reduce the potential for confusion by forcing tiddlers to always open at the top (or bottom) of the page instead of being displayed following the tiddler containing the link that was clicked.
<<<
!!!!!Configuration
<<<
When installed, this plugin automatically adds checkboxes in the AdvancedOptions tiddler so you can enable/disable the plugin behavior. For convenience, these checkboxes are also included here:
<<option chkSinglePageMode>> Display one tiddler at a time
<<option chkSinglePagePermalink>> Automatically permalink current tiddler
<<option chkTopOfPageMode>> Always open tiddlers at the top of the page
<<option chkBottomOfPageMode>> Always open tiddlers at the bottom of the page
//Note: if both 'top' and 'bottom' settings are selected, "top of page" will be used. Also, in Apple's Safari browser, automatically setting the permalink causes an error and is disabled.//
When installed, this plugin automatically adds checkboxes in the ''shadow'' AdvancedOptions tiddler so you can enable/disable this behavior. However, if you have customized your AdvancedOptions, you may need to ''manually add these checkboxes to your customized tiddler.''
<<<
!!!!!Revision History
<<<
2007.12.22 [2.5.3] in checkLastURL(), use decodeURIComponent() instead of decodeURI so that tiddler titles with commas (and/or other punctuation) are correctly handled.
2007.10.26 [2.5.2] documentation cleanup
| Please see [[SinglePageModePluginHistory]] for previous revision details |
2005.08.15 [1.0.0] Initial Release. Support for BACK/FORWARD buttons adapted from code developed by Clint Checketts.
<<<
!!!!!Code
***/
//{{{
version.extensions.SinglePageMode= {major: 2, minor: 5, revision: 3, date: new Date(2007,12,22)};
if (config.options.chkSinglePageMode==undefined) config.options.chkSinglePageMode=false;
if (config.options.chkSinglePagePermalink==undefined) config.options.chkSinglePagePermalink=true;
if (config.options.chkTopOfPageMode==undefined) config.options.chkTopOfPageMode=false;
if (config.options.chkBottomOfPageMode==undefined) config.options.chkBottomOfPageMode=false;
if (config.optionsDesc) {
config.optionsDesc.chkSinglePageMode="Display one tiddler at a time";
config.optionsDesc.chkSinglePagePermalink="Automatically permalink current tiddler";
config.optionsDesc.chkTopOfPageMode="Always open tiddlers at the top of the page";
config.optionsDesc.chkBottomOfPageMode="Always open tiddlers at the bottom of the page";
} else {
config.shadowTiddlers.AdvancedOptions += "\
\n<<option chkSinglePageMode>> Display one tiddler at a time \
\n<<option chkSinglePagePermalink>> Automatically permalink current tiddler \
\n<<option chkTopOfPageMode>> Always open tiddlers at the top of the page \
\n<<option chkBottomOfPageMode>> Always open tiddlers at the bottom of the page";
}
config.SPMTimer = 0;
config.lastURL = window.location.hash;
function checkLastURL()
{
if (!config.options.chkSinglePageMode)
{ window.clearInterval(config.SPMTimer); config.SPMTimer=0; return; }
if (config.lastURL == window.location.hash)
return;
var tiddlerName = convertUTF8ToUnicode(decodeURIComponent(window.location.hash.substr(1)));
tiddlerName=tiddlerName.replace(/\[\[/,"").replace(/\]\]/,""); // strip any [[ ]] bracketing
if (tiddlerName.length) story.displayTiddler(null,tiddlerName,1,null,null);
}
if (Story.prototype.SPM_coreDisplayTiddler==undefined) Story.prototype.SPM_coreDisplayTiddler=Story.prototype.displayTiddler;
Story.prototype.displayTiddler = function(srcElement,title,template,animate,slowly)
{
if (config.options.chkSinglePageMode)
story.closeAllTiddlers();
else if (config.options.chkTopOfPageMode)
arguments[0]=null;
else if (config.options.chkBottomOfPageMode)
arguments[0]="bottom";
if (config.options.chkSinglePageMode && config.options.chkSinglePagePermalink && !config.browser.isSafari) {
window.location.hash = encodeURIComponent(convertUnicodeToUTF8(String.encodeTiddlyLink(title)));
config.lastURL = window.location.hash;
document.title = wikifyPlain("SiteTitle") + " - " + title;
if (!config.SPMTimer) config.SPMTimer=window.setInterval(function() {checkLastURL();},1000);
}
this.SPM_coreDisplayTiddler.apply(this,arguments); // let CORE render tiddler
var tiddlerElem=document.getElementById(story.idPrefix+title);
if (tiddlerElem) {
var yPos=ensureVisible(tiddlerElem); // scroll to top of tiddler
var isTopTiddler=(tiddlerElem.previousSibling==null);
if (config.options.chkSinglePageMode||config.options.chkTopOfPageMode||isTopTiddler)
yPos=0; // scroll to top of page instead of top of tiddler
if (config.options.chkAnimate) // defer scroll until 200ms after animation completes
setTimeout("window.scrollTo(0,"+yPos+")",config.animDuration+200);
else
window.scrollTo(0,yPos); // scroll immediately
}
}
if (Story.prototype.SPM_coreDisplayTiddlers==undefined) Story.prototype.SPM_coreDisplayTiddlers=Story.prototype.displayTiddlers;
Story.prototype.displayTiddlers = function(srcElement,titles,template,unused1,unused2,animate,slowly)
{
// suspend single-page mode (and/or top/bottom display options) when showing multiple tiddlers
var saveSPM=config.options.chkSinglePageMode; config.options.chkSinglePageMode=false;
var saveTPM=config.options.chkTopOfPageMode; config.options.chkTopOfPageMode=false;
var saveBPM=config.options.chkBottomOfPageMode; config.options.chkBottomOfPageMode=false;
this.SPM_coreDisplayTiddlers.apply(this,arguments);
config.options.chkBottomOfPageMode=saveBPM;
config.options.chkTopOfPageMode=saveTPM;
config.options.chkSinglePageMode=saveSPM;
}
//}}}
/%
|Name|AnimationEffectsSample|
|Source|http://www.TiddlyTools.com/#AnimationEffectsSample|
|Version|1.1.0|
|Author|Eric Shulman - ELS Design Studios|
|License|http://www.TiddlyTools.com/#LegalStatements <br>and [[Creative Commons Attribution-ShareAlike 2.5 License|http://creativecommons.org/licenses/by-sa/2.5/]]|
|~CoreVersion|2.1|
|Type|script|
|Requires|AnimationEffectsPlugin, StyleSheetShortcuts|
|Optional|InlineJavascriptPlugin, HideTiddlerTags, HideTiddlerBackground, HideTiddlerSubtitle, CloseOtherTiddlers, RefreshTiddler, ReplaceTiddlerTitle, TextAreaPlugin|
|Overrides||
|Description|demonstrates techniques for animating wiki-formatted content|
SET SPEED MULTIPLIER (global variable) [0:00]
%/<<tiddler {{
window.sec=config.options.txtAnimationEffectsRate||1000; // global abbreviation/default multiplier
config.options.txtAnimationEffectsRate=window.sec; // user option value initialization
""; // return blank tiddlername so macro doesn't produce output
}}>>/%
%/{{floatleft bold italic{/%
%/<<animate " " fontSize %0% 100 400 {{0*sec}} {{.5*sec}} 2>>/%
%/<<animate "g" fontSize %0% 100 350 {{.1*sec}} {{.5*sec}} 2>>/%
%/<<animate "e" fontSize %0% 100 300 {{.2*sec}} {{.5*sec}} 2>>/%
%/<<animate "e" fontSize %0% 100 300 {{.3*sec}} {{.5*sec}} 2>>/%
%/<<animate "k" fontSize %0% 100 300 {{.4*sec}} {{.5*sec}} 2>>/%
%/<<animate "i" fontSize %0% 100 300 {{.5*sec}} {{.5*sec}} 2>>/%
%/<<animate "n" fontSize %0% 100 300 {{.6*sec}} {{.5*sec}} 2>>/%
%/<<animate "g" fontSize %0% 100 300 {{.7*sec}} {{.5*sec}} 2>>/%
%/<<animate " " fontSize %0% 100 300 {{.8*sec}} {{.5*sec}} 2>>/%
%/<<animate "m" fontSize %0% 100 300 {{.9*sec}} {{.5*sec}} 2>>/%
%/<<animate "y" fontSize %0% 100 300 {{1*sec}} {{.5*sec}} 2>>/%
%/<<animate " " fontSize %0% 100 300 {{1.1*sec}} {{.5*sec}} 2>>/%
%/<<animate "way" fontSize %0% 100 300 {{1.2*sec}} {{.5*sec}} 2>>/%
%/<<animate " " fontSize %0% 100 300 {{1.3*sec}} {{.5*sec}} 2>>/%
%/<<animate "thro" fontSize %0% 100 300 {{1.3*sec}} {{.5*sec}} 2>>/%
%/<<animate "ugh" fontSize %0% 100 300 {{1.4*sec}} {{.5*sec}} 2>>/%
%/<<animate " " fontSize %0% 100 300 {{1.5*sec}} {{.5*sec}} 2>>/%
%/<<animate "life" fontSize %0% 100 300 {{1.6*sec}} {{.5*sec}} 2>>/%
%/<<animate "... " fontSize %0% 150 300 {{1.7*sec}} {{.5*sec}} 2>>/%
%/}}}/%
/***
|''Name:''|SparklinePlugin|
|''Description:''|Sparklines macro|
***/
//{{{
if(!version.extensions.SparklinePlugin) {
version.extensions.SparklinePlugin = {installed:true};
//--
//-- Sparklines
//--
config.macros.sparkline = {};
config.macros.sparkline.handler = function(place,macroName,params)
{
var data = [];
var min = 0;
var max = 0;
var v;
for(var t=0; t<params.length; t++) {
v = parseInt(params[t]);
if(v < min)
min = v;
if(v > max)
max = v;
data.push(v);
}
if(data.length < 1)
return;
var box = createTiddlyElement(place,"span",null,"sparkline",String.fromCharCode(160));
box.title = data.join(",");
var w = box.offsetWidth;
var h = box.offsetHeight;
box.style.paddingRight = (data.length * 2 - w) + "px";
box.style.position = "relative";
for(var d=0; d<data.length; d++) {
var tick = document.createElement("img");
tick.border = 0;
tick.className = "sparktick";
tick.style.position = "absolute";
tick.src = "data:image/gif,GIF89a%01%00%01%00%91%FF%00%FF%FF%FF%00%00%00%C0%C0%C0%00%00%00!%F9%04%01%00%00%02%00%2C%00%00%00%00%01%00%01%00%40%02%02T%01%00%3B";
tick.style.left = d*2 + "px";
tick.style.width = "2px";
v = Math.floor(((data[d] - min)/(max-min)) * h);
tick.style.top = (h-v) + "px";
tick.style.height = v + "px";
box.appendChild(tick);
}
};
}
//}}}
config.options.chkSinglePageMode=true;
<!--{{{-->
<div class= 'tiddlerBoxout'>
<div class='tiddlerBox'>
<div class='toolbar' macro='toolbar closeTiddler closeOthers editTiddler > fields syncing permalink references jump'></div>
<div class='title' macro='view title'></div>
<div class='tagging' macro='tagging'></div>
<div class='tagged' macro='tags'></div>
<div class='viewer' macro='view text wikified'></div>
<div class='tagClear'></div>
</div>
</div>
<!--}}}-->
/***
|StyleSheet|WebTheme|
***/
#sidebar, .tiddler .toolbar { display:none; }
#displayArea { margin-right: 1em; }
/***
|Name|AnimationEffectsPlugin|
|Source|http://www.TiddlyTools.com/#AnimationEffectsPlugin|
|Documentation|http://www.TiddlyTools.com/#AnimationEffectsPluginInfo|
|Version|3.1.1|
|Author|Eric Shulman - ELS Design Studios|
|License|http://www.TiddlyTools.com/#LegalStatements <br>and [[Creative Commons Attribution-ShareAlike 2.5 License|http://creativecommons.org/licenses/by-sa/2.5/]]|
|~CoreVersion|2.2|
|Type|plugin|
|Requires||
|Overrides||
|Description|display content with timer-based animations to manipulate multiple CSS attributes|
|Status|!BETA - EXPERIMENTAL - UNDER DEVELOPMENT - USE WITH CAUTION|
This plugin defines the {{{<<animate>>}}} macro that can be used to peform simple animations of formatted tiddler content by saving/setting/reseting the values of CSS style attributes at specified times. The macro can also be used to smoothly animate CSS styles that use ''numeric values'', by automatically computing a series of incremental values, ranging from //start// to //stop//, for a specified //duration//, with optional "pause-and-reverse" //cycles// to create repeating animations or continuous loops.
!!!!!Documentation
>see [[AnimationEffectsPluginInfo]] for macro syntax
>see [[AnimationEffectsSample]] for a live animation example...
!!!!!Revision History
<<<
2008.01.08 [*.*.*] plugin size reduction: documentation moved to [[AnimationEffectsPluginInfo]]
2008.01.07 [3.1.1] when animation is disabled, set inner container to original DIV/SPAN
2007.12.16 [3.1.0] added support for "add/remove" classname functionality. Also, in handling for "set", only stored previous attribute value if not already saved and, on "reset", clear saved value. This blocks animations from inadvertently overwriting the saved value while simulaneously processing animation sequences that act on the same attribute.
2007.12.08 [3.0.0] Combined ZoomTextPlugin and AnimateTiddler inline script into single plugin
2007.08.03 [2.1.0] converted from ZoomText inline script
2007.07.16 [2.0.0] added TW2.2-compatible Morpher handling for smoother animation on slower systems
2007.02.17 [1.0.0] initial release
<<<
!!!!!Code
***/
//{{{
version.extensions.AnimationEffects= {major: 3, minor: 1, revision: 1, date: new Date(2008,1,7)};
config.macros.animate = {
handler: function(place,macroName,params,wikifier,paramString,tiddler) {
var id=new Date().getTime()+Math.random().toString(); // globally unique ID (GUID)
if (params[0] && (params[0].toUpperCase()=="DIV"||params[0].toUpperCase()=="SPAN"))
var nodetype=params.shift().toUpperCase(); // optional param to force DIV/SPAN
var src=params.shift(); if (!src) src="="; // content is first parameter (if no params, animate container)
if (src.substr(0,1)=="=") { // content=DOM element... use "=here" or "=" (without ID) for current container
var target=place;
if (src.length>1 && src.substr(1).toUpperCase()!='HERE') target=document.getElementById(src.substr(1));
if (!target) return; // couldn't locate target element... do nothing.
var nodetype=nodetype||target.nodeName.toUpperCase();
} else { // use content from tiddler or "inline" param
if (src.substr(0,1)=="@") src=store.getTiddlerText(src.substr(1)); // "@TiddlerName"
var nodetype=nodetype||"span";
var target=createTiddlyElement(place,nodetype);
wikify(src,target);
}
if (params[0]) switch(params[0].toUpperCase()) {
case "SAVE":
var s=params[1]; if (!s) return; // must specify style attribute
if (s.substr(0,1)=="+") s=s.substr(1); // ignore leading "+" (if any)
var w=(params[2]!=undefined && config.options.chkAnimate)?parseInt(params[2]):0; // wait time before saving
if (!target.savedStyle) target.savedStyle={};
if (target.savedStyle[s]!==undefined) return; // value already saved... do nothing.
if (!w) { target.savedStyle[s]=target.style[s]; return; } // save style immediately... done.
target.id=target.id||id; // use existing ID if target has one, otherwise assign GUID
var fn='var e=document.getElementById("'+target.id+'"); \
if(e&&e.savedStyle["'+s+'"]==undefined) \
e.savedStyle["'+s+'"]=e.style["'+s+'"]';
setTimeout(fn,w); return; // timer is set... done.
case "SET":
var s=params[1]; if (!s) return; // must specify style attribute
if (s.substr(0,1)=="+") s=s.substr(1); // ignore leading "+" (if any)
var v=params[2]!=undefined?params[2]:""; // value to set
var w=(params[3]!=undefined && config.options.chkAnimate)?parseInt(params[3]):0; // wait time before setting
if (!w) { target.style[s]=v; return; } // set style immediately... done.
target.id=target.id||id; // use existing ID if target has one, otherwise assign GUID
var fn='var e=document.getElementById("'+target.id+'");if(e)e.style["'+s+'"]="'+v+'"';
setTimeout(fn,w); return; // timer is set... done.
case "RESET":
var s=params[1]; if (!s) return; // must specify style attribute
if (s.substr(0,1)=="+") s=s.substr(1); // ignore leading "+" (if any)
var w=(params[2]!=undefined && config.options.chkAnimate)?parseInt(params[2]):0; // wait time before reset
if (!w && target.savedStyle && (s in target.savedStyle))
{ target.style[s]=target.savedStyle[s]; target.savedStyle[s]=undefined; return; } // reset style immediately
target.id=target.id||id; // use existing ID if target has one, otherwise assign GUID
var fn='var e=document.getElementById("'+target.id+'"); \
if(e&&e.savedStyle&&("'+s+'" in e.savedStyle)) \
e.style["'+s+'"]=e.savedStyle["'+s+'"]; e.savedStyle["'+s+'"]=undefined';
setTimeout(fn,w); return; // timer is set... done.
case "ADD":
var add=true; // fall-through for further processing
case "REMOVE":
var c=params[1]; if (!c) return; // must specify a classname
if (c.substr(0,1)=="+") c=c.substr(1); // ignore leading "+" (if any)
var w=(params[2]!=undefined && config.options.chkAnimate)?parseInt(params[2]):0; // wait time before setting
if (!w) { (add?addClass:removeClass)(target,c); return; } // add class immediately... done.
target.id=target.id||id; // use existing ID if target has one, otherwise assign GUID
var fn='var e=document.getElementById("'+target.id+'");if(e)'+(add?'addClass':'removeClass')+'(e,"'+c+'")';
setTimeout(fn,w); return; // timer is set... done.
}
// remove old containers before RE-animating, unless combining effects (using "+style" param)
if (params[0] && params[0].substr(0,1)!="+") cleanup(target);
function cleanup(here) { // recursively finds all animation containers
if (here.childNodes) for (var n=0; n<here.childNodes.length; n++)
if (here.childNodes[n].className=="animationContainer") cleanup(here.childNodes[n]);
if (here.className=="animationContainer") { // move content up a level and remove container
var e=here.firstChild;
while (e) { var next=e.nextSibling; here.parentNode.insertBefore(e,here); e=next; }
removeNode(here);
}
}
// create animation outer "clipping" container and inner "formatting" container
var outer=createTiddlyElement(null,nodetype,null,"animationContainer");
outer.style.overflow="hidden";
var inner=createTiddlyElement(outer,nodetype,id,"animationContainer");
inner.style.position="relative"; inner.style.lineHeight="100%";
target.insertBefore(outer,target.firstChild);
// move content elements into the inner container
var e=target.firstChild.nextSibling;
while (e) { var next=e.nextSibling; inner.insertBefore(e,null); e=next; }
// params and defaults for morph
inner.OriginalType=target.nodeName.toUpperCase(); // SPAN or DIV
inner.What=params[0]?params[0]:'left';
if (inner.What.substr(0,1)=="+") inner.What=inner.What.substr(1); // trim off "+" prefix (if any)
inner.Format=params[1]!=undefined?params[1]:'%0%';
inner.Start=params[2]!=undefined?parseInt(params[2]):100;
inner.Stop=params[3]!=undefined?parseInt(params[3]):0;
inner.Wait=params[4]!=undefined?parseInt(params[4]):0;
inner.Duration=params[5]!=undefined?parseInt(params[5]):2000;
inner.Cycle=params[6]!=undefined?parseInt(params[6]):1
inner.Pause=params[7]!=undefined?parseInt(params[7]):0;
if (!config.options.chkAnimate) { // if not animating
if (inner.Cycle && (inner.Cycle % 2)) inner.Start=inner.Stop; // odd # of cycles: apply ending value
inner.style.display=inner.OriginalType!="DIV"?"inline":"block"; // restore original display style
var outer=inner.parentNode; if (outer && outer.parentNode) // remove outer clipping container
{ outer.parentNode.insertBefore(inner,outer); removeNode(outer); }
}
inner.style[inner.What]=inner.Format.format([inner.Start]); // set initial style value
if (inner.What=="fontSize" && inner.Start<=0) inner.style.display="none"; // hide text if initial size is 0
if (config.options.chkAnimate) setTimeout("config.macros.animate.morph('"+inner.id+"')",inner.Wait); // ANIMATE!
},
//}}}
//{{{
// animation 'tick' handler (timer callback)
morph: function(id) {
var inner=document.getElementById(id); if (!inner) return;
var p = [{style: inner.What, start: inner.Start, end: inner.Stop, template: inner.Format}];
var c = function(inner,p) { // reverse and re-animate until cycle count==0 (use -1 for continuous looping)
if (inner.Cycle==0 || inner.Cycle==1) {
// finished animation... discard outer container but keep inner container to display final style(s)
inner.style.display=inner.OriginalType!="DIV"?"inline":"block"; // restore original display style
if (p[0].style=="fontSize" && p[0].end<=0) inner.style.display="none"; // hide text if final size=0
var outer=inner.parentNode; if (outer && outer.parentNode) // remove outer clipping container
{ outer.parentNode.insertBefore(inner,outer); removeNode(outer); }
}
else { // reverse-and-repeat
inner.Cycle--; var t=inner.Start; inner.Start=inner.Stop; inner.Stop=t;
setTimeout("config.macros.animate.morph('"+inner.id+"')",inner.Pause);
}
};
inner.style.display=inner.nodeName.toUpperCase()!="DIV"?"inline":"block"; // show starting content
anim.startAnimating(new Morpher(inner,inner.Duration,p,c));
}
};
//}}}
//{{{
// for backward-compatibility with retired [[ZoomTextPlugin]]
config.macros.zoomText = {
handler: function(place,macroName,params,wikifier,paramString,tiddler) {
// convert old params to new params and invoke new handler
var Text=params[0]!=undefined?params[0]:"";
if (Text.substr(0,1)=="@") Text=store.getTiddlerText(Text.substr(1));
var Wait=params[1]!=undefined?parseInt(params[1]):0;
var Start=params[2]!=undefined?parseInt(params[2]):1;
var Stop=params[3]!=undefined?parseInt(params[3]):100;
var Duration=params[4]!=undefined?parseInt(params[4]):config.animDuration;
var Cycle=params[5]!=undefined?parseInt(params[5]):0
var Pause=params[6]!=undefined?parseInt(params[6]):0;
var newParams=[Text,"fontSize","%0%",Start,Stop,Wait,Duration,Cycle,Pause];
var newParamString=["[["+Text+"]]","fontSize","%0%",Start,Stop,Wait,Duration,Cycle,Pause].join(" ");
return config.macros.animate.handler(place,macroName,newParams,wikifier,newParamString,tiddler)
}
}
//}}}
if (readOnly) config.options.txtTheme="WebTheme";
if (config.browser.isIE) config.macros.rssReader.itemStyle="display: block;border: 0px ;padding: 5px;margin: 5px;";