Commit Graph

890 Commits

Author SHA1 Message Date
Jonathan Daugherty
bf0874598f combinedOpsForLayers: fix 2021-02-16 13:10:06 -08:00
Jonathan Daugherty
f5b7222065
Merge pull request #196 from lehins/master
Update upper bounds for `random`
2021-02-16 13:07:55 -08:00
Jonathan Daugherty
f0f729d755
Merge pull request #202 from hapytex/hlint/eta-reduction
eta reductions
2021-02-16 09:45:47 -08:00
Jonathan Daugherty
572c59881b
Merge pull request #203 from hapytex/hlint/use-fmap
make use of <$>
2021-02-16 09:44:49 -08:00
Willem Van Onsem
f2c58a1870 extra improvements 2021-02-16 09:26:54 +01:00
Jonathan Daugherty
dfa4c1ec08
Merge pull request #207 from hapytex/hlint/redundant-bracket
remove useless parenthesis and ellipse
2021-02-15 15:58:45 -08:00
Willem Van Onsem
9c479554ee revert pattern brackets 2021-02-15 23:59:25 +01:00
Jonathan Daugherty
ab621ee8a4
Merge pull request #204 from hapytex/hlint/remove-lambda
avoid lambda expressions
2021-02-15 14:48:32 -08:00
Jonathan Daugherty
7f8d21b8d6
Merge pull request #205 from hapytex/hlint/use-string
use String over [Char]
2021-02-15 14:43:08 -08:00
Willem Van Onsem
0e5c1646f6 remove useless parenthesis and ellipse 2021-02-15 23:07:09 +01:00
Willem Van Onsem
bed8068d37 use String over [Char] 2021-02-15 17:42:45 +01:00
Willem Van Onsem
b5da64bb63 avoid lambda expressions 2021-02-15 17:39:53 +01:00
Willem Van Onsem
d3a1a5576a make use of <$> 2021-02-15 17:08:15 +01:00
Willem Van Onsem
ec463f1c85 eta reductions 2021-02-15 12:12:20 +01:00
Jonathan Daugherty
9022a45d5d
Merge pull request #197 from felixonmars/patch-2
Allow microlens 0.4.12
2020-12-30 12:18:34 -08:00
Felix Yan
ac3560cc72
Allow microlens 0.4.12
All tests passed here.
2020-12-31 03:06:14 +08:00
Jonathan Daugherty
fd90f7dc85 Cursor: add PositionOnly constructor for cursor placement without visibility 2020-12-06 17:17:20 -08:00
Alexey Kuleshevich
05b65fc5bc
Update upper bounds for random 2020-12-05 23:05:04 +03:00
Jonathan Daugherty
6fead08444
Merge pull request #195 from jtdaugherty/simplify-attr
Simplify definition of MaybeDefault
2020-11-16 11:00:51 -08:00
Eric Mertens
36c1dcc451 Simplify definition of MaybeDefault
The previous version of MaybeDefault stores pointers to the Eq, Show, and Read instances of the defaulted value.

MaybeDefault is used with Style, Color, and Text. All of these types already have all of the necessary instances, and we never work with MaybeDefault generically. Defering the Show, Eq, and Read instances down to the SetTo case isn't helping us to work with types that don't have these instances.
2020-11-16 09:56:30 -08:00
Jonathan Daugherty
d470f5f9d4 Bump version, update changelog 2020-11-08 20:43:37 -08:00
Jonathan Daugherty
99d738b02c Add missing import 2020-11-08 20:43:06 -08:00
Jonathan Daugherty
fd8c4def96
Merge pull request #194 from emekoi/fix-utf8
Ensure detection of UTF-8 mode regardless of case
2020-11-08 20:39:29 -08:00
Emeka Nkurumeh
4aa1873485 follow up to #89 - ensure string are the same case 2020-11-08 22:37:12 -06:00
Jonathan Daugherty
0b4fa6410b Merge branch 'master' of github.com:jtdaugherty/vty into master 2020-11-04 18:11:48 -08:00
Jonathan Daugherty
27e9bf77a5 specialSupportKeys: add cases for Meta-PageUp and Meta-PageDown (fixes #193) 2020-11-04 18:11:43 -08:00
Jonathan Daugherty
ef6b73d71b supportsItalics, supportsStrikethrough: documentation 2020-10-13 08:57:43 -07:00
Jonathan Daugherty
bcbf7fabc1 Output: add supportsItalics and supportsStrikethrough to check for feature support 2020-10-13 08:52:18 -07:00
Jonathan Daugherty
63adf9e4db Bump version, update changelog 2020-09-30 15:44:46 -07:00
Jonathan Daugherty
1dc2379e3c Add support for strikethrough mode
This change adds a new 'strikethrough' Style value and uses the 'smxx'
and 'rmxx' Terminfo capabilities to activate and deactivate
strikethrough mode, respectively. If the terminfo does not report those
capabilities, this style is ignored.

For details, see

https://invisible-island.net/xterm/terminfo-contents.html#tic-ecma_strikeout
2020-09-30 12:45:58 -07:00
Jonathan Daugherty
90ea18379d
Merge pull request #189 from gdziadkiewicz/master
Update LICENSE file to make it recognizable by GitHub
2020-08-15 07:59:32 -07:00
Grzegorz Dziadkiewicz
da1d567668
Update LICENSE to make it recognizable by GitHub 2020-08-15 14:57:16 +02:00
Jonathan Daugherty
dea6fbfa98 XTermColor: remove unhelpful comment 2020-07-29 11:35:17 -07:00
Jonathan Daugherty
00b0cbcfa9 gwinsz.h: fix vty_c_get_window_size prototype 2020-07-15 13:50:31 -07:00
Jonathan Daugherty
2fabd997b6 Whitespace 2020-07-15 13:50:23 -07:00
Jonathan Daugherty
6a9c90da0e Output: add setDisplayBounds field and implementation for TerminfoBased backend 2020-07-15 13:49:05 -07:00
Jonathan Daugherty
5922c53459 Bump version, update changelog 2020-07-15 12:17:41 -07:00
Jonathan Daugherty
cb08446df4 Graphics.Vty: add setWindowTitle (fixes #188) 2020-07-15 10:42:29 -07:00
Jonathan Daugherty
95ea88c814 Bump version, update changelog 2020-07-09 15:17:22 -07:00
Jonathan Daugherty
a828f305d0 Merge branch 'bugfix/terminal-init-flags' 2020-07-09 15:05:20 -07:00
Jonathan Daugherty
812e873499 Input: add a new field, restoreInputState
This change adds a new record field to the Input type to allow the end
user to have direct access to the logic needed to restore the terminal's
input state flags. Prior to this change, this state restoration logic
could only be invoked as part of calling 'shutdownInput', but since that
function does other things (like killing threads) it is not advisable to
call it repeatedly (which is necessary in the use case this change is
intended to support).

This change supports a use case where an application initializes
Vty repeatedly, with changes to the input state flags in between
initializations, but where the application wants to ensure that the
*final* input state flag configuration matches the terminal's condition
before Vty started handling input for the first time. This change allows
applications to access the state restoration for the initial Vty handle
by exposing the logic directly in a field of Input.

The input state restoration is still an implicit part of invoking
'shutdownInput' (and thus 'shutdown') so no user-facing changes are
required for applications that do not build their own Input structures.
2020-07-09 15:01:45 -07:00
Jonathan Daugherty
e49ea78472 Whitespace 2020-07-09 14:14:17 -07:00
Jonathan Daugherty
be263d4893 Typo 2020-07-09 14:07:33 -07:00
Jonathan Daugherty
620a5ca544 attributeControl: document which constructors map to which terminal mode flags 2020-07-09 14:07:14 -07:00
Jonathan Daugherty
95cabe0b87 inputForConfig: move mode flag documentation to the right place and update it to include enabled flags 2020-07-09 14:05:45 -07:00
Jonathan Daugherty
c572ad1ac7 attributeControl: explicitly enable a required mode flag (see #187)
Prior to this change, Vty would initialize the terminal by clearing the
flags it needed to clear. That is good, but it means that some flags
that were assumed to be enabled but not *explicitly* enabled by Vty
would cause trouble if they were not, in fact, enabled prior to Vty
initialization.

This comes up in (pathological?) cases where the terminal state prior to
Vty initialization is not what Vty assumes it will be, i.e., cases in
which some flags which are assumed to be set are not. We found this to
be true when an application (in this case vim) was terminated uncleanly,
leaving the terminal mode flags in a state that Vty did not anticipate.

To resolve this problem, this change explicitly sets one flag which we
now know to be required for Vty to function properly (the ICRNL flag).
2020-07-09 13:57:33 -07:00
Jonathan Daugherty
17e2560846 Clarify the meaning of "escapes" in some Haddocks (fixes #186) 2020-05-02 15:53:44 -07:00
Jonathan Daugherty
f7eef975de Bump version, update changelog 2020-03-27 09:14:12 -07:00
Jonathan Daugherty
a0a32ec5fa Depend on semigroups for older GHCs (fixes #185) 2020-03-27 09:12:48 -07:00
Jonathan Daugherty
92590dead1 Bump version, update changelog 2020-03-09 15:37:46 -07:00