doc.go 2.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. // Copyright 2018 The TCell Authors
  2. //
  3. // Licensed under the Apache License, Version 2.0 (the "License");
  4. // you may not use file except in compliance with the License.
  5. // You may obtain a copy of the license at
  6. //
  7. // http://www.apache.org/licenses/LICENSE-2.0
  8. //
  9. // Unless required by applicable law or agreed to in writing, software
  10. // distributed under the License is distributed on an "AS IS" BASIS,
  11. // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  12. // See the License for the specific language governing permissions and
  13. // limitations under the License.
  14. // Package tcell provides a lower-level, portable API for building
  15. // programs that interact with terminals or consoles. It works with
  16. // both common (and many uncommon!) terminals or terminal emulators,
  17. // and Windows console implementations.
  18. //
  19. // It provides support for up to 256 colors, text attributes, and box drawing
  20. // elements. A database of terminals built from a real terminfo database
  21. // is provided, along with code to generate new database entries.
  22. //
  23. // Tcell offers very rich support for mice, dependent upon the terminal
  24. // of course. (Windows, XTerm, and iTerm 2 are known to work very well.)
  25. //
  26. // If the environment is not Unicode by default, such as an ISO8859 based
  27. // locale or GB18030, Tcell can convert input and output, so that your
  28. // terminal can operate in whatever locale is most convenient, while the
  29. // application program can just assume "everything is UTF-8". Reasonable
  30. // defaults are used for updating characters to something suitable for
  31. // display. Unicode box drawing characters will be converted to use the
  32. // alternate character set of your terminal, if native conversions are
  33. // not available. If no ACS is available, then some ASCII fallbacks will
  34. // be used.
  35. //
  36. // Note that support for non-UTF-8 locales (other than C) must be enabled
  37. // by the application using RegisterEncoding() -- we don't have them all
  38. // enabled by default to avoid bloating the application unnecessarily.
  39. // (These days UTF-8 is good enough for almost everyone, and nobody should
  40. // be using legacy locales anymore.) Also, actual glyphs for various code
  41. // point will only be displayed if your terminal or emulator (or the font
  42. // the emulator is using) supports them.
  43. //
  44. // A rich set of key codes is supported, with support for up to 65 function
  45. // keys, and various other special keys.
  46. package tcell