From 08b89f4f05b54f369aff9a3347cbfe17d192013c Mon Sep 17 00:00:00 2001
From: Florian Kargl <f.kargl@posteo.de>
Date: Wed, 27 Oct 2021 22:44:07 +0200
Subject: [PATCH] Add missing hints to search dialog
---
.../openstreetmap/josm/gui/dialogs/SearchDialog.java | 11 +++++++++--
1 file changed, 9 insertions(+), 2 deletions(-)
diff --git a/src/org/openstreetmap/josm/gui/dialogs/SearchDialog.java b/src/org/openstreetmap/josm/gui/dialogs/SearchDialog.java
index 83a27eec28..c2f4ff137b 100644
|
a
|
b
|
private static JPanel buildHintsSection(AutoCompComboBox<SearchSetting> hcbSearc
|
| 321 | 321 | GBC.eol()); |
| 322 | 322 | hintPanel.add(new SearchKeywordRow(hcbSearchString) |
| 323 | 323 | .addKeyword("<i>key:</i>", null, tr("matches if ''key'' exists")) |
| | 324 | .addKeyword("<i>key?</i>", null, tr("matches if ''key''' has a truthy value (''true'', ''yes'', ''1', ''on')")) |
| 324 | 325 | .addKeyword("<i>key</i>=<i>value</i>", null, tr("''key'' with exactly ''value''")) |
| 325 | 326 | .addKeyword("<i>key</i>~<i>regexp</i>", null, tr("value of ''key'' matching the regular expression ''regexp''")) |
| 326 | 327 | .addKeyword("<i>key</i>=*", null, tr("''key'' with any value")) |
| … |
… |
private static JPanel buildHintsSection(AutoCompComboBox<SearchSetting> hcbSearc
|
| 338 | 339 | .addKeyword("<i>expr</i> <i>expr</i>", null, |
| 339 | 340 | tr("logical and (both expressions have to be satisfied)"), |
| 340 | 341 | trc("search string example", "Baker Street")) |
| | 342 | .addKeyword("<i>expr</i> & <i>expr</i>", "& ", tr("logical and (both expressions have to be satisfied)")) |
| | 343 | .addKeyword("<i>expr</i> AND <i>expr</i>", "AND ", tr("logical and (both expressions have to be satisfied)")) |
| 341 | 344 | .addKeyword("<i>expr</i> | <i>expr</i>", "| ", tr("logical or (at least one expression has to be satisfied)")) |
| 342 | | .addKeyword("<i>expr</i> OR <i>expr</i>", "OR ", tr("logical or (at least one expression has to be satisfied)")) |
| | 345 | .addKeyword("<i>expr</i> OR <i>expr</i>", "OR ", tr("logical or (at least one expression has to be satisfied)")), |
| | 346 | GBC.eol()); |
| | 347 | hintPanel.add(new SearchKeywordRow(hcbSearchString) |
| | 348 | .addKeyword("<i>expr</i> ^ <i>expr</i>", "^ ", tr("logical xor (one and only one expression has to be satisfied)")) |
| | 349 | .addKeyword("<i>expr</i> XOR <i>expr</i>", "XOR ", tr("logical or (one and only one expression has to be satisfied)")) |
| 343 | 350 | .addKeyword("-<i>expr</i>", null, tr("logical not")) |
| 344 | 351 | .addKeyword("(<i>expr</i>)", "()", tr("use parenthesis to group expressions")), |
| 345 | | GBC.eol()); |
| | 352 | GBC.eol().anchor(GBC.CENTER)); |
| 346 | 353 | |
| 347 | 354 | SearchKeywordRow objectHints = new SearchKeywordRow(hcbSearchString) |
| 348 | 355 | .addTitle(tr("objects")) |