Releases: varabyte/kotter
v1.0.1
This is a very small release, adding support for CTRL-C on Windows where it didn't previously work.
v1.0.0
Announcing: the first stable release of Kotter 🎉 🎉 🎉
At this point, Kotter provides a core API for writing dynamic CLIs that is:
- cross platform (linux, mac, win)
- fully featured
- well tested
- well documented (check out the extensive README or dive into the rich API docs)
Outside of documentation changes, there were a handful of API changes that snuck in since v1.0.0-rc3, gaps I noticed when poring over the API docs:
TextAnim
s no longer implementCharSequence
.- The original decision was causing its API to expose additional properties that were unnecessarily confusing (e.g.
length
means the length of the text for that frame, not the length of the animation.) - If, after upgrading, you get a compile error that
text(myTextAnim)
in your project, simply right-click on it and import the new extension method that fixes it. Or, change it totext("$myTextAnim")
as another alternative.
- The original decision was causing its API to expose additional properties that were unnecessarily confusing (e.g.
- Added a new
shiftRight { ... }
method, which takes any text rendered in the block and prepends all lines with spaces. - Added the
minWidth
property to thejustified
method- So you can now do
justified(CENTER, minWidth = 10) { text("Hi") }
- So you can now do
- Animation changes
- Allow pausing animations via the
paused
property - Provide the
looping
parameter when creating animations, so that you can define one-shot animations. - Added a few other properties for querying the state of animations:
totalDuration
,isRunning
, andlastFrame
- Allow pausing animations via the
- Fixed a crash in the virtual terminal you could get clicking on a blank line.
v1.0.0-rc3
- Code coverage is now above 90% and very healthy
- Introduced the new
link(...)
method for adding text links- For example:
link("https://github.com/varabyte/kotter", "Learn Kotter!")
- See also: OSC hyperlink support
- Huge thanks to @cbcmg for their support with this feature! 🙇
- For example:
With the current level of code coverage and the fact that link
was the last feature I was planning on squeezing into 1.0, it's hoped that this 1.0-rc3 release will become 1.0, assuming no bugs or other issues are discovered by users before then. I might also make a pass at reviewing / updating code docs, but if all goes well, no more code changes will need to be made 🤞
v1.0.0-rc2
- Tons of unit tests added, bringing code coverage up to > 70%, and fixing a slew of subtle bugs that were uncovered by them.
- Added a new
viewMap
parameter to theinput
method, which allows you to map characters in your input text before they show up on the screen.- For example, the feature allows password fields like so:
input(viewMap = { '*' })
- For example, the feature allows password fields like so:
- Created (and published) a
kotter-test-support
library, as a home for code that I not only use in my own Kotter tests but could be useful to anyone who wants to test their own programs backed by Kotter.
v1.0.0-rc1
First 1.0.0 release candidate! 🎉
At this point, all v1.0 milestone bugs have been resolved except for a final code coverage requirement.
This seems like a good time to start advertising we're getting close to a 1.0 release. If no high priority community feature requests or bugs come in, we'll just keep adding more tests over time, and lock things down once code coverage hits a high enough percent.
Now, onto the fixes added in this release:
- Added new
LiveMap
andLiveSet
classes, in a similar vein to the existingLiveList
class. - Any exceptions thrown during the
run
block are no longer silently swallowed but will now crash the calling thread. This makes it so you no longer have programs that might fail silently, and also you can wrap a whole session in a single try/catch block now to handle all possible errors. - Fixed a bug where asides in a
run
block could get lost if their parent section block finished too quickly. - Exceptions thrown in a
section
block no longer prevent internal state from getting cleaned up
In addition to the bug fixes, code coverage was added and is now being tracked. As we've added more and more unit tests for this goal, it has helped surface subtle inefficiencies with extra rendering that have since been fixed.
v0.9.9
- Added ways to query and set
input()
values outside ofonInputChanged
/onInputEntered
methods.- You shouldn't need this in most cases but it's an important escape hatch when available.
- Created a new
VirtualTerminal
implementation backed by Compose. It works but is still considered experimental.- It is in a separate
kotterx.compose
module. - Unlike the Swing version, you can't simply deploy it effortlessly, but you need to package it differently on Windows, MacOS, and Linux. It may only ever be good for the rare application that intentionally wants to launch ONLY uses a virtual terminal and never using an actual command line.
- It is in a separate
- Added a
clearTerminal
argument that you can set to true when creating a session. Useful if you're making a "full screen" terminal application, such as a game. - Added a handful of missing color methods. Thanks @LeafyLappa!
- Fixed a hard lock that could happen with subtle timing if you pressed ESC very quickly followed by a control key.
v0.9.8
- README updated, with animated gifs or at least screenshots for most examples.
- Fixed a bug with how
p
worked, which was buggy if you had twop
blocks in a row. - Fixed a bug where setting
addTimer { repeat = false }
wasn't actually working behind the scenes - Major change to
input
enabling advanced use-cases:- You can now call
input()
more than once in a render block. However, only one input block can be active at a time, and each input block must have a different ID. - Added
onInputActivated
andonInputDeactivated
callbacks for intercepting focus change events. - Updated the
input
example to demonstrate this new behavior. - Simple code written as described in the README should still work.
- You can now call
v0.9.7
Misc bug fixes / minor feature additions.
- Fixed a bug with border rendering caused by setting both left/right AND top/bottom padding
- Fixed an occasional crash that could be caused due to a threading issue around how the ESC key was handled
- Added a try/catch around code that calls into user space and previously could break system assumptions from within if it threw an exception
- Added the ability to call
clearInput
inonInputEntered
, ensuring theinput()
field would be empty on the next render pass.
v0.9.6
Patch fix.
- BREAKING CHANGE
animOf
is nowtextAnimOf
(andAnim
is nowTextAnim
) - Introduce
renderAnimOf
andRenderAnim
- Update Kotlin compilation version (which doesn't affect the end user but eliminates warnings when compiling Kotter)
v0.9.5
Patch fix.
- BREAKING CHANGE
RunScope
is now a top-level class.- Change imports of
Section.RunScope
to justRunScope
- Made this change for API consistency with
RenderScope
- Change imports of
- Added
hasNextLine
to the offscreen buffer renderer class. - Fixed a crash when
ConcurrentScopedData
value initialization register dependent values as part of its logic. - Added a new sliding tile sample.
- Added a new "extend Kotter" sample.
- Added a bunch of information to the README about extending Kotter.