Hello, |
Re: carriage returns and diff() function But I wonder what would happen if you replaced all the existing EOLs in the two texts with <EOL> followed by an EOL; you could then I suppose see which ones have been inserted, although you have the problem of seeing unmodified "<EOL>" in places that have not changed.
|
Re: carriage returns and diff() function llandale - Wed Oct 12 18:26:27 EDT 2011
Is there no built-in find and replace function within DXL? Also when searching for '\r' I can't find any '\r' does DOORS only use '\n' for carriage returns (Enter Key)? Thank you, Jim |
Re: carriage returns and diff() function SystemAdmin - Thu Oct 13 02:04:48 EDT 2011 The text is stored as RTF and thus the \r and \n are converted to RTF formatting. |
Re: carriage returns and diff() function OurGuest - Thu Oct 13 06:21:55 EDT 2011 Mathias Mamsch, IT-QBase GmbH, Consultant for Requirement Engineering and D00RS |
Re: carriage returns and diff() function Mathias Mamsch - Thu Oct 13 09:12:57 EDT 2011 Mathias Mamsch, IT-QBase GmbH, Consultant for Requirement Engineering and D00RS |
Re: carriage returns and diff() function SystemAdmin - Thu Oct 13 02:04:48 EDT 2011 It does not make sense to me to do a "diff" on rich text; I wonder how you should show the difference between "shall" and "shall" with underscores and strikeouts; or worse yet End of lines in the raw text are equal to '\n'; as are I believe line-feed. I don't think I've ever retrieved raw text from an object and seen an '\r' character; but maybe someone will prove me wrong. Paragraph characters in word are the object boundaries when imported into DOORS. LF characters are preserved in the same object, but become '\n' characters once in DOORS.
When I first started with DOORS I was tasked with changing all reference of "ITT" to "ITTL" in all the requirements. Well, if you do that twice you end up with "ITTLL", so I had to enhance my 'replace' function to handle when the search string is a sub-set of the replace-string, and not do the replace when its already in the code. Sometime later I ran into the problem of looking for rich text tags e.g. "\\par ", when I realized that its not a paragraph definition when it looks like "\\\par ", but again it is when its "\\\\par ". Yuuuck. I saw the quagmire and confinced the powers to do something else. |