diff --git a/src/csfml_audio.nim b/src/csfml_audio.nim index 05888a2..9b88a6c 100644 --- a/src/csfml_audio.nim +++ b/src/csfml_audio.nim @@ -37,7 +37,7 @@ include csfml_audio_gen proc newSound*(buffer: SoundBuffer): Sound = - ## *Returns:* A new Sound with this buffer + ## *Returns*: A new Sound with this buffer result = newSound() if result == nil: return nil result.buffer = buffer diff --git a/src/csfml_graphics.nim b/src/csfml_graphics.nim index e8d62ae..bea3f56 100644 --- a/src/csfml_graphics.nim +++ b/src/csfml_graphics.nim @@ -46,6 +46,7 @@ proc color*(red, green, blue: int, alpha: int = 255): Color = ## - ``green``: Green component (in the range [0, 255]) ## - ``blue``: Blue component (in the range [0, 255]) ## - ``alpha``: Alpha (opacity) component (in the range [0, 255]) + ## ## *Returns*: Color from its 4 RGBA components result.r = uint8 red result.g = uint8 green @@ -178,6 +179,7 @@ proc matrixGL*(transform: Transform): array[0..15, cfloat] = ## ## *Arguments*: ## - ``transform``: Transform object + ## ## *Returns*: 16-element array transform.getMatrix(addr(result[0])) diff --git a/src/csfml_window.nim b/src/csfml_window.nim index 9f2fe29..1a72bc6 100644 --- a/src/csfml_window.nim +++ b/src/csfml_window.nim @@ -49,6 +49,7 @@ proc contextSettings*(depth: cint = 0, stencil: cint = 0, antialiasing: cint = 0 ## ``antialiasing``: Antialiasing level ## ``major``: Major number of the context version ## ``minor``: Minor number of the context version + ## ## *Returns*: ContextSettings with these members result.depthBits = depth result.stencilBits = stencil @@ -74,6 +75,7 @@ proc videoMode*(modeWidth, modeHeight: cint, bitsPerPixel: cint = 32): VideoMode ## - ``modeWidth``: Width in pixels ## - ``modeHeight``: Height in pixels ## - ``modeBitsPerPixel``: Pixel depths in bits per pixel + ## ## *Returns*: a VideoMode with these members result.width = modeWidth result.height = modeHeight @@ -132,6 +134,7 @@ proc newWindow*(mode: VideoMode, title: string, style: BitMaskU32 = WindowStyle. ## - ``title``: Title of the window (normal UTF-8 string) ## - ``style``: Window style ## - ``settings``: Additional settings for the underlying OpenGL context + ## ## *Returns:* A new Window object var t = utf8to32(title) newWindow_U32(mode, addr(t[0]), style, settings)