浏览代码

add f as same as H

Yasuhiro Matsumoto 8 年之前
父节点
当前提交
167de6bfdf
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      colorable_windows.go

+ 1 - 1
colorable_windows.go

@@ -508,7 +508,7 @@ loop:
 			procGetConsoleScreenBufferInfo.Call(uintptr(w.handle), uintptr(unsafe.Pointer(&csbi)))
 			csbi.cursorPosition.x = short(n - 1)
 			procSetConsoleCursorPosition.Call(uintptr(w.handle), *(*uintptr)(unsafe.Pointer(&csbi.cursorPosition)))
-		case 'H':
+		case 'H', 'f':
 			procGetConsoleScreenBufferInfo.Call(uintptr(w.handle), uintptr(unsafe.Pointer(&csbi)))
 			if buf.Len() > 0 {
 				token := strings.Split(buf.String(), ";")