Change formatted string

Is it possible in LibreOffice to replace italic string something to unformatted string delimited with two characters, e.g. to /something/ ?

Do you want to replace all the text ranges formatted italic in the described way?
Shall italic text be replaced only if the attribute italic is applied by hard formatting or also if a respective named caharacter style is applied? If a style was used to make the text italic: Do you want to set a different style?
Generally: Describe to much more detail what you actually want/need.

Yes, I want to replace the text ranges formatted italic in the described way.
If a text of any style is italic, it should be replaced by the unformatted text delimited by two slashes.

For which reason? Do you want to export Writer formatted text to some application using exotic formatting directives?

Yes. Actually my main goal is to convert an odt file to tex.

I never did something of the kind, but I verified with V7.1.1.1 that the F&R tool can be used to do it. Unfortunately a complete instruction would get lengthy. Therefore I will assume you are a clever and experienced user, and only give some hints.

  1. Call F&R and choose Format...
  2. Select Italic there, but nothing else. OK
  3. Enable Including Styles in the F&R window.
  4. Find All.
    Do not touch the text itself now! The findings will be shown as multiselection.
  5. Enable Regular expressions and Current selection only.
  6. Click No Format.
  7. Enter (.*) behind Find:.
  8. Enter /$1/ behind Replace:.
  9. Replace All.
  10. Assign the Default character style (not Italic!) to the still selected findings.
  11. If still some text is italic due to hard attributes hit Ctrl+I twice.

(Untested) The proceeding may fail for itralic text associated with TextField objects by automatisms.
Good luck.

This exactly does what I want - thank you for the help!

For such a conversion, I recommend you query the extension site with “latex” keyword.

This is much easier than trying to implement a procedure yourself.

To show the community your question has been answered, click the ✓ next to the correct answer, and “upvote” by clicking on the ^ arrow of any helpful answers. These are the mechanisms for communicating the quality of the Q&A on this site. Thanks!

In case you need clarification, edit your question (not an answer which is reserved for solutions) or comment the relevant answer.