Skip to content

Commit

Permalink
Merge pull request #622 from MKadaner/mzk-viewer-search-std
Browse files Browse the repository at this point in the history
Viewer now uses the standard Search dialog.
  • Loading branch information
alabuzhev committed Feb 1, 2023
2 parents 833c939 + f022952 commit a4a8315
Show file tree
Hide file tree
Showing 16 changed files with 94 additions and 413 deletions.
14 changes: 4 additions & 10 deletions far/FarCze.hlf.m4
Original file line number Diff line number Diff line change
Expand Up @@ -2886,25 +2886,22 @@ beginning in the text.

Poznámka:

1. ^<wrap>Do vyvolaného ~vyhledávacího~@ViewerSearch@ dialogu můžete začít psát text,
který hledáte.

2. ^<wrap>The viewer opens files with the permission to be deleted.
1. ^<wrap>The viewer opens files with the permission to be deleted.
If another process attempts to delete the file while it is open in the
viewer, the file will be deleted after the viewer is closed. Any
operation on a file while its deletion is pending will fail. This is
a feature of the Windows operating system.

3. ^<wrap>The maximum number of columns displayed in the #text#
2. ^<wrap>The maximum number of columns displayed in the #text#
~view mode~@ViewerMode@ can be configured in the
~Viewer settings~@ViewerSettings@ dialog. The range is between 100 to 100,000,
the default is 10,000. Lines longer than the maximum will be split into
several screen rows even if word wrap mode is turned off.

4. ^<wrap>Far starts ~searching~@ViewerSearch@ (#F7#) from the
3. ^<wrap>Far starts ~searching~@ViewerSearch@ (#F7#) from the
beginning of the currently visible area.

5. ^<wrap>To auto-scroll a file which is being appended by another
4. ^<wrap>To auto-scroll a file which is being appended by another
process (conf. Linux “tail”), go to the end of the file (press the #End# key).


Expand Down Expand Up @@ -3871,9 +3868,6 @@ Pro zadání souboru pro prohlížení použijte ~speciální symboly~@MetaSymbo
#Persistent selection#
Do not remove block selection after moving the cursor.

#Search dialog auto-focus#
Always returns focus to the search text field in the Viewer ~Search~@ViewerSearch@ dialog.

#Velikost Tabulátoru#
Počet mezer ve znaku tabulátoru.

Expand Down
14 changes: 4 additions & 10 deletions far/FarEng.hlf.m4
Original file line number Diff line number Diff line change
Expand Up @@ -2852,25 +2852,22 @@ beginning in the text.

Notes:

1. ^<wrap>Start typing the search pattern to open the
~search~@ViewerSearch@ dialog.

2. ^<wrap>The viewer opens files with the permission to be deleted.
1. ^<wrap>The viewer opens files with the permission to be deleted.
If another process attempts to delete the file while it is open in the
viewer, the file will be deleted after the viewer is closed. Any
operation on a file while its deletion is pending will fail. This is
a feature of the Windows operating system.

3. ^<wrap>The maximum number of columns displayed in the #text#
2. ^<wrap>The maximum number of columns displayed in the #text#
~view mode~@ViewerMode@ can be configured in the
~Viewer settings~@ViewerSettings@ dialog. The range is between 100 to 100,000,
the default is 10,000. Lines longer than the maximum will be split into
several screen rows even if word wrap mode is turned off.

4. ^<wrap>Far starts ~searching~@ViewerSearch@ (#F7#) from the
3. ^<wrap>Far starts ~searching~@ViewerSearch@ (#F7#) from the
beginning of the currently visible area.

5. ^<wrap>To auto-scroll a file which is being appended by another
4. ^<wrap>To auto-scroll a file which is being appended by another
process (conf. Linux “tail”), go to the end of the file (press the #End# key).


Expand Down Expand Up @@ -3838,9 +3835,6 @@ Use ~special symbols~@MetaSymbols@ to specify the name of the file to view.
#Persistent selection#
Do not remove block selection after moving the cursor.

#Search dialog auto-focus#
Always returns focus to the search text field in the Viewer ~Search~@ViewerSearch@ dialog.

#Tab size#
Number of spaces per single tab position.

Expand Down
14 changes: 4 additions & 10 deletions far/FarGer.hlf.m4
Original file line number Diff line number Diff line change
Expand Up @@ -2926,25 +2926,22 @@ beginning in the text.

Hinweise:

1. ^<wrap>Sie können zusätzlich zu #F7# den ~Suchdialog~@ViewerSearch@ einfach
durch Eingabe des zu suchenden Textes starten.

2. ^<wrap>The viewer opens files with the permission to be deleted.
1. ^<wrap>The viewer opens files with the permission to be deleted.
If another process attempts to delete the file while it is open in the
viewer, the file will be deleted after the viewer is closed. Any
operation on a file while its deletion is pending will fail. This is
a feature of the Windows operating system.

3. ^<wrap>The maximum number of columns displayed in the #text#
2. ^<wrap>The maximum number of columns displayed in the #text#
~view mode~@ViewerMode@ can be configured in the
~Viewer settings~@ViewerSettings@ dialog. The range is between 100 to 100,000,
the default is 10,000. Lines longer than the maximum will be split into
several screen rows even if word wrap mode is turned off.

4. ^<wrap>Far starts ~searching~@ViewerSearch@ (#F7#) from the
3. ^<wrap>Far starts ~searching~@ViewerSearch@ (#F7#) from the
beginning of the currently visible area.

5. ^<wrap>To auto-scroll a file which is being appended by another
4. ^<wrap>To auto-scroll a file which is being appended by another
process (conf. Linux “tail”), go to the end of the file (press the #End# key).


Expand Down Expand Up @@ -3915,9 +3912,6 @@ Benutzen Sie die ~Spezialsymbole~@MetaSymbols@ um den Namen der anzuzeigenden Da
#Persistent selection#
Do not remove block selection after moving the cursor.

#Search dialog auto-focus#
Always returns focus to the search text field in the Viewer ~Search~@ViewerSearch@ dialog.

#Tabulatorgröße#
Tab zeigt die entsprechende Anzahl Leerzeichen an.

Expand Down
14 changes: 4 additions & 10 deletions far/FarHun.hlf.m4
Original file line number Diff line number Diff line change
Expand Up @@ -2934,24 +2934,21 @@ beginning in the text.

Megjegyzések:

1. ^<wrap>A ~keresőablak~@ViewerSearch@ meghívásához a nézőkében az is elég, ha elkezdjük
begépelni a keresett szöveget.

2. ^<wrap>Az, hogy a nézőkében megnyitunk egy fájlt, nem zárja ki,
1. ^<wrap>Az, hogy a nézőkében megnyitunk egy fájlt, nem zárja ki,
hogy közben egy másik folyamat ne törölhetné azt. Annak ellenére, hogy a fájl
valójában csak a nézőke bezárásakor törlődik, a törölt fájlra irányuló további
műveletek hibával fognak leállni - ez Windows sajátosság.

3. ^<wrap>The maximum number of columns displayed in the #text#
2. ^<wrap>The maximum number of columns displayed in the #text#
~view mode~@ViewerMode@ can be configured in the
~Viewer settings~@ViewerSettings@ dialog. The range is between 100 to 100,000,
the default is 10,000. Ha valamelyik sor túllépi ezt, a Far akkor is
több sorban jeleníti meg, ha a sortörés ki van kapcsolva.

4. ^<wrap>A Far nézőke ~keresője~@ViewerSearch@ (#F7#) a fájl képernyőn
3. ^<wrap>A Far nézőke ~keresője~@ViewerSearch@ (#F7#) a fájl képernyőn
megjelenő részének kezdetétől az első előfordulásig keresi a sztringet.

5. ^<wrap>Ha automatikusan szeretnénk gördíteni egy folyamatosan változó
4. ^<wrap>Ha automatikusan szeretnénk gördíteni egy folyamatosan változó
tartalmú fájlt, vigyük a kurzort a fájl végére (az End billentyűvel).


Expand Down Expand Up @@ -3932,9 +3929,6 @@ A parancssorban a megnézendő fájlnevek megadásához alkalmazhatunk ~különl
#Maradó blokkok#
Nem veszi le a kijelölést a blokkokról, ha megmozdítjuk a kurzort.

#Search dialog auto-focus#
Always returns focus to the search text field in the Viewer ~Search~@ViewerSearch@ dialog.

#Tabulátor mérete#
A tabulátor szóközökben mért hossza.

Expand Down
13 changes: 4 additions & 9 deletions far/FarPol.hlf.m4
Original file line number Diff line number Diff line change
Expand Up @@ -2849,24 +2849,22 @@ początkowym.

Uwagi:

1. ^<wrap>Rozpoczęcie pisania otwiera okno ~wyszukiwania~@ViewerSearch@.

2. ^<wrap>Przeglądarka otwiera pliki z uprawnieniem do usunięcia.
1. ^<wrap>Przeglądarka otwiera pliki z uprawnieniem do usunięcia.
Jeżeli inny proces próbuje usunąć plik otwarty do poglądu, zostanie
on usunięty po zamknięciu podglądu. Każda operacja na pliku oczekującym
na usunięcie zakończy się niepowodzeniem. Jest to cecha systemu operacyjnego
Windows.

3. ^<wrap>Maksymalna liczba kolumn wyświetlanych w ~podglądzie~@ViewerMode@ #tekstowym#
2. ^<wrap>Maksymalna liczba kolumn wyświetlanych w ~podglądzie~@ViewerMode@ #tekstowym#
można skonfigurować w oknie ~ustawieniach podglądu~@ViewerSettings@. Zakres
zawiera się między 100 a 100.000, domyślnie ustawione jest 10.000. Linie
dłuższe niż ustawiony zakres zostaną podzielone kilka wierszy, nawet jeżeli
opcja zawijania wierszy jest wyłączona.

4. ^<wrap>Far rozpoczyna ~wyszukiwanie~@ViewerSearch@ (#F7#) od początku
3. ^<wrap>Far rozpoczyna ~wyszukiwanie~@ViewerSearch@ (#F7#) od początku
aktualnie widocznego obszaru.

5. ^<wrap>Aby automatycznie przewijać plik, który jest dołączany przez inny
4. ^<wrap>Aby automatycznie przewijać plik, który jest dołączany przez inny
proces (podobnie jak polecenie Linux "tail"), należy przejść na koniec pliku
(naciśnięcie klawisza #End#).

Expand Down Expand Up @@ -3837,9 +3835,6 @@ Można użyć ~symboli specjalnych~@MetaSymbols@ do wpisania nazwy pliku.
#Trwałe zaznaczenie#
Nie usuwaj zaznaczonego bloku po przesunięciu kursora.

#Auto-focus okna szukania#
Zawsze przywraca fokus do pola tekstowego wyszukiwania w oknie dialogowym ~Szukaj~@ViewerSearch@.

#Rozmiar tabulatora#
Liczba znaków spacji na pojedynczy znak tabulacji.

Expand Down
14 changes: 4 additions & 10 deletions far/FarRus.hlf.m4
Original file line number Diff line number Diff line change
Expand Up @@ -2908,25 +2908,22 @@ $ #Программа просмотра: клавиши управления#

Примечания:

1. ^<wrap>Начните вводить образец поиска, чтобы открыть диалог
~поиска~@ViewerSearch@.

2. ^<wrap>Программа просмотра открывает файл в режиме, когда
1. ^<wrap>Программа просмотра открывает файл в режиме, когда
разрешено его удаление. Если другой процесс попытается удалить файл,
пока он открыт в программе просмотра, то файл будет удалён после
закрытия программы просмотра. Все операции на файле, находящемся в таком
состоянии, будут заканчиваться неуспехом. Это свойство операционной системы Windows.

3. ^<wrap>Максимальное число колонок, показываемых в
2. ^<wrap>Максимальное число колонок, показываемых в
~режиме просмотра~@ViewerMode@ #текст#, можно задать в диалоге
~настроек программы просмотра~@ViewerSettings@. Допустимые значения
от 100 до 100 000, умолчание 10 000. Строки длиннее максимума будут разбиты
на несколько строк, даже если режим переноса строк отключён.

4. ^<wrap>Far начинает ~поиск~@ViewerSearch@ (#F7#) от начала
3. ^<wrap>Far начинает ~поиск~@ViewerSearch@ (#F7#) от начала
видимой в данный момент области.

5. ^<wrap>Для авто-скроллинга файла, который непрерывно пополняется
4. ^<wrap>Для авто-скроллинга файла, который непрерывно пополняется
другим процессом (ср. Linux «tail»), установите текущую позицию на конец
файла (нажмите клавишу #End#).

Expand Down Expand Up @@ -3888,9 +3885,6 @@ $ #Настройка программы просмотра#
#Постоянное выделение#
Не удалять пометку блока при перемещении курсора.

#Авто-фокус в диалоге поиска#
В диалоге ~поиска~@ViewerSearch@ автоматически делать активным поле ввода искомого текста.

#Размер табуляции#
Количество пробелов на одну позицию табуляции.

Expand Down
14 changes: 4 additions & 10 deletions far/FarSky.hlf.m4
Original file line number Diff line number Diff line change
Expand Up @@ -2847,25 +2847,22 @@ beginning in the text.

Poznámky:

1. ^<wrap>Dialógové okno ~hľadania~@ViewerSearch@ sa spustí automaticky ak začnete
písať text, ktorý chcete vyhľadať.

2. ^<wrap>The viewer opens files with the permission to be deleted.
1. ^<wrap>The viewer opens files with the permission to be deleted.
If another process attempts to delete the file while it is open in the
viewer, the file will be deleted after the viewer is closed. Any
operation on a file while its deletion is pending will fail. This is
a feature of the Windows operating system.

3. ^<wrap>The maximum number of columns displayed in the #text#
2. ^<wrap>The maximum number of columns displayed in the #text#
~view mode~@ViewerMode@ can be configured in the
~Viewer settings~@ViewerSettings@ dialog. The range is between 100 to 100,000,
the default is 10,000. Lines longer than the maximum will be split into
several screen rows even if word wrap mode is turned off.

4. ^<wrap>Far starts ~searching~@ViewerSearch@ (#F7#) from the
3. ^<wrap>Far starts ~searching~@ViewerSearch@ (#F7#) from the
beginning of the currently visible area.

5. ^<wrap>To auto-scroll a file which is being appended by another
4. ^<wrap>To auto-scroll a file which is being appended by another
process (conf. Linux “tail”), go to the end of the file (press the #End# key).


Expand Down Expand Up @@ -3833,9 +3830,6 @@ Na špecifikáciu mena súboru, ktorý sa má prezrieť použite ~špeciálne sy
#Persistent selection#
Do not remove block selection after moving the cursor.

#Search dialog auto-focus#
Always returns focus to the search text field in the Viewer ~Search~@ViewerSearch@ dialog.

#Veľkosť tabulátora#
Počet medzier reprezentujúcich znak tabulátora.

Expand Down
14 changes: 4 additions & 10 deletions far/FarUkr.hlf.m4
Original file line number Diff line number Diff line change
Expand Up @@ -2915,26 +2915,23 @@ beginning in the text.

Примітки:

1. ^<wrap>Для виклику діалогу ~пошуку~@ViewerSearch@ ви також можете просто почати
вводити призначений для пошуку текст.

2. ^<wrap>Файл відкривається у програмі перегляду із дозволом на
1. ^<wrap>Файл відкривається у програмі перегляду із дозволом на
видалення його стороннім процесом. Якщо відбудеться таке
видалення, то реально файл буде видалений із каталогу тільки
після закриття програми перегляду, при цьому він не буде
доступний для обробки із любого процесу - це властивість
операційної системи Windows.

3. ^<wrap>The maximum number of columns displayed in the #text#
2. ^<wrap>The maximum number of columns displayed in the #text#
~view mode~@ViewerMode@ can be configured in the
~Viewer settings~@ViewerSettings@ dialog. The range is between 100 to 100,000,
the default is 10,000. Рядки довжиною більше цього числа будуть займати
на екрані не один рядок, а кілька, навіть якщо вимкнений режим переносу рядків.

4. ^<wrap>Far ~шукає~@ViewerSearch@ перше входження підрядка (#F7#) з початку видимої
3. ^<wrap>Far ~шукає~@ViewerSearch@ перше входження підрядка (#F7#) з початку видимої
ділянки екрана програми перегляду.

5. ^<wrap>To auto-scroll a file which is being appended by another
4. ^<wrap>To auto-scroll a file which is being appended by another
process (conf. Linux “tail”), go to the end of the file (press the #End# key).


Expand Down Expand Up @@ -3899,9 +3896,6 @@ $ #Конфігурація програми перегляду#
#Persistent selection#
Do not remove block selection after moving the cursor.

#Search dialog auto-focus#
Always returns focus to the search text field in the Viewer ~Search~@ViewerSearch@ dialog.

#Розмір табуляції#
Кількість пробілів при показі символа табуляції.

Expand Down
10 changes: 10 additions & 0 deletions far/changelog
Original file line number Diff line number Diff line change
@@ -1,3 +1,13 @@
--------------------------------------------------------------------------------
MZK 30.01.2023 21:02:33 -0800 - build 6099

1. Viewer now uses the standard Search dialog.

2. Removed the following features:
- Opening Viewer's Search dialog on typing the first character of the search pattern.
See gh-614 for the discussion.
- Search dialog auto-focus.

--------------------------------------------------------------------------------
rohitab 30.01.2023 01:17:44 +1100 - build 6098

Expand Down
2 changes: 0 additions & 2 deletions far/config.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -817,7 +817,6 @@ void Options::ViewerConfig(ViewerOptions &ViOptRef, bool Local)

Builder.StartColumns();
Builder.AddCheckbox(lng::MViewConfigPersistentSelection, ViOptRef.PersistentBlocks);
Builder.AddCheckbox(lng::MViewConfigEditAutofocus, ViOptRef.SearchEditFocus);
const auto& TabSize = Builder.AddIntEditField(ViOptRef.TabSize, 3);
Builder.AddTextAfter(TabSize, lng::MViewConfigTabSize);
Builder.ColumnBreak();
Expand Down Expand Up @@ -2101,7 +2100,6 @@ void Options::InitConfigsData()
{FSSF_PRIVATE, NKeyViewer, L"SaveViewerShortPos"sv, ViOpt.SaveShortPos, true},
{FSSF_PRIVATE, NKeyViewer, L"SaveViewerWrapMode"sv, ViOpt.SaveWrapMode, false},
{FSSF_PRIVATE, NKeyViewer, L"SaveViewMode"sv, ViOpt.SaveViewMode, true},
{FSSF_PRIVATE, NKeyViewer, L"SearchEditFocus"sv, ViOpt.SearchEditFocus, false},
{FSSF_PRIVATE, NKeyViewer, L"SearchRegexp"sv, ViOpt.SearchRegexp, false},
{FSSF_PRIVATE, NKeyViewer, L"SearchWrapStop"sv, ViOpt.SearchWrapStop, BSTATE_CHECKED},
{FSSF_PRIVATE, NKeyViewer, L"ShowArrows"sv, ViOpt.ShowArrows, true},
Expand Down
1 change: 0 additions & 1 deletion far/config.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -604,7 +604,6 @@ class Options: noncopyable
BoolOption SaveShortPos;
BoolOption SaveViewMode;
BoolOption SaveWrapMode;
BoolOption SearchEditFocus; // auto-focus on edit text/hex window
BoolOption SearchRegexp;
Bool3Option SearchWrapStop; // [NonStop] / {Start-End} / [Full Cycle]
BoolOption ShowArrows;
Expand Down
14 changes: 0 additions & 14 deletions far/farlang.templ.m4
Original file line number Diff line number Diff line change
Expand Up @@ -3960,20 +3960,6 @@ upd:"Visible '\\0'"
"Адлюстроўваць '\\&0'"
upd:"Visible '\\&0'"

MViewConfigEditAutofocus
"Авто-&фокус в диалоге поиска"
"Search dialog auto-&focus"
"Automaticky aktivovat dialog hledání"
"Auto&fokus in der Suche in Dialog"
upd:"Search dialog auto-focus"
"Auto-&focus okna szukania"
"Auto-enfocar en &diálogo de búsqueda"
"Automaticky aktivovať dialóg hľadania"
"Auto Riposiziona Dialogo Di &Ricerca"
"Авто-&фокус у діалозі пошуку"
"Аўта-&фокус у гутарцы"
upd:"Search dialog auto-&focus"

MEditConfigTitle
l:
"Редактор"
Expand Down
2 changes: 1 addition & 1 deletion far/vbuild.m4
Original file line number Diff line number Diff line change
@@ -1 +1 @@
6098
6099
Loading

0 comments on commit a4a8315

Please sign in to comment.