diff --git a/CMakeLists.txt b/CMakeLists.txt index 177a0db..11ff7ad 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -30,6 +30,7 @@ file(MAKE_DIRECTORY "${DOXYGEN_BUILD_DIR_CMAKE}/html") # copy files to build directory file(COPY "${CMAKE_CURRENT_SOURCE_DIR}/doxyconfig-header.html" DESTINATION "${SOURCE_DOCS_DIR}") file(COPY "${CMAKE_CURRENT_SOURCE_DIR}/doxyconfig-Doxyfile" DESTINATION "${SOURCE_DOCS_DIR}") +file(COPY "${CMAKE_CURRENT_SOURCE_DIR}/doxyconfig-icons.js" DESTINATION "${SOURCE_DOCS_DIR}") file(COPY "${CMAKE_CURRENT_SOURCE_DIR}/doxyconfig.css" DESTINATION "${SOURCE_DOCS_DIR}") file(COPY "${CMAKE_CURRENT_SOURCE_DIR}/doxyconfig-readthedocs-search.js" DESTINATION "${SOURCE_DOCS_DIR}") @@ -62,17 +63,15 @@ set(SHARED_WEB_FILES_DEPENDS "${CMAKE_CURRENT_SOURCE_DIR}/node_modules/@lizardbyte/shared-web/dist/crowdin-doxygen-css.css" ) -# set FONT_AWESOME_FILES depends -set(FONT_AWESOME_FILES_DEPENDS - "${CMAKE_CURRENT_SOURCE_DIR}/node_modules/@fortawesome/fontawesome-free/css/all.min.css" - "${CMAKE_CURRENT_SOURCE_DIR}/node_modules/@fortawesome/fontawesome-free/js/all.min.js" - "${CMAKE_CURRENT_SOURCE_DIR}/node_modules/@fortawesome/fontawesome-free/webfonts/" +# set LUCIDE_FILES depends +set(LUCIDE_FILES_DEPENDS + "${CMAKE_CURRENT_SOURCE_DIR}/node_modules/lucide/dist/umd/lucide.min.js" ) find_program(NPM npm REQUIRED) add_custom_target(_docs_npm_install COMMENT "Installing node modules" - BYPRODUCTS ${SHARED_WEB_FILES_DEPENDS} ${FONT_AWESOME_FILES_DEPENDS} + BYPRODUCTS ${SHARED_WEB_FILES_DEPENDS} ${LUCIDE_FILES_DEPENDS} COMMAND ${NPM} ci --ignore-scripts WORKING_DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}" VERBATIM @@ -91,20 +90,16 @@ add_custom_command( DEPENDS ${SHARED_WEB_FILES_DEPENDS} ) -# copy Font Awesome files +# copy Lucide files add_custom_command( - OUTPUT FONT_AWESOME_FILES + OUTPUT LUCIDE_FILES COMMAND ${CMAKE_COMMAND} - -E copy ${CMAKE_CURRENT_SOURCE_DIR}/node_modules/@fortawesome/fontawesome-free/css/all.min.css - ${DOXYGEN_BUILD_DIR_CMAKE}/html/assets/fontawesome/css/all.min.css + -E make_directory ${DOXYGEN_BUILD_DIR_CMAKE}/html/assets/lucide COMMAND ${CMAKE_COMMAND} - -E copy ${CMAKE_CURRENT_SOURCE_DIR}/node_modules/@fortawesome/fontawesome-free/js/all.min.js - ${DOXYGEN_BUILD_DIR_CMAKE}/html/assets/fontawesome/js/all.min.js - COMMAND ${CMAKE_COMMAND} - -E copy_directory ${CMAKE_CURRENT_SOURCE_DIR}/node_modules/@fortawesome/fontawesome-free/webfonts - ${DOXYGEN_BUILD_DIR_CMAKE}/html/assets/fontawesome/webfonts - COMMENT "Copying Font Awesome files" - DEPENDS ${FONT_AWESOME_FILES_DEPENDS} + -E copy ${CMAKE_CURRENT_SOURCE_DIR}/node_modules/lucide/dist/umd/lucide.min.js + ${DOXYGEN_BUILD_DIR_CMAKE}/html/assets/lucide/lucide.min.js + COMMENT "Copying Lucide files" + DEPENDS ${LUCIDE_FILES_DEPENDS} ) # convert to relative path, so doxygen doesn't get confused on Windows @@ -130,5 +125,5 @@ add_custom_target(docs ALL DOXYCONFIG_THREADS=${DOXYGEN_NUM_THREADS} ${DOXYGEN_EXECUTABLE} doxyconfig-Doxyfile VERBATIM - DEPENDS FONT_AWESOME_FILES SHARED_WEB_FILES + DEPENDS LUCIDE_FILES SHARED_WEB_FILES ) diff --git a/docs/source_code.md b/docs/source_code.md index 2a13d87..1bc9484 100644 --- a/docs/source_code.md +++ b/docs/source_code.md @@ -161,8 +161,8 @@ We have defined some custom aliases to simplify documenting examples. * \@examples - Start of an example block. This will format the following text as `cpp`. * \@examples_end - End of an example block. -* \@fa_icon{font awsome definition} - Insert a Font Awesome icon. Give the icon style and name as arguments. - e.g. \@fa_icon{fa-solid fa-check}. +* \@lucide_icon{icon name} - Insert a Lucide icon. Give the icon name as an argument. + e.g. \@lucide_icon{check}. * Admonitions * \@admonition{Custom Title | Content } @admonition{The one with the custom titles | It’s got a certain charm to it.} diff --git a/doxyconfig-Doxyfile b/doxyconfig-Doxyfile index 0f20c6c..d3e344e 100644 --- a/doxyconfig-Doxyfile +++ b/doxyconfig-Doxyfile @@ -44,6 +44,7 @@ HTML_EXTRA_FILES += ../third-party/doxyconfig/doxygen-awesome-css/doxygen-awesom HTML_EXTRA_FILES += ../third-party/doxyconfig/doxygen-awesome-css/doxygen-awesome-paragraph-link.js HTML_EXTRA_FILES += ../third-party/doxyconfig/doxygen-awesome-css/doxygen-awesome-interactive-toc.js HTML_EXTRA_FILES += ../third-party/doxyconfig/doxygen-awesome-css/doxygen-awesome-tabs.js +HTML_EXTRA_FILES += doxyconfig-icons.js HTML_EXTRA_STYLESHEET = ../third-party/doxyconfig/doxygen-awesome-css/doxygen-awesome.css HTML_HEADER = doxyconfig-header.html @@ -55,24 +56,24 @@ HTML_EXTRA_STYLESHEET += doxyconfig.css ALIASES = "" ALIASES += "examples=^^**Examples**^^@code{.cpp}" ALIASES += "examples_end=@endcode^^" -# fontawesome -ALIASES += "fa_icon{1}=" +# lucide +ALIASES += "lucide_icon{1}=" # admonitions -ALIASES += "_admonition{4|}=
@fa_icon{\3} \1
\4
" -ALIASES += "_admonition_b{4|}=
@fa_icon{\3} \1
\4
" +ALIASES += "_admonition{4|}=
@lucide_icon{\3} \1
\4
" +ALIASES += "_admonition_b{4|}=
@lucide_icon{\3} \1
\4
" # see: https://jothepro.github.io/doxygen-awesome-css/class_my_library_1_1_example.html#autotoc_md6 -ALIASES += "admonition{2|}=@_admonition_b{\1 | todo | fa-solid fa-bars | \2}" -ALIASES += "attention{1}=@_admonition{Attention | section attention | | \1}" -ALIASES += "caution{1}=@_admonition{Caution | section warning | | \1}" -ALIASES += "danger{1}=@_admonition{Danger | bug | fa-solid fa-triangle-exclamation | \1}" -ALIASES += "error{1}=@_admonition{Error | bug | fa-solid fa-circle-xmark | \1}" -ALIASES += "hint{1}=@_admonition{Hint | section pre | | \1}" -ALIASES += "important{1}=@_admonition{Important | section important | | \1}" -ALIASES += "note{1}=@_admonition{Note | section note | | \1}" -ALIASES += "seealso{1}=@_admonition{See also | section remark | | \1}" -ALIASES += "tip{1}=@_admonition{Tip | section pre | | \1}" -ALIASES += "todo{1}=@_admonition{TODO | section deprecated | | \1}" -ALIASES += "warning{1}=@_admonition{Warning | section warning | | \1}" +ALIASES += "admonition{2|}=@_admonition_b{\1 | todo | menu | \2}" +ALIASES += "attention{1}=@_admonition{Attention | section attention | circle-alert | \1}" +ALIASES += "caution{1}=@_admonition{Caution | section warning | triangle-alert | \1}" +ALIASES += "danger{1}=@_admonition{Danger | bug | triangle-alert | \1}" +ALIASES += "error{1}=@_admonition{Error | bug | circle-x | \1}" +ALIASES += "hint{1}=@_admonition{Hint | section pre | info | \1}" +ALIASES += "important{1}=@_admonition{Important | section important | flame | \1}" +ALIASES += "note{1}=@_admonition{Note | section note | sticky-note | \1}" +ALIASES += "seealso{1}=@_admonition{See also | section remark | info | \1}" +ALIASES += "tip{1}=@_admonition{Tip | section pre | info | \1}" +ALIASES += "todo{1}=@_admonition{TODO | section deprecated | pencil | \1}" +ALIASES += "warning{1}=@_admonition{Warning | section warning | triangle-alert | \1}" # tabs # see: https://github.com/jothepro/doxygen-awesome-css/discussions/146 ALIASES += tab{2|}="@htmlonly
  • @endhtmlonly^^\1^^@htmlonly@endhtmlonly^^\2^^@htmlonly
  • @endhtmlonly" diff --git a/doxyconfig-header.html b/doxyconfig-header.html index ad4f130..64cfb83 100644 --- a/doxyconfig-header.html +++ b/doxyconfig-header.html @@ -24,10 +24,10 @@ $extrastylesheet - - - - + + + + @@ -44,6 +44,7 @@