Fix small lint & spelling issues

This commit is contained in:
Jaime Piña 2016-12-05 15:37:37 -08:00 committed by Garrett D'Amore
parent 6b28764250
commit 44772c121b
5 changed files with 8 additions and 8 deletions

View File

@ -46,7 +46,7 @@ var encodingFallback EncodingFallback = EncodingFallbackFail
// Aliases can be registered as well, for example "8859-15" could be an alias
// for "ISO8859-15".
//
// For POSIX systems, the tcell pacakge will check the environment variables
// For POSIX systems, the tcell package will check the environment variables
// LC_ALL, LC_CTYPE, and LANG (in that order) to determine the character set.
// These are expected to have the following pattern:
//

View File

@ -94,7 +94,7 @@ func setupterm(name string) error {
plist = append(plist, "")
rsn := C.int(0)
for _, p := range(plist) {
for _, p := range plist {
// Override environment
if p == "" {
os.Unsetenv("TERMINFO")
@ -145,7 +145,7 @@ func getinfo(name string) (*tcell.Terminfo, error) {
if strings.HasSuffix(name, "-truecolor") {
base := name[:len(name)-len("-truecolor")]
// Probably -256color is closest to what we want
if err = setupterm(base+"-256color"); err != nil {
if err = setupterm(base + "-256color"); err != nil {
err = setupterm(base)
}
if err == nil {
@ -638,7 +638,7 @@ func main() {
}
} else {
tdata[t.Name] = t
if t2, e := getinfo(term+"-256color"); e == nil {
if t2, e := getinfo(term + "-256color"); e == nil {
tdata[t2.Name] = t2
}
}

View File

@ -133,7 +133,7 @@ type Screen interface {
Sync()
// CharacterSet returns information about the character set.
// This isn't the full locale, but it does give us the input/ouput
// This isn't the full locale, but it does give us the input/output
// character set. Note that this is just for diagnostic purposes,
// we normally translate input/output to/from UTF-8, regardless of
// what the user's environment is.

View File

@ -417,7 +417,7 @@ outer:
continue
}
return failed == false
return !failed
}
func (s *simscreen) Sync() {

View File

@ -725,7 +725,7 @@ func loadFromFile(fname string, term string) (*Terminfo, error) {
}
}
// LookupTerminfo attemps to find a definition for the named $TERM.
// LookupTerminfo attempts to find a definition for the named $TERM.
// It first looks in the builtin database, which should cover just about
// everyone. If it can't find one there, then it will attempt to read
// one from the JSON file located in either $TCELLDB, $HOME/.tcelldb