Yup, that did the trick -- thank you. BTW, I wasn't able to figure out how to get it working with the libraries download -- I had to go to the src download and then copy the api directory out of src/webapp/. I can't tell from the README whether that is intended. Based on the names, I expected the libraries package to be a drop-in package that I could unzip and deploy. However, it looks like there are some key things missing from timeline_js/ directory such as the styles/ directory that is present in the api/ dir. So is the recommended deployment to go straight to the source download?
In any case, it is working great now -- thanks for helping resolve this so quickly! Ramon On Oct 4, 6:36 pm, LarryK <[EMAIL PROTECTED]> wrote: > Hi Ramon, > > The problem is that you're not using the current release of Timeline. > Use either release 2.2.0 (current release) or the trunk version. > Release 2.2.0 is available > here:http://simile-widgets.googlecode.com/svn/timeline/tags/2.2.0/ > > It does NOT wrap long labels on FF3/Win, Safari/Win, Chrome/Win, IE7/ > Win, Safari/Mac. It does wrap long labels on FF3/Mac > > Regards, > > Larry > > On Oct 3, 8:29 pm, felciano <[EMAIL PROTECTED]> wrote: > > > I'm using Firefox 3 on Windows, and have reproduced this in IE7 on > > Windows as well. > > > The JSON and HTML below reproduce the problem. The HTML is based > > closely on the sample code on the wiki, and the JSON is very simple, > > but with long titles. On my screen, "This is not an unusually long > > title but you probably can't read the end of it" is truncated to "This > > is not an unusually long title". If you look closely, it looks like > > the contents are wrapping. > > > <html> > > <head> > > <title>Broken Timeline</title> > > <span style="background:#FFFFE0"> > > <script src="http://simile.mit.edu/timeline/api/timeline-api.js" > > type="text/javascript"></script> > > </span> > > <script> > > var tl; > > function onLoad() { > > var eventSource = new Timeline.DefaultEventSource(); > > var bandInfos = [ > > Timeline.createBandInfo({ > > eventSource: eventSource, > > width: "70%", > > intervalUnit: Timeline.DateTime.HOUR, > > intervalPixels: 100 > > }), > > Timeline.createBandInfo({ > > eventSource: eventSource, > > showEventText: false, > > width: "20%", > > intervalUnit: Timeline.DateTime.DAY, > > intervalPixels: 200 > > }) > > ]; > > bandInfos[1].syncWith = 0; > > bandInfos[1].highlight = true; > > > bandInfos[1].eventPainter.setLayout(bandInfos[0].eventPainter.getLayout()); > > > tl = Timeline.create(document.getElementById("my-timeline"), > > bandInfos); > > > tl.loadJSON("broken-events.js", function(json, url) { > > eventSource.loadJSON(json, url); > > }); > > > } > > > var resizeTimerID = null; > > function onResize() { > > if (resizeTimerID == null) { > > resizeTimerID = window.setTimeout(function() { > > resizeTimerID = null; > > tl.layout(); > > }, 500); > > } > > } > > </script> > > </head> > > <body onload="onLoad();" onresize="onResize();"> > > <div id="my-timeline" style="height: 550px; border: 1px solid > > #aaa"></div> > > </body> > > </html> > > > { > > 'dateTimeFormat': 'iso8601', > > 'events': [ > > { > > 'start':"2008-10-04 00:00:00 -0600", > > 'title':"This is my example and it is actually very long" > > }, { > > 'start':"2008-10-04 00:00:00 -0600" , > > 'end':"2008-10-05 00:00:00 -0600" , > > 'title':"This is not an unusually long title but you probably > > can't read the end of it" > > } > > ] > > > } > > > On Oct 3, 4:03 pm, LarryK <[EMAIL PROTECTED]> wrote: > > > > Hi Ramon, > > > > AFAIK, labels should never be wrapped. There's a known bug (see the > > > Timeline release notes) with label wrapping occurring on Firefox 3 for > > > Mac. Which browser and platform are you using? > > > > For example, some of the titles on the Kennedy example are quite long > > > and they don't wrap. > > > Eg, this label does not wrap: > > > > If time flies when you're having fun, it hits the afterburners when > > > you don't think you're having enough. > > > > (I'm adding the above as another test in the test timeline.) > > > Exactly how long are your labels that are wrapping? > > > > How label widths are calculated: > > > The original-painter.js file sets an explicit .style.width property > > > -- see Timeline.OriginalEventPainter.prototype._paintEventLabel > > > > The div width is determined by first loading a hidden span with the > > > title, then seeing what its width is. This measurement is done by > > > SimileAjax.Graphics._FontRenderingContext.prototype.computeSize in > > > file graphics.js (in the ajax tree, not timeline tree). > > > > The span used for the measuring is created by original-painter.js in > > > function Timeline.OriginalEventPainter.prototype._prepareForPainting > > > -- note the section that culminates in the call to this._frc = > > > SimileAjax.Graphics.getFontRenderingContext(eventLabelPrototype); > > > > Regards, > > > > Larry > > > > On Oct 3, 5:49 pm, felciano <[EMAIL PROTECTED]> wrote: > > > > > Hi -- > > > > > Is there a Timeline setting that controls the width or truncation > > > > point for displayed event labels? Events with long titles appear > > > > truncated, or wrapped around to a 2nd line that isn't visible in the > > > > timeline. Is that configurable? > > > > > In case it matters, I've noticed this is a particular problem when > > > > there the label has very_long_words_in_it (I am visualizing code > > > > elements, so there are long variable names w underscores). > > > > > Thanks, > > > > > Ramon > > --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "SIMILE Widgets" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/simile-widgets?hl=en -~----------~----~----~----~------~----~------~--~---
