ebiten/ui.go

33 lines
845 B
Go
Raw Normal View History

2014-12-09 15:16:04 +01:00
/*
Copyright 2014 Hajime Hoshi
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
*/
2014-12-09 14:09:22 +01:00
package ebiten
2013-06-18 17:48:41 +02:00
2013-11-29 19:21:10 +01:00
type UI interface {
2014-12-06 20:14:35 +01:00
Start(widht, height, scale int, title string) (Canvas, error)
2014-01-13 07:26:20 +01:00
DoEvents()
Terminate()
2013-11-29 19:21:10 +01:00
}
2013-12-09 14:40:54 +01:00
type GraphicsContextDrawer interface {
2014-12-09 15:16:04 +01:00
Draw(d GraphicsContext) error
2014-12-06 20:14:35 +01:00
}
2014-05-11 14:24:37 +02:00
type Canvas interface {
Draw(drawer GraphicsContextDrawer) error
2014-05-12 03:04:28 +02:00
IsClosed() bool
2013-12-09 14:40:54 +01:00
}