bridge

package
v0.0.0-...-df0110e Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 20, 2021 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Control

type Control interface {
	Window
}

type Controls

type Controls interface {
	Control

	AddControl(control Control)
	RemoveControl(control Control)
	GetChilds() []Control
}

type Form

type Form interface {
	Controls

	Close()
	ShowDialog()
	SetTitle(title string)
	SetBorderStyle(style fm.FormBorder)
	ShowToMax()
	ShowToMin()
	/*
		允许在无边框模式下调整窗体大小
	*/
	NoneBorderResize()
	Active()

	SetMaximizeBox(isShow bool)
	SetMinimizeBox(isShow bool)
	SetIcon(iconFile string)
	SetTopMost(isTop bool)

	SetOnState(proc FormStateProc) FormStateProc
	SetOnActive(proc FormActiveProc) FormActiveProc
}

type FormActiveProc

type FormActiveProc func()

type FormParam

type FormParam struct {
	HideInTaskbar bool
	HideIcon      bool
}

type FormStateProc

type FormStateProc func(state fm.FormState)

type MsgBox

type MsgBox interface {
	Show(param fm.MsgBoxParam) fm.MsgBoxResult
}

type Provider

type Provider interface {
	RunMain(form Form)
	Exit(code int)
	SetIcon(file string)
	GetScreen() f.Screen
	ModifierKeys() map[f.Keys]bool
	MouseIsDown() map[f.MouseButtons]bool
	MouseLocation() f.Point
	AppDir() string

	NewForm(param FormParam) Form
	NewControl() Control
	NewMsgBox() MsgBox
}

type Window

type Window interface {
	GetHandle() uintptr
	SetOnCreate(proc WindowCreateProc) WindowCreateProc
	SetOnDestroy(proc WindowDestroyProc) WindowDestroyProc
	SetOnResize(proc WindowResizeProc) WindowResizeProc
	SetOnMove(proc WindowMoveProc) WindowMoveProc
	SetOnMouseMove(proc WindowMouseMoveProc) WindowMouseMoveProc
	SetOnMouseDown(proc WindowMouseDownProc) WindowMouseDownProc
	SetOnMouseUp(proc WindowMouseUpProc) WindowMouseUpProc
	SetOnMouseWheel(proc WindowMouseWheelProc) WindowMouseWheelProc
	SetOnMouseClick(proc WindowMouseClickProc) WindowMouseClickProc
	SetOnPaint(proc WindowPaintProc) WindowPaintProc
	SetOnKeyDown(proc WindowKeyDownProc) WindowKeyDownProc
	SetOnKeyUp(proc WindowKeyUpProc) WindowKeyUpProc
	SetOnKeyPress(proc WindowKeyPressProc) WindowKeyPressProc
	SetOnCursor(proc WindowSetCursorProc) WindowSetCursorProc
	SetOnImeStartComposition(proc WindowImeStartCompositionProc) WindowImeStartCompositionProc
	SetOnFocus(proc WindowFocusProc) WindowFocusProc
	SetOnLostFocus(proc WindowLostFocusProc) WindowLostFocusProc
	SetOnShow(proc WindowShowProc) WindowShowProc

	GetProvider() Provider
	Invoke(fn func(state interface{}), state interface{})
	IsInvoke() bool
	SetSize(w int, h int)
	SetLocation(x int, y int)
	GetBound() fm.Bound
	Show()
	Hide()
	SetBgColor(color int32)
	CreateGraphics() fm.Graphics
	SetCursor(cursor fm.CursorType)
	GetCursor() fm.CursorType
	GetParent() Control
	GetOwner() Form
	ToClientPoint(p fm.Point) fm.Point
	IsEnable() bool
	Enable(b bool)
}

type WindowCreateProc

type WindowCreateProc func(handle uintptr)

type WindowDestroyProc

type WindowDestroyProc func()

type WindowFocusProc

type WindowFocusProc func() bool

type WindowImeStartCompositionProc

type WindowImeStartCompositionProc func() bool

type WindowKeyDownProc

type WindowKeyDownProc func(e *fm.KeyEvArgs)

type WindowKeyPressProc

type WindowKeyPressProc func(e *fm.KeyPressEvArgs)

type WindowKeyUpProc

type WindowKeyUpProc func(e *fm.KeyEvArgs)

type WindowLostFocusProc

type WindowLostFocusProc func() bool

type WindowMouseClickProc

type WindowMouseClickProc func(e *fm.MouseEvArgs)

type WindowMouseDownProc

type WindowMouseDownProc func(e *fm.MouseEvArgs)

type WindowMouseMoveProc

type WindowMouseMoveProc func(e *fm.MouseEvArgs)

type WindowMouseUpProc

type WindowMouseUpProc func(e *fm.MouseEvArgs)

type WindowMouseWheelProc

type WindowMouseWheelProc func(e *fm.MouseEvArgs)

type WindowMoveProc

type WindowMoveProc func(e fm.Point) bool

type WindowPaintProc

type WindowPaintProc func(e fm.PaintEvArgs) bool

type WindowResizeProc

type WindowResizeProc func(e fm.Rect)

type WindowSetCursorProc

type WindowSetCursorProc func() bool

type WindowShowProc

type WindowShowProc func()

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL