From b9efd6983ca1834fb4ee50e56e2d152e18aa4e83 Mon Sep 17 00:00:00 2001 From: Guillaume Damiand Date: Thu, 17 Apr 2025 17:45:10 +0200 Subject: [PATCH] replace macro CGAL_USE_BASIC_VIEWER by CGAL_USE_BASIC_VIEWER_QT --- .../Arrangement_on_surface_2.txt | 4 +-- .../CGAL/draw_arrangement_2.h | 4 +-- .../Arrangement_on_surface_2/CMakeLists.txt | 18 ++++++------- .../doc/Basic_viewer/CGAL/Qt/Basic_viewer.h | 6 ++--- .../Boolean_set_operations_2/CMakeLists.txt | 2 +- .../include/CGAL/draw_polygon_set_2.h | 8 +++--- .../create_and_use_a_cmakelist.txt | 2 +- .../cmake/modules/CGALConfig_binary.cmake.in | 8 +++--- .../cmake/modules/CGALConfig_install.cmake.in | 8 +++--- .../cmake/modules/CGAL_add_test.cmake | 2 +- ...GAL_enable_end_of_configuration_hook.cmake | 2 +- Installation/lib/cmake/CGAL/CGALConfig.cmake | 7 ----- .../test_configuration_qt.cmake.in | 2 +- .../demo/Linear_cell_complex/CMakeLists.txt | 2 +- .../CGAL/draw_linear_cell_complex.h | 4 +-- .../Linear_cell_complex.txt | 4 +-- .../Linear_cell_complex/CMakeLists.txt | 6 ++--- Mesh_2/examples/Mesh_2/CMakeLists.txt | 4 +-- Nef_3/doc/Nef_3/CGAL/draw_nef_3.h | 4 +-- Nef_3/doc/Nef_3/Nef_3.txt | 4 +-- Nef_3/examples/Nef_3/CMakeLists.txt | 2 +- .../CGAL/draw_periodic_2_triangulation_2.h | 4 +-- .../Periodic_2_triangulation_2/CMakeLists.txt | 2 +- .../CGAL/draw_periodic_2_triangulation_2.h | 4 +-- Point_set_3/doc/Point_set_3/Point_set_3.txt | 4 +-- .../examples/Point_set_3/CMakeLists.txt | 2 +- Point_set_3/include/CGAL/draw_point_set_3.h | 4 +-- Polygon/doc/Polygon/Polygon.txt | 4 +-- Polygon/examples/Polygon/CMakeLists.txt | 8 +++--- .../CGAL/draw_multipolygon_with_holes_2.h | 10 +++---- Polygon/include/CGAL/draw_polygon_2.h | 4 +-- .../include/CGAL/draw_polygon_with_holes_2.h | 4 +-- .../examples/Polygon_repair/CMakeLists.txt | 4 +-- .../repair_non_zero_polygon_2.cpp | 4 +-- .../repair_union_intersect_2.cpp | 8 +++--- .../test/Polygon_repair/CMakeLists.txt | 4 +-- .../doc/Polyhedron/CGAL/draw_polyhedron.h | 4 +-- Polyhedron/doc/Polyhedron/Polyhedron.txt | 4 +-- Polyhedron/examples/Polyhedron/CMakeLists.txt | 2 +- .../Straight_skeleton_2/CMakeLists.txt | 12 ++++----- .../test/Straight_skeleton_2/CMakeLists.txt | 16 ++++++------ .../CMakeLists.txt | 2 +- .../doc/Surface_mesh/Surface_mesh.txt | 4 +-- .../examples/Surface_mesh/CMakeLists.txt | 2 +- Surface_mesh/include/CGAL/draw_surface_mesh.h | 4 +-- .../CGAL/draw_face_graph_with_paths.h | 4 +-- .../Surface_mesh_topology/CMakeLists.txt | 26 +++++++++---------- .../Surface_mesh_topology/facewidth.cpp | 2 +- .../Surface_mesh_topology/path_homotopy.cpp | 4 +-- .../unsew_edgewidth_repeatedly.cpp | 12 ++++----- .../test/Surface_mesh_topology/CMakeLists.txt | 8 +++--- .../fundamental_group_of_the_circle.cpp | 6 ++--- .../fundamental_group_of_the_torus.cpp | 4 +-- .../path_with_rle_deformation_tests.cpp | 16 ++++++------ .../Surface_mesh_topology/test_homotopy.cpp | 8 +++--- .../CGAL/draw_triangulation_2.h | 4 +-- .../doc/Triangulation_2/Triangulation_2.txt | 4 +-- .../examples/Triangulation_2/CMakeLists.txt | 8 +++--- .../CGAL/draw_triangulation_3.h | 4 +-- .../doc/Triangulation_3/Triangulation_3.txt | 4 +-- .../examples/Triangulation_3/CMakeLists.txt | 2 +- .../CGAL/draw_voronoi_diagram_2.h | 4 +-- .../Voronoi_diagram_2/Voronoi_diagram_2.txt | 4 +-- .../examples/Voronoi_diagram_2/CMakeLists.txt | 2 +- .../include/CGAL/draw_voronoi_diagram_2.h | 4 +-- 65 files changed, 173 insertions(+), 180 deletions(-) diff --git a/Arrangement_on_surface_2/doc/Arrangement_on_surface_2/Arrangement_on_surface_2.txt b/Arrangement_on_surface_2/doc/Arrangement_on_surface_2/Arrangement_on_surface_2.txt index 2498396f920..909fabbfe45 100644 --- a/Arrangement_on_surface_2/doc/Arrangement_on_surface_2/Arrangement_on_surface_2.txt +++ b/Arrangement_on_surface_2/doc/Arrangement_on_surface_2/Arrangement_on_surface_2.txt @@ -6859,8 +6859,8 @@ An arrangement data structure can be visualized by calling the \link PkgArrangem \cgalExample{Arrangement_on_surface_2/draw_arr.cpp} -This function requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER` is defined. -Linking with the cmake target `CGAL::CGAL_Basic_viewer` will link with `CGAL_Qt6` and add the definition `CGAL_USE_BASIC_VIEWER`. +This function requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER_QT` is defined. +Linking with the cmake target `CGAL::CGAL_Basic_viewer_Qt` will link with `CGAL_Qt6` and add the definition `CGAL_USE_BASIC_VIEWER_QT`. \cgalFigureBegin{aos_fig-draw_arr,draw_arr.png} A snapshot of the window created by the program diff --git a/Arrangement_on_surface_2/doc/Arrangement_on_surface_2/CGAL/draw_arrangement_2.h b/Arrangement_on_surface_2/doc/Arrangement_on_surface_2/CGAL/draw_arrangement_2.h index 905588aaf88..1353c014215 100644 --- a/Arrangement_on_surface_2/doc/Arrangement_on_surface_2/CGAL/draw_arrangement_2.h +++ b/Arrangement_on_surface_2/doc/Arrangement_on_surface_2/CGAL/draw_arrangement_2.h @@ -29,8 +29,8 @@ namespace CGAL { * `CGAL::Arrangement_2` class template. Parameters of the drawing are taken * from the optional graphics scene options parameter. * -A call to this function blocks the execution of the program until the drawing window is closed. This function requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER`/`CGAL_USE_BASIC_VIEWER_QT` (Qt viewer) is defined. -Linking with the cmake target `CGAL::CGAL_Basic_viewer`/`CGAL::CGAL_Basic_viewer_Qt` will link with `CGAL_Qt6` and add the definition `CGAL_USE_BASIC_VIEWER`/`CGAL_USE_BASIC_VIEWER_QT`. +A call to this function blocks the execution of the program until the drawing window is closed. This function requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER_QT` (Qt viewer) is defined. +Linking with the cmake target `CGAL::CGAL_Basic_viewer_Qt` will link with `CGAL_Qt6` and add the definition `CGAL_USE_BASIC_VIEWER_QT`. * * \tparam GeometryTraits_2 a geometry traits type, a model of a 2D arrangement * traits concept. At this point it must be an instance of either diff --git a/Arrangement_on_surface_2/examples/Arrangement_on_surface_2/CMakeLists.txt b/Arrangement_on_surface_2/examples/Arrangement_on_surface_2/CMakeLists.txt index bb5566835ab..b8fc3c5ee32 100644 --- a/Arrangement_on_surface_2/examples/Arrangement_on_surface_2/CMakeLists.txt +++ b/Arrangement_on_surface_2/examples/Arrangement_on_surface_2/CMakeLists.txt @@ -16,15 +16,15 @@ foreach(cppfile ${cppfiles}) endforeach() if(CGAL_Qt6_FOUND) - target_link_libraries(draw_arr PRIVATE CGAL::CGAL_Basic_viewer) - target_link_libraries(linear_conics PRIVATE CGAL::CGAL_Basic_viewer) - target_link_libraries(parabolas PRIVATE CGAL::CGAL_Basic_viewer) - target_link_libraries(ellipses PRIVATE CGAL::CGAL_Basic_viewer) - target_link_libraries(hyperbolas PRIVATE CGAL::CGAL_Basic_viewer) - target_link_libraries(polylines PRIVATE CGAL::CGAL_Basic_viewer) - target_link_libraries(circles PRIVATE CGAL::CGAL_Basic_viewer) - target_link_libraries(circular_arcs PRIVATE CGAL::CGAL_Basic_viewer) - target_link_libraries(spherical_insert PRIVATE CGAL::CGAL_Basic_viewer) + target_link_libraries(draw_arr PRIVATE CGAL::CGAL_Basic_viewer_Qt) + target_link_libraries(linear_conics PRIVATE CGAL::CGAL_Basic_viewer_Qt) + target_link_libraries(parabolas PRIVATE CGAL::CGAL_Basic_viewer_Qt) + target_link_libraries(ellipses PRIVATE CGAL::CGAL_Basic_viewer_Qt) + target_link_libraries(hyperbolas PRIVATE CGAL::CGAL_Basic_viewer_Qt) + target_link_libraries(polylines PRIVATE CGAL::CGAL_Basic_viewer_Qt) + target_link_libraries(circles PRIVATE CGAL::CGAL_Basic_viewer_Qt) + target_link_libraries(circular_arcs PRIVATE CGAL::CGAL_Basic_viewer_Qt) + target_link_libraries(spherical_insert PRIVATE CGAL::CGAL_Basic_viewer_Qt) else() message( STATUS diff --git a/Basic_viewer/doc/Basic_viewer/CGAL/Qt/Basic_viewer.h b/Basic_viewer/doc/Basic_viewer/CGAL/Qt/Basic_viewer.h index 0604905bdae..b50ee225b57 100644 --- a/Basic_viewer/doc/Basic_viewer/CGAL/Qt/Basic_viewer.h +++ b/Basic_viewer/doc/Basic_viewer/CGAL/Qt/Basic_viewer.h @@ -5,7 +5,7 @@ namespace CGAL { /*! \ingroup PkgBasicViewerClasses -The class `Basic_viewer` is a Qt widget based on `QGLViewer` that allows to visualize 3D elements: points, segments, triangles, rays and lines. This class stores a reference to a `Graphics_scene`. Elements are added through the scene. This class requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER_QT` is defined. Linking with the cmake target `CGAL::CGAL_Basic_viewer` or `CGAL::CGAL_Basic_viewer_Qt` will link with `CGAL_Qt6` and add the definition `CGAL_USE_BASIC_VIEWER` & `CGAL_USE_BASIC_VIEWER_QT`. +The class `Basic_viewer` is a Qt widget based on `QGLViewer` that allows to visualize 3D elements: points, segments, triangles, rays and lines. This class stores a reference to a `Graphics_scene`. Elements are added through the scene. This class requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER_QT` is defined. Linking with the cmake target `CGAL::CGAL_Basic_viewer_Qt` will link with `CGAL_Qt6` and add the definition `CGAL_USE_BASIC_VIEWER_QT`. CGAL::QGLViewer is our internal fork of QGLViewer class which is A versatile 3D OpenGL viewer based on QOpenGLWidget. */ @@ -207,7 +207,7 @@ public: The class `QApplication_and_basic_viewer` regroups a `Basic_viewer` and Qt `QApplication`. The `QApplication` is created in the constructor, but started by the `run()` method. This allows for example users to modify the `on_key_pressed` method of the `Basic_viewer` to define their own behavior. -This class requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER` or `CGAL_USE_BASIC_VIEWER_QT` is defined. Linking with the cmake target `CGAL::CGAL_Basic_viewer` or `CGAL::CGAL_Basic_viewer_Qt` will link with `CGAL_Qt6` and add the definition `CGAL_USE_BASIC_VIEWER` & `CGAL_USE_BASIC_VIEWER_QT`. +This class requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER_QT` is defined. Linking with the cmake target `CGAL::CGAL_Basic_viewer_Qt` will link with `CGAL_Qt6` and add the definition `CGAL_USE_BASIC_VIEWER_QT`. */ class QApplication_and_basic_viewer @@ -230,7 +230,7 @@ public: /*! \ingroup PkgBasicViewerClasses - opens a new window and draws the given `Graphics_scene` (which must have been filled before). `title` will be the title of the window. A call to this method is blocking, that is the program continues as soon as the user closes the window. This function requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER` is defined. Linking with the cmake target `CGAL::CGAL_Basic_viewer` will link with `CGAL_Qt6` and add the definition CGAL_USE_BASIC_VIEWER. + opens a new window and draws the given `Graphics_scene` (which must have been filled before). `title` will be the title of the window. A call to this method is blocking, that is the program continues as soon as the user closes the window. This function requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER_QT` is defined. Linking with the cmake target `CGAL::CGAL_Basic_viewer_Qt` will link with `CGAL_Qt6` and add the definition CGAL_USE_BASIC_VIEWER_QT. */ void draw_graphics_scene(const Graphics_scene& graphic_scene, const char *title="CGAL Basic Viewer") diff --git a/Boolean_set_operations_2/examples/Boolean_set_operations_2/CMakeLists.txt b/Boolean_set_operations_2/examples/Boolean_set_operations_2/CMakeLists.txt index 99d2c05f6ce..0f1a86fcbba 100644 --- a/Boolean_set_operations_2/examples/Boolean_set_operations_2/CMakeLists.txt +++ b/Boolean_set_operations_2/examples/Boolean_set_operations_2/CMakeLists.txt @@ -16,7 +16,7 @@ foreach(cppfile ${cppfiles}) endforeach() if(CGAL_Qt6_FOUND) - target_link_libraries(draw_polygon_set PRIVATE CGAL::CGAL_Basic_viewer) + target_link_libraries(draw_polygon_set PRIVATE CGAL::CGAL_Basic_viewer_Qt) else() message(STATUS "NOTICE: The example 'draw_polygon_set' requires Qt and drawing will be disabled.") endif() diff --git a/Boolean_set_operations_2/include/CGAL/draw_polygon_set_2.h b/Boolean_set_operations_2/include/CGAL/draw_polygon_set_2.h index e8af7da33d8..5504103efeb 100644 --- a/Boolean_set_operations_2/include/CGAL/draw_polygon_set_2.h +++ b/Boolean_set_operations_2/include/CGAL/draw_polygon_set_2.h @@ -166,7 +166,7 @@ void compute_elements(const PWH& pwh, } // End namespace draw_function_for_boolean_set_2 -#if defined(CGAL_USE_BASIC_VIEWER_QT) || defined(CGAL_USE_BASIC_VIEWER) +#if defined(CGAL_USE_BASIC_VIEWER_QT) template class Polygon_set_2_basic_viewer_qt : public Basic_viewer @@ -259,7 +259,7 @@ private: GSOptions& gso; }; -#endif // CGAL_USE_BASIC_VIEWER +#endif // CGAL_USE_BASIC_VIEWER_QT #define CGAL_PS2_TYPE CGAL::Polygon_set_2 @@ -281,7 +281,7 @@ void add_to_graphics_scene(const CGAL_PS2_TYPE& ap2, draw_function_for_boolean_set_2::compute_elements(ap2, graphics_scene, gso); } -#ifdef CGAL_USE_BASIC_VIEWER +#ifdef CGAL_USE_BASIC_VIEWER_QT // Specialization of draw function. template @@ -319,7 +319,7 @@ void draw(const CGAL_PS2_TYPE& ps, draw(ps, gso, title); } -#endif // CGAL_USE_BASIC_VIEWER_QT || CGAL_USE_BASIC_VIEWER +#endif // CGAL_USE_BASIC_VIEWER_QT #undef CGAL_PS2_TYPE diff --git a/Documentation/doc/Documentation/Developer_manual/create_and_use_a_cmakelist.txt b/Documentation/doc/Documentation/Developer_manual/create_and_use_a_cmakelist.txt index dd6506eb496..da3ab4d22f1 100644 --- a/Documentation/doc/Documentation/Developer_manual/create_and_use_a_cmakelist.txt +++ b/Documentation/doc/Documentation/Developer_manual/create_and_use_a_cmakelist.txt @@ -43,7 +43,7 @@ This section describes a minimal example of a program that uses \cgal and Qt6 fo \skip if(CGAL_Qt6_FOUND) -\until target_link_libraries(draw_surface_mesh PRIVATE CGAL::CGAL_Basic_viewer) +\until target_link_libraries(draw_surface_mesh PRIVATE CGAL::CGAL_Basic_viewer_Qt) \skip endif \until #end of the file diff --git a/Installation/cmake/modules/CGALConfig_binary.cmake.in b/Installation/cmake/modules/CGALConfig_binary.cmake.in index eaab3c7f7f7..0af7e1a6862 100644 --- a/Installation/cmake/modules/CGALConfig_binary.cmake.in +++ b/Installation/cmake/modules/CGALConfig_binary.cmake.in @@ -208,10 +208,10 @@ endif() # # Define a specific target for basic viewer # -if (NOT TARGET CGAL::CGAL_Basic_viewer) - add_library(CGAL::CGAL_Basic_viewer INTERFACE IMPORTED GLOBAL) - set_target_properties(CGAL::CGAL_Basic_viewer PROPERTIES - INTERFACE_COMPILE_DEFINITIONS "CGAL_USE_BASIC_VIEWER;QT_NO_KEYWORDS" +if (NOT TARGET CGAL::CGAL_Basic_viewer_Qt) + add_library(CGAL::CGAL_Basic_viewer_Qt INTERFACE IMPORTED GLOBAL) + set_target_properties(CGAL::CGAL_Basic_viewer_Qt PROPERTIES + INTERFACE_COMPILE_DEFINITIONS "CGAL_USE_BASIC_VIEWER_QT;QT_NO_KEYWORDS" INTERFACE_LINK_LIBRARIES CGAL::CGAL_Qt6) endif() diff --git a/Installation/cmake/modules/CGALConfig_install.cmake.in b/Installation/cmake/modules/CGALConfig_install.cmake.in index eac955bb91c..888da0f485f 100644 --- a/Installation/cmake/modules/CGALConfig_install.cmake.in +++ b/Installation/cmake/modules/CGALConfig_install.cmake.in @@ -193,10 +193,10 @@ endif() # # Define a specific target for basic viewer # -if (NOT TARGET CGAL::CGAL_Basic_viewer) - add_library(CGAL::CGAL_Basic_viewer INTERFACE IMPORTED GLOBAL) - set_target_properties(CGAL::CGAL_Basic_viewer PROPERTIES - INTERFACE_COMPILE_DEFINITIONS "CGAL_USE_BASIC_VIEWER;QT_NO_KEYWORDS" +if (NOT TARGET CGAL::CGAL_Basic_viewer_Qt) + add_library(CGAL::CGAL_Basic_viewer_Qt INTERFACE IMPORTED GLOBAL) + set_target_properties(CGAL::CGAL_Basic_viewer_Qt PROPERTIES + INTERFACE_COMPILE_DEFINITIONS "CGAL_USE_BASIC_VIEWER_QT;QT_NO_KEYWORDS" INTERFACE_LINK_LIBRARIES CGAL::CGAL_Qt6) endif() diff --git a/Installation/cmake/modules/CGAL_add_test.cmake b/Installation/cmake/modules/CGAL_add_test.cmake index edc7b43dbee..61247c3c665 100644 --- a/Installation/cmake/modules/CGAL_add_test.cmake +++ b/Installation/cmake/modules/CGAL_add_test.cmake @@ -124,7 +124,7 @@ function(cgal_add_compilation_test exe_name) if(TARGET CGAL_Qt6_moc_and_resources) # if CGAL_Qt6 was searched, and is header-only get_property(linked_libraries TARGET "${exe_name}" PROPERTY LINK_LIBRARIES) # message(STATUS "${exe_name} depends on ${linked_libraries}") - if( ("CGAL_Qt6" IN_LIST linked_libraries OR "CGAL::CGAL_Qt6" IN_LIST linked_libraries OR "CGAL::CGAL_Basic_viewer" IN_LIST linked_libraries) + if( ("CGAL_Qt6" IN_LIST linked_libraries OR "CGAL::CGAL_Qt6" IN_LIST linked_libraries OR "CGAL::CGAL_Basic_viewer_Qt" IN_LIST linked_libraries) AND NOT TARGET "compilation_of__CGAL_Qt6_moc_and_resources") # This custom target is useless. It is used only as a flag to # detect that the test has already been created. diff --git a/Installation/cmake/modules/CGAL_enable_end_of_configuration_hook.cmake b/Installation/cmake/modules/CGAL_enable_end_of_configuration_hook.cmake index 43d17a055f8..006b90a1249 100644 --- a/Installation/cmake/modules/CGAL_enable_end_of_configuration_hook.cmake +++ b/Installation/cmake/modules/CGAL_enable_end_of_configuration_hook.cmake @@ -110,7 +110,7 @@ function(CGAL_hook_fix_ctest_depending_on_Qt6) continue() endif() get_property(_target_links TARGET ${_target} PROPERTY LINK_LIBRARIES) - if("CGAL_Qt6" IN_LIST _target_links OR "CGAL::CGAL_Qt6" IN_LIST _target_links OR "CGAL::CGAL_Basic_viewer" IN_LIST _target_links) + if("CGAL_Qt6" IN_LIST _target_links OR "CGAL::CGAL_Qt6" IN_LIST _target_links OR "CGAL::CGAL_Basic_viewer_Qt" IN_LIST _target_links) set_property(TEST "compilation of ${_target}" APPEND PROPERTY FIXTURES_REQUIRED CGAL_Qt6_moc_and_resources_Fixture) endif() endforeach() diff --git a/Installation/lib/cmake/CGAL/CGALConfig.cmake b/Installation/lib/cmake/CGAL/CGALConfig.cmake index 9f850cab51f..ea8fdd14cae 100644 --- a/Installation/lib/cmake/CGAL/CGALConfig.cmake +++ b/Installation/lib/cmake/CGAL/CGALConfig.cmake @@ -196,13 +196,6 @@ endforeach() # # Define a specific target for basic viewer # -if (NOT TARGET CGAL::CGAL_Basic_viewer) - add_library(CGAL::CGAL_Basic_viewer INTERFACE IMPORTED GLOBAL) - set_target_properties(CGAL::CGAL_Basic_viewer PROPERTIES - INTERFACE_COMPILE_DEFINITIONS "CGAL_USE_BASIC_VIEWER" - INTERFACE_LINK_LIBRARIES CGAL::CGAL_Qt6) -endif() - if (NOT TARGET CGAL::CGAL_Basic_viewer_Qt) add_library(CGAL::CGAL_Basic_viewer_Qt INTERFACE IMPORTED GLOBAL) set_target_properties(CGAL::CGAL_Basic_viewer_Qt PROPERTIES diff --git a/Installation/test/Installation/test_configuration_qt.cmake.in b/Installation/test/Installation/test_configuration_qt.cmake.in index 3e2e50894f4..4fcad54189b 100644 --- a/Installation/test/Installation/test_configuration_qt.cmake.in +++ b/Installation/test/Installation/test_configuration_qt.cmake.in @@ -1,7 +1,7 @@ cmake_minimum_required(VERSION 3.12...3.31) project(test_configuration) find_package(CGAL COMPONENTS Qt6) -add_definitions(-DCGAL_USE_BASIC_VIEWER -DQT_NO_KEYWORDS) +add_definitions(-DCGAL_USE_BASIC_VIEWER_QT -DQT_NO_KEYWORDS) get_filename_component(CGAL_DIR_PATH "${CGAL_DIR}/CMakeConfig.cmake" DIRECTORY) get_filename_component(CGAL_GIVEN_DIR_PATH "${CGAL_GIVEN_DIR}/CMakeConfig.cmake" DIRECTORY) diff --git a/Linear_cell_complex/demo/Linear_cell_complex/CMakeLists.txt b/Linear_cell_complex/demo/Linear_cell_complex/CMakeLists.txt index b71bfe57fe0..b916ab37020 100644 --- a/Linear_cell_complex/demo/Linear_cell_complex/CMakeLists.txt +++ b/Linear_cell_complex/demo/Linear_cell_complex/CMakeLists.txt @@ -40,7 +40,7 @@ if(NOT CGAL_Qt6_FOUND OR NOT Qt6_FOUND) else() - add_compile_definitions(CGAL_USE_BASIC_VIEWER QT_NO_KEYWORDS) + add_compile_definitions(CGAL_USE_BASIC_VIEWER_QT QT_NO_KEYWORDS) set(CMAKE_AUTOMOC ON) set(CMAKE_AUTOUIC ON) set(CMAKE_AUTORCC ON) diff --git a/Linear_cell_complex/doc/Linear_cell_complex/CGAL/draw_linear_cell_complex.h b/Linear_cell_complex/doc/Linear_cell_complex/CGAL/draw_linear_cell_complex.h index 8bd648331e8..f4091dec72f 100644 --- a/Linear_cell_complex/doc/Linear_cell_complex/CGAL/draw_linear_cell_complex.h +++ b/Linear_cell_complex/doc/Linear_cell_complex/CGAL/draw_linear_cell_complex.h @@ -5,8 +5,8 @@ namespace CGAL { opens a new window and draws a linear cell complex. Parameters of the drawing are taken from the optional graphics scene options parameter. -A call to this function blocks the execution of the program until the drawing window is closed. This function requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER`/`CGAL_USE_BASIC_VIEWER_QT` (Qt viewer) is defined. -Linking with the cmake target `CGAL::CGAL_Basic_viewer`/`CGAL::CGAL_Basic_viewer_Qt` will link with `CGAL_Qt6` and add the definition `CGAL_USE_BASIC_VIEWER`/`CGAL_USE_BASIC_VIEWER_QT`. +A call to this function blocks the execution of the program until the drawing window is closed. This function requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER_QT` (Qt viewer) is defined. +Linking with the cmake target `CGAL::CGAL_Basic_viewer_Qt` will link with `CGAL_Qt6` and add the definition `CGAL_USE_BASIC_VIEWER_QT`. \tparam LCC which must be an instantiation of a `CGAL::Linear_cell_complex_for_combinatorial_map<...>` or `CGAL::Linear_cell_complex_for_generalized_map<...>`. \tparam GSOptions a model of `GraphicsSceneOptions` concept. diff --git a/Linear_cell_complex/doc/Linear_cell_complex/Linear_cell_complex.txt b/Linear_cell_complex/doc/Linear_cell_complex/Linear_cell_complex.txt index d58e0f6e2e5..f028e70182c 100644 --- a/Linear_cell_complex/doc/Linear_cell_complex/Linear_cell_complex.txt +++ b/Linear_cell_complex/doc/Linear_cell_complex/Linear_cell_complex.txt @@ -265,8 +265,8 @@ A linear cell complex can be visualized by calling the \link PkgDrawLinearCellCo \cgalExample{Linear_cell_complex/draw_linear_cell_complex.cpp} -This function requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER` is defined. -Linking with the cmake target `CGAL::CGAL_Basic_viewer` will link with `CGAL_Qt6` and add the definition `CGAL_USE_BASIC_VIEWER`. +This function requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER_QT` is defined. +Linking with the cmake target `CGAL::CGAL_Basic_viewer_Qt` will link with `CGAL_Qt6` and add the definition `CGAL_USE_BASIC_VIEWER_QT`. \cgalFigureBegin{fig_draw_lcc,draw_lcc.png} Result of the run of the draw_linear_cell_complex program. A window shows two 3D cubes and allows to navigate through the 3D scene. diff --git a/Linear_cell_complex/examples/Linear_cell_complex/CMakeLists.txt b/Linear_cell_complex/examples/Linear_cell_complex/CMakeLists.txt index e9604793e4b..c68c8153f7f 100644 --- a/Linear_cell_complex/examples/Linear_cell_complex/CMakeLists.txt +++ b/Linear_cell_complex/examples/Linear_cell_complex/CMakeLists.txt @@ -30,7 +30,7 @@ create_single_source_cgal_program("voronoi_3.cpp") create_single_source_cgal_program("draw_linear_cell_complex.cpp") if(CGAL_Qt6_FOUND) - target_link_libraries(draw_linear_cell_complex PRIVATE CGAL::CGAL_Basic_viewer) - target_link_libraries(linear_cell_complex_3_incremental_builder PRIVATE CGAL::CGAL_Basic_viewer) - target_link_libraries(linear_cell_complex_3_insert PRIVATE CGAL::CGAL_Basic_viewer) + target_link_libraries(draw_linear_cell_complex PRIVATE CGAL::CGAL_Basic_viewer_Qt) + target_link_libraries(linear_cell_complex_3_incremental_builder PRIVATE CGAL::CGAL_Basic_viewer_Qt) + target_link_libraries(linear_cell_complex_3_insert PRIVATE CGAL::CGAL_Basic_viewer_Qt) endif() diff --git a/Mesh_2/examples/Mesh_2/CMakeLists.txt b/Mesh_2/examples/Mesh_2/CMakeLists.txt index c94cec90f83..c7c061010d6 100644 --- a/Mesh_2/examples/Mesh_2/CMakeLists.txt +++ b/Mesh_2/examples/Mesh_2/CMakeLists.txt @@ -13,6 +13,6 @@ foreach(cppfile ${cppfiles}) endforeach() if(CGAL_Qt6_FOUND) - target_link_libraries(mesh_with_seeds PRIVATE CGAL::CGAL_Basic_viewer) - target_link_libraries(mesh_marked_domain PRIVATE CGAL::CGAL_Basic_viewer) + target_link_libraries(mesh_with_seeds PRIVATE CGAL::CGAL_Basic_viewer_Qt) + target_link_libraries(mesh_marked_domain PRIVATE CGAL::CGAL_Basic_viewer_Qt) endif() diff --git a/Nef_3/doc/Nef_3/CGAL/draw_nef_3.h b/Nef_3/doc/Nef_3/CGAL/draw_nef_3.h index 75f721ea29e..7b3ebc4c546 100644 --- a/Nef_3/doc/Nef_3/CGAL/draw_nef_3.h +++ b/Nef_3/doc/Nef_3/CGAL/draw_nef_3.h @@ -5,8 +5,8 @@ namespace CGAL { opens a new window and draws a nef polyhedron. Parameters of the drawing are taken from the optional graphics scene options parameter. -A call to this function blocks the execution of the program until the drawing window is closed. This function requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER`/`CGAL_USE_BASIC_VIEWER_QT` (Qt viewer) is defined. -Linking with the cmake target `CGAL::CGAL_Basic_viewer`/`CGAL::CGAL_Basic_viewer_Qt` will link with `CGAL_Qt6` and add the definition `CGAL_USE_BASIC_VIEWER`/`CGAL_USE_BASIC_VIEWER_QT`. +A call to this function blocks the execution of the program until the drawing window is closed. This function requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER_QT` (Qt viewer) is defined. +Linking with the cmake target `CGAL::CGAL_Basic_viewer_Qt` will link with `CGAL_Qt6` and add the definition `CGAL_USE_BASIC_VIEWER_QT`. \tparam NP3 which must be an instantiation of a `CGAL::Nef_polyhedron_3<...>`. \tparam GSOptions a model of `GraphicsSceneOptions` concept. diff --git a/Nef_3/doc/Nef_3/Nef_3.txt b/Nef_3/doc/Nef_3/Nef_3.txt index d205dd42a11..19a1e667d31 100644 --- a/Nef_3/doc/Nef_3/Nef_3.txt +++ b/Nef_3/doc/Nef_3/Nef_3.txt @@ -424,8 +424,8 @@ A nef polyhedron can be visualized by calling the \link PkgDrawNef3 CGAL::draw`. \tparam GSOptions a model of `GraphicsSceneOptionsPeriodic2Triangulation2` concept. diff --git a/Periodic_2_triangulation_2/examples/Periodic_2_triangulation_2/CMakeLists.txt b/Periodic_2_triangulation_2/examples/Periodic_2_triangulation_2/CMakeLists.txt index 85d443b4c6f..144f32fb0eb 100644 --- a/Periodic_2_triangulation_2/examples/Periodic_2_triangulation_2/CMakeLists.txt +++ b/Periodic_2_triangulation_2/examples/Periodic_2_triangulation_2/CMakeLists.txt @@ -16,5 +16,5 @@ foreach(cppfile ${cppfiles}) endforeach() if(CGAL_Qt6_FOUND) - target_link_libraries(draw_periodic_2_triangulation_2 PRIVATE CGAL::CGAL_Basic_viewer) + target_link_libraries(draw_periodic_2_triangulation_2 PRIVATE CGAL::CGAL_Basic_viewer_Qt) endif() diff --git a/Periodic_2_triangulation_2/include/CGAL/draw_periodic_2_triangulation_2.h b/Periodic_2_triangulation_2/include/CGAL/draw_periodic_2_triangulation_2.h index e0a636b0854..ba7d22b4efb 100644 --- a/Periodic_2_triangulation_2/include/CGAL/draw_periodic_2_triangulation_2.h +++ b/Periodic_2_triangulation_2/include/CGAL/draw_periodic_2_triangulation_2.h @@ -220,7 +220,7 @@ void add_to_graphics_scene(const CGAL_P2T2_TYPE& p2t2, add_to_graphics_scene(p2t2, graphics_scene, gs_options); } -#if defined(CGAL_USE_BASIC_VIEWER_QT) || defined(CGAL_USE_BASIC_VIEWER) +#if defined(CGAL_USE_BASIC_VIEWER_QT) // Specialization of draw function template @@ -278,7 +278,7 @@ void draw(const CGAL_P2T2_TYPE& ap2t2, draw(ap2t2, gs_options, title); } -#endif // CGAL_USE_BASIC_VIEWER_QT || CGAL_USE_BASIC_VIEWER +#endif // CGAL_USE_BASIC_VIEWER_QT #undef CGAL_P2T2_TYPE diff --git a/Point_set_3/doc/Point_set_3/Point_set_3.txt b/Point_set_3/doc/Point_set_3/Point_set_3.txt index f06483789f0..1dcbb61ad4e 100644 --- a/Point_set_3/doc/Point_set_3/Point_set_3.txt +++ b/Point_set_3/doc/Point_set_3/Point_set_3.txt @@ -169,8 +169,8 @@ A 3D point set can be visualized by calling the \link PkgDrawPointSet3D CGAL::dr \cgalExample{Point_set_3/draw_point_set_3.cpp} -This function requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER` is defined. -Linking with the cmake target `CGAL::CGAL_Basic_viewer` will link with `CGAL_Qt6` and add the definition `CGAL_USE_BASIC_VIEWER`. +This function requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER_QT` is defined. +Linking with the cmake target `CGAL::CGAL_Basic_viewer_Qt` will link with `CGAL_Qt6` and add the definition `CGAL_USE_BASIC_VIEWER_QT`. \cgalFigureBegin{fig_draw_point_set,draw_point_set.png} Result of the run of the draw_point_set_3 program. A window shows the 3D points and allows to navigate through the 3D scene. diff --git a/Point_set_3/examples/Point_set_3/CMakeLists.txt b/Point_set_3/examples/Point_set_3/CMakeLists.txt index 1019bcd4ef1..78c5550f443 100644 --- a/Point_set_3/examples/Point_set_3/CMakeLists.txt +++ b/Point_set_3/examples/Point_set_3/CMakeLists.txt @@ -24,5 +24,5 @@ endif() create_single_source_cgal_program("draw_point_set_3.cpp") if(CGAL_Qt6_FOUND) - target_link_libraries(draw_point_set_3 PRIVATE CGAL::CGAL_Basic_viewer) + target_link_libraries(draw_point_set_3 PRIVATE CGAL::CGAL_Basic_viewer_Qt) endif() diff --git a/Point_set_3/include/CGAL/draw_point_set_3.h b/Point_set_3/include/CGAL/draw_point_set_3.h index e01725be598..779e1dc1e24 100644 --- a/Point_set_3/include/CGAL/draw_point_set_3.h +++ b/Point_set_3/include/CGAL/draw_point_set_3.h @@ -28,8 +28,8 @@ namespace CGAL { opens a new window and draws a point set. Parameters of the drawing are taken from the optional graphics scene options parameter. -A call to this function blocks the execution of the program until the drawing window is closed. This function requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER`/`CGAL_USE_BASIC_VIEWER_QT` (Qt viewer) is defined. -Linking with the cmake target `CGAL::CGAL_Basic_viewer`/`CGAL::CGAL_Basic_viewer_Qt` will link with `CGAL_Qt6` and add the definition `CGAL_USE_BASIC_VIEWER`/`CGAL_USE_BASIC_VIEWER_QT`. +A call to this function blocks the execution of the program until the drawing window is closed. This function requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER_QT` (Qt viewer) is defined. +Linking with the cmake target `CGAL::CGAL_Basic_viewer_Qt` will link with `CGAL_Qt6` and add the definition `CGAL_USE_BASIC_VIEWER_QT`. \tparam PS which must be an instantiation of a `CGAL::Point_set_3<...>`. \tparam GSOptions a model of `GraphicsSceneOptions` concept. diff --git a/Polygon/doc/Polygon/Polygon.txt b/Polygon/doc/Polygon/Polygon.txt index 093cb03d5f6..ce882c21f8a 100644 --- a/Polygon/doc/Polygon/Polygon.txt +++ b/Polygon/doc/Polygon/Polygon.txt @@ -107,8 +107,8 @@ CGAL::draw() \endlink. \cgalExample{Polygon/draw_polygon.cpp} -This function requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER` is defined. -Linking with the cmake target `CGAL::CGAL_Basic_viewer` will link with `CGAL_Qt6` and add the definition `CGAL_USE_BASIC_VIEWER`. +This function requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER_QT` is defined. +Linking with the cmake target `CGAL::CGAL_Basic_viewer_Qt` will link with `CGAL_Qt6` and add the definition `CGAL_USE_BASIC_VIEWER_QT`. \cgalFigureBegin{fig_draw_polygon,draw_polygon.png} Result of the run of the draw_polygon program. A window shows the polygon and allows to navigate through the scene. diff --git a/Polygon/examples/Polygon/CMakeLists.txt b/Polygon/examples/Polygon/CMakeLists.txt index f41d86812bd..c2362a91dfd 100644 --- a/Polygon/examples/Polygon/CMakeLists.txt +++ b/Polygon/examples/Polygon/CMakeLists.txt @@ -16,8 +16,8 @@ foreach(cppfile ${cppfiles}) endforeach() if(CGAL_Qt6_FOUND) - target_link_libraries(draw_polygon PRIVATE CGAL::CGAL_Basic_viewer) - target_link_libraries(draw_polygon_with_holes PRIVATE CGAL::CGAL_Basic_viewer) - target_link_libraries(draw_polygon_with_holes_2 PRIVATE CGAL::CGAL_Basic_viewer) - target_link_libraries(draw_multipolygon_with_holes PRIVATE CGAL::CGAL_Basic_viewer) + target_link_libraries(draw_polygon PRIVATE CGAL::CGAL_Basic_viewer_Qt) + target_link_libraries(draw_polygon_with_holes PRIVATE CGAL::CGAL_Basic_viewer_Qt) + target_link_libraries(draw_polygon_with_holes_2 PRIVATE CGAL::CGAL_Basic_viewer_Qt) + target_link_libraries(draw_multipolygon_with_holes PRIVATE CGAL::CGAL_Basic_viewer_Qt) endif() diff --git a/Polygon/include/CGAL/draw_multipolygon_with_holes_2.h b/Polygon/include/CGAL/draw_multipolygon_with_holes_2.h index ddcc967a1de..e900e3042fa 100644 --- a/Polygon/include/CGAL/draw_multipolygon_with_holes_2.h +++ b/Polygon/include/CGAL/draw_multipolygon_with_holes_2.h @@ -30,9 +30,9 @@ namespace CGAL { * `CGAL::Multipolygon_with_holes_2` class. A call to this function is blocking, that * is the program continues as soon as the user closes the window. This function * requires `CGAL_Qt6`, and is only available if the macro - * `CGAL_USE_BASIC_VIEWER` is defined. Linking with the cmake target - * `CGAL::CGAL_Basic_viewer` will link with `CGAL_Qt6` and add the definition - * `CGAL_USE_BASIC_VIEWER`. + * `CGAL_USE_BASIC_VIEWER_QT` is defined. Linking with the cmake target + * `CGAL::CGAL_Basic_viewer_Qt` will link with `CGAL_Qt6` and add the definition + * `CGAL_USE_BASIC_VIEWER_QT`. * \tparam PH an instance of the `CGAL::Multipolygon_with_holes_2` class. * \param aph the multipolygon with holes to draw. */ @@ -44,7 +44,7 @@ void draw(const MPH& aph); #endif -#if defined(CGAL_USE_BASIC_VIEWER_QT) || defined(CGAL_USE_BASIC_VIEWER) +#if defined(CGAL_USE_BASIC_VIEWER_QT) #include #include @@ -207,6 +207,6 @@ void draw(const CGAL::Multipolygon_with_holes_2& mpwh, } // End namespace CGAL -#endif // CGAL_USE_BASIC_VIEWER_QT || CGAL_USE_BASIC_VIEWER +#endif // CGAL_USE_BASIC_VIEWER_QT #endif // CGAL_DRAW_MULTIPOLYGON_WITH_HOLES_2_H diff --git a/Polygon/include/CGAL/draw_polygon_2.h b/Polygon/include/CGAL/draw_polygon_2.h index 38b6da1335f..65c2bfb33be 100644 --- a/Polygon/include/CGAL/draw_polygon_2.h +++ b/Polygon/include/CGAL/draw_polygon_2.h @@ -31,8 +31,8 @@ namespace CGAL { opens a new window and draws a 2D polygon. Parameters of the drawing are taken from the optional graphics scene options parameter. -A call to this function blocks the execution of the program until the drawing window is closed. This function requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER`/`CGAL_USE_BASIC_VIEWER_QT` (Qt viewer) is defined. -Linking with the cmake target `CGAL::CGAL_Basic_viewer`/`CGAL::CGAL_Basic_viewer_Qt` will link with `CGAL_Qt6` and add the definition `CGAL_USE_BASIC_VIEWER`/`CGAL_USE_BASIC_VIEWER_QT`. +A call to this function blocks the execution of the program until the drawing window is closed. This function requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER_QT` (Qt viewer) is defined. +Linking with the cmake target `CGAL::CGAL_Basic_viewer_Qt` will link with `CGAL_Qt6` and add the definition `CGAL_USE_BASIC_VIEWER_QT`. \tparam P which must be an instantiation of a `CGAL::Polygon_2<...>`. \tparam GSOptions a model of `GraphicsSceneOptions` concept. diff --git a/Polygon/include/CGAL/draw_polygon_with_holes_2.h b/Polygon/include/CGAL/draw_polygon_with_holes_2.h index 1a7085944be..72c75097267 100644 --- a/Polygon/include/CGAL/draw_polygon_with_holes_2.h +++ b/Polygon/include/CGAL/draw_polygon_with_holes_2.h @@ -31,8 +31,8 @@ namespace CGAL { opens a new window and draws a 2D polygon with holes. Parameters of the drawing are taken from the optional graphics scene options parameter. -A call to this function blocks the execution of the program until the drawing window is closed. This function requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER`/`CGAL_USE_BASIC_VIEWER_QT` (Qt viewer) is defined. -Linking with the cmake target `CGAL::CGAL_Basic_viewer`/`CGAL::CGAL_Basic_viewer_Qt` will link with `CGAL_Qt6` and add the definition `CGAL_USE_BASIC_VIEWER`/`CGAL_USE_BASIC_VIEWER_QT`. +A call to this function blocks the execution of the program until the drawing window is closed. This function requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER_QT` (Qt viewer) is defined. +Linking with the cmake target `CGAL::CGAL_Basic_viewer_Qt` will link with `CGAL_Qt6` and add the definition `CGAL_USE_BASIC_VIEWER_QT`. \tparam PH which must be an instantiation of a `CGAL::Polygon_with_holes_2<...>`. \tparam GSOptions a model of `GraphicsSceneOptions` concept. diff --git a/Polygon_repair/examples/Polygon_repair/CMakeLists.txt b/Polygon_repair/examples/Polygon_repair/CMakeLists.txt index 3453a093f10..c3fe86a22ef 100644 --- a/Polygon_repair/examples/Polygon_repair/CMakeLists.txt +++ b/Polygon_repair/examples/Polygon_repair/CMakeLists.txt @@ -18,6 +18,6 @@ endforeach() if(CGAL_Qt6_FOUND) - target_link_libraries(repair_non_zero_polygon_2 PUBLIC CGAL::CGAL_Basic_viewer) - target_link_libraries(repair_union_intersect_2 PUBLIC CGAL::CGAL_Basic_viewer) + target_link_libraries(repair_non_zero_polygon_2 PUBLIC CGAL::CGAL_Basic_viewer_Qt) + target_link_libraries(repair_union_intersect_2 PUBLIC CGAL::CGAL_Basic_viewer_Qt) endif() diff --git a/Polygon_repair/examples/Polygon_repair/repair_non_zero_polygon_2.cpp b/Polygon_repair/examples/Polygon_repair/repair_non_zero_polygon_2.cpp index 3ce04501ab0..d868d68165f 100644 --- a/Polygon_repair/examples/Polygon_repair/repair_non_zero_polygon_2.cpp +++ b/Polygon_repair/examples/Polygon_repair/repair_non_zero_polygon_2.cpp @@ -5,7 +5,7 @@ #include #include #include -#ifdef CGAL_USE_BASIC_VIEWER +#ifdef CGAL_USE_BASIC_VIEWER_QT #include #endif @@ -24,7 +24,7 @@ int main(int argc, char* argv[]) { CGAL::IO::read_polygon_WKT(in, pin); Multipolygon_with_holes_2 mp = CGAL::Polygon_repair::repair(pin, CGAL::Polygon_repair::Non_zero_rule()); -#ifdef CGAL_USE_BASIC_VIEWER +#ifdef CGAL_USE_BASIC_VIEWER_QT CGAL::draw(mp); #endif diff --git a/Polygon_repair/examples/Polygon_repair/repair_union_intersect_2.cpp b/Polygon_repair/examples/Polygon_repair/repair_union_intersect_2.cpp index bec35767d1c..f00da2bd943 100644 --- a/Polygon_repair/examples/Polygon_repair/repair_union_intersect_2.cpp +++ b/Polygon_repair/examples/Polygon_repair/repair_union_intersect_2.cpp @@ -3,7 +3,7 @@ #include #include -#ifdef CGAL_USE_BASIC_VIEWER +#ifdef CGAL_USE_BASIC_VIEWER_QT #include #endif @@ -41,7 +41,7 @@ main(int argc, char* argv[]) { std::ofstream out("union.wkt"); CGAL::IO::write_multi_polygon_WKT(out, mpwh); -#ifdef CGAL_USE_BASIC_VIEWER +#ifdef CGAL_USE_BASIC_VIEWER_QT CGAL::draw(mpwh); #endif } @@ -49,7 +49,7 @@ main(int argc, char* argv[]) { std::ofstream out("intersection.wkt"); CGAL::IO::write_multi_polygon_WKT(out, mpwh); -#ifdef CGAL_USE_BASIC_VIEWER +#ifdef CGAL_USE_BASIC_VIEWER_QT CGAL::draw(mpwh); #endif } @@ -64,7 +64,7 @@ main(int argc, char* argv[]) std::ofstream out("joinn.wkt"); CGAL::IO::write_multi_polygon_WKT(out, mpwh); -#ifdef CGAL_USE_BASIC_VIEWER +#ifdef CGAL_USE_BASIC_VIEWER_QT CGAL::draw(mpwh); #endif } diff --git a/Polygon_repair/test/Polygon_repair/CMakeLists.txt b/Polygon_repair/test/Polygon_repair/CMakeLists.txt index 1ec7a341fc2..796a894bbef 100644 --- a/Polygon_repair/test/Polygon_repair/CMakeLists.txt +++ b/Polygon_repair/test/Polygon_repair/CMakeLists.txt @@ -20,6 +20,6 @@ create_single_source_cgal_program( "exact_test.cpp") create_single_source_cgal_program( "repair_polygon_2_test.cpp" ) if(CGAL_Qt6_FOUND) - target_link_libraries(draw_test_polygons PRIVATE CGAL::CGAL_Basic_viewer) - target_link_libraries(exact_test PRIVATE CGAL::CGAL_Basic_viewer) + target_link_libraries(draw_test_polygons PRIVATE CGAL::CGAL_Basic_viewer_Qt) + target_link_libraries(exact_test PRIVATE CGAL::CGAL_Basic_viewer_Qt) endif() diff --git a/Polyhedron/doc/Polyhedron/CGAL/draw_polyhedron.h b/Polyhedron/doc/Polyhedron/CGAL/draw_polyhedron.h index ea701a78983..3fa6bb748c7 100644 --- a/Polyhedron/doc/Polyhedron/CGAL/draw_polyhedron.h +++ b/Polyhedron/doc/Polyhedron/CGAL/draw_polyhedron.h @@ -5,8 +5,8 @@ namespace CGAL { opens a new window and draws a polyhedron. Parameters of the drawing are taken from the optional graphics scene options parameter. -A call to this function blocks the execution of the program until the drawing window is closed. This function requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER`/`CGAL_USE_BASIC_VIEWER_QT` (Qt viewer) is defined. -Linking with the cmake target `CGAL::CGAL_Basic_viewer`/`CGAL::CGAL_Basic_viewer_Qt` will link with `CGAL_Qt6` and add the definition `CGAL_USE_BASIC_VIEWER`/`CGAL_USE_BASIC_VIEWER_QT`. +A call to this function blocks the execution of the program until the drawing window is closed. This function requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER_QT` (Qt viewer) is defined. +Linking with the cmake target `CGAL::CGAL_Basic_viewer_Qt` will link with `CGAL_Qt6` and add the definition `CGAL_USE_BASIC_VIEWER_QT`. \tparam P which must be an instantiation of a `CGAL::Polyhedron_3<...>`. \tparam GSOptions a model of `GraphicsSceneOptions` concept. diff --git a/Polyhedron/doc/Polyhedron/Polyhedron.txt b/Polyhedron/doc/Polyhedron/Polyhedron.txt index 9e7ac47116e..b73357916f5 100644 --- a/Polyhedron/doc/Polyhedron/Polyhedron.txt +++ b/Polyhedron/doc/Polyhedron/Polyhedron.txt @@ -284,8 +284,8 @@ A polyhedron can be visualized by calling the \link PkgDrawPolyhedron CGAL::draw \cgalExample{Polyhedron/draw_polyhedron.cpp} -This function requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER` is defined. -Linking with the cmake target `CGAL::CGAL_Basic_viewer` will link with `CGAL_Qt6` and add the definition `CGAL_USE_BASIC_VIEWER`. +This function requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER_QT` is defined. +Linking with the cmake target `CGAL::CGAL_Basic_viewer_Qt` will link with `CGAL_Qt6` and add the definition `CGAL_USE_BASIC_VIEWER_QT`. \cgalFigureBegin{fig_draw_polyhedron,draw_polyhedron.png} Result of the run of the draw_polyhedron program. A window shows the polyhedron and allows to navigate through the 3D scene. diff --git a/Polyhedron/examples/Polyhedron/CMakeLists.txt b/Polyhedron/examples/Polyhedron/CMakeLists.txt index aa94d1a604a..cbe2dab0363 100644 --- a/Polyhedron/examples/Polyhedron/CMakeLists.txt +++ b/Polyhedron/examples/Polyhedron/CMakeLists.txt @@ -16,5 +16,5 @@ foreach(cppfile ${cppfiles}) endforeach() if(CGAL_Qt6_FOUND) - target_link_libraries(draw_polyhedron PRIVATE CGAL::CGAL_Basic_viewer) + target_link_libraries(draw_polyhedron PRIVATE CGAL::CGAL_Basic_viewer_Qt) endif() diff --git a/Straight_skeleton_2/examples/Straight_skeleton_2/CMakeLists.txt b/Straight_skeleton_2/examples/Straight_skeleton_2/CMakeLists.txt index 5ddeeabc56c..fdada16b1bf 100644 --- a/Straight_skeleton_2/examples/Straight_skeleton_2/CMakeLists.txt +++ b/Straight_skeleton_2/examples/Straight_skeleton_2/CMakeLists.txt @@ -15,12 +15,12 @@ foreach(cppfile ${cppfiles}) endforeach() if(CGAL_Qt6_FOUND) - target_link_libraries(draw_straight_skeleton_2 PRIVATE CGAL::CGAL_Basic_viewer) - target_link_libraries(exterior_offset_of_multiple_polygons_with_holes PRIVATE CGAL::CGAL_Basic_viewer) - target_link_libraries(Create_straight_skeleton_2 PRIVATE CGAL::CGAL_Basic_viewer) - target_link_libraries(Show_offset_polygon PRIVATE CGAL::CGAL_Basic_viewer) - target_link_libraries(Show_straight_skeleton PRIVATE CGAL::CGAL_Basic_viewer) - target_link_libraries(extrude_skeleton PRIVATE CGAL::CGAL_Basic_viewer) + target_link_libraries(draw_straight_skeleton_2 PRIVATE CGAL::CGAL_Basic_viewer_Qt) + target_link_libraries(exterior_offset_of_multiple_polygons_with_holes PRIVATE CGAL::CGAL_Basic_viewer_Qt) + target_link_libraries(Create_straight_skeleton_2 PRIVATE CGAL::CGAL_Basic_viewer_Qt) + target_link_libraries(Show_offset_polygon PRIVATE CGAL::CGAL_Basic_viewer_Qt) + target_link_libraries(Show_straight_skeleton PRIVATE CGAL::CGAL_Basic_viewer_Qt) + target_link_libraries(extrude_skeleton PRIVATE CGAL::CGAL_Basic_viewer_Qt) else() message(STATUS "NOTICE: The example 'draw_straight_skeleton_2' requires Qt and will not be compiled.") endif() diff --git a/Straight_skeleton_2/test/Straight_skeleton_2/CMakeLists.txt b/Straight_skeleton_2/test/Straight_skeleton_2/CMakeLists.txt index e08dcd859b2..d2c98e446f2 100644 --- a/Straight_skeleton_2/test/Straight_skeleton_2/CMakeLists.txt +++ b/Straight_skeleton_2/test/Straight_skeleton_2/CMakeLists.txt @@ -17,8 +17,8 @@ create_single_source_cgal_program("test_sls_traits.cpp") create_single_source_cgal_program("test_straight_skeleton_copy.cpp") if(CGAL_Qt6_FOUND) - target_link_libraries(issue4684 PRIVATE CGAL::CGAL_Basic_viewer) - target_link_libraries(test_sls_previous_issues PRIVATE CGAL::CGAL_Basic_viewer) + target_link_libraries(issue4684 PRIVATE CGAL::CGAL_Basic_viewer_Qt) + target_link_libraries(test_sls_previous_issues PRIVATE CGAL::CGAL_Basic_viewer_Qt) endif() if (CGAL_Core_FOUND OR LEDA_FOUND) @@ -30,11 +30,11 @@ if (CGAL_Core_FOUND OR LEDA_FOUND) create_single_source_cgal_program("test_sls_weighted_polygons.cpp") create_single_source_cgal_program("test_sls_weighted_polygons_with_holes.cpp") if(CGAL_Qt6_FOUND) - target_link_libraries(issue7149 PRIVATE CGAL::CGAL_Basic_viewer) - target_link_libraries(issue7284 PRIVATE CGAL::CGAL_Basic_viewer) - target_link_libraries(test_sls_offset PRIVATE CGAL::CGAL_Basic_viewer) - target_link_libraries(test_sls_weighted_offset PRIVATE CGAL::CGAL_Basic_viewer) - target_link_libraries(test_sls_weighted_polygons PRIVATE CGAL::CGAL_Basic_viewer) - target_link_libraries(test_sls_weighted_polygons_with_holes PRIVATE CGAL::CGAL_Basic_viewer) + target_link_libraries(issue7149 PRIVATE CGAL::CGAL_Basic_viewer_Qt) + target_link_libraries(issue7284 PRIVATE CGAL::CGAL_Basic_viewer_Qt) + target_link_libraries(test_sls_offset PRIVATE CGAL::CGAL_Basic_viewer_Qt) + target_link_libraries(test_sls_weighted_offset PRIVATE CGAL::CGAL_Basic_viewer_Qt) + target_link_libraries(test_sls_weighted_polygons PRIVATE CGAL::CGAL_Basic_viewer_Qt) + target_link_libraries(test_sls_weighted_polygons_with_holes PRIVATE CGAL::CGAL_Basic_viewer_Qt) endif() endif() diff --git a/Straight_skeleton_extrusion_2/test/Straight_skeleton_extrusion_2/CMakeLists.txt b/Straight_skeleton_extrusion_2/test/Straight_skeleton_extrusion_2/CMakeLists.txt index ff03f42493d..d6408e4a892 100644 --- a/Straight_skeleton_extrusion_2/test/Straight_skeleton_extrusion_2/CMakeLists.txt +++ b/Straight_skeleton_extrusion_2/test/Straight_skeleton_extrusion_2/CMakeLists.txt @@ -12,7 +12,7 @@ include_directories(BEFORE "include") if (CGAL_Core_FOUND OR LEDA_FOUND) create_single_source_cgal_program("test_sls_extrude.cpp") if(CGAL_Qt6_FOUND) - target_link_libraries(test_sls_extrude PRIVATE CGAL::CGAL_Basic_viewer) + target_link_libraries(test_sls_extrude PRIVATE CGAL::CGAL_Basic_viewer_Qt) endif() else() message("NOTICE: Tests require CGAL_Core (or LEDA), and will not be compiled.") diff --git a/Surface_mesh/doc/Surface_mesh/Surface_mesh.txt b/Surface_mesh/doc/Surface_mesh/Surface_mesh.txt index 670449c2ee6..f9d41b8ab02 100644 --- a/Surface_mesh/doc/Surface_mesh/Surface_mesh.txt +++ b/Surface_mesh/doc/Surface_mesh/Surface_mesh.txt @@ -388,8 +388,8 @@ A surface mesh can be visualized by calling the \link PkgDrawSurfaceMesh CGAL::d \cgalExample{Surface_mesh/draw_surface_mesh.cpp} -This function requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER` is defined. -Linking with the cmake target `CGAL::CGAL_Basic_viewer` will link with `CGAL_Qt6` and add the definition `CGAL_USE_BASIC_VIEWER`. +This function requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER_QT` is defined. +Linking with the cmake target `CGAL::CGAL_Basic_viewer_Qt` will link with `CGAL_Qt6` and add the definition `CGAL_USE_BASIC_VIEWER_QT`. \cgalFigureBegin{fig_draw_surface_mesh,draw_surface_mesh.png} Result of the run of the draw_surface_mesh program. A window shows the surface mesh and allows to navigate through the 3D scene. diff --git a/Surface_mesh/examples/Surface_mesh/CMakeLists.txt b/Surface_mesh/examples/Surface_mesh/CMakeLists.txt index bae80a7b2c2..b3feea3541e 100644 --- a/Surface_mesh/examples/Surface_mesh/CMakeLists.txt +++ b/Surface_mesh/examples/Surface_mesh/CMakeLists.txt @@ -30,7 +30,7 @@ create_single_source_cgal_program("draw_surface_mesh.cpp") if(CGAL_Qt6_FOUND) #link it with the required CGAL libraries - target_link_libraries(draw_surface_mesh PRIVATE CGAL::CGAL_Basic_viewer) + target_link_libraries(draw_surface_mesh PRIVATE CGAL::CGAL_Basic_viewer_Qt) endif() diff --git a/Surface_mesh/include/CGAL/draw_surface_mesh.h b/Surface_mesh/include/CGAL/draw_surface_mesh.h index fdddb8b7dc0..569941b769e 100644 --- a/Surface_mesh/include/CGAL/draw_surface_mesh.h +++ b/Surface_mesh/include/CGAL/draw_surface_mesh.h @@ -20,8 +20,8 @@ opens a new window and draws a surface mesh. Parameters of the drawing are taken from the optional graphics scene options parameter. -A call to this function blocks the execution of the program until the drawing window is closed. This function requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER`/`CGAL_USE_BASIC_VIEWER_QT` (Qt viewer) is defined. -Linking with the cmake target `CGAL::CGAL_Basic_viewer`/`CGAL::CGAL_Basic_viewer_Qt` will link with `CGAL_Qt6` and add the definition `CGAL_USE_BASIC_VIEWER`/`CGAL_USE_BASIC_VIEWER_QT`. +A call to this function blocks the execution of the program until the drawing window is closed. This function requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER_QT` (Qt viewer) is defined. +Linking with the cmake target `CGAL::CGAL_Basic_viewer_Qt` will link with `CGAL_Qt6` and add the definition `CGAL_USE_BASIC_VIEWER_QT`. \tparam SM which must be an instantiation of a `CGAL::Surface_mesh<...>`. \tparam GSOptions a model of `GraphicsSceneOptions` concept. diff --git a/Surface_mesh_topology/doc/Surface_mesh_topology/CGAL/draw_face_graph_with_paths.h b/Surface_mesh_topology/doc/Surface_mesh_topology/CGAL/draw_face_graph_with_paths.h index dc764f93211..953e19f5651 100644 --- a/Surface_mesh_topology/doc/Surface_mesh_topology/CGAL/draw_face_graph_with_paths.h +++ b/Surface_mesh_topology/doc/Surface_mesh_topology/CGAL/draw_face_graph_with_paths.h @@ -5,8 +5,8 @@ namespace CGAL { opens a new window and draws `amesh`, either a 2D linear cell complex or a model of the FaceGraph concept, plus the paths lying on this mesh given in `apaths`. Parameters of the drawing are taken from the optional graphics scene options parameter. -A call to this function blocks the execution of the program until the drawing window is closed. This function requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER`/`CGAL_USE_BASIC_VIEWER_QT` (Qt viewer) is defined. -Linking with the cmake target `CGAL::CGAL_Basic_viewer`/`CGAL::CGAL_Basic_viewer_Qt` will link with `CGAL_Qt6` and add the definition `CGAL_USE_BASIC_VIEWER`/`CGAL_USE_BASIC_VIEWER_QT`. +A call to this function blocks the execution of the program until the drawing window is closed. This function requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER_QT` (Qt viewer) is defined. +Linking with the cmake target `CGAL::CGAL_Basic_viewer_Qt` will link with `CGAL_Qt6` and add the definition `CGAL_USE_BASIC_VIEWER_QT`. \tparam Mesh either a 2D linear cell complex or a model of the FaceGraph concept. \tparam GSOptions a model of `GraphicsSceneOptionsFaceGraphWithPaths` concept. diff --git a/Surface_mesh_topology/examples/Surface_mesh_topology/CMakeLists.txt b/Surface_mesh_topology/examples/Surface_mesh_topology/CMakeLists.txt index b528c238d49..73b4e94b353 100644 --- a/Surface_mesh_topology/examples/Surface_mesh_topology/CMakeLists.txt +++ b/Surface_mesh_topology/examples/Surface_mesh_topology/CMakeLists.txt @@ -32,17 +32,17 @@ foreach(cppfile ${SOURCE_FILES}) endforeach() if(CGAL_Qt6_FOUND) - target_link_libraries(edgewidth_lcc PRIVATE CGAL::CGAL_Basic_viewer) - target_link_libraries(edgewidth_surface_mesh PRIVATE CGAL::CGAL_Basic_viewer) - target_link_libraries(facewidth PRIVATE CGAL::CGAL_Basic_viewer) - target_link_libraries(open_path_homotopy PRIVATE CGAL::CGAL_Basic_viewer) - target_link_libraries(path_homotopy PRIVATE CGAL::CGAL_Basic_viewer) - target_link_libraries(path_homotopy_double_torus PRIVATE CGAL::CGAL_Basic_viewer) - target_link_libraries(path_homotopy_torus PRIVATE CGAL::CGAL_Basic_viewer) - target_link_libraries(path_homotopy_with_sm_and_polyhedron PRIVATE CGAL::CGAL_Basic_viewer) - target_link_libraries(path_simplicity_double_torus PRIVATE CGAL::CGAL_Basic_viewer) - target_link_libraries(path_simplicity_double_torus_2 PRIVATE CGAL::CGAL_Basic_viewer) - target_link_libraries(shortest_noncontractible_cycle_2 PRIVATE CGAL::CGAL_Basic_viewer) - target_link_libraries(shortest_noncontractible_cycle PRIVATE CGAL::CGAL_Basic_viewer) - target_link_libraries(unsew_edgewidth_repeatedly PRIVATE CGAL::CGAL_Basic_viewer) + target_link_libraries(edgewidth_lcc PRIVATE CGAL::CGAL_Basic_viewer_Qt) + target_link_libraries(edgewidth_surface_mesh PRIVATE CGAL::CGAL_Basic_viewer_Qt) + target_link_libraries(facewidth PRIVATE CGAL::CGAL_Basic_viewer_Qt) + target_link_libraries(open_path_homotopy PRIVATE CGAL::CGAL_Basic_viewer_Qt) + target_link_libraries(path_homotopy PRIVATE CGAL::CGAL_Basic_viewer_Qt) + target_link_libraries(path_homotopy_double_torus PRIVATE CGAL::CGAL_Basic_viewer_Qt) + target_link_libraries(path_homotopy_torus PRIVATE CGAL::CGAL_Basic_viewer_Qt) + target_link_libraries(path_homotopy_with_sm_and_polyhedron PRIVATE CGAL::CGAL_Basic_viewer_Qt) + target_link_libraries(path_simplicity_double_torus PRIVATE CGAL::CGAL_Basic_viewer_Qt) + target_link_libraries(path_simplicity_double_torus_2 PRIVATE CGAL::CGAL_Basic_viewer_Qt) + target_link_libraries(shortest_noncontractible_cycle_2 PRIVATE CGAL::CGAL_Basic_viewer_Qt) + target_link_libraries(shortest_noncontractible_cycle PRIVATE CGAL::CGAL_Basic_viewer_Qt) + target_link_libraries(unsew_edgewidth_repeatedly PRIVATE CGAL::CGAL_Basic_viewer_Qt) endif() diff --git a/Surface_mesh_topology/examples/Surface_mesh_topology/facewidth.cpp b/Surface_mesh_topology/examples/Surface_mesh_topology/facewidth.cpp index 1ac14f92fda..4881a304c59 100644 --- a/Surface_mesh_topology/examples/Surface_mesh_topology/facewidth.cpp +++ b/Surface_mesh_topology/examples/Surface_mesh_topology/facewidth.cpp @@ -33,7 +33,7 @@ int main(int argc, char* argv[]) { std::cout<<" Number of faces: "<=3 && std::string(argv[2])=="-draw") { draw_facewidth(lcc, cycle); } #endif diff --git a/Surface_mesh_topology/examples/Surface_mesh_topology/path_homotopy.cpp b/Surface_mesh_topology/examples/Surface_mesh_topology/path_homotopy.cpp index def33c86cf6..1c0e62fc625 100644 --- a/Surface_mesh_topology/examples/Surface_mesh_topology/path_homotopy.cpp +++ b/Surface_mesh_topology/examples/Surface_mesh_topology/path_homotopy.cpp @@ -4,7 +4,7 @@ #include /* If you want to use a viewer, you can use qglviewer. */ -#ifdef CGAL_USE_BASIC_VIEWER +#ifdef CGAL_USE_BASIC_VIEWER_QT #include #endif @@ -167,7 +167,7 @@ int main(int argc, char** argv) if (!res) { errors_seeds.push_back(random.get_seed()); } -#ifdef CGAL_USE_BASIC_VIEWER +#ifdef CGAL_USE_BASIC_VIEWER_QT if (draw) { CGAL::draw(lcc, paths); } #endif diff --git a/Surface_mesh_topology/examples/Surface_mesh_topology/unsew_edgewidth_repeatedly.cpp b/Surface_mesh_topology/examples/Surface_mesh_topology/unsew_edgewidth_repeatedly.cpp index 441d41bd45c..b0730077818 100644 --- a/Surface_mesh_topology/examples/Surface_mesh_topology/unsew_edgewidth_repeatedly.cpp +++ b/Surface_mesh_topology/examples/Surface_mesh_topology/unsew_edgewidth_repeatedly.cpp @@ -32,7 +32,7 @@ private: const LCC_3& m_lcc; }; -#ifdef CGAL_USE_BASIC_VIEWER +#ifdef CGAL_USE_BASIC_VIEWER_QT struct Draw_functor: public CGAL::Graphics_scene_options // If you want to use a viewer, you can use qglviewer. -#ifdef CGAL_USE_BASIC_VIEWER +#ifdef CGAL_USE_BASIC_VIEWER_QT #include #endif @@ -76,11 +76,11 @@ void create_positive_loop_24(Path_on_surface& p, unsigned int n) { p.extend_straight_positive((10*n)-1); -#ifdef CGAL_USE_BASIC_VIEWER +#ifdef CGAL_USE_BASIC_VIEWER_QT /* std::vector > v; v.push_back(p); CGAL::draw(p.get_mesh(), v, "Title"); */ -#endif // CGAL_USE_BASIC_VIEWER +#endif // CGAL_USE_BASIC_VIEWER_QT assert(p.is_closed()); } diff --git a/Surface_mesh_topology/test/Surface_mesh_topology/fundamental_group_of_the_torus.cpp b/Surface_mesh_topology/test/Surface_mesh_topology/fundamental_group_of_the_torus.cpp index 799198f5c0c..548d70d6d2a 100644 --- a/Surface_mesh_topology/test/Surface_mesh_topology/fundamental_group_of_the_torus.cpp +++ b/Surface_mesh_topology/test/Surface_mesh_topology/fundamental_group_of_the_torus.cpp @@ -119,10 +119,10 @@ int main() bool cij, ckl, hij_ij, hij_kl, hkl_ij, hkl_kl; bool test_valid=true; /* -#ifdef CGAL_USE_BASIC_VIEWER +#ifdef CGAL_USE_BASIC_VIEWER_QT std::vector > paths={pij, pkl}; CGAL::draw(sm, paths); // Enable only if CGAL was compiled with Qt6 -#endif // CGAL_USE_BASIC_VIEWER +#endif // CGAL_USE_BASIC_VIEWER_QT */ for (int i=-4; i<=4; ++i) { diff --git a/Surface_mesh_topology/test/Surface_mesh_topology/path_with_rle_deformation_tests.cpp b/Surface_mesh_topology/test/Surface_mesh_topology/path_with_rle_deformation_tests.cpp index 4eed5e7ea8e..e601cd924e1 100644 --- a/Surface_mesh_topology/test/Surface_mesh_topology/path_with_rle_deformation_tests.cpp +++ b/Surface_mesh_topology/test/Surface_mesh_topology/path_with_rle_deformation_tests.cpp @@ -11,7 +11,7 @@ #include "Creation_of_test_cases_for_paths.h" // If you want to use a viewer, you can use qglviewer. -#ifdef CGAL_USE_BASIC_VIEWER +#ifdef CGAL_USE_BASIC_VIEWER_QT #include #endif @@ -53,21 +53,21 @@ void transform_path(Path_on_surface& path, Transformation t, bool use_only_positive, bool use_only_negative, bool -#ifdef CGAL_USE_BASIC_VIEWER +#ifdef CGAL_USE_BASIC_VIEWER_QT draw #endif =false, std::size_t repeat=0) // If 0, repeat as long as there is one modification; // otherwise repeat the given number of times { -#ifdef CGAL_USE_BASIC_VIEWER +#ifdef CGAL_USE_BASIC_VIEWER_QT std::vector > v; if (draw) { v.push_back(path); // CGAL::draw(path.get_map(), v); } -#endif // CGAL_USE_BASIC_VIEWER +#endif // CGAL_USE_BASIC_VIEWER_QT internal::Light_MQ lmq(path.get_map()); Path_on_surface prepp(path.get_map()); @@ -100,9 +100,9 @@ void transform_path(Path_on_surface& path, Transformation t, if (modified) { prevp=Path_on_surface(curp); -#ifdef CGAL_USE_BASIC_VIEWER +#ifdef CGAL_USE_BASIC_VIEWER_QT if (draw) { v.push_back(prevp); } -#endif // CGAL_USE_BASIC_VIEWER +#endif // CGAL_USE_BASIC_VIEWER_QT } // if (draw /* && nbtest==1*/) @@ -112,13 +112,13 @@ void transform_path(Path_on_surface& path, Transformation t, } while((repeat==0 && modified) || (nb #endif @@ -44,7 +44,7 @@ bool unit_test_canonize(Curves_on_surface_topology& cst, std::vector >& paths, const char* msg, bool -#ifdef CGAL_USE_BASIC_VIEWER +#ifdef CGAL_USE_BASIC_VIEWER_QT draw #endif , int testtorun) @@ -70,13 +70,13 @@ bool unit_test_canonize(Curves_on_surface_topology& cst, } } -#ifdef CGAL_USE_BASIC_VIEWER +#ifdef CGAL_USE_BASIC_VIEWER_QT if (draw) { std::string title="Test "+std::to_string(nbtests); CGAL::draw(paths[0].get_map(), paths, title.c_str()); } -#endif // CGAL_USE_BASIC_VIEWER +#endif // CGAL_USE_BASIC_VIEWER_QT #ifdef CGAL_TRACE_PATH_TESTS if (res) { std::cout<`. \tparam GSOptions a model of `GraphicsSceneOptions` concept. diff --git a/Triangulation_2/doc/Triangulation_2/Triangulation_2.txt b/Triangulation_2/doc/Triangulation_2/Triangulation_2.txt index 1fa311710e0..220bc6730bb 100644 --- a/Triangulation_2/doc/Triangulation_2/Triangulation_2.txt +++ b/Triangulation_2/doc/Triangulation_2/Triangulation_2.txt @@ -509,8 +509,8 @@ A 2D triangulation can be visualized by calling the \link PkgDrawTriangulation2 \cgalExample{Triangulation_2/draw_triangulation_2.cpp} -This function requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER` is defined. -Linking with the cmake target `CGAL::CGAL_Basic_viewer` will link with `CGAL_Qt6` and add the definition `CGAL_USE_BASIC_VIEWER`. +This function requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER_QT` is defined. +Linking with the cmake target `CGAL::CGAL_Basic_viewer_Qt` will link with `CGAL_Qt6` and add the definition `CGAL_USE_BASIC_VIEWER_QT`. \cgalFigureBegin{fig_draw_triangulation_2,draw_triangulation_2.png} Result of the run of the draw_triangulation_2 program. A window shows the 2D triangulation and allows to navigate through the scene. diff --git a/Triangulation_2/examples/Triangulation_2/CMakeLists.txt b/Triangulation_2/examples/Triangulation_2/CMakeLists.txt index 22051dcdf3c..8176c0da09e 100644 --- a/Triangulation_2/examples/Triangulation_2/CMakeLists.txt +++ b/Triangulation_2/examples/Triangulation_2/CMakeLists.txt @@ -16,10 +16,10 @@ foreach(cppfile ${cppfiles}) endforeach() if(CGAL_Qt6_FOUND) - target_link_libraries(constrained PRIVATE CGAL::CGAL_Basic_viewer) - target_link_libraries(draw_triangulation_2 PRIVATE CGAL::CGAL_Basic_viewer) - target_link_libraries(polygon_triangulation PRIVATE CGAL::CGAL_Basic_viewer) - target_link_libraries(star_conflict_zone PRIVATE CGAL::CGAL_Basic_viewer) + target_link_libraries(constrained PRIVATE CGAL::CGAL_Basic_viewer_Qt) + target_link_libraries(draw_triangulation_2 PRIVATE CGAL::CGAL_Basic_viewer_Qt) + target_link_libraries(polygon_triangulation PRIVATE CGAL::CGAL_Basic_viewer_Qt) + target_link_libraries(star_conflict_zone PRIVATE CGAL::CGAL_Basic_viewer_Qt) else() message(STATUS "NOTICE: Several examples require Qt6 and will not be compiled.") endif() diff --git a/Triangulation_3/doc/Triangulation_3/CGAL/draw_triangulation_3.h b/Triangulation_3/doc/Triangulation_3/CGAL/draw_triangulation_3.h index 192ee8de4f1..c6e9bd17c69 100644 --- a/Triangulation_3/doc/Triangulation_3/CGAL/draw_triangulation_3.h +++ b/Triangulation_3/doc/Triangulation_3/CGAL/draw_triangulation_3.h @@ -5,8 +5,8 @@ namespace CGAL { opens a new window and draws a 3D triangulation. Parameters of the drawing are taken from the optional graphics scene options parameter. -A call to this function blocks the execution of the program until the drawing window is closed. This function requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER`/`CGAL_USE_BASIC_VIEWER_QT` (Qt viewer) is defined. -Linking with the cmake target `CGAL::CGAL_Basic_viewer`/`CGAL::CGAL_Basic_viewer_Qt` will link with `CGAL_Qt6` and add the definition `CGAL_USE_BASIC_VIEWER`/`CGAL_USE_BASIC_VIEWER_QT`. +A call to this function blocks the execution of the program until the drawing window is closed. This function requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER_QT` (Qt viewer) is defined. +Linking with the cmake target `CGAL::CGAL_Basic_viewer_Qt` will link with `CGAL_Qt6` and add the definition `CGAL_USE_BASIC_VIEWER_QT`. \tparam T3 which must be an instantiation of a `CGAL::Triangulation_3<...>`. \tparam GSOptions a model of `GraphicsSceneOptions` concept. diff --git a/Triangulation_3/doc/Triangulation_3/Triangulation_3.txt b/Triangulation_3/doc/Triangulation_3/Triangulation_3.txt index 0e555a26767..adbc40c9296 100644 --- a/Triangulation_3/doc/Triangulation_3/Triangulation_3.txt +++ b/Triangulation_3/doc/Triangulation_3/Triangulation_3.txt @@ -569,8 +569,8 @@ A 3D triangulation can be visualized by calling the \link PkgDrawTriangulation3 \cgalExample{Triangulation_3/draw_triangulation_3.cpp} -This function requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER` is defined. -Linking with the cmake target `CGAL::CGAL_Basic_viewer` will link with `CGAL_Qt6` and add the definition `CGAL_USE_BASIC_VIEWER`. +This function requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER_QT` is defined. +Linking with the cmake target `CGAL::CGAL_Basic_viewer_Qt` will link with `CGAL_Qt6` and add the definition `CGAL_USE_BASIC_VIEWER_QT`. \cgalFigureBegin{fig_draw_triangulation_3,draw_triangulation_3.png} Result of the run of the draw_triangulation_3 program. A window shows the 3D triangulation and allows to navigate through the 3D scene. diff --git a/Triangulation_3/examples/Triangulation_3/CMakeLists.txt b/Triangulation_3/examples/Triangulation_3/CMakeLists.txt index 2a9989ce852..e67d84d02df 100644 --- a/Triangulation_3/examples/Triangulation_3/CMakeLists.txt +++ b/Triangulation_3/examples/Triangulation_3/CMakeLists.txt @@ -22,7 +22,7 @@ create_single_source_cgal_program("simplex.cpp") create_single_source_cgal_program("draw_triangulation_3.cpp") if(CGAL_Qt6_FOUND) - target_link_libraries(draw_triangulation_3 PRIVATE CGAL::CGAL_Basic_viewer) + target_link_libraries(draw_triangulation_3 PRIVATE CGAL::CGAL_Basic_viewer_Qt) else() message(STATUS "NOTICE: The example 'draw_triangulation_3' requires Qt6, and will not be compiled.") endif() diff --git a/Voronoi_diagram_2/doc/Voronoi_diagram_2/CGAL/draw_voronoi_diagram_2.h b/Voronoi_diagram_2/doc/Voronoi_diagram_2/CGAL/draw_voronoi_diagram_2.h index 6ef047520ec..b4da9a8b1f8 100644 --- a/Voronoi_diagram_2/doc/Voronoi_diagram_2/CGAL/draw_voronoi_diagram_2.h +++ b/Voronoi_diagram_2/doc/Voronoi_diagram_2/CGAL/draw_voronoi_diagram_2.h @@ -27,8 +27,8 @@ struct Graphics_scene_options_voronoi_diagram_2: public CGAL::Graphics_scene_opt opens a new window and draws a 2D voronoi diagram. Parameters of the drawing are taken from the optional graphics scene options parameter. -A call to this function blocks the execution of the program until the drawing window is closed. This function requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER`/`CGAL_USE_BASIC_VIEWER_QT` (Qt viewer) is defined. -Linking with the cmake target `CGAL::CGAL_Basic_viewer`/`CGAL::CGAL_Basic_viewer_Qt` will link with `CGAL_Qt6` and add the definition `CGAL_USE_BASIC_VIEWER`/`CGAL_USE_BASIC_VIEWER_QT`. +A call to this function blocks the execution of the program until the drawing window is closed. This function requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER_QT` (Qt viewer) is defined. +Linking with the cmake target `CGAL::CGAL_Basic_viewer_Qt` will link with `CGAL_Qt6` and add the definition `CGAL_USE_BASIC_VIEWER_QT`. \tparam VD2 which must be an instantiation of a `CGAL::Voronoi_diagram_2<...>`. \tparam GSOptions a model of `GraphicsSceneOptionsVoronoiDiagram2` concept. diff --git a/Voronoi_diagram_2/doc/Voronoi_diagram_2/Voronoi_diagram_2.txt b/Voronoi_diagram_2/doc/Voronoi_diagram_2/Voronoi_diagram_2.txt index 36676947fff..1fe18e04a62 100644 --- a/Voronoi_diagram_2/doc/Voronoi_diagram_2/Voronoi_diagram_2.txt +++ b/Voronoi_diagram_2/doc/Voronoi_diagram_2/Voronoi_diagram_2.txt @@ -493,8 +493,8 @@ location queries. A 2D Voronoi Diagram can be visualized by calling the \link PkgDrawVoronoiDiagram2 CGAL::draw() \endlink function as shown in the following example. This function opens a new window showing the Voronoi Diagram of the given input sites/vertex locations. A call to this function is blocking, that is the program continues as soon as the user closes the window. -This function requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER` is defined. -Linking with the cmake target `CGAL::CGAL_Basic_viewer` will link with `CGAL_Qt6` and add the definition `CGAL_USE_BASIC_VIEWER`. +This function requires `CGAL_Qt6`, and is only available if the macro `CGAL_USE_BASIC_VIEWER_QT` is defined. +Linking with the cmake target `CGAL::CGAL_Basic_viewer_Qt` will link with `CGAL_Qt6` and add the definition `CGAL_USE_BASIC_VIEWER_QT`. \cgalExample{Voronoi_diagram_2/draw_voronoi_diagram_2.cpp} diff --git a/Voronoi_diagram_2/examples/Voronoi_diagram_2/CMakeLists.txt b/Voronoi_diagram_2/examples/Voronoi_diagram_2/CMakeLists.txt index f7e5cdd4475..b0fba03e202 100644 --- a/Voronoi_diagram_2/examples/Voronoi_diagram_2/CMakeLists.txt +++ b/Voronoi_diagram_2/examples/Voronoi_diagram_2/CMakeLists.txt @@ -16,7 +16,7 @@ foreach(cppfile ${cppfiles}) endforeach() if(CGAL_Qt6_FOUND) - target_link_libraries(draw_voronoi_diagram_2 PRIVATE CGAL::CGAL_Basic_viewer) + target_link_libraries(draw_voronoi_diagram_2 PRIVATE CGAL::CGAL_Basic_viewer_Qt) else() message(STATUS "NOTICE: The Qt6 library was not found. The example 'draw_voronoi_diagram_2' will not be compiled.") endif() diff --git a/Voronoi_diagram_2/include/CGAL/draw_voronoi_diagram_2.h b/Voronoi_diagram_2/include/CGAL/draw_voronoi_diagram_2.h index deb38a94de8..a49594feecc 100644 --- a/Voronoi_diagram_2/include/CGAL/draw_voronoi_diagram_2.h +++ b/Voronoi_diagram_2/include/CGAL/draw_voronoi_diagram_2.h @@ -371,7 +371,7 @@ void add_to_graphics_scene(const CGAL_VORONOI_TYPE& v2, add_to_graphics_scene(v2, graphics_scene, gs_options); } -#if defined(CGAL_USE_BASIC_VIEWER) || defined(CGAL_USE_BASIC_VIEWER_QT) +#if defined(CGAL_USE_BASIC_VIEWER_QT) // Specialization of draw function. template @@ -449,7 +449,7 @@ void draw(const CGAL_VORONOI_TYPE& av2, draw(av2, gs_options, title); } -#endif // CGAL_USE_BASIC_VIEWER || CGAL_USE_BASIC_VIEWER_QT +#endif // CGAL_USE_BASIC_VIEWER_QT #undef CGAL_VORONOI_TYPE