diff options
Diffstat (limited to 'public')
-rw-r--r-- | public/assets/style.css | 43 | ||||
-rw-r--r-- | public/footpedal.md | 93 | ||||
-rw-r--r-- | public/message-threading.md | 76 | ||||
-rw-r--r-- | public/relax-ng-errata.md | 42 |
4 files changed, 227 insertions, 27 deletions
diff --git a/public/assets/style.css b/public/assets/style.css index f345dc1..8fa9dbf 100644 --- a/public/assets/style.css +++ b/public/assets/style.css @@ -9,13 +9,6 @@ body { font-family: sans-serif; } -blockquote { - border-left: solid .2em #DDDDFF; - margin-left: 1.5em; - padding-left: 0.3em; - font-style: italic; -} - footer { text-align: center; font-size: 70%; @@ -26,32 +19,28 @@ footer { li > p:first-child { margin-top: 0; } li p + ul { margin-top: -1em; } +/* blockquote elements */ + +blockquote { + border-left: solid .2em #DDDDFF; + margin-left: 1.5em; + padding-left: 0.3em; +} +blockquote cite { + font-style: italic; +} +blockquote cite::before { + content: "-- "; +} + /* code elements */ kbd, code, samp, tt, pre { background: #DDDDFF; -} -kbd, code, samp, tt, { - white-space: pre-wrap; -} -@media screen { - /* Firefox for Android does weird hacks with font-size. In - * particular, `white-space: pre` is broken on Firefox for - * Android if you don't set an absolute font-size. So this is - * a hack to get reasonable behavior without setting - * `white-space: pre`. */ - pre { - white-space: pre-wrap; - overflow-x: auto; - } - pre > code { - white-space: pre-wrap; - display: block; - min-width: max-content; - } + white-space: pre; } @media print { - pre, pre > code { + kbd, code, samp, tt, pre { white-space: pre-wrap; } } diff --git a/public/footpedal.md b/public/footpedal.md new file mode 100644 index 0000000..57c1d92 --- /dev/null +++ b/public/footpedal.md @@ -0,0 +1,93 @@ +My footpedal +============ +--- +date: "2025-05-31" +markdown_options: "+superscript" +--- + +A collection of things I have written about the footpedal that I +sometimes use with my computer: + +---- + +> I have a VEC Infinity IN-USB-2 that I grabbed at Goodwill for $5. +> +> I love it. I tend to use it less when the RSI isn't flaring up, but +> the first time I had RSI being bad is when I started to use it--it +> really helped. My RSI was in the few fingers on the pinky-side of +> my hands (so the opposite of <abbr title="Carpel Tunnel +> Syndrome">CTS</abbr>; I'm told this is less common, but I'm figuring +> it's more common for Emacs users, with all the talk of +> "Emacs-pinky"), and much worse on my right hand. The pedal has 3 +> keys; I have them as (left-to-right) Control, Shift, and Alt/Meta, +> with the addition that if I short-tap the center, it does Enter; +> this basically means that I can avoid using my right pinky at all +> when typing. This allowed me to keep using the computer without +> making things worse, while I did other things to improve the RSI +> (stretches, wearing wrist braces at night). The tap-for-Enter seems +> a bit weird, but I added it after that motion seemed instinctual +> when using left-button for control in a repeated C-s search; hold +> foot-left and tap keyboard-S to increment search, then tap +> foot-center to complete the search. +> +> About the IN-USB-2 specifically: +> +> ***It's an XK-3:*** It's actually made by P.I. Engineering for VEC; +> it's a [rear-hinged X-Keys +> XK-3](https://web.archive.org/web/20180119/http://piengineering.com/xkeys/xkfootRear.php)^([updated +> link](https://xkeys.com/xkfootrear.html))^ with a different (less +> capable) firmware. The benefit of the crippled firmware is that the +> IN-USB-2 is way cheaper than buying a "real" XK-3 (even without +> finding one at Goodwill). +> +> ***Firmware:*** On the downside of that, the firmware is less +> capable; unlike the XK-3, it shows up as a generic HID device with 3 +> buttons, instead of as a keyboard, and thus you can't configure +> which button is which key. That is, you'll have to have a program +> running to monitor the HID buttons and synthesize whichever key +> events you want, instead of configuring the keys on the device. +> Fortunately, the device is supported by P.I. Engineering's Linux +> SDK, +> [`pihid`](https://web.archive.org/web/20180119/http://xkeys.com/PISupport/DeveloperLinuxSDK.php)^([updated +> link](https://xkeys.com/software/developer/developerlinuxsdk.html))^ +> ([git](https://github.com/piengineering/xkeys)), so that program is +> fairly easy to write (and as an Emacs user, you probably appreciate +> that configuration-is-code gives you more flexibility). The `pihid` +> SDK is a crappy little wrapper around the `hidapi` library with the +> appropriate magic numbers for the hardware. `hidapi` is portable to +> macOS; I imagine that getting `pihid` working on macOS is no trouble +> at all. (IDK if their +> [ControllerMate](https://web.archive.org/web/20180119/http://piengineering.com/PISupport/SoftwareControllerMate.php) +> program for macOS works with it, or if ControllerMate requires the +> real XK-3 firmware.) +> +> ***Hardware:*** The thing feels sturdy. If the switch ever craps +> out (not that I think it would), it's a generic switch that's in +> everything that you can pick up for $0.50; which is nice for +> peace-of-mind. The middle button feels a little wide; I generally +> have my foot around the left side of it, for Control, and it is +> difficult to reach over to the right for Meta, and usually end up +> hitting Meta on the keyboard instead. +> +> <cite>[Reddit, 2018-01-19](https://reddit.com/r/emacs/comments/7remed/has_anybody_used_foot_pedals/dswhzkt/)</cite> + +---- + +> I love it, but I don't necessarily love it *more than I would any +> other foot pedal*. If you find a different one for cheaper, go for +> it. +> +> <cite>[Reddit, 2018-01-19](https://reddit.com/r/emacs/comments/7remed/has_anybody_used_foot_pedals/dswrf3r/)</cite> + +---- + +> I found that my brain didn't want to treat the pedals like it did +> keys--it wanted to treat them modally. I wasn't *pressing control*, +> I was *entering control-mode*. I wasn't *pressing shift*, I was +> *entering caps-mode*. Which works out, because it isn't the quick +> keystrokes that cause the most strain, it's holding the modifier +> with one finger while the rest of the hand moves around. I wouldn't +> use the footpedal Control for the usual quick C-f/b/n/p, but it's +> great for holding Control as you C-s through a document. +> +> <cite>[Reddit, 2018-01-19](https://reddit.com/r/emacs/comments/7remed/has_anybody_used_foot_pedals/dswrmo5/)</cite> diff --git a/public/message-threading.md b/public/message-threading.md new file mode 100644 index 0000000..a710631 --- /dev/null +++ b/public/message-threading.md @@ -0,0 +1,76 @@ +Notes on email message threading +================================ +--- +date: "2024-06-08" +markdown_options: "-smart" +--- + +> I sent an email to Jamie Zawinski with feedback on his venerable +> email threading algorithm. Perhaps my commentary will be a useful +> reference to others implementing email threading. +> +> You can see my implementation of his algorithm at +> <https://git.lukeshu.com/www/tree/cmd/generate/mailstuff/thread_alg.go> +> (and a use of it at +> <https://git.lukeshu.com/www/tree/cmd/generate/mailstuff/thread.go>). + +<div style="font-family: monospace"> +To: [Jamie Zawinski] [<jwz@jwz.org>]<br/> +Subject: message threading<br/> +Date: Sat, 08 Jun 2024 22:34:41 -0600 +Message-ID: <87tti2ybry.wl-lukeshu@lukeshu.com> +</div> + +Hi, + +I'm implementing message threading, and have been referencing both +your document [<https://www.jwz.org/doc/threading.html>]; and [RFC 5256]. +I'm not sure whether you're interested in updating a document that's +more than 25 years old, but if you are: I hope you find the following +feedback valuable. + +You write that the algorithm in RFC 5256 is merely a <q>restating</q> of +your algorithm, but I noticed 3 (minor) differences: + +1. In your step 1.C, the RFC says to check whether this would create a + loop, and if it would to skip creating the link; your version only + says to perform this check in step 1.B. + +2. The RFC says to sort the messages by date between your steps 4 and + 5; that is: when grouping by subject, containers in the root set + should be processed in date-order (you do not specify an order), + and that if container in the root set is empty then the subject + should be taken from the earliest-date child (you say to use an + arbitrary child). + +3. The RFC precisely states how to trim a subject down to a "base + subject," rather than simply saying <q>Strip \`\`Re:'', \`\`RE:'', + \`\`RE[5]:'', \`\`Re: Re[4]: Re:'' and so on.</q> + +Additionally, there are two minor points on which I found their +version to be clearer: + +1. The RFC specifies how to handle messages without a Message-Id or + with a duplicate Message-Id (on [page 9]), as well as how to + normalize a Message-Id (by referring to [RFC 2822]). This is perhaps + out-of-scope of your algorithm document, but I feel that it would + be worth mentioning in your background or definitions section. + +2. In your step 1.B, I did not understand what <q>If they are already + linked, don't change the existing links</q> meant until I read the + RFC, which words it as <q>If a message already has a parent, don't + change the existing link.</q> It was unclear to me what <q>they</q> was + referring to in your version. + +<div style="font-family: monospace"> +-- <br/> +Happy hacking,<br/> +~ Luke T. Shumaker<br/> +</div> + +[Jamie Zawinski]: https://www.jwz.org/ +[<jwz@jwz.org>]: https://www.jwz.org/about.html +[<https://www.jwz.org/doc/threading.html>]: https://www.jwz.org/doc/threading.html +[RFC 5256]: https://datatracker.ietf.org/doc/html/rfc5256 +[RFC 2822]: https://datatracker.ietf.org/doc/html/rfc2822 +[page 9]: https://datatracker.ietf.org/doc/html/rfc5256#page-9 diff --git a/public/relax-ng-errata.md b/public/relax-ng-errata.md new file mode 100644 index 0000000..1de39be --- /dev/null +++ b/public/relax-ng-errata.md @@ -0,0 +1,42 @@ +RELAX NG Compact Syntax errata +============================== +--- +date: "2024-07-10" +markdown_options: "-smart" +--- + +<div style="font-family: monospace"> +To: relax-ng-comment@lists.oasis-open.org, jjc@jclark.com, eb2m-mrt@asahi-net.or.jp<br/> +Subject: RELAX NG Compact Syntax errata<br/> +Date: Sun, 09 Jun 2024 17:47:17 -0600<br/> +Message-ID: <87sexly8ze.wl-lukeshu@lukeshu.com> +</div> + +Hello, + +I believe that I have found an error in the [RELAX NG Compact Syntax +document](https://relaxng.org/compact-20021121.html) (and am unsure if +this is the best way to report it). + +In the definition for `primary`, it says + +``` + primary returns Element ::= +… + | "empty" + { <empty/> } + | "notAllowed" + { <notAllowed/> } + | "empty" + { <text/> } +… +``` + +Surely that second "empty" literal should be "text"? + +<div style="font-family: monospace"> +-- <br/> +Cheers,<br/> +~ Luke T. Shumaker<br/> +</div> + |