Documentation
¶
Overview ¶
Package gui is an abstraction layer for real GUI implementations. It defines the Events that can be passed from the GUI to the emulation code and also the Requests that can be made from the emulation code to the GUI. Implementations need to convert their specific signals and requests to and from these abstractions.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Event ¶
type Event interface{}
Event represents all the different type of events that can occur in the gui
Events are the things that happen in the gui, as a result of user interaction, and sent over a registered event channel.
type EventDbgMouseButton ¶
type EventDbgMouseButton struct {
Button MouseButton
Down bool
X int
Y int
HorizPos int
Scanline int
}
EventDbgMouseButton is the data that accompanies MouseEventMove events
type EventKeyboard ¶
EventKeyboard is the data that accompanies EventKeyboard events
type EventMouseButton ¶
type EventMouseButton struct {
Button MouseButton
Down bool
}
EventMouseButton is the data that accompanies MouseEventMove events
type EventMouseMotion ¶
EventMouseMotion is the data that accompanies MouseEventMove events
type FeatureReq ¶
type FeatureReq string
FeatureReq is used to request the setting of a gui attribute eg. toggling the overlay
const ( ReqSetVisibility FeatureReq = "ReqSetVisibility" // bool ReqToggleVisibility FeatureReq = "ReqToggleVisibility" // none ReqSetVisibleOnStable FeatureReq = "ReqSetVisibleOnStable" // none ReqSetPause FeatureReq = "ReqSetPause" // bool ReqSetCropping FeatureReq = "ReqSetCropping" // bool ReqToggleCropping FeatureReq = "ReqToggleCropping" // none ReqSetAltColors FeatureReq = "ReqSetAltColors" // bool ReqToggleAltColors FeatureReq = "ReqToggleAltColors" // none ReqSetOverlay FeatureReq = "ReqSetOverlay" // bool ReqToggleOverlay FeatureReq = "ReqToggleOverlay" // none ReqSetScale FeatureReq = "ReqSetScale" // float ReqIncScale FeatureReq = "ReqIncScale" // none ReqDecScale FeatureReq = "ReqDecScale" // none ReqAddDebugger FeatureReq = "ReqAddDebugger" // *debugger.Debugger ReqAddVCS FeatureReq = "ReqAddVCS" // *hardware.VCS ReqAddDisasm FeatureReq = "ReqAddDisasm" // *disassembly.Disassembly // the event channel is used to by the GUI implementation to send // information back to the main program. the GUI may or may not be in its // own go routine but regardless, the event channel is used for this // purpose. ReqSetEventChan FeatureReq = "ReqSetEventChan" // chan gui.Event() )
List of valid feature requests. argument must be of the type specified or else the interface{} type conversion will fail and the application will probably crash.
Note that, like the name suggests, these are requests, they may or may not be satisifed depending other conditions in the GUI. For example, in the imgui gui implementation, a capture mouse request will only be honoured if the "TV screen" window is active.
type GUI ¶
type GUI interface {
// send a request to set a gui feature
SetFeature(request FeatureReq, args ...interface{}) error
}
GUI defines the operations that can be performed on visual user interfaces.
type MouseButton ¶
type MouseButton int
MouseButton identifies the mouse button
const ( MouseButtonNone MouseButton = iota MouseButtonLeft MouseButtonRight MouseButtonMiddle )
list of valid MouseButtonIDs
Directories
¶
| Path | Synopsis |
|---|---|
|
Package sdlaudio provides the Audio type.
|
Package sdlaudio provides the Audio type. |
|
Package sdldebug implements the GUI interface.
|
Package sdldebug implements the GUI interface. |
|
lazyvalues
Package lazyvalues is the method used by sdlimgui (and possibly other GUI implementations) when access emulator data from the GUI thread.
|
Package lazyvalues is the method used by sdlimgui (and possibly other GUI implementations) when access emulator data from the GUI thread. |
|
Package sdlplay implements the GUI interface.
|
Package sdlplay implements the GUI interface. |
|
generator
command
|