Get rid of some more warnings regarding conversions. Also make the truncateAt function take a size_t param, size having a negative frame to truncate doesn't make sense