James Tauber

journeyman of some

blog > 2006 > 01 >

James Tauber's Blog 2006/01/28

Dynamic Interlinears with Javascript and CSS

After the continuation of a permathread on the b-greek mailing list about the pros and cons of interlinears, I built some quick demonstrations of how CSS and Javascript could be used for dynamic interlinear glosses that would not be possible on the printed page.

  • Plain — show static glosses
  • Hover — show glosses when a word is hovered over
  • Toggle — toggle showing a gloss when a word is clicked
  • Frequency — filter appearance of gloss by frequency

They might be interesting as little Javascript tutorials too.

by jtauber : Created on Jan. 28, 2006 : Last modified Jan. 28, 2006 : Categories linguistics javascript css : 5 comments (permalink)

Javascript in IE

Nathan Vander Wilt has been helping me with my Javascript for Quisition in IE.

From him I've learnt a couple of key things recently:

  • don't name your variables the same as your element IDs
  • ['a', 'b', 'c', 'd',] has 4 elements in Firefox and Safari but 5 in IE (note the final comma)

Thanks Nathan! I've now (hopefully) fixed the Quisition Short-Term Test Demo for IE users.

I still have some suggestions from Tim Wegener to implement.

by jtauber : Created on Jan. 28, 2006 : Last modified Jan. 28, 2006 : Categories quisition javascript : 0 comments (permalink)

More or Less

Yesterday I saw James Marcus using 'more' on the command line and I asked him why he didn't use 'less'. He responded by asking me why people use 'less' and not 'more'.

I use 'less' out of habit because when I started using Unix 13 years ago it wasn't the same as 'more'—it was more.

But I guess somewhere along the line, the old 'more' disappeared and the new 'more' became the same as 'less'. So if you want 'less' now you can just use 'more'.

I figured it's probably a symbolic link, just like 'sh' is often a symlink to 'bash'.

I just checked on Mac OS X and, sure enough, 'less' is 'more'; but it's actually a hard link, not a symbolic link.

In contrast, 'sh' and 'bash' on Mac OS X are distinct files but with the same content.

Go figure.

by jtauber : Created on Jan. 28, 2006 : Last modified Jan. 28, 2006 : Categories unix : 1 comment (permalink)