Closed BsNoSi closed 3 weeks ago
I don't know how Autohotkey works. I use https://espanso.org/, and they are using the clipboard for getting text in, and that works great in all GUI applications and even the Terminal. 🤷
Are there different modes in Autohotkey that you can test?
Autohotkey uses for the basic shortcuts "sendkey" to the keyboard buffer. I can also use the clipboard for pasting, but defining shortcuts to use the clipboard needs higher efforts.
Additionally, Autohotkey allows coding complex operations, which I am using, too.
Espanso is new to me (thanks for hint). I will take a look, as soon as I have an impression, I will give feedback, if it might be a "workaround" for me.
Autohotkey uses for the basic shortcuts "sendkey" to the keyboard buffer. I can also use the clipboard for pasting, but defining shortcuts to use the clipboard needs higher efforts.
Then I guess you want to open a Qt issue on https://bugreports.qt.io/secure/Dashboard.jspa for QPlainTextEdit.
Additionally, Autohotkey allows coding complex operations, which I am using, too.
You can even run applications in espanso, like I do here: https://github.com/pbek/nixcfg/blob/be8f9995e1701818b0003a4128aa24b821928e0b/modules/mixins/espanso.nix#L50
Could you be so kind, trying this with Espanso:
- trigger: "..test"
replace: "😉"
In my case it behaves identical to Autohotkey: "..test" is replaced to "."
Which means, that Espenso maybe uses "sendkey", too, because cut and paste of 😉 works fine.
Another hint for that:
:?*:..1.::①
This autohotkey definition works fine in QOwnnotes.
🤔 Using the search bar of Espanso inserts 😉 into QOwnNotes.
This points to a general problem of UTF8 handling in keyboard buffer of qt (try "test" in search box as well)
I created a little routine to explicitly paste all symbols that have crumbled output to the clipboard. This is a faster solution than using Espanso (which looks interesting regardless).
From my side this issue can be closed because it seems to be not an issue of QOwnNotes.
Could you be so kind, trying this with Espanso:
For me, espanso replaces it to 😉
.
🤔 This is interesting. But, while typing my reply, I have an idea. … ⏳ … I remembered an update of Powertoys, which should solve interference problems with AHK. But this is not the case of my side effect. It seems, as if all 4 byte symbols (😉 🏁) are blocked, while 3 byte symbols ( ① ② ) pass through.
For those, I coded a short helper function, that uses temporarily the clipboard
TextClip(put) {
ClipSaved := ClipboardAll()
A_Clipboard := ""
A_Clipboard := put
ClipWait
Send "^v"
Sleep(100)
A_Clipboard := ClipSaved
ClipSaved := ""
}
The standard code for replacement string
:?*:..bink::😉
extends a (very) little bit
:?*:..blink::{
TextClip("😉")
}
Whatever the reason is, it does not bother me anymore. 😀
Because it is obviously no QOwnNotes issue → cloesd.
Expected behaviour
Usage of Autohotkey as in any other application.
Actual behaviour
If an insert phrase contains symbols ( 😉 🤣 🙆 … ) the input is crumbled (s. video).
https://github.com/user-attachments/assets/d508ed61-e70d-4561-b7a0-057c5e73343d
Steps to reproduce
Relevant log output in the Log panel
Expand
``` [08:32:21] [debug] updatePanelMenu - 'updatePanelMenu' [08:32:21] [debug] currentLocalPath - 'currentLocalPath': "C:/Tools/Notizen/NC-Sync" [08:32:21] [debug] Code block of lang detected: "\r" 0 [08:32:21] [debug] Code block of lang detected: "\r" 0 [08:32:21] [debug] cloudConnection: CloudConnection:Information about the application, settings and environment
Expand
QOwnNotes Debug Information =========================== ## General Info **Current Date**: `So Nov 3 08:41:57 2024` **Version**: `24.10.5` **Build date**: `Oct 30 2024` **Build number**: `1136` **Platform**: `windows (windows)` **Operating System**: `Windows 10 Version 2009` **Build architecture**: `x86_64` **Current architecture**: `x86_64` **Release**: `GitHub Actions` **Qt Version (build)**: `5.15.2` **Qt Version (runtime)**: `5.15.2` **Portable mode**: `no` **Settings path / key**: `\HKEY_CURRENT_USER\Software\PBE\QOwnNotes` **Application database path**: `C:\Users\xxxx\AppData\Roaming\PBE\QOwnNotes\QOwnNotes.sqlite` **Application arguments**: `C:\Tools\QOwnNotes\QOwnNotes.exe`, `C:\Tools\QOwnNotes\QOwnNotes.exe`, `--allow-multiple-instances` **Qt Debug**: `0` **Locale (system)**: `de_DE` **Locale (interface)**: *empty* **Primary screen resolution**: `3840x2160` **Icon theme**: `breeze-dark-qownnotes` **Notes in current note folder**: `453` **Calendar items**: `3` **Enabled scripts**: `3` **Database drivers**: `QSQLITE, QODBC, QODBC3, QPSQL, QPSQL7` ## Server Info **serverUrl**: `https://xx.xxx.de` **appIsValid**: `no` **notesPathExists**: *empty* **connectionErrorMessage**: *empty* ## Spellchecking **Enabled**: `false` **Selected language**: `auto` **Language codes**: `de_DE_frami, en_GB` **Language names**: `Deutsch (Deutschland), British English (United Kingdom)` **Application dictionaries path**: `C:\Users\xxxx\AppData\Roaming\PBE\QOwnNotes\dicts` ## Note folders **currentNoteFolderId**: `1` ### Note folder `Notizen` **id**: `1` **isCurrent**: `yes` **activeTagId**: `-1` **localPath**: `C:\Tools\Notizen\NC-Sync` **remotePath**: `Notes` **cloudConnectionId**: `1` **isShowSubfolders**: `yes` **isUseGit**: `no` **allowDifferentNoteFileName**: `no` **activeNoteSubFolder name**: *empty* **database file**: `C:\Tools\Notizen\NC-Sync\notes.sqlite` ## Cloud connections ### Cloud connection `Standard` **id**: `1` **isCurrent**: `yes` **serverUrl**: `https://xx.xxx.de` **username**: `xxxx` **accountId**: *empty* ## Enabled scripts ### Script `Markdown-it markdown parser` **id**: `1` **path**: `C:\Users\xxxx\AppData\Roaming\PBE\QOwnNotes\scripts\markdown-it\markdown-it.qml` **variablesJson**: ``` { "customStylesheet": "", "options": "{\n html: true, // Enable HTML tags in source\n //xhtmlOut: false, // Use '/' to close single tags ()\n breaks: true, // Convert '\\n' in paragraphs into
\n //langPrefix: 'language-', // CSS language prefix for fenced blocks\n linkify: true, // autoconvert URL-like texts to links\n\n // Enable some language-neutral replacements + quotes beautification\n typographer: true,\n\n // Double + single quotes replacement pairs, when typographer enabled,\n // and smartquotes on. Could be either a String or an Array.\n //\n // For example, you can use '«»„“' for Russian, '„“‚‘' for German,\n // and ['«\\xA0', '\\xA0»', '‹\\xA0', '\\xA0›'] for French (including nbsp).\n //quotes: '\\u201c\\u201d\\u2018\\u2019', /* “”‘’ */\n\n // Highlighter function. Should return escaped HTML,\n // or '' if the source string is not changed and should be escaped externaly.\n // If result starts with