From 679df3ed041b6abca1532307293215d03d0086ef Mon Sep 17 00:00:00 2001 From: Jack Bennett Date: Sat, 14 Oct 2023 21:52:18 +0100 Subject: [PATCH] Update documentation for new Cocoa function --- docs/pages/api/core/wsi.rst | 16 +++++++++++++--- include/thallium/core/wsi/cocoa_window_surface.h | 4 ++-- 2 files changed, 15 insertions(+), 5 deletions(-) diff --git a/docs/pages/api/core/wsi.rst b/docs/pages/api/core/wsi.rst index 416b245..6e96064 100644 --- a/docs/pages/api/core/wsi.rst +++ b/docs/pages/api/core/wsi.rst @@ -24,9 +24,19 @@ Functions --------- -For X11 systems - via XCB +For Cocoa (macOS) systems ^^^^^^^^^^^^^^^^^^^^^^^^^ +.. important:: + Definitions for these functions is compiled **only if** the ``-DTHALLIUM_WSI_COCOA=ON`` CMake flag was present at build. This is the + **default behaviour** on **Apple** systems. + +.. doxygenfunction:: TL_WindowSurfaceCreateCocoa + + +For Xorg systems (via xcb) +^^^^^^^^^^^^^^^^^^^^^^^^^^ + .. important:: Definitions for these functions is compiled **only if** the ``-DTHALLIUM_WSI_XCB=ON`` CMake flag was present at build. This is the **default behaviour** on **Unix** *(not Apple)* systems. @@ -34,8 +44,8 @@ For X11 systems - via XCB .. doxygenfunction:: TL_WindowSurfaceCreateXCB -For X11 systems - via Xlib -^^^^^^^^^^^^^^^^^^^^^^^^^^ +For Xorg systems (via Xlib) +^^^^^^^^^^^^^^^^^^^^^^^^^^^ .. important:: Definitions for these functions is compiled **only if** the ``-DTHALLIUM_WSI_XLIB=ON`` CMake flag was present at build. This is the diff --git a/include/thallium/core/wsi/cocoa_window_surface.h b/include/thallium/core/wsi/cocoa_window_surface.h index 102d627..f777c37 100644 --- a/include/thallium/core/wsi/cocoa_window_surface.h +++ b/include/thallium/core/wsi/cocoa_window_surface.h @@ -18,9 +18,9 @@ /** * @brief Create a Thallium window surface from a Cocoa window handle. * - * This function creates a window surface for Thallium functions, using a Cocoa window handle. + * This function creates a window surface for Thallium functions, using a Cocoa `NSWindow` window handle. * - * @param window + * @param window The Cocoa `NSWindow` handle (as a void ptr) * @param debugger NULL or a debugger for function debugging * @return Resulting window surface for use in Thallium functions. */