Date: prev next · Thread: first prev next last
2022 Archives by date, by thread · List index


Hi jomali,

Would you care to elaborate and provide links?

Dave

On 16/03/2022 22:04, jomali wrote:
I just looked at LibreOffice help, searched for Regular Expressions,
selected the list of regular expressions, and found all of the info you are
looking for..

On Wed, Mar 16, 2022 at 5:55 PM Dave Barton <daveb@libreoffice.org> wrote:


Fantastic, but why does the LO project *_NOT_* inform it's users about
this *_HIDDEN_* option?

Please provide links to the the TDF/LO Help/Documentation files that
provide this information to our users.

-------- Original Message --------
From: Michael D. Setzer II [mailto:msetzerii@gmail.com]
Sent: Wednesday, March 16, 2022, 20:53 UTC
To: Dave Barton; users@global.libreoffice.org
Subject: [libreoffice-users] Help with find & replace.

On 16 Mar 2022 at 20:41, Dave Barton wrote:

Subject:              Re: [libreoffice-users] Help with find &
replace.
To:                   users@global.libreoffice.org
From:                 Dave Barton <daveb@libreoffice.org>
Date sent:            Wed, 16 Mar 2022 20:41:43 +0000

On 16/03/2022 20:01, Steve Edmonds wrote:


On 17/03/2022 08:34, Dave Barton wrote:
On 16/03/2022 18:27, Brian Barker wrote:
At 16:29 16/03/2022 +0000, Dave Barton wrote:
I am looking for a find & replace solution in Writer, where there
is a
blank space as the last character of a paragraph (eg. last word
<space><LF><CR>). In the original OOo and most of the text editors I
use the simple solution that worked/works perfectly is: Find =
<space>$ Replace = $ (Note: I use <space> here to represent a single
space character). This does not work in LO Writer, so I am forced to
fiddle around copying from LO and pasting into AOO, running F&R in
AOO, then copy/paste back again. Any pointers would be welcome.
I'm surprised that exactly what you say works in OpenOffice. Don't
you
need to find space-dollar, just as you describe, but to replace with
nothing? Replacing with dollar will surely insert an unwanted dollar
character?

Or have you forgotten to click "Other options" in the Find and
Replace
dialogue and to tick "Regular expressions"?

I trust this helps.

Brian Barker
Hi Brian,

After 22 Years of you and I being involved in this project, I
genuinely
bow to your superior knowledge in this area. However, I do assure you
that the convoluted LO->AOO->LO� nonsense works for me, exactly as it
did in the days of OOo.

No, I have not forgotten to click "Other options in the Find and
Replace
dialogue and to tick "Regular expressions", please see my screen
capture:
https://www.mediafire.com/view/80552jkp3qw6o8x/F%2526R_LO.png/file

Here is a very simplistic file illustrating the <space><CR><LF>
paragraph endings:
https://www.mediafire.com/file/vmixa9r4dhjpc9e/F%2526R_LO.odt/file

Version: 7.3.1.3 (x64) / LibreOffice Community
Build ID: a69ca51ded25f3eefd52d7bf9a5fad8c90b87951
CPU threads: 8; OS: Windows 10.0 Build 19043; UI render: default; VCL:
win
Locale: es-ES (en_IE); UI: en-US
Calc: threaded

If you can please show me where I am going wrong, I would be extremely
grateful.

Dave Barton


May be this is sorted and I have received the emails out of order, but
assuming you just want to remove the trailing space from each line,
both
Johnny's and Michael's methods work for me on your sample file.

Find= [:space:]{1,}$
Replace= empty

Find= <space>$
Replace= empty

Use regular expression= checked
Steve


Thanks Steve, but no it's NOT sorted.

You have "Kinda" given me 1/2 a clue.

What does {.1.} mean?

file:///opt/libreoffice7.3/help/en-US/text/shared/01/02100001.html?&DbPAR=WRITER

{N}

The post-fix repetition operator that specifies an exact
number of occurrences ("N") of the regular expression
term immediately preceding it must be present for a
match to occur. For example, "tre{2}" matches "tree".

{N,M}
 The post-fix repetition operator that specifies a range
(minimum of "N" to a maximum of "M") of occurrences of
the regular expression term immediately preceding it
that can be present for a match to occur. For example,
"tre{1,2}" matches "tre" and "tree".

{N,}

The post-fix repetition operator that specifies a range
(minimum "N" to an unspecified maximum) of
occurrences of the regular expression term immediately
preceding it that can be present for a match to occur.
(The maximum number of occurrences is limited only by
the size of the document). For example, "tre{2,}"
matches "tree", "treee", and "treeeee".

So, [:space:]{1,}$ matches one or more spaces at end of
line.
<space>{1,}$ does the same with <space> actually
being a single space.

In all my researching of regular expressions, I have never encountered
this option. The wonderful thing about *_STANDARDS_* is that there are
such a wide variety of different ones to randomly chose and use.

Dave




--
To unsubscribe e-mail to: users+unsubscribe@global.libreoffice.org
Problems?
https://www.libreoffice.org/get-help/mailing-lists/how-to-unsubscribe/
Posting guidelines + more: https://wiki.documentfoundation.org/Netiquette
List archive: https://listarchives.libreoffice.org/global/users/
Privacy Policy: https://www.documentfoundation.org/privacy




-- 
To unsubscribe e-mail to: users+unsubscribe@global.libreoffice.org
Problems? https://www.libreoffice.org/get-help/mailing-lists/how-to-unsubscribe/
Posting guidelines + more: https://wiki.documentfoundation.org/Netiquette
List archive: https://listarchives.libreoffice.org/global/users/
Privacy Policy: https://www.documentfoundation.org/privacy

Context


Privacy Policy | Impressum (Legal Info) | Copyright information: Unless otherwise specified, all text and images on this website are licensed under the Creative Commons Attribution-Share Alike 3.0 License. This does not include the source code of LibreOffice, which is licensed under the Mozilla Public License (MPLv2). "LibreOffice" and "The Document Foundation" are registered trademarks of their corresponding registered owners or are in actual use as trademarks in one or more countries. Their respective logos and icons are also subject to international copyright laws. Use thereof is explained in our trademark policy.