Exemple #1
0
// Echo turns on/off the printing of typed characters
func Echo(on bool) {
	if on {
		C.echo()
		return
	}
	C.noecho()
}
Exemple #2
0
func Echo() os.Error {
	in()
	defer out()
	if int(C.echo()) == 0 {
		return CursesError{"Echo failed"}
	}
	return nil
}
Exemple #3
0
func Echo(args ...string) {
	cs := C.CString(strings.Join(args, " "))
	C.echo(cs)
	C.free(unsafe.Pointer(cs))
}
Exemple #4
0
func Echo() error {
	if int(C.echo()) == 0 {
		return ErrorEcho
	}
	return nil
}
Exemple #5
0
// Enable character echoing while reading.
func Echo() {
	C.echo()
}
Exemple #6
0
func endCurses() {
	C.nocbreak()
	C.echo()
	C.nl()
	C.endwin()
}
Exemple #7
0
func main() {
	flag.Parse()
	cs := C.CString(strings.Join(flag.Args(), " "))
	C.echo(cs)
	C.free(unsafe.Pointer(cs))
}
Exemple #8
0
func Echo() error {
	if C.echo() == C.ERR {
		return CursesError{"echo failed"}
	}
	return nil
}