summaryrefslogtreecommitdiff
path: root/sys/src/cmd/ktrans
AgeCommit message (Collapse)Author
2023-04-25ktrans: correct 'exit' text (thanks Keegan)Jacob Moody
終了 is more appropriate then 出口 in this context.
2023-02-19mkfiles: add 'mk test' supportOri Bernstein
9front has several tests scattered throughout the source, as well as more tests in an external 'regress' repository. Many of these tests are broken, because there is no easy way to build and track all of them. This pulls in several tests from different sources, deletes the broken tests, tests with missing data, and adds a single command that can be run from the root of the src directory to test our system. The hope is that as we develop new code, we add more tests, and eventually start running the tests on every commit. Please enter the commit message for your changes. Lines starting
2023-01-31ktrans: tests and various bug fixesJacob Moody
* exit if we get eof on kbdtap * do not nuke the line if we restore a kanji selection without okurigana * guard against unfortunate scheduling, the dictthread needs to get through all it can before the keythread processes more. In typical use, the processing was fast enough to never notice this condition but writing out a large set of input can trigger it.
2023-01-30ktrans: simplify kbdtap read loopJacob Moody
we were not handling multi null delimted messages with one read. This makes us a bit more uniform to other handling on the system as well ... something about clever code.
2022-10-12ktrans(1): remove README filesJacob Moody
While the logic described in these has been preserved carefully and still accurate, the man page now covers all that is presented and includes documentation on newer features.
2022-10-12ktrans: revisit grammer handling and do some spring cleaningJacob Moody
Revisiting the man page example and README from the original ktrans there was some descripency on how to handle punction marks and special characters. Notably 。(.) and 、(,) need special casing. If we have anything in the buffer we need to tack on these characters as an Okuri tail and avoid the actual punction from entering the Kanji buffer. Newlines were previously modified to be taken as a completion if there was runes in the buffer. This has been backed out, instead Shift + Space can serve this role via kbmap should they prefer (and as is done in the jp kbmap). Instead we treat newlines as hints to reset the buffer. There was also a bug in where after cycling through all options the original hiragana was not printed back. This has been corrected. The max number of candidates has been bumped to 32 and moved to an enum. This does nearly double our resident memory size, but we reguarly had matches exceed this limit. A better solution is slated. The man page now makes an attempt to explain the rules around Okuri and Joshi input modes.
2022-10-09ktrans: gui and man page reworkJacob Moody
Graphical display shows current candidate list.
2022-09-30ktrans: listen on lang port for plumberJacob Moody
This also does some slight style normalization and removes the Msg struct in favor of just using a plain char array. The previous kbdsink fprint calls were incorrect and was not passing upon the null bytes.
2022-09-28rio: ensure single reader and single writer for kbdtapJacob Moody
Multiple readers eat each other's lunch, and it makes more sense to limit use to one 'pipeline' then just one reader. This also brings back the 'focus' message from kbdtap used by ktrans to reset its line buffers when the user switches windows. An event file was considered, but deemed harmful to the artwork. To paraphrase an old excuse found in the code: "rio just isn't structured for that. Apologies."
2022-09-21ktrans: clean headersJacob Moody
we no longer serve 9p
2022-08-23ktrans: xin chàoJacob Moody
Add telex Vietnamese input.
2022-08-17ktrans: use stdio by defaultJacob Moody
The kbdtap is now given as the first argument instead. The use of stdio allows for multiple taps to be chained together in something like: ; </dev/kbdtap ktrans | progB | progC >/dev/kbdtap
2022-08-15ktrans: tow inside the environmentJacob Moody
2022-08-08ktrans: cast switch statement for armJacob Moody
2022-08-03ktrans: 新しい降りJacob Moody
Rewrite of ktrans to act as an overlay to kbdfs. Move map files outside of the binary in to /lib/ktrans and get our dictionaries out of /lib while we're at it. Use \n as an alias for ctrl-\ for first lookup, use ^w to clear okurigana input. This also in general changes the logic to never us to 'swallow' a character and always echo them out, using backspaces for cleaning us up.
2022-07-17ktrans: don't leak on conflicting jisho linesJacob Moody
Tidy up the hash interface to make cleanup a bit more explicit vs non cleanup.
2022-07-17ktrans: 你好Jacob Moody
This consolidates jisho and map lookups to use the same structure and removes the old jisho code.
2022-07-06add ktrans. こんにちは!rodri