itagagaki / charu3-SE

Text input support tool for Windows that allows you to paste canned text previously registered into the active window. Also has some other features. // 予め登録した定型文をアクティブなウィンドウにペーストすることができるWindows用テキスト入力支援ツール。他にも様々な機能あり。
13 stars 2 forks source link

$SEL & $CLIP macroses do not work #52

Closed Lichtenshtein closed 1 year ago

Lichtenshtein commented 1 year ago

It is impossible to perform operations with the selected text and the text from the clipboard. Most likely, as a result of this, plugins like addQuotation.dll also do not work.

Charu 3.8.3

itagagaki commented 1 year ago

For the point where $SEL is always empty, it would be a duplicate of #47.

Lichtenshtein commented 1 year ago

Most of my macroses broke because of this change and don't work (BB-Code, HTML, Markdown, youtube-dl, advanced text operations). The remaining ones are tied to AHK and still work. I hope the problem is fixable, as for me Charu means more to me than just a clipboard extender.

itagagaki commented 1 year ago

I have re-enabled the function to get selected text. Could you please test today's build attached?

Charu3_20230908.zip

Lichtenshtein commented 1 year ago

I have re-enabled the function to get selected text. Could you please test today's build attached?

Charu3_20230908.zip

I'm very sorry for very late answer. I will test it right now.

Lichtenshtein commented 1 year ago

First of all, as far as i remember, the original Charu package included a data tree example file with a mini tutorial and some examples of using macros and plugins. Do you have it? I think it would be good to add it to your fork, it would be convenient for new users who are not familiar with Charu.


The macro for operations with the selected text $SEL sometimes does not work. It works in 90% of cases. Perhaps it was the same in the original Charu, I just rarely paid attention to it. For example, in operations similar to framing the selected text (in this case BB-Code):

<charuMACRO>[code]$SEL[/code]</charuMACRO>

In case of failure, Charu simply cuts and pastes the selected word again.

If i highlight a word, call the Charu popup window, and double-click on any old fragment from the History Folder, in some cases Charu cuts and pastes the highlighted word again, instead of pasting selected fragment from the history.

It seems to me that after you turn on $SEL again, Charu started working a little slower (like the original Charu)?


The plugins.


I have also noticed strange behavior in Charu for quite some time. I will try to describe it.

The pop-up window with data tree is assigned to the Alt+c keys. Inside the data tree, i created a folder called "Samples". I press Edit -> Optional Properties -> Hotkey to Popup. I set HotKey=Alt+q for quick opening of the folder using these key combinations.

In my system, there are 2 main languages that I switch between: English (ENG) and Russian (RUS).

If i launch Charu.exe when the input language in the system is currently set to Russian (RUS), the Alt+q combination does not work in Charu. Nothing is happening when i press it.

If i launch Charu.exe when the input language is set to English (ENG), the Alt+q combination works in Charu and the Samples folder in the data tree opens. This behavior is present in the original Charu as well.

itagagaki commented 1 year ago

Let's resolve each one in turn.

Charu package included a data tree example file with a mini tutorial and some examples of using macros and plugins

I will think about examples and tutorials, but I welcome your contributions. Right now I'm doing my best to improve the Wiki .

In case of failure, Charu simply cuts and pastes the selected word again.

Try to increse "Copy Delay" value in Key Event tab of Settings. Then it will be slower but more reliable.

It seems to me that after you turn on $SEL again, Charu started working a little slower (like the original Charu)?

Probably yes. There are two reasons for the slowdown: the first is the delay mentioned above. The second is that the original always slows down because it works by copying the selection from the target window, regardless of whether the text to be pasted contains $SEL or not. The delay is necessary, but I have made an improvement to omit this process if there is no need to get $SEL. Please try the attached binary.

Charu3_20230914.zip

set to Russian (RUS), the Alt+q combination does not work

I have a feeling that the hotkeys are eaten by some other preferred process. Could you please use the following tool to check which application is registering Alt + Q?

Hotkey Screener - Free Tool to Enumerate Hotkeys and Detect Apps which Use Them - NTWind Software

Lichtenshtein commented 1 year ago

I will think about examples and tutorials, but I welcome your contributions. Right now I'm doing my best to improve the Wiki

Very nice.

Here is a compressed folder with a portable version of Charu. In the Docs folder, there are some chapters from the old documentation and FAQ that i had (in Japanese and English) from http://keiziweb.age.jp/ (not opening anymore). Also, there is Charu3.c3d - a data tree file that i compiled with a brief original practical manual and examples of using macros and plugins. I added a few templates for Markdown, BB-Code, HTML, Youtube-dl, and text processing using Charu's capabilities.

Try to increse "Copy Delay" value in Key Event tab of Settings. Then it will be slower but more reliable.

I think you're right, that helped. By default, the value was set extremely low, only 10. Usually, i set the delay to 100 or higher.

Please try the attached binary.

Feels better. (͡ ° ͜ʖ ͡ °)

Could you please use the following tool to check which application is registering Alt + Q?

Thank you. If i switch to (RUS) and launch Charu.exe i see no Alt + Q in the list at all.

Alt + Unknown (0xFF) Charu3.exe (PID: 9264)
Alt + C Charu3.exe (PID: 9264)

If i switch to (ENG) and launch Charu.exe i see Alt + Q in the list.

Alt + Q Charu3.exe (PID: 11576)

itagagaki commented 1 year ago

I was able to reproduce the problem in Russian. This topic is branched into a new issue #56 .