Displays colour rectangle.
Methods
method draw(self: SwitchRef; w, h: GLfloat) {...}{.raises: [GLerror, Exception], tags: [RootEffect].}
- this method uses in the window.nim.
method duplicate(self: SwitchRef): SwitchRef {...}{.base, raises: [], tags: [].}
- Duplicates Switch object and create a new Switch.
method handle(self: SwitchRef; event: InputEvent; mouse_on: var NodeRef) {...}{. raises: [Exception], tags: [RootEffect].}
- Handles user input. This uses in the window.nim.
method toggle(self: SwitchRef) {...}{.base, raises: [], tags: [].}
- Toggles value.