Commit Graph

481 Commits

Author SHA1 Message Date
dependabot[bot] 88b9c25c3c Bump codecov/codecov-action from 4.1.0 to 4.3.0
Bumps [codecov/codecov-action](https://github.com/codecov/codecov-action) from 4.1.0 to 4.3.0.
- [Release notes](https://github.com/codecov/codecov-action/releases)
- [Changelog](https://github.com/codecov/codecov-action/blob/main/CHANGELOG.md)
- [Commits](https://github.com/codecov/codecov-action/compare/v4.1.0...v4.3.0)

---
updated-dependencies:
- dependency-name: codecov/codecov-action
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-04-15 13:41:49 -07:00
Garrett D'Amore e656a4a5df Bump encoding package dependency. 2024-03-13 23:00:31 -07:00
Garrett D'Amore 78110e30f8 fixes #561 Add clipboard support.
This is not supported for Windows or WebAssembly yet.
It's possible for applications to post to the clipboard using
Screen.SetClipboard (any data), and they can retrieve the clipboard
(if permitted) using GetClipboard.  The terminal may well reject either
of these.

Retrieval will arrive as a new EventClipboard, if it can.  (There is
no good way to make this synchronous.)

This work was inspired by a PR submitted by Consolatis (#562), and
has some work based on it, but it was also substantially improved and
now includes both sides of the clipboard access pattern.
2024-03-10 14:05:48 -07:00
Garrett D'Amore feef990b56 Fixes for unicode in Web terminal
This is very partial, and my experience shows that the terminal
renders these poorly at best; in particular spacing in the DOM
model seems to be unpredictable with emoji and some of the esoteric
combining characters.  Still this represents a significant improvement
by actually including the combining characters.  Plus it is faster.
2024-03-09 18:15:42 -08:00
Garrett D'Amore c9ba0cf327 fixes #710 Add support for setting the window title 2024-03-09 10:05:58 -08:00
Garrett D'Amore 887cf2766e fixes #666 cursor color
This adds a new optional parameter to screen.SetCursorStyle,
which is a color.  The cursors demo is enhanced to show this.

This ability is supported on screen types, provided the underlying
terminal supports the capability.
2024-03-07 08:32:39 -08:00
Garrett D'Amore 652ba11803 mkinfo typo for DottedUnderline 2024-03-07 06:10:54 -08:00
dependabot[bot] 0f7dbfbc6d Bump codecov/codecov-action from 4.0.1 to 4.1.0
Bumps [codecov/codecov-action](https://github.com/codecov/codecov-action) from 4.0.1 to 4.1.0.
- [Release notes](https://github.com/codecov/codecov-action/releases)
- [Changelog](https://github.com/codecov/codecov-action/blob/main/CHANGELOG.md)
- [Commits](https://github.com/codecov/codecov-action/compare/v4.0.1...v4.1.0)

---
updated-dependencies:
- dependency-name: codecov/codecov-action
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-03-06 09:17:24 -08:00
dependabot[bot] 5001167077 Bump golang.org/x/term from 0.17.0 to 0.18.0
Bumps [golang.org/x/term](https://github.com/golang/term) from 0.17.0 to 0.18.0.
- [Commits](https://github.com/golang/term/compare/v0.17.0...v0.18.0)

---
updated-dependencies:
- dependency-name: golang.org/x/term
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-03-06 09:12:40 -08:00
Garrett D'Amore 2453c933e4
Update README.md
Minor markup fix.
2024-03-05 07:46:57 -08:00
Garrett D'Amore f275d42be3 Fix color test 2024-03-05 07:34:34 -08:00
Garrett D'Amore 81f6648f64 Underline colors for webassembly. 2024-03-05 02:40:30 -08:00
Garrett D'Amore 24d9487d4a Fix color values for named RGB colors. 2024-03-05 02:40:02 -08:00
Garrett D'Amore 9970579247 style test: better contrast colors 2024-03-05 01:00:52 -08:00
dependabot[bot] 2449fd30cc Bump golang.org/x/sys from 0.17.0 to 0.18.0
Bumps [golang.org/x/sys](https://github.com/golang/sys) from 0.17.0 to 0.18.0.
- [Commits](https://github.com/golang/sys/compare/v0.17.0...v0.18.0)

---
updated-dependencies:
- dependency-name: golang.org/x/sys
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-03-05 00:27:54 -08:00
Garrett D'Amore 581a114039 Windows: hyperlink support 2024-03-05 00:25:29 -08:00
Garrett D'Amore 18256bb692 Windows build fix. 2024-03-05 00:11:19 -08:00
Garrett D'Amore 9bc5c636ae Underline API change.
The underline styles are mutually exclusive.  And let's simplify
passing the color with the underline style in a single function call.
2024-03-04 23:56:23 -08:00
Garrett D'Amore 826c271964 Colored underlines.
This supports UNIX and Windows.
2024-03-04 21:19:42 -08:00
Garrett D'Amore ed7527708c Forgot to commit mkinfo.go 2024-03-04 19:59:29 -08:00
Garrett D'Amore 9a52dc2a4e terminals: move the import into tscreen_unix.go
(Rationale: we might want to use a *much* smaller database for
systems that have a fixed set of strings, such as xterm.js.)
2024-03-04 00:07:22 -08:00
Garrett D'Amore ecac43f113 wasm: fix the blink by injecting a sub-span. 2024-03-03 19:13:22 -08:00
Garrett D'Amore ef0ee53eee minor clean up for style demo 2024-03-03 19:06:42 -08:00
Garrett D'Amore 1fb8cfe768 feature: underline styles
This supports now curly, double, dashed, and dotted underline styles
where trhe terminal supports it.  This works well on Windows Terminal,
reasonably on iTerm2, Alacritty, Kitty, and probably others.

The wasm mode terminal includes support for this, dependent on the browser
capabilities.

The macOS Terminal just changes the background color.  Legacy Windows
console does nothing.

We will try to provide a regular underscore as a fallback.  A new style.go
demo is included to see some style combinations.
2024-03-03 19:04:45 -08:00
Aaron Riekenberg edd4f70bdd Add go-tetris. 2024-03-03 15:23:46 -08:00
Garrett D'Amore d1364d5937 windows: restore cursor location correctly 2024-03-03 15:19:20 -08:00
Garrett D'Amore b02dac3826 fix stress demo (race on close) 2024-03-03 15:02:14 -08:00
Marcel Schramm 2c305c06d7 Add little stresser that just draws as much 'random' stuff as possible 2024-03-03 13:51:12 -08:00
Garrett D'Amore de408507f9 terminfo: regenerate all entries
Previously we had lost StrikeThrough, and this fixes a few other
discrepancies.  This was generated on Ubuntu Noble (24.04), after
installing the following packages: ncurses-term kitty-terminfo
2024-03-03 08:30:47 -08:00
Garrett D'Amore 6c95e8dbb3 Try not to clear screen on Windows if TCELL_ALTSCREEN=disable 2024-03-02 14:22:12 -08:00
Garrett D'Amore 6984e257e4 Allow use of TCELL_ALTSCREEN=disable to disable alternate screen.
This hack will also prevent the clearing of the screen at disengage
time.  This may be useful for certain kinds of applications that
want to draw the screen, then place the cursor at a specific location.
(The application will need to do a TGoto on it's own first.)
2024-03-02 14:18:52 -08:00
Garrett D'Amore 552bf3cec1 windows: Use alt screen by default (supress with TCELL_ALTSCREEN=disable)
The alternate screen buffer right now only works in VT mode.
2024-03-02 12:47:28 -08:00
Garrett D'Amore 5a591d4275 Use automargin disable 2024-03-02 12:02:40 -08:00
Garrett D'Amore f6c43a3372 ConEmu fixes - we cannot go to 24-bit mode on that yet. 2024-03-02 11:55:11 -08:00
Garrett D'Amore cd0fe984d9 Windows: enable VT mode output by default
The special environment variable TCELL_VTMODE may be set to "disable"
to return to legacy console mode.  (This environment variable may
be removed in the future, if we determine it is no longer useful.)
2024-03-02 11:31:16 -08:00
Garrett D'Amore d17cf8bb6b fixes #621 Unicode disappears if requested twice on the same place on Windows 2024-02-17 10:49:06 -08:00
Garrett D'Amore 547b1102d3 fixes #669 Focus event support for Windows console 2024-02-17 10:28:53 -08:00
dependabot[bot] a58de98116 Bump golang.org/x/term from 0.15.0 to 0.17.0
Bumps [golang.org/x/term](https://github.com/golang/term) from 0.15.0 to 0.17.0.
- [Commits](https://github.com/golang/term/compare/v0.15.0...v0.17.0)

---
updated-dependencies:
- dependency-name: golang.org/x/term
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-02-16 00:09:01 -08:00
dependabot[bot] 2833ff3aa0 Bump golang.org/x/sys from 0.15.0 to 0.17.0
Bumps [golang.org/x/sys](https://github.com/golang/sys) from 0.15.0 to 0.17.0.
- [Commits](https://github.com/golang/sys/compare/v0.15.0...v0.17.0)

---
updated-dependencies:
- dependency-name: golang.org/x/sys
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-02-16 00:06:37 -08:00
dependabot[bot] c4ecc72735 Bump codecov/codecov-action from 3.1.4 to 4.0.1
Bumps [codecov/codecov-action](https://github.com/codecov/codecov-action) from 3.1.4 to 4.0.1.
- [Release notes](https://github.com/codecov/codecov-action/releases)
- [Changelog](https://github.com/codecov/codecov-action/blob/main/CHANGELOG.md)
- [Commits](https://github.com/codecov/codecov-action/compare/v3.1.4...v4.0.1)

---
updated-dependencies:
- dependency-name: codecov/codecov-action
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-02-16 00:04:46 -08:00
dependabot[bot] 984d851637 Bump actions/setup-go from 4 to 5
Bumps [actions/setup-go](https://github.com/actions/setup-go) from 4 to 5.
- [Release notes](https://github.com/actions/setup-go/releases)
- [Commits](https://github.com/actions/setup-go/compare/v4...v5)

---
updated-dependencies:
- dependency-name: actions/setup-go
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-02-15 23:59:50 -08:00
Garrett D'Amore 216e30afd7 fixes #679 Some emojis move entire line upwards when at bottom of terminal
This fix is not perfect, in that it will not fix every terminal that has
automargin support, but it fixes the *vast* majority of them by eliminating
the hacky workaround for the automargin - essentially using the rmam capability
to disable automatic wrapping at the margin.
2024-02-15 23:53:05 -08:00
Garrett D'Amore 5bdcc2579b Termite is dead/deprecated - drop it.
Fallback support will still work, but termite is no longer supported
and users of termite are advised to switch to Alacritty.
2024-02-15 23:51:10 -08:00
Garrett D'Amore 15a4f4f1fb fixes #677 PollEvent() returns nil when screen is suspended 2024-02-15 22:25:45 -08:00
Garrett D'Amore b05ee8f998 remove stale comment 2024-02-15 22:11:18 -08:00
Garrett D'Amore cc24c71d4b fixes #682 views/app uses deprecated PostEventWait 2024-02-15 22:02:11 -08:00
Garrett D'Amore c3711de418 fixes #683 views: remove unused contentV member 2024-02-15 22:02:01 -08:00
Garrett D'Amore 0393f5eb0b Add security policy. 2024-01-20 17:19:54 -08:00
stk 96e2990564 Don't set modifiers for AltGr on Windows
AltGr is the same as ctrl+alt, and we don't want those to be set when you press
a key using AltGr.
2024-01-03 10:06:01 -08:00
Garrett D'Amore 337e381927 fixes #606 Want ColorNone to preserve existing color(s)
While here, consolidate the use of the Fill() function from
CellBuffer (eliminating redundant code).
2023-12-08 00:19:52 -08:00