This changes the cursor color config to use the `text` and `cursor`
properties instead of the current `foreground` and `background`
properties. The latter names stop making sense when dealing with cursors
like a vertical bar or underscore. In the new system, the block,
underscore, or vertical bar would always take the color of `cursor`, and
the text would take the color of `text` when using a block, or keep its
normal color when using the underscore or vertical bar.
A warning is now emitted on startup when the old form of cursor color
config is used. This will be a hard error in the future.
* Dimensions default to 80x24 which is standard for terminals
* Remove commented out Solarized color scheme
* Enable visual bell by default
* Add visual bell config to macos defaults
* Fix default keybindings to match xterm terminfo on Ubuntu 16.04
This commit adds support for a visual bell. Although the Handler in src/ansi.rs
warns "Hopefully this is never implemented", I wanted to give it a try. A new
config option is added, `visual_bell`, which sets the `duration` and `animation`
function of the visual bell. The default `duration` is 150 ms, and the default
`animation` is `EaseOutExpo`. To disable the visual bell, set its duration to 0.
The visual bell is modeled by VisualBell in src/term/mod.rs. It has a method to
ring the bell, `ring`, and another method, `intensity`. Both return the
"intensity" of the bell, which ramps down from 1.0 to 0.0 at a rate set by
`duration` and `animation`.
Whether or not the Processor waits for events is now configurable in order to
allow for smooth drawing of the visual bell.
Fix tests and add line select
Refactor BidirectionalIter to remove if blocks
Allow for cells tagged with WRAPLINE to continue expanding the selection
Reorganize config into structs
Add test coverage that callbacks are called
Cleanup mouse config
- Uses Duration type for ClickHandler::threshold
- Removes `action` property from ClickHandler--this can be added in a
backwards compatible way later on
- Renames ClickState::DblClick to DoubleClick
fixup! Cleanup mouse config
Adds a configuration option `dimensions` which will set initial
window size by columns and lines. Changes to the config file will
require restart.
resolves#370
Adds a new "Quit" action and binds it to Cmd-W and Cmd-Q on Mac OS in an
attempt to make Alacritty feel more like a "normal" citizen of the
operating system. Alternatives like Ctrl-D are okay, but I usually want
to leave my shells nested within Tmux open even if I exit my terminal.
It's also largely selfish: I've built up muscle memory over the years
that takes my fingers to Cmd-Q first (and I suspect I'm not the only
one).
The implementation for an exit is copied from `event.rs` which notably
is already tagged with a FIXME. It seems that `tty.rs` contains a
`process_should_exit` system to help handle a `SIGCHLD`, and it's
possible that these two exit implementations should be merged together.
I could probably tackle that as my next project.
As mentioned in #218, Alacritty can't really spawn other windows right
now, so I've tied in Cmd-W as simply another synonym for quitting until
that's implemented.
Fixes#218.
Makes thin stroke rendering for darwin configurable by a new toplevel
key under `font:` in the config file. Defaults to false, has no impact
on non macos.
This work started because we wanted to be able to simply say "monospace"
on Linux and have it give us some sort of font. The config format for
fonts changed to accomodate this new paradigm. As a result, italic and
bold can have different families from the normal (roman) face.
The fontconfig based font resolution probably works a lot better than
the CoreText version at this point. With CoreText, we simply iterate
over fonts and check it they match the requested properties. What's
worse is that the CoreText version requires a valid family. With
fontconfig, it will just provide the closest matching thing and use it
(unless a specific style is requested).
Bindings were previously hardcoded within input.rs; adding, removing, or
changing a binding required a recompile! Now, bindings may be declared
in alacritty.yml. Even better, bindings are live-reloaded when
alacritty.yml is changed!
One unexpected benefit of this change was that all of the special casing
in input.rs has disappeared.
Conversely, config.rs has gained complexity for all of the
deserialization logic.
Resolves#3.
The upcoming Utf8Chars iterator was vendored from a libstd PR. The
iterator works on BufRead types which is critical for improving
performance. A small modification was made where the number of unused
bytes is included with Utf8CharsError::IncompleteUtf8.
The pty reader thread was updated to use this new type. Next steps will
be moving the parsing there and either sending parse results in batches
or updating the terminal directly from that thread.
Configuration may now be specified in either `$HOME/.alacritty.yml` or
`$HOME/.config/alacritty.yml`. See `alacritty.yml` in the repository
root for an example.
When a configuration file cannot be located, a default configuration is
used.