Browse Source

add f as same as H

Yasuhiro Matsumoto 8 năm trước cách đây
mục cha
commit
167de6bfdf
1 tập tin đã thay đổi với 1 bổ sung1 xóa
  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(), ";")