Before, while the docs stated that template-dirs was a colon-separated
list, a delimiter was not specified in the struct tag, so it was falling
back to the default for the ini library (a comma). Also added a note to
the docs to clarify that templates are configured in the [templates]
section.
The functionality was broken since the decoding changes.
This commit also simplifies the code (in my view) to make the application logic
easier to follow.
The docs are updated accordingly (the feature was poorly documented).
As far as I am aware there should be no breaking changes (and is certainly
still in the spec of the prior documentation)
When the list of completions from the external command doesn't have
associated contact names, the email address we attempt to parse was
being terminated with a newline. Now, we strip the trailing newline if
present.
Previously the workers returned a mixture of decoded / encoded parts.
This lead to a whole bunch of issues.
This commit changes the msgviewer and the commands to assume parts to already
be decoded
Before, pressing <Enter> when completions were visible would execute the
selected completion. As soon as completions were provided, the first
item would be selected. This could cause issues e.g. when changing
folders:
:cf <Enter>
Previously, this would have selected the first folder in the list. Now,
since <Tab>, <C-n>, etc have not been pressed to select the first
completion, the command above simply executes `:cf `.
To accomplish this, a "no-op completion" has been added at index -1.
When addresses contain special characters, net/mail MIME-encodes them
to a valid RFC 5322 address for use in headers. However, these are not
pleasant for human consumption, so we decode them for use in the
completion list. Aerc properly encodes addresses when the message is
sent.
This patch also removes surrounding white space from contact names, if
present.
In order to accommodate for that, the headerlayout needed to be rewritten
to pass the filter criteria back to the msgviewer, instead of just using
the normal headers.
Note that, until we get color configuration, this means that the user *must*
have the %Z verb in the index format else it'll be horribly confusing
as no visual indication is provided