Skip to content
Chris Petersen edited this page Oct 16, 2014 · 1 revision

make-window defines the default window size. It also prevents a GUI application from going full screen

Parameter Description
w Width of application window
h Height of application window

Example

Example 1: Create a 320x480 px window, which is useful for mobile application development and initialize a gui with a red background.

(make-window 320 480)
(glgui-orientation-set! GUI_PORTRAIT)
(set! gui (make-glgui))
(let* ((w (glgui-width-get))
       (h (glgui-height-get))
       (dim (min (/ w 2) (/ h 2))))
  (glgui-box gui (/ (- w dim) 2) (/ (- h dim) 2) dim dim Red))
Clone this wiki locally