-
Notifications
You must be signed in to change notification settings - Fork 35
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
10 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,7 +2,7 @@ | |
MIT License | ||
Copyright (c) 2010-2020 nsf <[email protected]> | ||
2015-2021 Adam Saponara <[email protected]> | ||
2015-2022 Adam Saponara <[email protected]> | ||
Permission is hereby granted, free of charge, to any person obtaining a copy | ||
of this software and associated documentation files (the "Software"), to deal | ||
|
@@ -58,6 +58,8 @@ extern "C" { | |
|
||
// __ffi_start | ||
|
||
#define TB_VERSION_STR "2.0.0" | ||
|
||
#if defined(TB_LIB_OPTS) || 0 // __tb_lib_opts | ||
// Ensure consistent compile-time options when using as a library | ||
#undef TB_OPT_TRUECOLOR | ||
|
@@ -541,6 +543,7 @@ const char *tb_strerror(int err); | |
struct tb_cell *tb_cell_buffer(); | ||
int tb_has_truecolor(); | ||
int tb_has_egc(); | ||
const char *tb_version(); | ||
|
||
#ifdef __cplusplus | ||
} | ||
|
@@ -1860,6 +1863,10 @@ int tb_has_egc() { | |
#endif | ||
} | ||
|
||
const char *tb_version() { | ||
return TB_VERSION_STR; | ||
} | ||
|
||
static int tb_reset() { | ||
int ttyfd_open = global.ttyfd_open; | ||
memset(&global, 0, sizeof(global)); | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters