Lively Kernel canvas // this script is evaluated on world load{ borderWidth: 2, borderColor: Color.lightGray, strokeOpacity: 1, fillOpacity: 1, fill: Color.lightGray }pt(140, 100)function($super, date, optPos) { if (!optPos) optPos = pt(100,100); $super(optPos.extent(this.initialExtent)); this.dateMs = date.valueOf(); this.buildDateText(date); }function() { return new Date(this.dateMs); }function(date) { var bnds = this.innerBounds().translatedBy(pt(0, this.getExtent().y-25)); var text = new TextMorph(bnds, date.toUTCString().slice(0,11)); text.beLabel(); text.setFontSize(18); this.text = text; this.addMorphFront(text); }function($super, morph) { $super(morph); if (morph instanceof HandleMorph || morph instanceof SchedulableAction) return morph; var margin = 10; this.droppedMorph = morph; this.oldScale = morph.getScale(); var morphWidth = morph.bounds().extent().x; var myWidth = this.getExtent().x - margin; var morphHeight = morph.bounds().extent().y; var myHeight = this.getExtent().y - 50; var scaleFactor = Math.min(myWidth / morphWidth, myHeight/morphHeight); if (scaleFactor < 1) morph.setScale(scaleFactor*morph.getScale()); // using bounds of morph, its scale already in it, consider it when rescale morph.centerAt(this.innerBounds().center()); return morph; }Functions.Truefunction(evt) { if (!this.droppedMorph) return; this.droppedMorph.setScale(this.oldScale || 1); evt.hand.addMorph(this.droppedMorph); this.droppedMorph = null; }5new Date(24*60*60*1000) - new Date(0)function(date) { return new Date(date.valueOf() + this.day); }function(monthNo, startPos) { var pos = startPos; var extent = DayMorph.prototype.initialExtent; var margin = this.defaultMargin; monthNo -= 1; if (!this.morphs) this.morphs = []; var date = new Date(2009, monthNo/*month-1*/, 1/*day*/, 8/*hour*/, 1/*minute*/); do { this.createDayMorph(date, pos); pos = date.getDay() % 7 == 0 ? startPos.withY(pos.y + extent.y + margin) : pos.addXY(extent.x + margin, 0); date = this.nextDay(date); } while (date.getMonth() === monthNo); return this.morphs; }function(date, pos) { var x = new DayMorph(date, pos); this.morphs.push(x); x.openInWorld(); x.start(); }/* m= new DayMorph(new Date(), pt(100,100)); m.openInWorld(); m.highlight(); allM = new CalendarBuilder().buildMonth(3, pt(10,10)); allM.invoke('remove'); WorldMorph.current().submorphs .select(function(ea) { return ea.constructor = DayMorph}) .forEach(function(ea) { ea.stopStepping() }) WorldMorph.current().submorphs .select(function(ea) { return ea.constructor = DayMorph}) .forEach(function(ea) { ea.startStepping(100, "highlight"); }) highlight: function() { this.applyStyle(this.style); var oneDay = 1000*60*60*24; var fiveDays = 5*oneDay; var timeDiff = this.myDate() - new Date(); if (!this.droppedMorph || timeDiff < 0 || timeDiff > fiveDays) return; this.applyStyle({borderColor: Color.red}); },*/ Mon,05Oct18falsenull 10000.9673138278042869 10000.9298328122250247 1006.603652025353219 10020.112163738299998 1005.7531721184907031254722460000null Tue,06Oct18falsenull 10000.33596396719577826 Exam:Data-orientedXML1 10000.04199189957102813 1007.922596579122155 1007.995406579200002 1000.86045612423271281254808860000null1.8124911785125732 Wed,07Oct18falsenull 10001.203952196722709 10000.4983241373875127 1006.881111691856889 1005.169550418100001 1001.76224494255717851254895260000null Thu,08Oct18falsenull 10002.030741032843188 DeadlineFASE20101 10000.5308072266625969 10011.365109307189911 1004.997846880200001 1000.66475496930897521254981660000null2.0204434394836426 Fri,09Oct18falsenull 10000.0088510790078198 10001.7067077318310027 10022.323218840003378 1004.6677678291000015 1000.60540224241040051255068060000null Sat,10Oct18falsenull 10000.14801967550782955 10000.15779352563283952 1004.942779294069453 1002.40049 1001.11037663275946351255154460000null Sun,11Oct18falsenull 10000.5177200669655652 10001.5397565308469 1009.293403172877456 1003.523867829100001 1000.92883968189082211255240860000null Mon,12Oct18falsenull 10002.2711416393579524 10000.21641392427542433 1008.283094441492254 1005.578825599 1001.73694995057011361255327260000null Tue,13Oct18falsenull 10001.7012360183278445 Welcomenewstudents PrepareWikidemos 10000.8502103556828352 1008.699250203045812 1003.3852673692 1000.445651256568700141255413660000null1 Wed,14Oct18falsenull 10000.8137021775861878 LivelyWikiPresentation1 10000.5589968995523772 1006.5267391208604275 1008.3431191782 1000.0500544939003519441255500060000null1.9317231178283691 Thu,15Oct18falsenull 10001.0701323512617944 10001.0317479942563335 1005.664515627199391 1008.123661738100001 1000.46283084797063661255586460000null Fri,16Oct18falsenull 10000.35413605402638926 10001.5218436226921312 1006.7915286471813365 1006.8694399100000005 1000.84548287668459821255672860000nullnull2.627974510192871 Sat,17Oct18falsenull 10000.4617795199451972 10000.3912170543607633 1006.645530506067364 1007.787965420000001 1001.70896939263828541255759260000nullnull2.627974510192871 Sun,18Oct18falsenull 10000.2202552652558468 10001.5362848713110984 1009.318215353203621 1006.7303307601 1000.0180151377970103441255845660000nullnull2.627974510192871 Mon,19Oct18falsenull 10001.648876201991338 10000.13095320307488925 1005.7589284032217085 1001.4661 1000.57724142391579351255932060000nullnull1.9317231178283691 Tue,20Oct18falsenull 10002.9948962355425013 0.16072.845010197891870.16874981285142326 10000.6533897750790651 10022.234463320995058 10013.0373040763 1000.421687192941670951256018460000null1 Wed,21Oct18falsenull 10002.0780626617512987 10001.4652131825308419 10016.543756790471193 1005.336564019300001 1001.1287055124872111256104860000null Thu,22Oct18falsenull 10000.1345588863621672 10000.5607425810083343 1006.638885816806004 1002.3782969 1001.5439923016864721256191260000null Fri,23Oct18falsenull 10000.02241096858161426 10001.17091859801837 1004.41846377613145 1007.4743350391000005 1000.88455067021658571256277660000nullnull3.1622776985168457 Sat,24Oct18falsenull 10001.330448127533981 FlighttoOrlando 10001.4997686446146616 10010.416026104422277 1004.089985829100001 1000.213063460895686761256364060000null3.1622776985168457 Sun,25Oct18falsenull 10001.7787866165050987 VMIL:TalkDougSimon1 10000.5506260932508577 1005.7609373272563795 1005.158519929100001 1001.53265623122379551256450460000null3.1622776985168457 Mon,26Oct18falsenull 10000.3331617412368396 10001.1395411449229018 1009.570295529017931 10012.4675606892 1000.7310282025720101 10.30am:LivelyWikiPresentationWikiSym17.27999999999999831256536860000null1.9317231178283691 Tue,27Oct18falsenull 10001.5692054429543238 10000.7684180670627975 1009.963717169525609 1003.96411822 1001.093392574331811 1003.8945400883060217OOPSLA20.735999999999997 1256623260000null1.9027395248413086 Wed,28Oct18falsenull 10002.792751054657846 10000.025660427666994428 1008.455334402375764 1007.8785786601000005 1000.3861756056668028 1000.19502168974740305 1000.23744616240188374OOPSLA20.735999999999997 1256709660000null1.9027395248413086 Thu,29Oct18falsenull 10001.581832825567023 10000.8639183129758796 10010.312975480015876 1004.541430978 1001.6566374648015703 Flightback1256796060000null3.1622776985168457 Fri,30Oct18falsenull 10000.15023517120387309 10000.2811844028499233 1008.27049443701924 1006.8698117892 1000.226808929893052931256882460000null Sat,31Oct18falsenull 10000.3987744331328073 10000.574450211400161 1003.6875229256147146 1004.8155929902 1000.73432178205676991256968860000null 10000.000028915650003023977 1000.5593081102533294 1000.6561000000000001 1002.035689599633559Wikicontrol12truenull0 10000.2102562741916294 1001.134801030976816 1000.38742048900000015 1001.4640084237801947Wikicontrol12truenull0 10002.1121055230641854 1000.38742048900000015 1000.07405402285185514Wikicontrol12truenull0 Thu,01Oct18falsenull 10002.322537866123725 10002.594877363780637 10018.965871816844558 1005.411258389 1001.06889348924098541254376860000null Fri,02Oct18falsenull 10001.2441820167983737 10000.9422484140872553 1009.970239786176773 1004.452027650100001 1000.49853471823054271254463260000null1.2719085216522217null Sat,03Oct18falsenull 10001.2110645716620092 10000.6097954184677783 1008.49848325602414 1002.5761437802000007 1001.09347441698340591254549660000null Sun,04Oct18falsenull 10001.4774180799332604 10001.2018644333831259 1007.6096340700935015 10022.6466176501 1000.27993604153814851254636060000nullnull3.1622776985168457 10002.618822927576473 1000 1001.3588505324028453Wikicontrol12truenull0 10000.03055921753917457Wikicontrol12truenull0 10000.8555799258255476Wikicontrol0falsetruenullnull23