Download it now!
Bug 85102 - FORMATTING: Autoformat straight quotes using the Search and replace dialog
Summary: FORMATTING: Autoformat straight quotes using the Search and replace dialog
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
(earliest affected)
Hardware: All All
: medium enhancement
Assignee: Not Assigned
Depends on:
Blocks: Find&Replace-Dialog
  Show dependency treegraph
Reported: 2014-10-16 17:25 UTC by Adrià
Modified: 2019-08-13 18:50 UTC (History)
0 users

See Also:
Crash report or crash signature:


Note You need to log in before you can comment on or make changes to this bug.
Description Adrià 2014-10-16 17:25:49 UTC
==This is not a bug, it is an enhancement request==

Problem description: The problem is not related to the autocorrect options under the Tools menu, since this option applies to newly inserted quotation marks. The problem has to do with all the straight quotation marks (both double " and simple ') of a text and their replacement by formatted quotation marks using the Search and replace function.

Steps to reproduce:
(with straight quotation marks, simple or double, in a text)
1. Search and replace
2. Search with regular expressions ("\< for opening quotes and \>" for closing quotes)
3. Replace by formatted quotes (“ and ”)

Current behavior:
In order to replace straight quotes by formatted quotes using the Search and replace dialog, opening and closing quotes must be replaced separately, since otherwise all quotes (opening and closing) will be replaced by the same character. To this end, the only way as far as I know, is using regular expressions to find opening and closing quotes separately. I would search firstly the opening quotes of a text (and therefore, with characters to the right) by searching "\< (regular expressions enabled) and replace them with formatted opening quotes (“). After that I would search the closing quotes (or, at this point, the remaining straight quotes of a text) by searching \>" (regular expressions enabled) and replace them with formatted closing quotes (”).

Expected behavior:
It would be really handy if the search and replace function could automatically detect whether the straight quotes should have opening or closing format according to the presence or the absence of characters to the left and to right and format them automatically, without the need of regular expressions. MSWord allows users to autoformat quotes by searching and replacing quotes by the exactly same character. Please see the Note in the following link:

Thank you very much for your attention and your time. This is my first submission and hope everything is understandable.
Comment 1 Adolfo Jayme 2014-10-18 02:55:35 UTC
Thank you for your clear, detailed report.