questions about search/replace
Oxygen general issues.
-
- Posts: 26
- Joined: Mon Mar 04, 2013 1:42 pm
questions about search/replace
Hi,
Is there a way to search text and replace it surrounded by tags in author mode ? (I would prefer my users not to use text mode)
For instance to replace 'blabla' by 'blabla' in italic using html tag <i/>.
When in search/replace 'case sensitive' is uncheched, replace does not keep initial capital letters on words as Word does, for instance if I search 'tps' and want to replace by 'tapas', all 'Tps' are replaced by 'tapas' and not 'Tapas'. In fact the case in insensitive on search but sensitive on replace. Is there a way to mimic Word behaviour ?
Best regards,
Lionel
Is there a way to search text and replace it surrounded by tags in author mode ? (I would prefer my users not to use text mode)
For instance to replace 'blabla' by 'blabla' in italic using html tag <i/>.
When in search/replace 'case sensitive' is uncheched, replace does not keep initial capital letters on words as Word does, for instance if I search 'tps' and want to replace by 'tapas', all 'Tps' are replaced by 'tapas' and not 'Tapas'. In fact the case in insensitive on search but sensitive on replace. Is there a way to mimic Word behaviour ?
Best regards,
Lionel
-
- Posts: 2879
- Joined: Tue May 17, 2005 4:01 pm
Re: questions about search/replace
Hi,
The only way of mimicking the Word behavior in Find/Replace is to use a regular expression, but this only works if you keep the same first letter. This lets you keep it as it is, capitalized or not.
e.g. tps -> tapas (keep t/T capitalization)
Text to find: (t)ps
Replace with: $1apas
Regards,
Adrian
You could use the 'Find/Replace in Files' to replace 'blabla' with '<i>blabla</i>', but note that it actually processes the content of the files from the file system, not the content of the editors, so the edited files must be saved first if there are pending changes. You will be prompted to save the modified files when you use the 'Find/Replace in Files' dialog.LBarth wrote:Is there a way to search text and replace it surrounded by tags in author mode ? (I would prefer my users not to use text mode)
For instance to replace 'blabla' by 'blabla' in italic using html tag <i/>.
The 'Case sensitive' option from the Find/Replace dialog refers to the searched text. If 'Case sensitive' is enabled the searched text must be an exact match.LBarth wrote:When in search/replace 'case sensitive' is uncheched, replace does not keep initial capital letters on words as Word does, for instance if I search 'tps' and want to replace by 'tapas', all 'Tps' are replaced by 'tapas' and not 'Tapas'. In fact the case in insensitive on search but sensitive on replace. Is there a way to mimic Word behaviour ?
The only way of mimicking the Word behavior in Find/Replace is to use a regular expression, but this only works if you keep the same first letter. This lets you keep it as it is, capitalized or not.
e.g. tps -> tapas (keep t/T capitalization)
Text to find: (t)ps
Replace with: $1apas
Regards,
Adrian
Adrian Buza
<oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger
http://www.oxygenxml.com
<oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger
http://www.oxygenxml.com
Jump to
- Oxygen XML Editor/Author/Developer
- ↳ Feature Request
- ↳ Common Problems
- ↳ DITA (Editing and Publishing DITA Content)
- ↳ SDK-API, Frameworks - Document Types
- ↳ DocBook
- ↳ TEI
- ↳ XHTML
- ↳ Other Issues
- Oxygen XML Web Author
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Content Fusion
- ↳ Feature Request
- ↳ Common Problems
- Oxygen JSON Editor
- ↳ Feature Request
- ↳ Common Problems
- Oxygen PDF Chemistry
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Feedback
- ↳ Feature Request
- ↳ Common Problems
- Oxygen XML WebHelp
- ↳ Feature Request
- ↳ Common Problems
- XML
- ↳ General XML Questions
- ↳ XSLT and FOP
- ↳ XML Schemas
- ↳ XQuery
- NVDL
- ↳ General NVDL Issues
- ↳ oNVDL Related Issues
- XML Services Market
- ↳ Offer a Service