lehitoskin / ivy

Ivy, the Taggable Image Viewer
GNU General Public License v3.0
16 stars 3 forks source link

Truncate very long titles #62

Closed lehitoskin closed 7 years ago

lehitoskin commented 7 years ago

The program will throw a contract error if the title of the file is too long, so truncate it at a certain point.

IonoclastBrigham commented 7 years ago

What contract is it violating?

lehitoskin commented 7 years ago

It violated the label-string? for label in frame%. (label-string? v) Returns #t if v is a string whose length is less than or equal to 200.

Everything else is probably fine. We don't need to do anything special for file names in the database or thumbnail names (I think). It's just the label can't be too long.