示例#1
0
文件: glfw.go 项目: andrebq/glfw
// SetWindowPos changes the position of an opened window. It does not have any
// effect on a fullscreen window.
//
// Note: The behaviour of this function on multi-monitor systems is ill-defined.
func SetWindowPos(x, y int) { C.glfwSetWindowPos(C.int(x), C.int(y)) }
示例#2
0
func (w *Window) Move(x, y int) {
	C.glfwSetWindowPos(w.w, C.int(x), C.int(y))
}
示例#3
0
文件: window.go 项目: juturnas/glfw3
//SetPosition sets the position, in screen coordinates, of the upper-left corner
//of the client area of the window.
//
//If it is a full screen window, this function does nothing.
//
//If you wish to set an initial window position you should create a hidden
//window (using Hint and Visible), set its position and then show it.
//
//It is very rarely a good idea to move an already visible window, as it will
//confuse and annoy the user.
//
//The window manager may put limits on what positions are allowed.
//
//This function may only be called from the main thread. See
//https://code.google.com/p/go-wiki/wiki/LockOSThread
func (w *Window) SetPosition(xpos, ypos int) {
	C.glfwSetWindowPos(w.data, C.int(xpos), C.int(ypos))
}
示例#4
0
文件: glfw.go 项目: maun/glfw
func SetWindowPos(window Window, x, y int) {
	C.glfwSetWindowPos(C.GLFWwindow(window), C.int(x), C.int(y))
}
示例#5
0
文件: window.go 项目: godispy/glfw
// SetPos sets the position, in screen coordinates, of the upper-left corner
// of the client area of the window.
//
// If it is a full screen window, this function does nothing.
//
// If you wish to set an initial window position you should create a hidden
// window (using Hint and Visible), set its position and then show it.
//
// It is very rarely a good idea to move an already visible window, as it will
// confuse and annoy the user.
//
// The window manager may put limits on what positions are allowed.
//
// This function may only be called from the main thread.
func (w *Window) SetPos(xpos, ypos int) {
	C.glfwSetWindowPos(w.data, C.int(xpos), C.int(ypos))
	panicError()
}