Scripts discussion (3)

Discuss and announce AkelPad plugins
Locked
  • Author
  • Message
KDJ
Offline
Posts: 1949
Joined: Sat Mar 06, 2010 7:40 pm
Location: Poland

Post by KDJ »

Instructor
It seems to me that AKD_PATEXEC message with RESE_WHOLEWORD does not work properly.
I used this in FindReplaceEx.js script to count all occurrences (function Count(hButton, nID)).
This happens when at the beginning and at the end of the search string are word delimiters, eg. "Find".
Can you check it?

KDJ
Offline
Posts: 1949
Joined: Sat Mar 06, 2010 7:40 pm
Location: Poland

Post by KDJ »

FindReplaceEx.js
Added: transparency of the dialog.

YuS
Offline
Posts: 513
Joined: Sun Sep 15, 2013 8:25 am
Location: 013 в Тентуре, семь по Спирали, налево от Большой Медведицы

Post by YuS »

KDJ wrote: Added: transparency of the dialog.

Code: Select all

/**************************************************
FindReplaceEx.js - ver. 2016-01-14
Interface language
Language:      Russian (1049)
Translated by: F. Phoenix, Andrey_A_A, VladSh, YuS
**************************************************/
...
sTxtTransparentNA = 'Прозрачность (неактивная)';             //new

KDJ
Offline
Posts: 1949
Joined: Sat Mar 06, 2010 7:40 pm
Location: Poland

Post by KDJ »

YuS
Uploaded, thanks.

Offline
Posts: 202
Joined: Sat Mar 28, 2015 2:36 pm
Location: Russia

Post by Kley »

KDJ
FindReplaceEx.js
Установлены "Beginning" и "Prompt" (RadioButton/CheckBox).
Ищем какое-нибудь слово, до сообщения "Passed file boundary. Continue?".
После ответа включается RadioButton "Down".
Если теперь искать другое слово, которого нет в тексте, то опять включится "Beginning".

YuS
[IMHO]
"Прозрачность (неактивная)", как-то не очень...
Лучше было бы "Прозрачность при потере фокуса" или "Прозрачность (неактивный диалог)".
Правда, длинновато. Так: "Прозрачный неактивный диалог" - влазит :) И со строкой
"Отметить "В выделении" если есть выделение" почти наравне.
Ну, или еще как...
[/IMHO]

YuS
Offline
Posts: 513
Joined: Sun Sep 15, 2013 8:25 am
Location: 013 в Тентуре, семь по Спирали, налево от Большой Медведицы

Post by YuS »

Kley wrote:KDJ
FindReplaceEx.js
Установлены "Beginning" и "Prompt" (RadioButton/CheckBox).
Ищем какое-нибудь слово, до сообщения "Passed file boundary. Continue?".
После ответа включается RadioButton "Down".
Если теперь искать другое слово, которого нет в тексте, то опять включится "Beginning".
Кстати, да, в стандартном диалоге замены, самопроизвольного переключения направления поиска не происходит...
Kley wrote: YuS
"Прозрачность (неактивная)", как-то не очень...
Согласен, но эта корявость получилась из-за экономии длины фразы в переводе...
Kley wrote: Так: "Прозрачный неактивный диалог" - влазит :)
Да, так будет оптимально и по смыслу, и по длине.


KDJ, измените, пожалуйста, фразу:

Code: Select all

/**************************************************
FindReplaceEx.js - ver. 2016-01-15
Interface language
Language:      Russian (1049)
Translated by: F. Phoenix, Andrey_A_A, VladSh, YuS
**************************************************/
...
sTxtTransparentNA = 'Прозрачный неактивный диалог';             //new

Offline
Posts: 53
Joined: Wed Dec 09, 2015 6:33 pm

Post by beotiger »

KDJ wrote:FindReplaceEx.js
Added: manual parameter bLinesInLog in FindReplaceEx.ini. If set to true, "Find all" -> "Show in Log panel" displays entire lines where the text was found.
KDJ thank you very much. It works like a charm. One more point: may be we should trim lines from spaces in log panel?
And transparency is my dream coming true. :P

I think I found bug in FindReplaceFiles.js: when we go to modified file from `Files found` list, AkelPad shows dialog "Document was modified. Do you want to save it?" and hangs so that we must kill it from Task manager and run again.

KDJ
Offline
Posts: 1949
Joined: Sat Mar 06, 2010 7:40 pm
Location: Poland

Post by KDJ »

beotiger
It seems to me that I fixed it: FindReplaceFiles.js.

Offline
Posts: 53
Joined: Wed Dec 09, 2015 6:33 pm

Post by beotiger »

KDJ wrote:beotiger
It seems to me that I fixed it: FindReplaceFiles.js.
KDJ no. AkelPad hangs the same. One difference I can see that `Find Replace files` dialog disappears before AkelPad asks for saving modified file and hangs.

KDJ
Offline
Posts: 1949
Joined: Sat Mar 06, 2010 7:40 pm
Location: Poland

Post by KDJ »

beotiger
If you set "Settings" -> "Run in separate window" also hangs?

KDJ
Offline
Posts: 1949
Joined: Sat Mar 06, 2010 7:40 pm
Location: Poland

Post by KDJ »

beotiger
OK, now it should work.
FindReplaceFiles.js
Fixed: AkelPad hangs when trying to close or reopen the modified document (via the script).

Offline
Posts: 53
Joined: Wed Dec 09, 2015 6:33 pm

Post by beotiger »

KDJ wrote:beotiger
If you set "Settings" -> "Run in separate window" also hangs?
No, it seems work ok with this option set on.
What is the difference?

KDJ
Offline
Posts: 1949
Joined: Sat Mar 06, 2010 7:40 pm
Location: Poland

Post by KDJ »

beotiger
If "Run in separate window" is set, the script window has no owner. You can use Alt+Tab to switch between AkelPad window and the script window.
If "Run in separate window" is not set, the owner for the script window is AkelPad main window. In this case you can not use Alt+Tab to switch between windows, use F6 instead of Alt+Tab.

Offline
Posts: 53
Joined: Wed Dec 09, 2015 6:33 pm

Post by beotiger »

KDJ. I have taken some tests
with "Run in separate window" option on and off,
and it seems it worked ok in both cases.

Thank you.

Offline
Posts: 366
Joined: Mon Jan 10, 2011 5:28 pm
Contact:

Post by Lenchik »

KDJ
Can you please add to AkelPadTitle.js two more path options:
- full folder path (like %%F without %%f);
- only folder name or maybe some controllable option to cut path to show not more than particular number of closest folders back (e:\long\path\name\folder4\folder3\fold2\f1\filename.txt if set to 3 would be folder3\fold2\f1\).
Locked