1cdf0e10cSrcweir<?xml version="1.0" encoding="UTF-8"?>
2cdf0e10cSrcweir
3ce44d6c1SAndrew Rist<!--***********************************************************
4*1b580e6cSmseidel *
5ce44d6c1SAndrew Rist * Licensed to the Apache Software Foundation (ASF) under one
6ce44d6c1SAndrew Rist * or more contributor license agreements.  See the NOTICE file
7ce44d6c1SAndrew Rist * distributed with this work for additional information
8ce44d6c1SAndrew Rist * regarding copyright ownership.  The ASF licenses this file
9ce44d6c1SAndrew Rist * to you under the Apache License, Version 2.0 (the
10ce44d6c1SAndrew Rist * "License"); you may not use this file except in compliance
11ce44d6c1SAndrew Rist * with the License.  You may obtain a copy of the License at
12*1b580e6cSmseidel *
13ce44d6c1SAndrew Rist *   http://www.apache.org/licenses/LICENSE-2.0
14*1b580e6cSmseidel *
15ce44d6c1SAndrew Rist * Unless required by applicable law or agreed to in writing,
16ce44d6c1SAndrew Rist * software distributed under the License is distributed on an
17ce44d6c1SAndrew Rist * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
18ce44d6c1SAndrew Rist * KIND, either express or implied.  See the License for the
19ce44d6c1SAndrew Rist * specific language governing permissions and limitations
20ce44d6c1SAndrew Rist * under the License.
21*1b580e6cSmseidel *
22ce44d6c1SAndrew Rist ***********************************************************-->
23ce44d6c1SAndrew Rist
24*1b580e6cSmseidel<helpdocument version="1.0">
25cdf0e10cSrcweir<meta>
26*1b580e6cSmseidel<topic id="textshared0102100001xml" indexer="include" status="PUBLISH">
27*1b580e6cSmseidel<title xml-lang="en-US" id="tit">List of Regular Expressions</title>
28*1b580e6cSmseidel<filename>/text/shared/01/02100001.xhp</filename>
29*1b580e6cSmseidel</topic>
30*1b580e6cSmseidel</meta>
31*1b580e6cSmseidel<body>
32*1b580e6cSmseidel<bookmark xml-lang="en-US" branch="index" id="bm_id3146765">
33*1b580e6cSmseidel<bookmark_value>regular expressions; list of</bookmark_value>
34*1b580e6cSmseidel<bookmark_value>lists;regular expressions</bookmark_value>
35*1b580e6cSmseidel<bookmark_value>replacing;tab stops (regular expressions)</bookmark_value>
36*1b580e6cSmseidel<bookmark_value>tab stops;regular expressions</bookmark_value>
37*1b580e6cSmseidel<bookmark_value>concatenation, see ampersand symbol</bookmark_value>
38*1b580e6cSmseidel<bookmark_value>ampersand symbol, see also operators</bookmark_value>
39cdf0e10cSrcweir</bookmark><comment>mw added "replacing;" and "tab stops;"</comment>
40cdf0e10cSrcweir<paragraph xml-lang="en-US" id="hd_id3146765" role="heading" level="1" l10n="U"
41*1b580e6cSmseideloldref="203"><variable id="02100001"><link href="text/shared/01/02100001.xhp">List of Regular Expressions</link>
42cdf0e10cSrcweir</variable></paragraph>
43*1b580e6cSmseidel<table id="tbl_id3149517">
44*1b580e6cSmseidel<tablerow>
45*1b580e6cSmseidel<tablecell>
46*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3149741" role="tablehead" l10n="U" oldref="17">Character</paragraph>
47*1b580e6cSmseidel</tablecell>
48*1b580e6cSmseidel<tablecell>
49*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3155577" role="tablehead" l10n="U" oldref="18">Result/Use</paragraph>
50*1b580e6cSmseidel</tablecell>
51*1b580e6cSmseidel</tablerow>
52*1b580e6cSmseidel<tablerow>
53*1b580e6cSmseidel<tablecell>
54*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id6600543" role="tablecontent" l10n="NEW">Any character</paragraph>
55*1b580e6cSmseidel</tablecell>
56*1b580e6cSmseidel<tablecell>
57*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id9824518.00000001" role="tablecontent" l10n="CHG">Represents the given character unless otherwise specified.</paragraph>
58*1b580e6cSmseidel</tablecell>
59*1b580e6cSmseidel</tablerow>
60*1b580e6cSmseidel<tablerow>
61*1b580e6cSmseidel<tablecell>
62*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3152427" role="tablecontent" l10n="U" oldref="19">.</paragraph>
63*1b580e6cSmseidel</tablecell>
64*1b580e6cSmseidel<tablecell>
65*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3149031" role="tablecontent" l10n="CHG" oldref="20">Represents any single character except for a line break or paragraph break. For example, the search term "sh.rt" returns both "shirt" and "short".</paragraph>
66*1b580e6cSmseidel</tablecell>
67*1b580e6cSmseidel</tablerow>
68*1b580e6cSmseidel<tablerow>
69*1b580e6cSmseidel<tablecell>
70*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3154682" role="tablecontent" l10n="CHG" oldref="21">^</paragraph>
71*1b580e6cSmseidel</tablecell>
72*1b580e6cSmseidel<tablecell>
73*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3155351" role="tablecontent" l10n="CHG" oldref="22">Only finds the search term if the term is at the beginning of a paragraph. Special objects such as empty fields or character-anchored frames, at the beginning of a paragraph are ignored. Example: "^Peter".</paragraph>
74*1b580e6cSmseidel</tablecell>
75*1b580e6cSmseidel</tablerow>
76*1b580e6cSmseidel<tablerow>
77*1b580e6cSmseidel<tablecell>
78*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3159194" role="tablecontent" l10n="CHG" oldref="23">$</paragraph>
79*1b580e6cSmseidel</tablecell>
80*1b580e6cSmseidel<tablecell>
81*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3152542" role="tablecontent" l10n="CHG" oldref="24">Only finds the search term if the term appears at the end of a paragraph. Special objects such as empty fields or character-anchored frames at the end of a paragraph are ignored. Example: "Peter$".</paragraph>
82*1b580e6cSmseidel</tablecell>
83*1b580e6cSmseidel</tablerow>
84*1b580e6cSmseidel<tablerow>
85*1b580e6cSmseidel<tablecell>
86*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3156414" role="tablecontent" l10n="U" oldref="25">*</paragraph>
87*1b580e6cSmseidel</tablecell>
88*1b580e6cSmseidel<tablecell>
89*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3155555" role="tablecontent" l10n="CHG" oldref="26">Finds zero or more of the characters in front of the "*". For example, "Ab*c" finds "Ac", "Abc", "Abbc", "Abbbc", and so on.</paragraph>
90*1b580e6cSmseidel</tablecell>
91*1b580e6cSmseidel</tablerow>
92*1b580e6cSmseidel<tablerow>
93*1b580e6cSmseidel<tablecell>
94*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3147399" role="tablecontent" l10n="U" oldref="27">+</paragraph>
95*1b580e6cSmseidel</tablecell>
96*1b580e6cSmseidel<tablecell>
97*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3157958" role="tablecontent" l10n="CHG" oldref="28">Finds one or more of the characters in front of the "+". For example, "AX.+4" finds "AXx4", but not "AX4".</paragraph>
98*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3145313" role="tablecontent" l10n="U" oldref="207">The longest possible string that matches this search pattern in a paragraph is always found. If the paragraph contains the string "AX 4 AX4", the entire passage is highlighted.</paragraph>
99*1b580e6cSmseidel</tablecell>
100*1b580e6cSmseidel</tablerow>
101*1b580e6cSmseidel<tablerow>
102*1b580e6cSmseidel<tablecell>
103*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3143267" role="tablecontent" l10n="U" oldref="199">?</paragraph>
104*1b580e6cSmseidel</tablecell>
105*1b580e6cSmseidel<tablecell>
106*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3153684" role="tablecontent" l10n="CHG" oldref="200">Finds zero or one of the characters in front of the "?". For example, "Texts?" finds "Text" and "Texts" and "x(ab|c)?y" finds "xy", "xaby", or "xcy".</paragraph>
107*1b580e6cSmseidel</tablecell>
108*1b580e6cSmseidel</tablerow>
109*1b580e6cSmseidel<tablerow>
110*1b580e6cSmseidel<tablecell>
111*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3166410" role="tablecontent" l10n="U" oldref="158">\</paragraph>
112*1b580e6cSmseidel</tablecell>
113*1b580e6cSmseidel<tablecell>
114*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3147209" role="tablecontent" l10n="CHG" oldref="159">Search interprets the special character that follows the "\" as a normal character and not as a regular expression (except for the combinations \n, \t, \&gt;, and \&lt;). For example, "tree\." finds "tree.", not "treed" or "trees".</paragraph>
115*1b580e6cSmseidel</tablecell>
116*1b580e6cSmseidel</tablerow>
117*1b580e6cSmseidel<tablerow>
118*1b580e6cSmseidel<tablecell>
119*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3152945" role="tablecontent" l10n="U" oldref="166">\n</paragraph>
120*1b580e6cSmseidel</tablecell>
121*1b580e6cSmseidel<tablecell>
122*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3153700" role="tablecontent" l10n="CHG" oldref="167">Represents a line break that was inserted with the Shift+Enter key combination. To change a line break into a paragraph break, enter <emph>\n</emph> in the <emph>Search for</emph> and <emph>Replace with</emph> boxes, and then perform a search and replace.</paragraph>
123*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id9262672" role="tablecontent" l10n="NEW">\n in the <emph>Search for</emph> text box stands for a line break that was inserted with the Shift+Enter key combination.</paragraph>
124*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id2366100" role="tablecontent" l10n="NEW">\n in the <emph>Replace with</emph> text box stands for a paragraph break that can be entered with the Enter or Return key.</paragraph>
125*1b580e6cSmseidel</tablecell>
126*1b580e6cSmseidel</tablerow>
127*1b580e6cSmseidel<tablerow>
128*1b580e6cSmseidel<tablecell>
129*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3153258" role="tablecontent" l10n="U" oldref="29">\t</paragraph>
130*1b580e6cSmseidel</tablecell>
131*1b580e6cSmseidel<tablecell>
132*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3157809" role="tablecontent" l10n="CHG" oldref="30">Represents a tab. You can also use this expression in the <emph>Replace with</emph> box.</paragraph>
133*1b580e6cSmseidel</tablecell>
134*1b580e6cSmseidel</tablerow>
135*1b580e6cSmseidel<tablerow>
136*1b580e6cSmseidel<tablecell>
137*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3150670" role="tablecontent" l10n="U" oldref="35">\b</paragraph>
138*1b580e6cSmseidel</tablecell>
139*1b580e6cSmseidel<tablecell>
140*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3153666" role="tablecontent" l10n="CHG" oldref="36">Match a word boundary. For example, "\bbook" finds "bookmark" but not "checkbook" whereas "book\b" finds "checkbook" but not "bookmark". The discrete word "book" is found by both search terms.</paragraph>
141*1b580e6cSmseidel</tablecell>
142*1b580e6cSmseidel</tablerow>
143*1b580e6cSmseidel<tablerow>
144*1b580e6cSmseidel<tablecell>
145*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3149576" role="tablecontent" l10n="U" oldref="37">^$</paragraph>
146*1b580e6cSmseidel</tablecell>
147*1b580e6cSmseidel<tablecell>
148*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3151245" role="tablecontent" l10n="CHG" oldref="38">Finds an empty paragraph.</paragraph>
149*1b580e6cSmseidel</tablecell>
150*1b580e6cSmseidel</tablerow>
151*1b580e6cSmseidel<tablerow>
152*1b580e6cSmseidel<tablecell>
153*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3148550" role="tablecontent" l10n="U" oldref="41">^.</paragraph>
154*1b580e6cSmseidel</tablecell>
155*1b580e6cSmseidel<tablecell>
156*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3159413" role="tablecontent" l10n="CHG" oldref="42">Finds the first character of a paragraph.</paragraph>
157*1b580e6cSmseidel</tablecell>
158*1b580e6cSmseidel</tablerow>
159*1b580e6cSmseidel<tablerow>
160*1b580e6cSmseidel<tablecell>
161*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3147282" role="tablecontent" l10n="CHG" oldref="43">&amp; or $0</paragraph>
162*1b580e6cSmseidel</tablecell>
163*1b580e6cSmseidel<tablecell>
164*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3153961" role="tablecontent" l10n="CHG" oldref="44">Adds the string that was found by the search criteria in the <emph>Search for</emph> box to the term in the <emph>Replace with</emph> box when you make a replacement.</paragraph>
165*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3149650" role="tablecontent" l10n="CHG" oldref="201">For example, if you enter "window" in the <emph>Search for</emph> box and "&amp;frame" in the <emph>Replace with</emph> box, the word "window" is replaced with "windowframe".</paragraph>
166*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3150543" role="tablecontent" l10n="CHG" oldref="206">You can also enter an "&amp;" in the <emph>Replace with</emph> box to modify the <emph>Attributes</emph> or the <emph>Format</emph> of the string found by the search criteria.</paragraph>
167*1b580e6cSmseidel</tablecell>
168*1b580e6cSmseidel</tablerow>
169*1b580e6cSmseidel<tablerow>
170*1b580e6cSmseidel<tablecell>
171*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3145419" role="tablecontent" l10n="U" oldref="172">[abc123]</paragraph>
172*1b580e6cSmseidel</tablecell>
173*1b580e6cSmseidel<tablecell>
174*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3154630" role="tablecontent" l10n="CHG" oldref="173">Represents one of the characters that are between the brackets.</paragraph>
175*1b580e6cSmseidel</tablecell>
176*1b580e6cSmseidel</tablerow>
177*1b580e6cSmseidel<tablerow>
178*1b580e6cSmseidel<tablecell>
179*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3156293" role="tablecontent" l10n="U" oldref="174">[a-e]</paragraph>
180*1b580e6cSmseidel</tablecell>
181*1b580e6cSmseidel<tablecell>
182*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3149167" role="tablecontent" l10n="CHG" oldref="175">Represents any of the characters that are between a and e, including both start and end characters</paragraph>
183*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id100520090232005" role="tablecontent" l10n="NEW">The characters are ordered by their code numbers.</paragraph>
184*1b580e6cSmseidel</tablecell>
185*1b580e6cSmseidel</tablerow>
186*1b580e6cSmseidel<tablerow>
187*1b580e6cSmseidel<tablecell>
188*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3155994" role="tablecontent" l10n="U" oldref="176">[a-eh-x]</paragraph>
189*1b580e6cSmseidel</tablecell>
190*1b580e6cSmseidel<tablecell>
191*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3148676" role="tablecontent" l10n="CHG" oldref="177">Represents any of the characters that are between a-e and h-x.</paragraph>
192*1b580e6cSmseidel</tablecell>
193*1b580e6cSmseidel</tablerow>
194*1b580e6cSmseidel<tablerow>
195*1b580e6cSmseidel<tablecell>
196*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3145318" role="tablecontent" l10n="U" oldref="178">[^a-s]</paragraph>
197*1b580e6cSmseidel</tablecell>
198*1b580e6cSmseidel<tablecell>
199*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3153351" role="tablecontent" l10n="CHG" oldref="179">Represents everything that is not between a and s.</paragraph>
200*1b580e6cSmseidel</tablecell>
201*1b580e6cSmseidel</tablerow>
202*1b580e6cSmseidel<tablerow>
203*1b580e6cSmseidel<tablecell>
204*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3156543" role="tablecontent" l10n="U" oldref="180">\xXXXX</paragraph>
205*1b580e6cSmseidel</tablecell>
206*1b580e6cSmseidel<tablecell>
207*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3153768" role="tablecontent" l10n="U" oldref="181">Represents a special character based on its four-digit hexadecimal code (XXXX).</paragraph>
208*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3159252" role="tablecontent" l10n="U" oldref="208">The code for the special character depends on the font used. You can view the codes by choosing <emph>Insert - Special Character</emph>.</paragraph>
209*1b580e6cSmseidel</tablecell>
210*1b580e6cSmseidel</tablerow>
211*1b580e6cSmseidel<tablerow>
212*1b580e6cSmseidel<tablecell>
213*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3153951" role="tablecontent" l10n="U" oldref="186">|</paragraph>
214*1b580e6cSmseidel</tablecell>
215*1b580e6cSmseidel<tablecell>
216*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3154985" role="tablecontent" l10n="CHG" oldref="187">Finds the terms that occur before the "|" and also finds the terms that occur after the "|". For example, "this|that" finds "this" and "that".</paragraph>
217*1b580e6cSmseidel</tablecell>
218*1b580e6cSmseidel</tablerow>
219*1b580e6cSmseidel<tablerow>
220*1b580e6cSmseidel<tablecell>
221*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3147376" role="tablecontent" l10n="U" oldref="209">{2}</paragraph>
222*1b580e6cSmseidel</tablecell>
223*1b580e6cSmseidel<tablecell>
224*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3150103" role="tablecontent" l10n="U" oldref="210">Defines the number of times that the character in front of the opening bracket occurs. For example, "tre{2}" finds and selects "tree".</paragraph>
225*1b580e6cSmseidel</tablecell>
226*1b580e6cSmseidel</tablerow>
227*1b580e6cSmseidel<tablerow>
228*1b580e6cSmseidel<tablecell>
229*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3151289" role="tablecontent" l10n="U" oldref="211">{1,2}</paragraph>
230*1b580e6cSmseidel</tablecell>
231*1b580e6cSmseidel<tablecell>
232*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3147317" role="tablecontent" l10n="CHG" oldref="212">Defines the minimum and maximum number of times that the character in front of the opening bracket can occur. For example, "tre{1,2}" finds and selects "tre" and "tree".</paragraph>
233*1b580e6cSmseidel</tablecell>
234*1b580e6cSmseidel</tablerow>
235*1b580e6cSmseidel<tablerow>
236*1b580e6cSmseidel<tablecell>
237*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id4870754" role="tablecontent" l10n="NEW">{1,}</paragraph>
238*1b580e6cSmseidel</tablecell>
239*1b580e6cSmseidel<tablecell>
240*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id843836" role="tablecontent" l10n="NEW">Defines the minimum number of times that the character in front of the opening bracket can occur. For example, "tre{2,}" finds "tree", "treee", and "treeeee".</paragraph>
241*1b580e6cSmseidel</tablecell>
242*1b580e6cSmseidel</tablerow>
243*1b580e6cSmseidel<tablerow>
244*1b580e6cSmseidel<tablecell>
245*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3148616" role="tablecontent" l10n="U" oldref="213">( )</paragraph>
246*1b580e6cSmseidel</tablecell>
247*1b580e6cSmseidel<tablecell>
248*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id2701803" role="tablecontent" l10n="NEW">In the <emph>Search for</emph> box:</paragraph>
249*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3153573" role="tablecontent" l10n="CHG" oldref="214">Defines the characters inside the parentheses as a reference. You can then refer to the first reference in the current expression with "\1", to the second reference with "\2", and so on.</paragraph>
250*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3156061" role="tablecontent" l10n="U" oldref="215">For example, if your text contains the number 13487889 and you search using the regular expression (8)7\1\1, "8788" is found.</paragraph>
251*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id2367931" role="tablecontent" l10n="NEW">You can also use () to group terms, for example, "a(bc)?d" finds "ad" or "abcd".</paragraph>
252*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id9200109" role="tablecontent" l10n="NEW">In the <emph>Replace with</emph> box:<comment>i83322</comment></paragraph>
253*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id5766472" role="tablecontent" l10n="NEW">Use $ (dollar) instead of \ (backslash) to replace references. Use $0 to replace the whole found string.</paragraph>
254*1b580e6cSmseidel</tablecell>
255*1b580e6cSmseidel</tablerow>
256*1b580e6cSmseidel<tablerow>
257*1b580e6cSmseidel<tablecell>
258*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3154790" role="tablecontent" l10n="U" oldref="226">[:alpha:]</paragraph>
259*1b580e6cSmseidel</tablecell>
260*1b580e6cSmseidel<tablecell>
261*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3147397" role="tablecontent" l10n="CHG" oldref="227">Represents an alphabetic character. Use [:alpha:]+ to find one or more of them.</paragraph>
262*1b580e6cSmseidel</tablecell>
263*1b580e6cSmseidel</tablerow>
264*1b580e6cSmseidel<tablerow>
265*1b580e6cSmseidel<tablecell>
266*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3152885" role="tablecontent" l10n="U" oldref="216">[:digit:]</paragraph>
267*1b580e6cSmseidel</tablecell>
268*1b580e6cSmseidel<tablecell>
269*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3150010" role="tablecontent" l10n="CHG" oldref="217">Represents a decimal digit. Use [:digit:]+ to find one or more of them.</paragraph>
270*1b580e6cSmseidel</tablecell>
271*1b580e6cSmseidel</tablerow>
272*1b580e6cSmseidel<tablerow>
273*1b580e6cSmseidel<tablecell>
274*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3153743" role="tablecontent" l10n="U" oldref="224">[:alnum:]</paragraph>
275*1b580e6cSmseidel</tablecell>
276*1b580e6cSmseidel<tablecell>
277*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3153281" role="tablecontent" l10n="CHG" oldref="225">Represents an alphanumeric character ([:alpha:] and [:digit:]).</paragraph>
278*1b580e6cSmseidel</tablecell>
279*1b580e6cSmseidel</tablerow>
280*1b580e6cSmseidel<tablerow>
281*1b580e6cSmseidel<tablecell>
282*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3153726" role="tablecontent" l10n="U" oldref="218">[:space:]</paragraph>
283*1b580e6cSmseidel</tablecell>
284*1b580e6cSmseidel<tablecell>
285*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3150961" role="tablecontent" l10n="CHG" oldref="219">Represents a whitespace character.</paragraph>
286*1b580e6cSmseidel</tablecell>
287*1b580e6cSmseidel</tablerow>
288*1b580e6cSmseidel<tablerow>
289*1b580e6cSmseidel<tablecell>
290*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3150486" role="tablecontent" l10n="U" oldref="220">[:print:]</paragraph>
291*1b580e6cSmseidel</tablecell>
292*1b580e6cSmseidel<tablecell>
293*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3150872" role="tablecontent" l10n="CHG" oldref="221">Represents a printable character.</paragraph>
294*1b580e6cSmseidel</tablecell>
295*1b580e6cSmseidel</tablerow>
296*1b580e6cSmseidel<tablerow>
297*1b580e6cSmseidel<tablecell>
298*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3155854" role="tablecontent" l10n="U" oldref="222">[:cntrl:]</paragraph>
299*1b580e6cSmseidel</tablecell>
300*1b580e6cSmseidel<tablecell>
301*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3152576" role="tablecontent" l10n="CHG" oldref="223">Represents a nonprinting character.</paragraph>
302*1b580e6cSmseidel</tablecell>
303*1b580e6cSmseidel</tablerow>
304*1b580e6cSmseidel<tablerow>
305*1b580e6cSmseidel<tablecell>
306*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3149958" role="tablecontent" l10n="U" oldref="228">[:lower:]</paragraph>
307*1b580e6cSmseidel</tablecell>
308*1b580e6cSmseidel<tablecell>
309*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3145730" role="tablecontent" l10n="CHG" oldref="229">Represents a lowercase character if <emph>Match case</emph> is selected in <emph>Options</emph>.</paragraph>
310*1b580e6cSmseidel</tablecell>
311*1b580e6cSmseidel</tablerow>
312*1b580e6cSmseidel<tablerow>
313*1b580e6cSmseidel<tablecell>
314*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3148455" role="tablecontent" l10n="U" oldref="230">[:upper:]</paragraph>
315*1b580e6cSmseidel</tablecell>
316*1b580e6cSmseidel<tablecell>
317*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id3150092" role="tablecontent" l10n="CHG" oldref="231">Represents an uppercase character if <emph>Match case</emph> is selected in <emph>Options.</emph>
318*1b580e6cSmseidel</paragraph>
319*1b580e6cSmseidel</tablecell>
320*1b580e6cSmseidel</tablerow>
321*1b580e6cSmseidel</table>
322*1b580e6cSmseidel<paragraph xml-lang="en-US" id="hd_id5311441" role="heading" level="2" l10n="NEW">Examples</paragraph>
323cdf0e10cSrcweir<paragraph xml-lang="en-US" id="par_id956834773" role="paragraph" l10n="NEW">e([:digit:])?    -- finds 'e' followed by zero or one digit. Note that currently all named character classes like [:digit:] must be enclosed in parentheses.<comment>issue 64368 and 113035</comment></paragraph>
324cdf0e10cSrcweir<paragraph xml-lang="en-US" id="par_id952368773" role="paragraph" l10n="NEW">^([:digit:])$    -- finds lines or cells with exactly one digit.</paragraph>
325*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id9568773" role="paragraph" l10n="NEW">You can combine the search terms to form complex searches.</paragraph>
326*1b580e6cSmseidel<paragraph xml-lang="en-US" id="hd_id71413" role="heading" level="3" l10n="NEW">To find three-digit numbers alone in a paragraph</paragraph>
327*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id2924283" role="code" l10n="NEW">^[:digit:]{3}$</paragraph>
328*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id5781731" role="paragraph" l10n="NEW">^ means the match has to be at the start of a paragraph, </paragraph>
329*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id6942045" role="paragraph" l10n="NEW">[:digit:] matches any decimal digit, </paragraph>
330*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id4721823" role="paragraph" l10n="NEW">{3} means there must be exactly 3 copies of "digit", </paragraph>
331*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id5806756" role="paragraph" l10n="NEW">$ means the match must end a paragraph. </paragraph>
332*1b580e6cSmseidel<section id="relatedtopics">
333*1b580e6cSmseidel<embed href="text/shared/01/02100000.xhp#02100000"/>
334cdf0e10cSrcweir<switch select="appl">
335cdf0e10cSrcweir<case select="WRITER"><embed href="text/swriter/guide/search_regexp.xhp#search_regexp"/>
336*1b580e6cSmseidel<embed href="text/swriter/guide/finding.xhp#finding"/>
337cdf0e10cSrcweir</case>
338cdf0e10cSrcweir</switch>
3396f9008d8SAriel Constenla-Haile<paragraph xml-lang="en-US" id="par_id1751457" role="paragraph" l10n="NEW"><link href="https://wiki.openoffice.org/wiki/Documentation/How_Tos/Regular_Expressions_in_Writer">Wiki page about regular expressions in Writer</link></paragraph>
340*1b580e6cSmseidel<paragraph xml-lang="en-US" id="par_id5483870" role="paragraph" l10n="NEW"><link href="https://wiki.openoffice.org/wiki/Documentation/How_Tos/Regular_Expressions_in_Calc">Wiki page about regular expressions in Calc</link></paragraph>
341*1b580e6cSmseidel</section>
342*1b580e6cSmseidel</body>
34308d2dd9aSHerbert Dürr</helpdocument>
344