summaryrefslogtreecommitdiff
path: root/tikzit/src/common/NSString+Util.h
AgeCommit message (Collapse)Author
2013-08-07Add variant of stringWithContentsOfFile that produces an errorAlex Merry
It turns out that the [NSString stringWithContentsOfFile:] family of methods do not have a way of reporting why a file could not be read; [NSString stringWithContentsOfFile:usedEncoding:error:] will only set the error object if there was a problem with decoding. So, we cook our own variant that tries to figure out why opening the file failed. User-visible effect: in the GTK+ port, if you try to open a file from the "open recent" menu that no longer exists, you will get a more helpful error message.