protected void FormatMessage(TitleBuilder title, BooruPost.Rating rated, string warning, int postNo) { string rating = ResolveRating(rated); title.SetFormat("{0}[{1}]", NormalCode, rating); title.Append(warning).AppendFormat("[ #{0} ]", postNo); }
static void FormatBinaryInfo(TitleBuilder title, string content, MediaProperties media, long length) { if (media.Dimensions.Width > 0 && media.Dimensions.Height > 0) { title.SetFormat("[ {0}: {1}x{2} ]", content, media.Dimensions.Width, media.Dimensions.Height); title.AppendTime(media.Duration); if (media.HasAudio) { title.Append('♫'); } title.AppendSize(length); } else { title.SetFormat("[ {0} ]", content).AppendSize(length); } }