public string GetMediaInfo(string p, PublishOptionsPacket options) { StringBuilder sbPublish = new StringBuilder(); if (options.AlignCenter) { p = BbCode.AlignCenter(p); } if (options.PreformattedText) { sbPublish.AppendLine(BbCode.Pre(p)); } else { sbPublish.AppendLine(p); } return(sbPublish.ToString()); }
private static string BbFormat(string p, PublishOptions options) { StringBuilder sbPublish = new StringBuilder(); if (options.AlignCenter) { p = BbCode.AlignCenter(p); } if (options.PreformattedText) { sbPublish.AppendLine(BbCode.Pre(p)); } else { sbPublish.AppendLine(p); } return(sbPublish.ToString().Trim()); }