B2019-037 added logic to replace ~ and # characters with superscript and subscript commands
This commit is contained in:
@@ -216,11 +216,18 @@ namespace VEPROMS.CSLA.Library
|
||||
// return null;
|
||||
//}
|
||||
|
||||
public string GetTranslatedRoValue(string ROID16, bool DoCaret)
|
||||
public string GetTranslatedRoValue(string ROID16, bool DoCaret, bool DoDOSSuperSubScript)
|
||||
{
|
||||
string retval = GetRoValue(ROID16);
|
||||
retval = ReplaceUnicode(retval, DoCaret);
|
||||
retval = ConvertFortranFormatToScienctificNotation(retval);
|
||||
// B2019-037 handle the super an sub scripts after getting the RO value from the FST
|
||||
// the corrected RO text is added to the display text in the link info
|
||||
if (DoDOSSuperSubScript)
|
||||
{
|
||||
retval = Regex.Replace(retval, "[#](.*?)[#]", "\\up2 $1\\up0 ");// Superscript
|
||||
retval = Regex.Replace(retval, "[~](.*?)[~]", "\\dn2 $1\\up0 ");// Subscript
|
||||
}
|
||||
return retval.Replace("\r\n", @"\par ");
|
||||
}
|
||||
private string ReplaceUnicode(string s2, bool DoCaret)
|
||||
|
Reference in New Issue
Block a user