Summary: | Typing ZWNJ in Writer is not possible on Windows | ||
---|---|---|---|
Product: | LibreOffice | Reporter: | Hossein <hossein> |
Component: | Writer | Assignee: | Not Assigned <libreoffice-bugs> |
Status: | NEW --- | ||
Severity: | normal | CC: | afshin, heiko.tietze, momonasmon, vmiklos |
Priority: | medium | ||
Version: | 7.4.0.3 release | ||
Hardware: | All | ||
OS: | Windows (All) | ||
See Also: |
https://bugs.documentfoundation.org/show_bug.cgi?id=150512 https://bugs.documentfoundation.org/show_bug.cgi?id=156443 |
||
Whiteboard: | |||
Crash report or crash signature: | Regression By: | ||
Bug Depends on: | |||
Bug Blocks: | 43808, 151986 |
Description
Hossein
2022-08-20 09:26:48 UTC
Hossein, it seems, that nobody could confirm your report for half a year. I don't use Persian keyboard layout, but I also couldn't find any information, that LO has a shortcurt for ZWNJ. I couldn't find any information in oline help and also in guide for keyboard shortcuts [1]. So I would like to ask design-team, if this feature is available and how. cc: Design-Team [1] https://wiki.documentfoundation.org/images/e/e4/GS7414-KeyboardShortcuts.odt (In reply to Dieter from comment #1) > Hossein, it seems, that nobody could confirm your report for half a year. I > don't use Persian keyboard layout, but I also couldn't find any information, > that LO has a shortcurt for ZWNJ. > > I couldn't find any information in oline help and also in guide for keyboard > shortcuts [1]. So I would like to ask design-team, if this feature is > available and how. > > cc: Design-Team > > [1] > https://wiki.documentfoundation.org/images/e/e4/GS7414-KeyboardShortcuts.odt Thank you Dieter, for your response. Actually, there are other methods available to insert ZWNJ other than pressing ctrl+shift+2, like assigning a shortcut to insert this specific character. The same method can also be used in MS Word. But, I expect that pressing ctrl+shift+2 also works. But, anyway, installing Persian keyboard in Windows is not that hard. It only takes a few clicks, and you may remove it later. For example, see: How To Type in Farsi (Persian) On Windows 10 https://www.lingalot.com/install-farsi-keyboard-windows-10/ What command should be assigned to the shortcut? We have these special break/character in the main menu <menu:menu menu:id=".uno:FormattingMarkMenu"> <menu:menupopup> <menu:menuitem menu:id=".uno:InsertNonBreakingSpace"/> <menu:menuitem menu:id=".uno:InsertHardHyphen"/> <menu:menuitem menu:id=".uno:InsertSoftHyphen"/> <menu:menuitem menu:id=".uno:InsertNarrowNobreakSpace"/> (done for bug 121596) <menu:menuitem menu:id=".uno:InsertZWSP"/> <menu:menuitem menu:id=".uno:InsertWJ"/> <menu:menuitem menu:id=".uno:InsertLRM"/> <menu:menuitem menu:id=".uno:InsertRLM"/> </menu:menupopup> </menu:menu> In any case I disagree with a shortcut for these rarely used commands. At least not for English. You can do easily define localized shortcuts similar to this <node oor:name="S_MOD1" oor:op="replace"> <prop oor:name="Command"> <value xml:lang="x-no-translate">I10N SHORTCUTS - NO TRANSLATE</value> <value xml:lang="en-US">.uno:Save</value> <value xml:lang="es">.uno:Underline</value> </prop> </node> The ctrl+shift+2 actually generates ZWNJ in Persian keyboard, so there should not be any command or shortcut needed. I compare it to having ß or § on a German keyboard. I assume that LibreOffice ignores this character on Windows for some reason. I have seen this behavior elsewhere, for example in Qt, and KDE. So, the request is not to ignore the ZWNJ character input from the keyboard. Ctrl+Shift+<1..6> control the number format but customization is disabled for some reason. It's defined in officecfg/registry/data/org/openoffice/Office/Accelerators.xcu <node oor:name="2_SHIFT_MOD1" oor:op="replace"> <prop oor:name="Command"> <value xml:lang="x-no-translate">I10N SHORTCUTS - NO TRANSLATE</value> <value xml:lang="en-US" install:module="unxwnt">.uno:NumberFormatScientific</value> </prop> </node> Doubt we can just set it an empty value to clear the shortcut for some language like <value xml:lang="per-FA"></value> MSO uses Ctrl+Shift+Caret [1], which is not possible cross-platform with our way to handle shortcuts. Could imagine a toggle function similar to upper/lower case instead of individual commands. [1] https://support.microsoft.com/en-us/office/keyboard-shortcuts-in-excel-1798d9d5-842a-42b8-9c99-9b7213f0040f (In reply to Heiko Tietze from comment #5) > Ctrl+Shift+<1..6> control the number format Only for Calc, while this bug is reported against Writer. Which suggests that the problem is somewhere else. > but customization is disabled for some reason. These keys are listed as reserved in https://opengrok.libreoffice.org/xref/core/vcl/source/app/svapp.cxx?r=5c73c3aa#107. But I have no idea why and how they are actually used. > Doubt we can just set it an empty value to clear the shortcut for some > language like > > <value xml:lang="per-FA"></value> > > > MSO uses Ctrl+Shift+Caret [1], which is not possible cross-platform with our > way to handle shortcuts. > > Could imagine a toggle function similar to upper/lower case instead of > individual commands. > > [1] > https://support.microsoft.com/en-us/office/keyboard-shortcuts-in-excel- > 1798d9d5-842a-42b8-9c99-9b7213f0040f (In reply to Heiko Tietze from comment #5) > Ctrl+Shift+<1..6> control the number format Only for Calc, while this bug is reported against Writer. Which suggests that the problem is somewhere else. > but customization is disabled for some reason. These keys are listed as reserved in https://opengrok.libreoffice.org/xref/core/vcl/source/app/svapp.cxx?r=5c73c3aa#107. But I have no idea why and how they are actually used. > Doubt we can just set it an empty value to clear the shortcut for some > language like > > <value xml:lang="per-FA"></value> This actually might work. Looking at the code in XCUBasedAcceleratorConfiguration::impl_ts_load we seem to leave the shortcut as undefined in case of an empty command, and not falling back to en-US. (In reply to Maxim Monastirsky from comment #7) > These keys are listed as reserved in... IIRC, Miklos told me that reserved keys are used for some development testing. > > ...we can just set it an empty value to clear the shortcut... > This actually might work. Looking at the code in > XCUBasedAcceleratorConfiguration::impl_ts_load we seem to leave the shortcut > as undefined in case of an empty command, and not falling back to en-US. Hossein, mind to test this? Would be the safest solution. (In reply to Heiko Tietze from comment #8) > IIRC, Miklos told me that reserved keys are used for some development > testing. Hm, I can't recall that. I'm afraid I don't know much about those reserved keys, either. Platform-specific reserved keys are ugly. (In reply to Heiko Tietze from comment #8) > (In reply to Maxim Monastirsky from comment #7) > > These keys are listed as reserved in... > IIRC, Miklos told me that reserved keys are used for some development > testing. > > > > ...we can just set it an empty value to clear the shortcut... > > This actually might work. Looking at the code in > > XCUBasedAcceleratorConfiguration::impl_ts_load we seem to leave the shortcut > > as undefined in case of an empty command, and not falling back to en-US. > > Hossein, mind to test this? Would be the safest solution. Unfortunately this change didn't help. Even removing the whole node didn't change anything, and the shortcut wasn't usable. My patch https://gerrit.libreoffice.org/c/core/+/152279 got no reply and since I cannot test myself I'm going to abandon it. For dev advice see ESC minutes in https://listarchives.libreoffice.org/global/projects/msg02950.html A code pointer to start debugging: ImplHandleKeyMsg in vcl/win/window/salframe.cxx |