* fix: `Contain` not preserving aspect ratio of tall images
When both width and height is set to `Contain`, the scaling uses the
wrong direct proportional scaling formula for tall images. This is due
to `aspect` being `width / height`:
By dividing (original), the formula expands to `scaled_width /
scaled_height : height / width` which inversely scaled the width of tall
images. By multiplying instead, the formula correctly expands to
`scaled_width / scaled_height : width / height` which preserves aspect
ratio when scaling.
* refactor: simplify "Contain" and "Cover" formulas; use max for "Cover", min for "Contain"
This was derived from the principle of direct proportion `x=ky` where
`k` is the scaling factor, and `x` `y` are the dimensions. Scaling
factor is based on image's dimension relative to the window's.
Contain needs the minimum scaling factor to ensure both dimensions fit
within the window. Cover needs maximum scaling factor to ensure the
image's smaller dimension fits in the window, allowing the larger
dimension to crop, as expected.
It's not working; I suspect a cirrus environmental issue, but
have no time or energy to debug, and I want to free up the
compute credit and disable this source of noise.
* Update user-var-changed.md
By default base64 inserts a line break at some column which will truncate the user var. `-w 0` disables line wrapping
* added a note instead of changing the base64 command
This is a PITA. The objc crate does some stuff that spews warnings
everywhere that the sel! and msg_send! macros are used.
That crate is not currently maintained
There is a fork of the crate which resolves the spew, but we also
use the cocoa crate which pulls in the original crate
The new fork is not compatible with cargo workspace patching.
There is an alternative objc2 crate with a nicer, more type-safe
API, but the API changes to migrate are pretty huge: I just lost
a couple of hours on this and still hadn't gotten past the migrating
the NSMenu stuff over.
So, the approach here is to simply ignore the warnings in the modules
that use the objc crate.
This will need to be fixed by someone someday, but that day is not
today.
refs: https://github.com/SSheldon/rust-objc/issues/125
I forgot that these continually spam my github notifications
due to the cancelled builds like 10x for each push, pr and so on.
Let's turn these back off again for now.
* Copy terminfo into MacOS app resources
Currently the terminfo file has to be downloaded from the repo and
installed manually. It'd be nice to include it in the app so that a
package manager like Homebrew could install it in the right place when
Wezterm is installed, which is something that Alacritty does.
I've chosen to include the compiled version so that package manager
don't have to invoke `tic` and can just copy files around.
This will result in the following being added to the Resources folder:
```
WezTerm.app/Contents/Resources/terminfo/77/wezterm
```
Once this is in I'll send a patch to update the [Homebrew
formula](https://github.com/Homebrew/homebrew-cask/blob/master/Casks/w/wezterm.rb)
and have it actually install the terminfo.
* Fix filename...
The thesis was that it might help whatever borkage behind
https://github.com/orgs/community/discussions/66297 might be
happening, but it hasn't seemed to do anything useful, so
we may was well turn it back on again.
Apparently crons can interfere with the successful migration
of github actions around a repo transfer?
https://github.com/orgs/community/discussions/66297
Feels crazy! Let's try turning them off and see if that
helps the actions to start working again, more quickly