[HN Gopher] WinCompose - A Compose Key for Windows ___________________________________________________________________ WinCompose - A Compose Key for Windows Author : mkotowski Score : 166 points Date : 2021-08-13 15:00 UTC (8 hours ago) (HTM) web link (github.com) (TXT) w3m dump (github.com) | amyjess wrote: | WinCompose is one of a handful of utilities that's made using | Windows virtually painless as someone who's used to using Linux | as a daily driver. | | (other such utilities include Chocolatey, MobaXterm, Greenshot, | WSL in general for common CLI tools, and some KDE apps but | especially Kate and Okular) | MiddleEndian wrote: | Also worth checking out is Ditto, clipboard history manager. | Much snappier and lighter than the built-in one they eventually | put into Windows. Nearly identical to KDE's Klipper, CTRL ` and | your searchable clipboard history appears next to your cursor. | nickjj wrote: | > Much snappier and lighter than the built-in one they | eventually put into Windows | | Ditto also supports searching through your clipboard history. | Been using Ditto for years. | MiddleEndian wrote: | It's really a killer utility. I find it to be slightly | better than KDE's Klipper and much better than Butler as a | clipboard in OS X (although it's been many years since I've | used Butler) | leokennis wrote: | Love that app. The built in one does not show tons of stuff | you can copy to your clipboard. | | I work in IT and people are baffled when I copy a few things, | paste them one by one, then search for a thing I copied a | week ago...I feel naked without Ditto. | francislavoie wrote: | I prefer Scoop over Chocolatey https://scoop.sh/ | | Also Windows Terminal is really great | https://www.microsoft.com/en-us/p/windows-terminal/9n0dx20hk... | | I also prefer ShareX for screenshots https://getsharex.com/ | pitaj wrote: | I just use the built-in screen snip. You can configure it to | activate on press of the "print screen" key. | cpmsmith wrote: | It's also bound to Windows-Shift-S by default, as of 2018 | francislavoie wrote: | I like to be able to records gifs/mp4s quickly as well, for | reporting some issue with an animation on a website or | whatever. On Linux I like to use Peek for that, and I use | the built-in Screenshot tool otherwise on Ubuntu. | 0XAFFE wrote: | On windows you can use win+g which allows you to record | videos of the current window. I think it's for games but | it works for everything else pretty well. | leokennis wrote: | A nice alternative for MobaXterm is Royal TS, especially for | maintaining a list of 100's of servers and simultaneously | executing commands on a subset or all of them: | | https://royalapps.com/ts/win/features | aphit wrote: | I started to use WinCompose when I changed from a full size | keyboard (with numpad) to a TKL keyboard which omits it. | | As a mechanical engineer, I often need to type things like the | degree symbol and with WinCompose it is just Compose, o, o | whereas I used to type these using alt codes. | | Other common uses are for sub and super scripts (11), bullets | (*), and my own custom ones like on for my email, which I set as | Compose, e, m (since these days working from home I am constantly | logging into lots of things). | pier25 wrote: | Off topic... but damn, Windows emojis are still super ugly. | | Anyone knows if they are better in Windows 11? | robmerki wrote: | Totally agree. Apparently they're getting an overhaul: | https://www.xda-developers.com/microsoft-emoji-windows-11-mi... | pier25 wrote: | Oh wow these look great! | Proven wrote: | I think I'd like to use this to enter my SSO password on | corporate web sites. | ryanschneider wrote: | Total aside but I never knew about the `kbd` HTML tag used for | the key sequence renderings in the readme. | | https://developer.mozilla.org/en-US/docs/Web/HTML/Element/kb... | tangus wrote: | This is great! It's a shame XCompose doesn't follow rfc1345 | though, which is the input method I use on Emacs. I have to learn | two different sets of composing sequences :( | | (Fortunately they seem to agree on the majority of the accented | Latin letters I use.) | jamal-kumar wrote: | The guessability of combos to compose characters with is really | key to what makes the compose key a great tool. I wouldn't be | surprised if Microsoft adopts this into their OS someday. | cjauvin wrote: | I'm a big fan of the compose key, both for its universality and | intuitive "syntax". For many years I endured the pain of a dual | French/US keyboard layout (one for writing, the other for | coding), until a coworker showed me the special Option-key | shortcuts you can use on a Mac to make French accents, and then | finally I settled on the nice and intuitive Compose Key support | offered natively by Ubuntu: | https://help.ubuntu.com/community/ComposeKey | bombela wrote: | On Linux/xorg I use the qwerty international layout and a dead | compose key for the rarely used symbols. | | Example: e is "altgr+e", c is "altgr+", while O is "right-ctrl, | shift+w" and 6 is "right-ctrl,^,6" etc. | | You can do it all with the compose key. But for typing in | french I find altgr+e to be faster than "rightctrl,',e". | pbhjpbhj wrote: | I was trying to make a grave accent, opposite direction to an | acute, on Win10 - everything I tried seemed to make acute | accents ... how do I, please? | dhimes wrote: | Windows uses what they call "alt codes," where you hold | down the alt key and type a numerical code on your numeric | keypad. You can find them with a search: here's one site: | | https://sites.psu.edu/symbolcodes/windows/codealt/ | | Note that you can't just do an accent and apply it to any | character (like compose). You have to put in the code for | the accented character. | baq wrote: | nowadays the easiest way is to google the character by its | name and add "unicode", then copy-paste, unless you do it a | lot. | | e.g. "a acute unicode" yields | https://www.compart.com/en/unicode/U+00E1 | gsich wrote: | That's not really easy... | gerardvivancos wrote: | Assuming US keyboard, you can use US International as a | secondary layout. That would make typing "single quote" | then the letter an acute accented letter. | | So ' then a would become a | tinus_hn wrote: | The difference is if you don't use these characters a lot, | compose+accent, letter is a lot easier to remember than | altgr+random key. | | Especially when it's not printed on your keyboard. | tasogare wrote: | I'm using a logical FR layout on a physical Mac FR layout, the | underlying layout for Japanese input is QWERTY while the pinyin | for Traditional Chinese uses AZERTY... I'm tired of all these | context switches and I wish there was an universal keyboard IME | that allow me to type the languages I care about without having | to switch between IME all the time. Same complains about mobile | (iOS). I might build something one day because of how annoying | it is (at least typing English is easy from FR keyboard so | that's one less keyboard to use). | TacticalCoder wrote: | Basically the same here, now I settled on QWERTY with a few | tricks to do french diacritic signs. Compose key can be a bit | slow at times, so I only use it for the less common characters, | like e-circumflex. For the really common ones like e-acute and | e-grave I simply assign additional shortcuts: for example | hyper+e = e-acute (my keyboard has got additional modifier | keys: it's not just ctrl/alt/shift as I've got additional | physical keys, which I configured to act as Hyper and Super). | gerardvivancos wrote: | I also use dual layouts and found that switching between US | (for coding) and US international (typing with diacritics) is | the most comfortable setup for me. Both in Win and Mac | switching between both modes is just pressing Ctrl+Space and | the US international layout allows me to type all diacritics I | use (Catalan) with an US keyboard. | | Maybe I'm just stating the obvious and everybody already knows | and is moving aware from that, so I won't explain the details. | But if someone is interested just let me know | yetanother-1 wrote: | Same issue. | | I struggeled with french on German keyboard, so I searched how | to type everything, and all wad easy except the c. | | The only solution was to type ALT+135 from the keypad. It | worked until a recent windows update, now I get garbage from | that shortcut. | | I will give this a try, thanks! | igitur wrote: | I had a similar problem recently, but it was self-inflicted. | | Try changing the status of the "Beta: Use Unicode UTF-8 for | worldwide language support" checkbox. | | You can see this option by going to Settings and then: All | Settings -> Time & Language -> Language -> "Administrative | Language Settings" | ethhics wrote: | Being a plan 9 nerd, I originally found 9ime [1] when I wanted a | compose key in windows. It serves the same purpose and has the | same default compose key of right-Alt. I've yet to be frustrated | by it enough to switch to wincompose (but the UX is certainly | better). | | [1] https://github.com/sqweek/9ime | TriStateFarmer wrote: | I want to try this, is there a prebuilt binary available. | lloydatkinson wrote: | How does this compare to the built in Win + .? | asxd wrote: | Wow, I had no idea this was a thing. Not to distract from the | thread, but thanks for sharing! | nybble41 wrote: | The Win + . sequence opens the Emoji selector window, which as | the name implies can only be used to select emojis. It's also | more disruptive since it opens a separate window where you must | navigate to or search for the desired emoji, select it, close | the window, and then paste the selection into the original app. | WinCompose (like XCompose) works as you are typing, without | opening a new window; you just type a certain sequence starting | with a special Compose key (like "Right-Alt ( 3 )") and it | inserts arbitrary pre-defined characters (in this case 3). The | key sequences and their replacements can be redefined by the | user. | k12sosse wrote: | If you win+. from the carat/focus on text input, just type a | hint for the emoji and hit enter (or use arrow keys to select | other result) and it should replace the string you typed. | i.e. win+. Skull | nybble41 wrote: | Interesting. That was not my experience. I could type to | search, but pressing enter just showed a message about | copying the emoji to the clipboard. This was over a Remote | Desktop connection, so perhaps that affected the behavior? | Or it might depend on the specific type of text input | field. | | In any case, most of the characters I use XCompose for | (such as arrows, mathematical operators, Greek letters, and | non-ASCII punctuation) are not emojis and cannot be | selected this way. | falcrist wrote: | It looks like the whole Greek alphabet is accessible in | the pop up window | | aDdekbeThthLlGgzIimnpPTtKhKsxRrUuPsSssPhphOkhao | falcrist wrote: | > as the name implies can only be used to select emojis | | It has a tab for emojis, a tab for "kamoji" (emoticons), and | a tab for what looks like a decent chunk of the non-asian | symbols in the unicode basic multilingual plane. (c)(tm)||== | | I don't know about everyone else, but in my copy of Windows | 10, Win+. opens a small window attached to the text box I'm | typing into. I can then type the name of the symbol I'm | looking for, hit enter, and the symbol is inserted into the | text box. Escape closes the box, so I don't even have to | touch my mouse. | | https://i.imgur.com/FsDc7F9.png | | To be clear, it _is_ somewhat more disruptive, but requires | no prior knowledge of anything except how to open it. There | 's room for both methods. | MiddleEndian wrote: | Wincompose can handle emojis, Compose compose g o b l i n will | give you a tengu ("Japanese goblin") emoji for instance. But | it's on you to try to guess what you think their names are and | I usually fail. | | I prefer the Win . for emojis. | rtkwe wrote: | Cute. My least favorite part of any language class I've ever | taken is if I have to type anything outside of the standard US | english alphabet, the standard alt code method was never good. | mkotowski wrote: | Well, at least it wasn't at the level of pain of getting any | IME to work on Linux (not that Windows is much better in that | regard...). | binrec wrote: | It's not an off-the-shelf solution, but what I do is roll my | own keyboard layout with MSKLC. | Kaze404 wrote: | Do you know if such a tool exists for Linux? I would like to | use the US-INTL keyboard, as it allows me to write | international characters easily, but comes with the downside | that ' and " are dead keys, which makes programming annoying. | | I did once manage to manually write a keyboard layout that | gets around that, but it was a painful process and I've been | since looking for a tool that allows me to create keyboard | layouts more easily. | | edit: I did a quick search and it seems that such a keyboard | layout already exists. Here it is in case it's useful to | anyone else: https://pieter-degroote.github.io/UltimateKEYS/ | mackrevinack wrote: | these days i prefer to use menus like Rofi for things like this. | all you need to memorise is 1 hotkey to open the menu and then | you can search and filter the list to find whatever character you | want, say 'trademark' or 'tra' to find (tm), or search for an | emoji by describing it | pessimizer wrote: | You don't have to memorize compose key combinations unless you | use a few strange ones often. "Compose", "t", "m" gives me | "(tm)". Your first guess is usually right. | porker wrote: | Rofi won't work on Windows, will it? | emmanueloga_ wrote: | I was wondering why Windows doesn't come with a built in compose | implementation. There doesn't seem to be a reason, just something | that exists outside of the folklore of Microsoft/Windows [1]. | | 1: https://en.wikipedia.org/wiki/Compose_key | BrandoElFollito wrote: | Isn't this something that can be done in AutoHotkey? | | I feel that it is more effective to have a powerful tool such as | AHK and invest a bit into writing the combinations of | key/mouse/whatever than to have several standalone programs. | mkotowski wrote: | Actually, WinCompose started as an AHK script, so your | conclusion isn't far off. | nolok wrote: | The same way "2003 google can be done by yahoo" I guess | BrandoElFollito wrote: | Sorry but I do not understand this comment, can you please | clarify? | TriStateFarmer wrote: | This WinCompose app seemed to be what I've been looking for, but | it didn't work for me. | | Just so sluggish, sometimes missing keystrokes or waiting for it | to catch up. Keyboard is one of those things that have to be | INSTANT, even milliseconds is too long. This app is way to slow. | | It seems to be written in .NET? Which would be a very poor choice | for such an app. | | EDIT: I presumed the sluggishness was because of .NET, perhaps my | thinking is a bit dated. | aphit wrote: | I haven't had this experience at all, for whatever it's worth. | I type ~120-130wpm for reference. | mikkelam wrote: | Why do you think that .NET is a poor choice? | alkonaut wrote: | .NET (framework) should be a very compelling choice for a win- | only tray app. The framework is included with the OS, and the | standard libraries will most likely already be in memory. The | process footprint will be tiny and if the app is written | correctly, it should be quite possible to make a very resource | friendly app. | Semaphor wrote: | Related but different (and no emoji special features), I was once | recommended (either here or on Reddit) EurKEY [0] and have been | using it since. O is (AltGr/Ctrl+Alt)+Shift+o. | | I mainly type in English (and prefer it for programming), but I | still need German Umlauts, it's just a super convenient layout | and even has niceties like typographical apostrophes (' vs ') | built in (ctrl+shift+alt+0). | | To me, that seems more convenient than this (and Windows has a | decent emoji picker with Win+. anyway, if you are into that ) | | [0]: EurKEY The European Keyboard Layout | https://eurkey.steffen.bruentjen.eu/ | kzrdude wrote: | I'm on Linux and on a keyboard layout that already uses AltGr for | a lot of symbols. What key do you use for the compose key? I | certainly don't have a physical compose key on my keyboards. | kelnos wrote: | As documented in the linked README, they use right-alt as | compose, but that can be changed in the settings. | kzrdude wrote: | That's the readme for WinCompose. I'm wondering about linux | pricci wrote: | Maybe the menu key, if you have it | bmn__ wrote: | I use capslock. | | There are a number of popular choices that come preconfigured, | see file /usr/share/X11/xkb/rules/base.lst line 851 | | https://github.com/freedesktop/xkeyboard-config/blob/master/... | yc-kraln wrote: | I don't understand how this is different than the "International" | keyboard variants that ship with Windows. | | How is this better than the status quo? | mkotowski wrote: | Compose key -- and by extension WinCompose -- is used as a | mnemonic shortcut for various characters, both predefined and | custom. | | For example, I am using WinCompose right now: ... ' c ss a @ " | << ^ x th d n't d Y. All the characters inserted without | leaving hands off keyboard. | | As far as I know, there is no built-in keyboard on Windows with | that kind of functionality (the emoji keyboard under `Win+.` | coming close, but with no customization and more centered on | inputting singular characters rather than blending in with | normal keyboard usage). | mavhc wrote: | https://support.microsoft.com/en-us/topic/how-to-use-the- | uni... | | "Creating international characters | | When you press the APOSTROPHE ( ' ) key, QUOTATION MARK ( " ) | key, ACCENT GRAVE ( ` ) key, TILDE ( ~ ) key, or ACCENT | CIRCUMFLEX,. also called the CARET key, ( ^ ) key, nothing is | displayed on the screen until you press a second key:"... | jorams wrote: | The constant downside to that is that you can no longer | type these characters without considering what the next | character is going to be, and pressing space if you want to | opt out of the combination. If you type the accented | characters much more often than the quotes it can be fine, | but it gets annoying very quickly while programming. | | The compose key is basically an opt-in alternative to | combining those characters that also allows a lot of other | combinations. | shawnz wrote: | If you are willing to create your own layout or use a | third-party layout, you could forgo dead keys and instead | put all your symbols on the "AltGr" layer (which I think | basically works the same as the "Compose" key). | Springtime wrote: | Autohotkey is also useful for this. Any arbitrary set of | characters can be auto replaced with the desired output, or | alternatively be bound to a hotkey. | | This removes the need to memorize some abstract set of Alt | key sequences and instead one could type something such as | _++degree_ to produce deg. The sequence of characters could | be anything to distinguish it from regularly used text, here | using _++_ and name of the symbol to illustrate. | | WinCompose it appears uses a similar principle. | frosted-flakes wrote: | Fun fact, WinCompose used to be written in AutoHotkey. It's | still shown as a branch on GitHub: | https://github.com/samhocevar/wincompose/tree/autohotkey | kindall wrote: | I started writing my own WinCompose-like utility in | AutoHotkey, before I learned about WinCompose. Gave up on | that immediately, obviously. | | AutoHotkey is really an amazing tool. The actual | programming language is awkward, but it has capabilities | no other tool offers without writing a bunch of tricky | low-level C code yourself. | hollasch wrote: | That's my approach. Autohotkey plus sequences starting with | "qq", like qqdeg (degree), qq>- (right arrow), and so | forth. | lithiumfrost wrote: | For one, the character coverage is much broader than what's | typically found on an international keyboard. | | I use it all the time for typing arrows and other symbols, for | example. YMMV but I also find it mnemonically better, from time | to time I can just guess what the right Compose sequence is. | shawnz wrote: | Wouldn't it be better to just create a new keyboard layout | featuring the composed keys you want, rather than running | software constantly in the background to achieve the same | thing? | | See here for example: https://dailydoseoftech.com/how-to- | create-a-custom-keyboard-... | jtvjan wrote: | Not really. I don't know in advance which symbols I want to | type, and even then I'd have to learn where I put the | symbols on the custom layout, while the compose sequences I | can usually guess. Considering the amount of background | processes the typical Windows system runs, having one | additional program really doesn't make a difference. | shawnz wrote: | I don't necessarily mean that each individual user of the | software should do this. I mean, why not just create a | new layout instead of developing this? Or as a user, why | not just use a layout someone else has already developed | which has logical choices for the composed keys? | | EDIT: Some compelling arguments in favour of the app in | this thread. Thank you | frosted-flakes wrote: | Because a Compose key allows you to type any of thousands | of characters, which (a) isn't possible with a custom | keyboard layout, and even if it was, (b) would be very | difficult to learn. | shawnz wrote: | What makes this easier to learn? I think you could | implement the same kinds of sequences by using AltGr | combined with dead keys. | frosted-flakes wrote: | So you're going to turn every key on the keyboard into a | dead key? Also, the compose file can easily be | customized, and some entries output multiple characters | or involve non-character keys like the arrows. How is | that going to work with a static keyboard layout? | shawnz wrote: | Only AltGr + [the key] would be a dead key, not the bare | key itself. Perhaps a tool could be made to convert | compose files into Windows keyboard layout definitions | with this strategy | | That's a good point about non-character keys though, I | don't think that could be supported with this method. | Symbiote wrote: | You'd swiftly run out of practical combinations. | | On the 1 key, I have 1 and !. Maybe I could add 1 and 1, | with AltGr and Shift+AltGr (or Ctrl, or something). Maybe | 1/2 and 1/4? | | With Compose, I have 1, 1, 1/2, 1/3 , 1/4, 1/5 , 1/6 , | [?], 1/8 , [?], [?], 1, 10, 11, ... 41 which involve the | 1 key. I do not need to look up the sequences for these, | as they're intuitive: Compose ^ 1, Compose _ 1, Compose 1 | 2, ... Compose ( 4 1 ). | shawnz wrote: | You could maybe use AltGr combined with dead keys to | accomplish that, but I suppose it would be limited to | combinations of two keys (plus the modifier). | | EDIT: Actually, it seems Windows supports chained dead | keys, so I think you could accomplish longer sequences | with a plain old Windows keyboard layout definition too. | But that's not supported with MSKLC. | sterlind wrote: | you can't compose keyboard layouts, so you'd either have | to stick with only QWERTY or generate separate enhanced | layouts for Azerty + Dvorak + etc. discoverability would | also be harder, and you'd have to hold down every key in | the combo instead of pressing them in sequence holding | the compose key, so you couldn't distinguish /ae/ vs /ea/ | and you'd get carpal tunnel. | | side-note: X11 layouts are really frustrating. there's a | hard constraint of one key combo -> one Unicode | character, which makes it impossible to output multiple | characters. I run into this with Lushootseed, which has | /l/ (glottalized barred lambda encoded as barred lambda + | accent marker), but you'd never write it without the | accent in that language. | MiddleEndian wrote: | Say I want to type the copyright symbol, not something I do | every day, not something worth its own key on my keyboard. I | type Compose O C and it gives me: (c), Compose ~ ~ gives me | [?], | | The built-in shortcuts are very easy to guess, it's great for | things I don't type every day. Plus you can add or remove | shortcuts so you can change your layout on the fly. | | It's great in Windows, Compose is great in Linux, and it's also | is a good alternative for the otherwise useless CapsLock key. | asciimov wrote: | I'll have to remember this when I go back to windows one day. | | I roll my own keyboard layout on Linux, and the Compose key is a | nice to have. I put it where the right Alt normally lives along | with the dead greek key (by using shift-RALT). | cush wrote: | For emojis WIN+. is my go to. | pseudosavant wrote: | The touch keyboard can be really useful for any other special | characters too. Just hold your click down on the key and you'll | see other variants (e.g. S = sssSS). I wouldn't rely on it to | constantly type characters like that, but it is great every | once in a while. | alexanderh wrote: | Looks like a great project template for making a robust | keylogger. Neat. | alkonaut wrote: | Why is it composing e.g. ' + e into e when that's the default | behavior without composing? Is it just to make the compose key a | no-op in all such scenarios? | pier25 wrote: | For accents and such a good alternative is selecting an | international keyboard on Windows. For example you can write a n | with ALT + N. ___________________________________________________________________ (page generated 2021-08-13 23:00 UTC)