seanyo / Hello-I-Tweet-As

Name Tags are Back...in Twitter Form! Twitter's the New Name Tag!
itweet.as
2 stars 2 forks source link

Text doesn't scale based on length #4

Closed seanyo closed 13 years ago

seanyo commented 13 years ago

Clearly not a bug - but it is a todo.

To allow shorter IDs to be bigger, but not have longer IDs wrap or extend past the nametag, lets check the length of display strings and then set the font-size based on that.

I am planning on making this a function that takes a string and returns a number to be used as the px value for the font-size attribute. It will be called after each variable is set while inspecting the json object.

ccharles commented 13 years ago

With the move to canvas text should now either wrap-and-truncate or shrink to fit in its space.

See commit 7b7e00c6bc48ec4174d427fd99a3b96bad03c07d