pax_global_header00006660000000000000000000000064150056202750014514gustar00rootroot0000000000000052 comment=4c0398d9c34bbbcd568427091e9c93b335e0965e crystal-facet-uml-1.63.3/000077500000000000000000000000001500562027500151425ustar00rootroot00000000000000crystal-facet-uml-1.63.3/.gitignore000066400000000000000000000001441500562027500171310ustar00rootroot00000000000000# do not report untraced files in the build directory: /build/ # ignore temporary swap files: *.swp crystal-facet-uml-1.63.3/CMakeLists.txt000066400000000000000000000226701500562027500177110ustar00rootroot00000000000000CMAKE_MINIMUM_REQUIRED(VERSION 3.5) PROJECT(crystal-facet-uml LANGUAGES C) # pkgconfig is a helper program to find include directories and libraries: FIND_PACKAGE(PkgConfig REQUIRED) # ==== ==== ==== ==== ==== ==== ==== ==== Build Environment Settings ==== ==== ==== ==== ==== ==== ==== ==== SET(COMPILE_IN_INCLUDE_DIR "" CACHE FILEPATH "Path to additional include directory") SET(COMPILE_IN_SOURCE_FILE "" CACHE FILEPATH "Path to additional source file, e.g. sqlite3.c") SET(COMPILE_IN_LINKER_FLAG "" CACHE FILEPATH "Additional linker flag, e.g. win_app_icon.res") INCLUDE_DIRECTORIES(${COMPILE_IN_INCLUDE_DIR}) # crystal-facet-uml INCLUDE_DIRECTORIES(gui/include) INCLUDE_DIRECTORIES(main/include) INCLUDE_DIRECTORIES(ctrl/include) INCLUDE_DIRECTORIES(data/include) INCLUDE_DIRECTORIES(pencil/include) INCLUDE_DIRECTORIES(io/include) INCLUDE_DIRECTORIES(u8stream/include) #sqlite3 dependencies PKG_SEARCH_MODULE(SQLITE3 REQUIRED sqlite3) INCLUDE_DIRECTORIES(${SQLITE3_INCLUDE_DIRS}) #MESSAGE("SQLITE3: ${SQLITE3_INCLUDE_DIRS}") #gtk dependencies #Note: PKG_SEARCH_MODULE finds only the first successful match PKG_CHECK_MODULES(GLIB2 REQUIRED glib-2.0) INCLUDE_DIRECTORIES(${GLIB2_INCLUDE_DIRS}) MESSAGE("GLIB2: ${GLIB2_INCLUDE_DIRS}") MESSAGE("GLIB2: ${GLIB2_LIBRARY_DIRS}") MESSAGE("GLIB2: ${GLIB2_CFLAGS}") # for DEBUG mode, some headers may not be found automatically: #EXECUTE_PROCESS(COMMAND pkg-config --cflags glib-2.0 # OUTPUT_VARIABLE GLIB_MORE_CFLAGS) #SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${GLIB_MORE_CFLAGS}" ) #MESSAGE("GLIB_MORE_CFLAGS: ${GLIB_MORE_CFLAGS}") #search gtk4 # Note: PKG_CHECK_MODULES searched for all occurerences of the package PKG_CHECK_MODULES(GTK REQUIRED gtk4) INCLUDE_DIRECTORIES(${GTK_INCLUDE_DIRS}) MESSAGE("GTK: ${GTK_INCLUDE_DIRS}") MESSAGE("GTK: ${GTK_FOUND}") MESSAGE("GTK: ${GTK_LIBRARIES}") MESSAGE("GTK: ${GTK_LIBRARY_DIRS}") MESSAGE("GTK: ${GTK_LDFLAGS}") MESSAGE("GTK: ${GTK_LDFLAGS_OTHER}") MESSAGE("GTK: ${GTK_CFLAGS}") MESSAGE("GTK: ${GTK_CFLAGS_OTHER}") # for DEBUG mode, some headers may not be found automatically: #EXECUTE_PROCESS(COMMAND pkg-config --cflags graphene-1.0 # OUTPUT_VARIABLE GRAPHENE_MORE_CFLAGS) #SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${GRAPHENE_MORE_CFLAGS}" ) #MESSAGE("GRAPHENE_MORE_CFLAGS: ${GRAPHENE_MORE_CFLAGS}") PKG_SEARCH_MODULE(PANGOCAIRO REQUIRED pangocairo) INCLUDE_DIRECTORIES(${PANGOCAIRO_INCLUDE_DIRS}) #MESSAGE("PANGOCAIRO: ${PANGOCAIRO_INCLUDE_DIRS}") FILE(GLOB commonSource gui/source/*.c gui/source/attributes/*.c gui/source/sketch/*.c ctrl/source/*.c ctrl/source/consistency/*.c data/source/*.c data/source/entity/*.c data/source/storage/*.c data/source/set/*.c u8stream/source/utf8stringbuf/*.c u8stream/source/u8dir/*.c u8stream/source/u8stream/*.c u8stream/source/u8/*.c pencil/source/*.c pencil/source/geometry/*.c pencil/source/layout/*.c pencil/source/draw/*.c io/source/*.c io/source/image/*.c io/source/json/*.c io/source/document/*.c io/source/xmi/*.c io/source/format/*.c main/source/main_commands.c main/source/main_execute.c) FILE(GLOB appSource main/source/main.c) FILE(GLOB utestSource main/test/*.c data/test/unit/*.c data/test/integration/*.c ctrl/test/unit/*.c ctrl/test/integration/*.c gui/test/unit/*.c io/test/unit/*.c io/test/integration/*.c pencil/test/unit/*.c pencil/test/test_data/*.c pencil/test/integration/*.c u8stream/test/unit/*.c u8stream/test/integration/*.c) # ==== ==== ==== ==== ==== ==== ==== ==== Check if CMAKE_BUILD_TYPE is set ==== ==== ==== ==== ==== ==== ==== ==== IF(NOT CMAKE_BUILD_TYPE) MESSAGE( "Warn: CMAKE_BUILD_TYPE no set! setting(CMAKE_BUILD_TYPE \"Release\")") SET(CMAKE_BUILD_TYPE "Release") ENDIF(NOT CMAKE_BUILD_TYPE) MESSAGE( "Note: CMAKE_BUILD_TYPE = ${CMAKE_BUILD_TYPE}" ) MESSAGE( "Note: to build a release, run cmake -DCMAKE_BUILD_TYPE=Release " ${CMAKE_CURRENT_SOURCE_DIR} ) MESSAGE( "Note: to build with asserts and traces, run cmake -DCMAKE_BUILD_TYPE=Debug " ${CMAKE_CURRENT_SOURCE_DIR} ) # ==== ==== ==== ==== ==== ==== ==== ==== Common Settings ==== ==== ==== ==== ==== ==== ==== ==== SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=c11 -D_XOPEN_SOURCE=700 -O2 -pedantic -g -Wall -Wno-overlength-strings" ) # Note: The GIMP-generated images are longer that 4095 characters, therefore -Wno-overlength-strings is required here. # ==== ==== ==== ==== ==== ==== ==== ==== EXE Target Settings ==== ==== ==== ==== ==== ==== ==== ==== ADD_EXECUTABLE(crystal-facet-uml ${appSource} ${commonSource} ${COMPILE_IN_SOURCE_FILE}) TARGET_LINK_LIBRARIES(crystal-facet-uml ${GTK_LIBRARIES} ${GLIB2_LIBRARIES} ${PANGOCAIRO_LIBRARIES} ${SQLITE3_LIBRARIES} m) SET_TARGET_PROPERTIES(crystal-facet-uml PROPERTIES LINKER_LANGUAGE C) SET_TARGET_PROPERTIES(crystal-facet-uml PROPERTIES LINK_FLAGS "${COMPILE_IN_LINKER_FLAG}") # ==== ==== ==== ==== ==== ==== ==== ==== test Target Settings ==== ==== ==== ==== ==== ==== ==== ==== ADD_EXECUTABLE(test_crystal-facet-uml ${utestSource} ${commonSource} ${COMPILE_IN_SOURCE_FILE}) TARGET_INCLUDE_DIRECTORIES(test_crystal-facet-uml PUBLIC test_fw/include) TARGET_INCLUDE_DIRECTORIES(test_crystal-facet-uml PUBLIC data/test) TARGET_INCLUDE_DIRECTORIES(test_crystal-facet-uml PUBLIC ctrl/test) TARGET_INCLUDE_DIRECTORIES(test_crystal-facet-uml PUBLIC gui/test) TARGET_INCLUDE_DIRECTORIES(test_crystal-facet-uml PUBLIC io/test) TARGET_INCLUDE_DIRECTORIES(test_crystal-facet-uml PUBLIC pencil/test) TARGET_INCLUDE_DIRECTORIES(test_crystal-facet-uml PUBLIC u8stream/test) TARGET_LINK_LIBRARIES(test_crystal-facet-uml ${GTK_LIBRARIES} ${GLIB2_LIBRARIES} ${PANGOCAIRO_LIBRARIES} ${SQLITE3_LIBRARIES} m) SET_TARGET_PROPERTIES(test_crystal-facet-uml PROPERTIES LINKER_LANGUAGE C) SET_TARGET_PROPERTIES(test_crystal-facet-uml PROPERTIES LINK_FLAGS "${COMPILE_IN_LINKER_FLAG}") # ==== ==== ==== ==== ==== ==== ==== ==== Install Settings ==== ==== ==== ==== ==== ==== ==== ==== INSTALL(TARGETS crystal-facet-uml DESTINATION "/usr/bin/") INSTALL(FILES "${CMAKE_CURRENT_SOURCE_DIR}/installation/linux/crystal-facet-uml.desktop" DESTINATION "/usr/share/applications/") INSTALL(FILES "${CMAKE_CURRENT_SOURCE_DIR}/installation/linux/crystal-facet-uml.metainfo.xml" DESTINATION "/usr/share/metainfo/") INSTALL(FILES "${CMAKE_CURRENT_SOURCE_DIR}/gui/source/resources/crystal_facet_uml_80x80.png" DESTINATION "/usr/share/pixmaps/" RENAME "crystal-facet-uml.png") INSTALL(FILES "${CMAKE_CURRENT_SOURCE_DIR}/installation/linux/crystal-facet-uml.1.gz" DESTINATION "/usr/share/man/man1/") # ==== ==== ==== ==== ==== ==== ==== ==== gcov Target Settings ==== ==== ==== ==== ==== ==== ==== ==== if(CFU_ADD_GCOV_TARGET) if(CMAKE_COMPILER_IS_GNUCC) SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fprofile-arcs -ftest-coverage -O0" ) SET(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -fprofile-arcs" ) ADD_EXECUTABLE(gcov_crystal-facet-uml ${utestSource} ${commonSource} ${COMPILE_IN_SOURCE_FILE}) TARGET_INCLUDE_DIRECTORIES(gcov_crystal-facet-uml PUBLIC test_fw/include) TARGET_INCLUDE_DIRECTORIES(gcov_crystal-facet-uml PUBLIC data/test) TARGET_INCLUDE_DIRECTORIES(gcov_crystal-facet-uml PUBLIC ctrl/test) TARGET_INCLUDE_DIRECTORIES(gcov_crystal-facet-uml PUBLIC gui/test) TARGET_INCLUDE_DIRECTORIES(gcov_crystal-facet-uml PUBLIC io/test) TARGET_INCLUDE_DIRECTORIES(gcov_crystal-facet-uml PUBLIC pencil/test) TARGET_INCLUDE_DIRECTORIES(gcov_crystal-facet-uml PUBLIC u8stream/test) TARGET_LINK_LIBRARIES(gcov_crystal-facet-uml ${GTK_LIBRARIES} ${GLIB2_LIBRARIES} ${PANGOCAIRO_LIBRARIES} ${SQLITE3_LIBRARIES} m) SET_TARGET_PROPERTIES(gcov_crystal-facet-uml PROPERTIES LINKER_LANGUAGE C) SET_TARGET_PROPERTIES(gcov_crystal-facet-uml PROPERTIES EXCLUDE_FROM_ALL TRUE) endif(CMAKE_COMPILER_IS_GNUCC) endif(CFU_ADD_GCOV_TARGET) # ==== ==== ==== ==== ==== ==== ==== ==== run the msys2 deploy script ==== ==== ==== ==== ==== ==== ==== ==== ADD_CUSTOM_TARGET(msys2_deploy ${CMAKE_CURRENT_SOURCE_DIR}/build/msys2/deploy.sh ${CMAKE_CURRENT_SOURCE_DIR} ${CMAKE_CURRENT_BINARY_DIR}) # Copyright 2018-2025 Andreas Warnke # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. crystal-facet-uml-1.63.3/CONTRIBUTING.md000066400000000000000000000015271500562027500174000ustar00rootroot00000000000000 Steps for creating good issues or pull requests =============================================== Please file each bug fix, code adaption or new feature in a separate pull request. Links to external documentation, mailing lists, or a code of conduct ==================================================================== Please check the [coding_guidelines.txt](documentation/architecture/coding_guidelines.txt) Community and behavioral expectations ===================================== This software is licensed under the Apache 2.0 license. Contributions shall be provided under this same license. In case the license needs to be adapted due to changes in e.g. legislations or operation environment, adaptations will stay in the mindset of free and open source software (FOSS) as e.g. sketched by the Open Source Initiative (also known as the OSI). crystal-facet-uml-1.63.3/ChangeLog000066400000000000000000001437221500562027500167250ustar00rootroot00000000000000crystal-facet-uml (1.63.3) UNRELEASED; urgency=medium [ Andreas Warnke ] * Improved navigation in html export * All linebreaks are transformed to html and doxygen exports * removed limitation on maximum 10 appearance-links in html export -- Andreas Warnke Sun, 04 May 2025 10:30:00 +0100 crystal-facet-uml (1.63.2) UNRELEASED; urgency=medium [ Andreas Warnke ] * relationships to contained elements start from inner border, not outside * too short relationships are weighted by additional dept layout_good_cases ERR=0, W/C=8, W/F=1, W/L=25, W/R=61 layout_challenging_cases ERR=39, W/C=9751, W/F=503, W/L=6720, W/R=7636 * exported cross-references D0001#id work even if many characters follow -- Andreas Warnke Thu, 01 May 2025 11:00:00 +0100 crystal-facet-uml (1.63.1) UNRELEASED; urgency=medium [ Andreas Warnke ] * in sequence charts, labels of relationships are closer to the x-center * relationships may trespass parents/ancestors of their from/to nodes -- Andreas Warnke Sat, 22 Mar 2025 08:00:00 +0100 crystal-facet-uml (1.63.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * scripts added to build for Windows(TM) using msys2 * no fancy names for new objects, only New Diagram, New Element, New Feature * snapping distance increased for snapping classifiers to grid * layouting of relationship labels consider the surrouding space layout_good_cases ERR=0, W/C=8, W/F=1, W/L=25, W/R=79 layout_challenging_cases ERR=44, W/C=9751, W/F=509, W/L=6720, W/R=7777 -- Andreas Warnke Sat, 08 Mar 2025 18:30:00 +0100 crystal-facet-uml (1.62.3) UNRELEASED; urgency=medium [ Andreas Warnke ] * bugfix for layouting issue: line intersects were ignored in 1.62.2 -- Andreas Warnke Wed, 29 Jan 2025 18:30:00 +0100 crystal-facet-uml (1.62.2) UNRELEASED; urgency=medium [ Andreas Warnke ] * Layouting improved when classifier contains itself; less errors: * layouting further modified by adjusting debts OLD layout_good_cases: ERR=3, W/C=9, W/F=3, W/L=25, W/R=71 OLD layout_challenging_cases ERR=37, W/C=9433, W/F=531, W/L=6622, W/R=7844 NEW layout_good_cases ERR=0, W/C=8, W/F=2, W/L=25, W/R=64 NEW layout_challenging_cases ERR=32, W/C=9710, W/F=510, W/L=6716, W/R=8492 The diagrams look more orderly - even if this is not reflected in the stats -- Andreas Warnke Sun, 26 Jan 2025 15:30:00 +0100 crystal-facet-uml (1.62.1) UNRELEASED; urgency=medium [ Andreas Warnke ] * All new(!) files are of type json - no native sqlite3 format anymore * Stereotype icons of non-empty packages are positioned next to the label -- Andreas Warnke Tue, 31 Dec 2024 08:30:00 +0100 crystal-facet-uml (1.62.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * Gui shows labels below the icons of buttons * The save icon indicates if there are unsaved changes -- Andreas Warnke Sat, 21 Dec 2024 18:00:00 +0100 crystal-facet-uml (1.61.2) UNRELEASED; urgency=medium [ Andreas Warnke ] * Diagrams can show the defined maximum number of features and relationships independant of their occurrences in other diagrams -- Andreas Warnke Sun, 01 Dec 2024 08:30:00 +0100 crystal-facet-uml (1.61.1) UNRELEASED; urgency=medium [ Andreas Warnke ] * Database iterator allows the model export to handle unexpected many life- lines and messages -- Andreas Warnke Sun, 24 Nov 2024 18:30:00 +0100 crystal-facet-uml (1.61.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * Compatibility to version 1.25.0 and earlier dropped to increase test coverage. * Icons of diagram types are less similar to each other. -- Andreas Warnke Sun, 27 Oct 2024 08:00:00 +0100 crystal-facet-uml (1.60.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * When pasting a new diagram, navigation view is activated to see the changes * When undoing or redoing changes on diagrams,diagramelements or classifiers, changes are shown in a suitable view; also maybe features and relationships * While moving features, no classifier ordering lines are shown. -- Andreas Warnke Sat, 10 Aug 2024 08:00:00 +0200 crystal-facet-uml (1.59.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * some compiler warnings checked and switched off * while moving classifiers, grid lines better show the alignment towards other classifiers -- Andreas Warnke Thu, 11 Jul 2024 21:00:00 +0200 crystal-facet-uml (1.58.3) UNRELEASED; urgency=medium [ Andreas Warnke ] * no gtk_file_chooser_set_action in gui_file_use_db_dialog (Closes: #4) -- Andreas Warnke Sun, 02 Jun 2024 08:00:00 +0200 crystal-facet-uml (1.58.2) UNRELEASED; urgency=medium [ Andreas Warnke ] * in create mode, a click on a feature does not create another feature * in create mode, a click on a lifeline selects the classifier * in create mode, a click on a classifier name selects the classifier -- Andreas Warnke Sat, 11 May 2024 08:00:00 +0200 crystal-facet-uml (1.58.1) UNRELEASED; urgency=medium [ Andreas Warnke ] * selecting contained classifiers is possible again -- Andreas Warnke Tue, 07 May 2024 06:00:00 +0200 crystal-facet-uml (1.58.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * in create mode, the mouse-over element-part is highlighted * in edit mode, less accidential selections of the surrounding diagram * diagrams provide more automatic line breaks at features, relationships -- Andreas Warnke Sun, 05 May 2024 12:00:00 +0200 crystal-facet-uml (1.57.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * diagrams provide more automatic line breaks in classifier names -- Andreas Warnke Mon, 08 Apr 2024 21:30:00 +0200 crystal-facet-uml (1.56.1) UNRELEASED; urgency=medium [ Andreas Warnke ] * database supports worst-case length of diagram description texts * test cases can be selected more finegranular, test coverage more accurate * test coverage on u8stream package increased * on windows, the pango-rendered fonts are not cut on the top line of pixels -- Andreas Warnke Sat, 23 Mar 2024 05:00:00 +0100 crystal-facet-uml (1.56.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * gtk3 support dropped, more than 100 #if preprocessor-statements removed * GtkFileChooserDialog replaced by GtkFileDialog (without filetype selection) * deprecated function gdk_pixbuf_get_from_texture replaced * XMI export traces if a classifier contains a child twice (in DEBUG mode) -- Andreas Warnke Sun, 03 Mar 2024 10:00:00 +0100 crystal-facet-uml (1.55.3) UNRELEASED; urgency=medium [ Andreas Warnke ] * GdkPixbuf replaced by GdkTexture * GtkComboBox replaced by GtkDropDown -- Andreas Warnke Sat, 10 Feb 2024 09:00:00 +0100 crystal-facet-uml (1.55.2) UNRELEASED; urgency=medium [ Andreas Warnke ] * when loading a .tmp-cfu file from a terminated session, the right json file is restored, not the guessed .cfuJ file name. * moved example_diagrams/ to documentation/examples * gtk_widget_show/hide replaced by gtk4 function gtk_widget_set_visible * gtk_image_set_from_pixbuf replaced by gtk_image_set_from_paintable of gtk4 -- Andreas Warnke Sat, 27 Jan 2024 17:00:00 +0100 crystal-facet-uml (1.55.1) UNRELEASED; urgency=medium [ Andreas Warnke ] * Diagram descriptions can be 8191 bytes long, not reduced by SQL overhead * Too long entered texts are not cut in the middle of an utf8 code point -- Andreas Warnke Sat, 06 Jan 2024 10:00:00 +0100 crystal-facet-uml (1.55.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * readme.markdown renamed to README.md * license.txt renamed to LICENSE.txt * moved installation_linux/ to installation/linux * moved installation_win/ to installation/win * moved user_doc/crystal-facet-uml.1.gz to installation/linux/ * moved user_doc/crystal-facet-uml_documentation.pdf to installation/ * -DCFU_USE_GTK4=ON is default cmake option now * a couple of static code analysis findings are addressed -- Andreas Warnke Fri, 29 Dec 2023 11:00:00 +0100 crystal-facet-uml (1.54.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * The json export creates a schema file that explains the json format * The html export is html5 compliant and creates nav, main and article tags * The html+docbook(db) export lists diagrams where classifiers appear * The html+db export show stereotypes and relationship-type specific arrows -- Andreas Warnke Sun, 10 Dec 2023 12:00:00 +0100 crystal-facet-uml (1.53.1) UNRELEASED; urgency=medium [ Andreas Warnke ] * uncritical compiler warnings on enum/int type mismatches fixed -- Andreas Warnke Sun, 29 Oct 2023 07:00:00 +0100 crystal-facet-uml (1.53.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * Relationships draw stereotypes as text if no image is defined * Default relationship type from SUBSYSTEM is ASSOCIATION, not CONTAINMENT * Elements can be selected by click on their label, not only on their symbol * The window system shows an icon for the gtk3-window of crystal-facet-uml * Type-selector buttons are layouted by an gtk4-compatible grid * Type icons are different for part/object, class/interface, activity/state, stereotype/icon, assocication/ctrl-flow/object-flow/async-call * The database save action is confirmed by a status message * info: Unit test coverage increased from 21.5 % to 21.7 % -- Andreas Warnke Sat, 28 Oct 2023 07:00:00 +0200 crystal-facet-uml (1.52.1) UNRELEASED; urgency=medium [ Andreas Warnke ] * info: database triggers are re-entrant to allow recursion * statistics are with separated lifelines now: layout_good_cases: ERR=0, W/C=9, W/F=1, W/L=20, W/R=37 layout_challenging_cases: ERR=28, W/C=7728, W/F=520, W/L=5406, W/R=4869 -- Andreas Warnke Sat, 30 Sep 2023 19:00:00 +0200 crystal-facet-uml (1.52.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * Redesign of file-menu icons * Lifelines are deleted when the diagram type changes to non-interaction * When changing the diagram type, statistics on changes are displayed * In interaction diagrams, Stereotypes and Images are co-located to comments * info: New database files store ids, types and flags as NOT NULL -- Andreas Warnke Sun, 24 Sep 2023 09:00:00 +0200 crystal-facet-uml (1.51.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * Redesign of view-mode icons and stereotype icon * No overlap of stereotype icon with comment-corner * classifiers of unknown (future) type are drawn as cornerless box and logged as anomaly * features, relationships, diagrams of unknown type are just anomalies * The stereotype field is labelled as such. Exceptions are stated only in the user manual. * stereotype images are also drawn for diagrams, features and relationships * linebreaks in relationship and feature labels * the compartment separators in use cases do not exceed the outer circle * layouting quality improved to: layout_good_cases: ERR=0, W/C=6, W/F=17, W/R=33 layout_challenging_cases: ERR=29, W/C=8260, W/F=6415, W/R=4662 -- Andreas Warnke Sat, 26 Aug 2023 07:00:00 +0200 crystal-facet-uml (1.50.1) UNRELEASED; urgency=medium [ Andreas Warnke ] * Diagram titles do not touch the diagram elements anymore * The win version includes libgcc_s_seh-1.dll and libwinpthread-1.dll into the distribution package * The res icon is part of the exe file -- Andreas Warnke Sat, 03 Jun 2023 10:00:00 +0200 crystal-facet-uml (1.50.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * IDs of classifiers are not shown anymore, names are already unique * Stereotype-Images: svg-path use fill and stroke colors to draw * in stereotype images, the svg path data may be stated in single-quotes * if a stereotype image is drawn, the stereotype name is not drawn -- Andreas Warnke Sat, 13 May 2023 11:00:00 +0200 crystal-facet-uml (1.49.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * Stereotype-Images: svg-path draws arcs * In case of svg-path errors, line numbers are shown to the user * In case the user enters a duplicate name, a similar name is set instead -- Andreas Warnke Sat, 15 Apr 2023 14:00:00 +0200 crystal-facet-uml (1.48.1) UNRELEASED; urgency=medium [ Andreas Warnke ] * Test case testParseFloat fixed by using TEST_EXPECT_EQUAL_DOUBLE macro -- Andreas Warnke Sat, 01 Apr 2023 08:00:00 +0200 crystal-facet-uml (1.48.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * Classifiers show custom stereotype images made of SVG-path subset: Lines and Curves * Image classifier defined -- Andreas Warnke Fri, 31 Mar 2023 19:00:00 +0200 crystal-facet-uml (1.47.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * diagrams and relationships have stereotypes * stereotype (as classifier) and tagged value (as feature) defined * Rare issue fix: XMI-export exports also the non-lifeline features of interaction-ownedBehaviors (e.g. port of state in sequence) -- Andreas Warnke Sun, 19 Feb 2023 08:00:00 +0100 crystal-facet-uml (1.46.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * png images are 4 times more detailed to reduce scaling effects * less overlaps in sequence diagrams between classifiers and their lifelines * less overlaps in sequence diagrams between neighbor lifelines * opening json-based database files is faster by factor 5 * less anomaly and error messages in syslog (linux only) e.g. when loading a json based database, when creating a classifier or when undoing a create-action. * Removed false alarm ERR : U8_ERROR_STRING_BUFFER_EXCEEDED at loading a ... * pencil_layout_data_get_statistics() takes into account if features and relationships are visible; also lifelines may not overlap classifiers in sequence and timing diagrams anymore; this may influence export statistics. layout_good_cases: ERR=0, W/C=7, W/F=34, W/R=72 layout_challenging_cases: ERR=35, W/C=7361, W/F=6398, W/R=4799 * rust-based qualification test framework introduced -- Andreas Warnke Sat, 28 Jan 2023 08:00:00 +0100 crystal-facet-uml (1.45.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * On model changes, diffs on json data file are smaller (new sort order) * Search for empty fields omits stereo/value types; these are often empty * When exporting json files from command line, no .tmp-cfu file remains * No superfluous warnings from json_element_reader_skip_next_string anymore * No superfluous anomalies from data_database_reader_get_xy_by_uuid anymore * No superfluous errors in log during regular opening json data files * Application id changed from desktop.crystal-facet-uml to de.andreaswarnke.crystal-facet-uml -- Andreas Warnke Sun, 27 Nov 2022 16:00:00 +0100 crystal-facet-uml (1.44.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * Find-Occurrence button added for faster navigation in the model -- Andreas Warnke Sat, 12 Nov 2022 11:00:00 +0100 crystal-facet-uml (1.43.2) UNRELEASED; urgency=medium [ Andreas Warnke ] * License of file metainfo.xml changed from MIT to CC0-1.0 -- Andreas Warnke Wed, 02 Nov 2022 20:30:00 +0100 crystal-facet-uml (1.43.1) UNRELEASED; urgency=medium [ Andreas Warnke ] * Typos fixed as proposed by Mike Gabriel -- Andreas Warnke Tue, 01 Nov 2022 06:00:00 +0100 crystal-facet-uml (1.43.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * Timing and sequence diagrams do not show a 2d snap region while dragging * Errors at parsing json are shown to user including the line of occurrence * In case of errors at opening json fies, the temp file is removed again * specific error message in case of read-only parent directories added * json export omits ids of linked objects, only uuids are exported * subsystems/boundaries and interruptable regions can have features -- Andreas Warnke Tue, 01 Nov 2022 05:00:00 +0100 crystal-facet-uml (1.42.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * relationships connecting ports to inner sub-components avoid parent border * relationships: fine tuning straight lines and centered-preference * relationships: search for good free spaces avoids crossings; stats from layout_good_cases: ERR=0, W/C=7, W/F=167, W/R=59 layout_challenging_cases: ERR=64, W/C=8033, W/F=8379, W/R=5408 improved to layout_good_cases: ERR=0, W/C=7, W/F=167, W/R=72 layout_challenging_cases: ERR=64, W/C=8033, W/F=8379, W/R=5307 * relationships: dropped idea of overlapping same-typed arrows * relationships: avoid L, r, 7, J pattern-parts in respective corners -- Andreas Warnke Sat, 01 Oct 2022 14:00:00 +0100 crystal-facet-uml (1.41.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * relationships prefer centered over uncentered departure and arrival * relationships have a minimum gap distance towards all classifiers * relationships keep distance to symbol boxes of features * relationships keep distance to neighbor relationships * relationships can be simple straight lines * json: forward slashes are only decoded, not encoded in json anymore -- Andreas Warnke Sun, 11 Sep 2022 09:00:00 +0100 crystal-facet-uml (1.40.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * A single filename-parameter allows to open files by drag-n-drop on win * while exporting, the status line states "Exporting..." * Create-diagram icons highlight at mouse-over * Improving the relationship layouter, statistics changed on "Raspbian GNU/Linux 11 (bullseye)" from: layout_good_cases: ERR=0, W/C=7, W/F=171, W/R=45 layout_challenging_cases: ERR=64, W/C=8033, W/F=8379, W/R=5909 to: layout_good_cases: ERR=0, W/C=7, W/F=171, W/R=58 layout_challenging_cases: ERR=64, W/C=8033, W/F=8381, W/R=5175 -- Andreas Warnke Sun, 28 Aug 2022 08:00:00 +0100 crystal-facet-uml (1.39.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * Json format can be opened and written back from gui * save button was renamed from commit, moved to top tool bar * while loading, the status line states "Loading..." -- Andreas Warnke Sat, 16 Jul 2022 16:00:00 +0100 crystal-facet-uml (1.38.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * Nicer layout of grid while dragging and creating objects * A single click focuses and selects an element. A second click deselects it * json import speed up by factor 20 (1m37,071s -> 0m4,644s) by using one top-level transaction only * On Windows(TM), the black terminal window is hidden (via -mwindows) * The left-right shiftable panes keep the right side constant on resize -- Andreas Warnke Mon, 06 Jun 2022 19:00:00 +0100 crystal-facet-uml (1.37.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * the screen layout stays fix while creating features and relationships * New DB and Open DB are two separate buttons * on Windows(TM), the working directory is the installation root (again) -- Andreas Warnke Sat, 14 May 2022 15:00:00 +0100 crystal-facet-uml (1.36.1) UNRELEASED; urgency=medium [ Andreas Warnke ] * Workarounds for window switching in gtk 4.6.1 on Windows(TM) removed * The edit widgets auto-store only at focus left event also with gtk4 -- Andreas Warnke Sun, 24 Apr 2022 11:00:00 +0100 crystal-facet-uml (1.36.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * During import, changed ids and classifier-names are reported on stdout * The json export contains some more information to improve readability * sources can be compiled and linked against gtk4 (as done for win version) -- Andreas Warnke Sat, 23 Apr 2022 19:00:00 +0100 crystal-facet-uml (1.35.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * undo of paste requires just 1 click on undo btn (as in version 1.33.1) * when pasting from the clipboard, uuids are preserved. * pasting messages-between-lifelines from the clipboard to other diagrams is not possible anymore, please create new messages when needed. * when creating features, the type field is not pre-filled by a proposal * json export produces identical text files if there are no changes * json files can be imported * database test and repair options return with non-zero result if error, check via echo $? -- Andreas Warnke Sat, 01 Jan 2022 16:00:00 +0200 crystal-facet-uml (1.34.1) UNRELEASED; urgency=medium [ Andreas Warnke ] * no error if gtk_init_check fails - otherwise tests would fail -- Andreas Warnke Mon, 29 Nov 2021 20:00:00 +0200 crystal-facet-uml (1.34.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * export in json format contains also uuids as links (for auto-merging) * export in json format nicer for humans to read (for diff and merge) * export in json format contains also lifelines -- Andreas Warnke Sun, 28 Nov 2021 21:00:00 +0200 crystal-facet-uml (1.33.1) UNRELEASED; urgency=medium [ Andreas Warnke ] * fix: When cutting a diagram, one can immediately paste it to the previous position; also paste it immediately after opening a new db. * Layouting of lines prefers connector types Z over S, N over L7 -- Andreas Warnke Sat, 23 Oct 2021 18:00:00 +0200 crystal-facet-uml (1.33.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * The database has new fields uuid and diagram.display_flags * fix: when copying objects via clipboard, the last characters are not dropped if escape-sequences cause exceeding maximum string length * json export (experimental) -- Andreas Warnke Sat, 16 Oct 2021 08:00:00 +0200 crystal-facet-uml (1.32.1) UNRELEASED; urgency=medium [ Andreas Warnke ] * test_expand_space is now more robust against unexpected installed fonts -- Andreas Warnke Sun, 29 Aug 2021 19:00:00 +0200 crystal-facet-uml (1.32.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * overlaps between relationships with identical type, source and destination are avoided. * good default size of classifiers in case classifiers share same location * less overlaps to labels below actor, fork/join, start/end, h, time * nicer relationships to comments and requirements in sequences and timing -- Andreas Warnke Sun, 29 Aug 2021 16:00:00 +0200 crystal-facet-uml (1.31.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * component titles do not touch the type icon anymore * icon alignment in classifiers is not rounded to int anymore * use case circles do not cut into label texts * decision/choice rhombus do not cut into label texts * send signal arrows do not cut into label texts * accept event flags do not cut into label texts -- Andreas Warnke Sat, 31 Jul 2021 16:00:00 +0200 crystal-facet-uml (1.30.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * in search mode, objects are highlighted individually (not all per diagram) * in search result list, long names have nice linebreaks * in navigation tree, long names have nice linebreaks * Guillements characters surround stereoptypes -- Andreas Warnke Sat, 05 Jun 2021 08:00:00 +0200 crystal-facet-uml (1.29.1) UNRELEASED; urgency=medium [ Andreas Warnke ] * newly created classifiers are placed to clicked location (bugfix, bug introduced on Fri Mar 26, affecting v1.28.0 and v1.29.0) -- Andreas Warnke Sun, 02 May 2021 16:00:00 +0200 crystal-facet-uml (1.29.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * return arrows in sequences have filled arrow tips, distinguishable from dependencies * stereotypes are xmi-exported to LocalProfile namespace * valuetypes are xmi-exported to DataTypes * merainfo.xml references homepage which is now tls/https authenticated * nav-tree and search result lists draw a bit more space around texts * A white line is drawn around highlighted diagrams (additional to green marker) -- Andreas Warnke Sat, 01 May 2021 22:00:00 +0200 crystal-facet-uml (1.28.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * gcov target is only build if -DCFU_ADD_GCOV_TARGET=ON (Closes: #983836) * test coverage on pencil package increased * exporting image-file types shows statistics on exported elements * list layout improved, golden ratio is applied * timing and sequence diagram layouting improved; special handling for comments/reqs in timing and sequence diagrams * version compatibility also in debug mode: newer database-files can be opened with older programs; asserts removed * Messages are not cut off after 255 characters (511 now) * When resetting selection, diagram is redrawn -- Andreas Warnke Fri, 02 Apr 2021 08:00:00 +0200 crystal-facet-uml (1.27.3) UNRELEASED; urgency=medium [ Andreas Warnke ] * fixed most metainfo.xml warnings * build target for gcov measurement added * auto-delete relationships between classifiers that have no common diagram * when opening the second database, view switches back to navigation mode * when opening the second database, search entry field is cleared * when opening the second database, set of marked elements is cleared * search result view is updated when changing the database (e.g. by undo) * search result view stays when database update is triggered by a 2nd window * when clicking on a search result, the element is focused -- Andreas Warnke Tue, 09 Feb 2021 21:30:00 +0100 crystal-facet-uml (1.27.2) UNRELEASED; urgency=medium [ Andreas Warnke ] * compiler switch Werror removed; warnings should not cause build-breaks -- Andreas Warnke Sun, 03 Jan 2021 15:00:00 +0100 crystal-facet-uml (1.27.1) UNRELEASED; urgency=medium [ Andreas Warnke ] * compiler warning fixed: conversions from unsigned int to size_t explicit -- Andreas Warnke Sun, 03 Jan 2021 09:00:00 +0100 crystal-facet-uml (1.27.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * Tx/Rx for component ports and activity pins introduced * control flow pseudostate for state entry and state exit added * risk of nullpointer errors reduced when opening new db with old program * test case added to check for upwards compatibility of types at xmi export * XMI Export: use cases have uml:ExtensionPoints now * XMI Export: Requirement property base_Class renamed to base_NamedElement * notifying user if trying to change a read-only database file * in create mode, the mouse-tip-icon changes depending on users options * redesign of marker-icons for focused and selected elements -- Andreas Warnke Sat, 02 Jan 2021 19:00:00 +0100 crystal-facet-uml (1.26.1) UNRELEASED; urgency=medium [ Andreas Warnke ] * XMI Export: destination end of messages had fix enclosingInteraction=90001 * XMI Export: Properties have attributes class and interface if applicable * XMI Export: Warnings are issued at illegal relationship end types * XMI Export: dependencies of comments to annotatedElements conform to spec * XMI Export: associations and communication paths can connect to ports * XMI Export: nested activities are exported as StructuredActivityNode * icons beautified * program renamed from crystal_facet_uml to crystal-facet-uml -- Andreas Warnke Sat, 19 Dec 2020 21:30:00 +0100 crystal-facet-uml (1.26.0) UNRELEASED; urgency=medium [ Olaf Hering ] * CMakeLists adapted to find pangocairo (Closes: #2) [ Mike Gabriel ] * Grammar fixes in applicatenclosingInteractionion messages [ Andreas Warnke ] * xmi export exports sequence, timing, communication and interaction overview * xmi export creates property-elements at association-member-ends * system boundary renamed to subsystem (to match uml 2.5.1 spec) * The default relationship type between lifelines is a synchronous call -- Andreas Warnke Sun, 22 Nov 2020 16:30:00 +0100 crystal-facet-uml (1.25.1) UNRELEASED; urgency=medium [ Andreas Warnke ] * cmake does not depend on c++ compiler anymore -- Andreas Warnke Thu, 29 Oct 2020 20:30:00 +0100 crystal-facet-uml (1.25.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * moving ports follow the cursor more accurate * Constraint Blocks show their ports completely inside * Artifacts and Components do not waste space for contained children * Comment titles do not overlap with the comment-corner * packages containing children display their title in the tab-symbol * layouting containments does not reserve columns/rows for the container * Feature/Composite Requirement does not exist anymore, data from older versions is auto-converted to Requirement * Requirements are displyed as box-with-label omitting the description * Interaction Overview Diagram is redesigned, data from older versions is auto-converted to Activity Diagram -- Andreas Warnke Sun, 18 Oct 2020 20:30:00 +0200 crystal-facet-uml (1.24.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * XMI(TM) export reflects containment-hierarcy of elements * XMI(TM) export automatically disambiguates between activity/state contexts * warnings are printed to xml export if model is not uml compliant * no arrow tip at communication path * export shows statistics on diagrams or classifiers * internal: messages to user user are typesafe for their parameters -- Andreas Warnke Thu, 08 Oct 2020 20:30:00 +0200 crystal-facet-uml (1.23.1) UNRELEASED; urgency=medium [ Andreas Warnke ] * XMI(TM) export good enough to be checked by NIST validator -- Andreas Warnke Sun, 06 Sep 2020 11:30:00 +0200 crystal-facet-uml (1.23.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * at operations cut, copy, paste and delete: print understandable statistics * at operations undo, redo: print understandable statistics * layouting of classifiers improved * experimental xmi export -- Andreas Warnke Mon, 15 Jun 2020 11:30:00 +0200 crystal-facet-uml (1.22.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * the xhtml export produces a table-of-contents * the xhtml+db exports generate links to diagrams by D0001#name. * the element configuration area on the right does not take space needed by the drawing area * yellow highlighted names are drawn behind the classifier-contour-line -- Andreas Warnke Fri, 01 May 2020 17:30:00 +0200 crystal-facet-uml (1.21.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * containers embrace their children keeping wider gaps -- Andreas Warnke Sun, 12 Apr 2020 16:30:00 +0200 crystal-facet-uml (1.20.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * xhtml output generates a css file to allow defining own color schemes * xhtml output keeps linebreaks in selected (md) cases * bugfix: exporting docbook and xhtml via command line arguments works again, as in 1.16.1 (Closes: #1) * exported xhtml passes https://validator.w3.org/check (for quality.cfu1) * exported xhtml/css shows chapter numbers -- Andreas Warnke Mon, 23 Mar 2020 18:30:00 +0100 crystal-facet-uml (1.19.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * free text search * small memory leak in nav-tree-view fixed -- Andreas Warnke Sat, 14 Mar 2020 12:30:00 +0100 crystal-facet-uml (1.18.2) UNRELEASED; urgency=medium [ Andreas Warnke ] * internal: utf8 handling is limited to 21 bits (0-0x10ffff) (2003 standard) * internal: all error codes are positive bitmasks now * text entry reworked to not loose entered text at remote-xserver usage * name entry is immediately possible after object creation -- Andreas Warnke Mon, 03 Feb 2020 21:30:00 +0100 crystal-facet-uml (1.18.1) UNRELEASED; urgency=medium [ Andreas Warnke ] * when exporting xhtml and docbook files, windows pathnames are supported -- Andreas Warnke Mon, 20 Jan 2020 21:30:00 +0100 crystal-facet-uml (1.18.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * the search view allows one to search for object ids * bugfix: when changing type of an object, lastest changes to name or description are not lost * pressing enter in name or stereotype field causes a save action -- Andreas Warnke Sun, 19 Jan 2020 20:30:00 +0100 crystal-facet-uml (1.17.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * cmake build config is less platform dependent * nav-tree: dragging diagrams shows a tree-depth aware insert line * while dragging, grid lines are displayed * the description text-view has scrollbars * in nav view, a click into the current diagram zooms to edit mode * in create view, an icon next to the mouse cursor shows options * fix: type dropdown box does not change DB automatically if unknown type id * the type drop down box shows icons to faster find the right type * an icon grid allows one to change types quickly -- Andreas Warnke Sun, 05 Jan 2020 20:30:00 +0100 crystal-facet-uml (1.16.2) UNRELEASED; urgency=medium [ Andreas Warnke ] * relationships may overlap if same type and same direction * title and filename of exported docbook and xhtml equals database file name -- Andreas Warnke Sun, 08 Dec 2019 11:30:00 +0100 crystal-facet-uml (1.16.1) UNRELEASED; urgency=medium [ Andreas Warnke ] * rpm package build scripts beautified, doc installation excluded from cmake -- Andreas Warnke Tue, 26 Nov 2019 19:30:00 +0100 crystal-facet-uml (1.16.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * Diagram exports can be triggered from command line * Cut + paste of relationships is possible * Json format in clipboard slightly modified (set renamed to data, order required, relationship src/dst names added) * The default classifier size is calculated based on the grid-distances * Fix: Scenario based diagrams showing multiple identical classifier instances show not too many relationships -- Andreas Warnke Sat, 16 Nov 2019 19:30:00 +0100 crystal-facet-uml (1.15.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * The id of selected objects is displayed in the edit area * Child diagrams are layouted in a grid (in navigation view) -- Andreas Warnke Sun, 20 Oct 2019 12:30:00 +0200 crystal-facet-uml (1.14.2) UNRELEASED; urgency=medium [ Andreas Warnke ] * gtk is initialized before data and ctrl packages --> fix for wine -- Andreas Warnke Fri, 06 Sep 2019 19:30:00 +0200 crystal-facet-uml (1.14.1) UNRELEASED; urgency=medium [ Andreas Warnke ] * background image added to intro screen. * compatibility to GTK 3.6 established, newer features replaced * pthread dependency replaced by glib functions * build for wine using mingw -- Andreas Warnke Mon, 02 Sep 2019 21:30:00 +0200 crystal-facet-uml (1.14.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * all features (except lifelines) are hidden in scenario-based and box/list diagrams * non-global relationships are hidden in scenario-based and all in box/list diagrams * exporting descriptions of hidden relationships and features is suppressed * any classifier can be displayed as named instance or as anonymous instance. -- Andreas Warnke Sun, 14 Jul 2019 11:30:00 +0200 crystal-facet-uml (1.13.1) UNRELEASED; urgency=medium [ Andreas Warnke ] * sqlite3_db_cacheflush() is only called if on the build system and on the target system available. This is a bugfix for the sudden termination on older linuxes when clicking on the commit (Ctrl-S) button. -- Andreas Warnke Sun, 23 Jun 2019 15:30:00 +0200 crystal-facet-uml (1.13.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * improved auto-layout of relationship labels * call/transition to self is layouted nicely in sequence/timing diagrams * automatically grey out arrows if source or destination classifier is greyed out * prevent creation of relationships if unsuitable diagram type * prevent creation of features if unsuitable diagram type * prevent creation of features if unsuitable classifier type -- Andreas Warnke Fri, 21 Jun 2019 15:30:00 +0200 crystal-facet-uml (1.12.1) UNRELEASED; urgency=medium [ Andreas Warnke ] * Packageing warnings of lintian addressed -- Andreas Warnke Wed, 15 May 2019 20:30:00 +0200 crystal-facet-uml (1.12.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * operations and properites do not overlap with class/interface compartments * linebreaks in classifier names are possible * component and artifact icons do not overlap with the label * activities and states better embrace their children classifiers * labels of ports and interfaces and relationships are layouted avoiding overlaps -- Andreas Warnke Fri Apr 26 20:17:44 2019 +0200 crystal-facet-uml (1.11.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * export dialog allows to select multiple file formats simultaneously * docbook export * html export * embunit replaced by own test functions to comply to debian packaging rules -- Andreas Warnke Sun Mar 10 12:29:16 2019 +0100 crystal-facet-uml (1.10.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * new classifier types for activity, state, Interaction-Overview and parametric diagrams * part, artifact, node and object are automatically underlined as instance * objects and parts are always instances * sqlite3 is linked dynamically * symbols for interruptable region, diagram reference, decision, fork, join, timeout, send-sig, rcv-event, history -- Andreas Warnke Sun Feb 3 17:26:24 2019 +0100 crystal-facet-uml (1.9.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * the database check can repair circular diagram-parent references * user experience improvements at using text-edit widgets * communication diagram does select/highlight classifiers in edit mode but lifelines in create mode * lifeline properties cannot be changed anymore * include, extends, deploy, manifest relationships show their stereotype * refine and trace relations exist for requirements * component interfaces are rendered as circle and half-circle * new label-positioning of ports -- Andreas Warnke Thu Jan 17 18:21:15 2019 +0100 crystal-facet-uml (1.8.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * in navigation mode, diagrams can be re-ordered by dragging their names in the tree view * F7 workaround removed, key F7 is without function now * in edit mode, features can be re-ordered, ports can be moved along the classifier border * ids of diagrams and classifiers are shown -- Andreas Warnke Tue Jan 1 09:02:30 2019 +0100 crystal-facet-uml (1.7.1) UNRELEASED; urgency=medium [ Andreas Warnke ] * user-doc and manpages are generated from docbook now * doubleclick on .cfu1 files starts crystal_facet_uml -- Andreas Warnke Wed Nov 21 19:30:59 2018 +0100 crystal-facet-uml (1.7.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * tree view allows to navigate interactively * new sibling and new child diagrams can be created in tree view * when deleting a diagram, unfocused windows show parent diagram * only local-scenario relationships are shown in timing, sequence and communication diagrams -- Andreas Warnke Thu Nov 1 16:08:58 2018 +0100 crystal-facet-uml (1.6.1) UNRELEASED; urgency=medium [ Andreas Warnke ] * debian archives are now build by dh_make and debuild * fix for only partly visible background text -- Andreas Warnke Mon Oct 15 23:42:16 2018 +0200 crystal-facet-uml (1.6.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * element configuration moved from bottom area to the right of the window * tree view shows current diagram in hierarchy -- Andreas Warnke Mon Oct 1 20:41:27 2018 +0200 crystal-facet-uml (1.5.1) UNRELEASED; urgency=medium [ Andreas Warnke ] * no automatic database upgrades anymore, use -f parameter * fix for persisting moved relationships in sequence and timing diagrams -- Andreas Warnke Sun Aug 26 20:10:58 2018 +0200 crystal-facet-uml (1.5.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * Sequence and timing diagrams show messages/transitions * In sequence and timing diagrams, messages/transitions can be moved * Box and list diagrams hide all relationships * List diagrams soft the classifiers by list_order now * Database format changed (list_oder field for classifiers), up- and downwards compatible. -- Andreas Warnke Sat Aug 25 15:06:01 2018 +0200 crystal-facet-uml (1.4.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * relationships can connect to ports * the repair-database function can detect and repair broken focused_feature keys in diagramelements * the repair-database function can detect and repair broken from/to_feature keys in relationships -- Andreas Warnke Fri May 11 10:32:23 2018 +0200 crystal-facet-uml (1.3.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * lifelines are created and removed automatically for timing, sequence and communication diagrams * lifelines are drawn and can be selected/edited * ports can be created/selected/edited and are drawn -- Andreas Warnke Sun Apr 1 11:22:16 2018 +0200 crystal-facet-uml (1.2.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * all relations to/from multiple classifier instances are drawn -- Andreas Warnke Sun Mar 4 13:34:26 2018 +0100 crystal-facet-uml (1.1.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * greyed-out classifiers also grey-out their contained features * sqlite updated from 3.10.2 to 3.21.0 * Database format changed. * A newer crystal_facet_uml can still open older database files (and immediately update the file format). * Older crystal_facet_uml cannot open database files created or opened by a newer crystal_facet_uml! * relations where source and destination are identical are beautified * for comments and requirements, the description is shown -- Andreas Warnke Tue Jan 23 20:58:34 2018 +0100 crystal-facet-uml (1.0.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * F7 in navigation view moves child diagram up and parent down * The text export contains IDs -- Andreas Warnke Wed Jan 3 17:58:38 2018 +0100 crystal-facet-uml (0.20.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * navigation mode: a newly initialized database shows a quick guide * navigation mode: root diagram has sky-blue background * orange background color marks new-object and new-diagram modes * link to the home page is added in the man page and on the startup screen * The 2nd click on the about button removes the about message * Ctrl-X/C/V,DEL work as expected during text editing * edit mode: Pink-selects elements only at the second click -- Andreas Warnke Tue Dec 26 17:11:33 2017 +0100 crystal-facet-uml (0.19.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * The default-names of new classifiers match their type * default-types of new objects fit to the diagram type and to the origin-classifier type now. * default-names of new objects are unique, no duplicate name errors unless forced * In new object mode, clicking into a possible parent classifiers creates a new child (depending on type) * children of CONTAINMENT relations are automatically embraced by _any_ ancestor * nicer layout when parents embrace CONTAINED children * Easier selection of the right relation in GUI_SKETCH_TOOLS_EDIT mode * Easier selection of classifiers in GUI_SKETCH_TOOLS_CREATE_OBJECT mode * Nicer layout: space area shall depend on the classifier type -- Andreas Warnke Sun Dec 10 11:36:30 2017 +0100 crystal-facet-uml (0.18.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * parent classifiers can contain children -- Andreas Warnke Sat Nov 4 18:55:43 2017 +0100 crystal-facet-uml (0.17.1) UNRELEASED; urgency=medium [ Andreas Warnke ] * fix for include paths on openSuSE Tumbleweed i586 -- Andreas Warnke Sat Oct 28 17:55:54 2017 +0200 crystal-facet-uml (0.17.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * Key control is possible: CTRL+C,V,X,Y,Z * Layout of relationships improved * Man page added -- Andreas Warnke Mon Oct 2 08:46:58 2017 +0200 crystal-facet-uml (0.16.2) UNRELEASED; urgency=medium [ Andreas Warnke ] * fix: install uses less global paths for app icon -- Andreas Warnke Mon Sep 11 16:30:00 2017 +0200 crystal-facet-uml (0.16.1) UNRELEASED; urgency=medium [ Andreas Warnke ] * fix: desktop file is included in src distribution -- Andreas Warnke Sun Sep 10 17:35:06 2017 +0200 crystal-facet-uml (0.16.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * Classifier drawings represent the classifier type -- Andreas Warnke Wed May 24 20:48:00 2017 +0200 crystal-facet-uml (0.15.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * Arrow, line and feather types of connectors are determined by relation type * A reset button clears the current selection * Relations are auto-layouted in a nicer way -- Andreas Warnke Fri Apr 14 18:03:58 2017 +0200 crystal-facet-uml (0.14.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * Classifiers are layouted avoiding overlaps -- Andreas Warnke Sat Mar 18 10:40:48 2017 +0100 crystal-facet-uml (0.13.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * The txt-file export contains features and relationships * The user can export pdf and ps formats * The user is able to import features from the clipboard * The user is able to export relationships and features to the clipboard -- Andreas Warnke Sat Feb 25 14:15:36 2017 +0100 crystal-facet-uml (0.12.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * Features can be created, modified, deleted (incl. undo/redo) -- Andreas Warnke Sun Feb 12 16:11:30 2017 +0100 crystal-facet-uml (0.11.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * Align objects vertically and horizontally (snap) * Edit new classifiers or relationships immediately -- Andreas Warnke Sun Feb 5 22:13:05 2017 +0100 crystal-facet-uml (0.10.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * Relationships can be created, modified, deleted (incl. undo/redo) * DB format changed: features.key is not UNIQUE anymore (compatible change) -- Andreas Warnke Sat Jan 28 07:32:48 2017 +0100 crystal-facet-uml (0.9.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * Mark and instantiate classifiers * Test the database for errors and fix them * Diagrams show also non-ascii names now -- Andreas Warnke Thu Dec 22 21:38:24 2016 +0100 crystal-facet-uml (0.8.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * Export of png and svg diagrams and txt descriptions * DB format changed: classifier.name is UNIQUE, features.key is UNIQUE (compatible change) -- Andreas Warnke Sun Dec 11 00:08:44 2016 +0100 crystal-facet-uml (0.7.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * The user can move classifiers -- Andreas Warnke Sat Nov 26 20:49:29 2016 +0100 crystal-facet-uml (0.6.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * cut+copy+paste allow to copy diagrams and classifiers to and from the clipboard -- Andreas Warnke Thu Oct 6 21:27:21 2016 +0200 crystal-facet-uml (0.5.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * The program integrates into a freedesktop.org desktop * rpm and deb installers are generated * undo/redo works for creating, modifying and deleting objects -- Andreas Warnke Fri Aug 12 05:56:31 2016 +0200 crystal-facet-uml (0.4.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * The user can delete classifiers and diagrams * DB format incompatible to version 0.3.0 (todo: in diagramelements, manually create the column "display_flags" as INTEGER) -- Andreas Warnke Sun Jul 3 11:52:47 2016 +0200 crystal-facet-uml (0.3.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * The user can select and switch the database file -- Andreas Warnke Sun May 22 15:22:46 2016 +0200 crystal-facet-uml (0.2.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * The user can create and rename classifiers like classes * DB format incompatible to version 0.01 -- Andreas Warnke Sun May 1 22:51:16 2016 +0200 crystal-facet-uml (0.1.0) UNRELEASED; urgency=medium [ Andreas Warnke ] * The user can create, rename and navigate diagrams -- Andreas Warnke Thu Mar 31 20:28:08 2016 +0200 crystal-facet-uml-1.63.3/LICENSE.txt000066400000000000000000000267461500562027500170040ustar00rootroot00000000000000 crystal-facet-uml is provided under the Apache-2.0 License. See below. crystal-facet-uml dynamically links to libraries - glib - gdk - gtk - atk - freetype - cairo - pango - gio-unix - sqlite3 It relies on - a POSIX OS The build environment requires - a c compiler and linker - cmake and make - doxygen ---------------------------------------------------------------------------- Apache License Version 2.0, January 2004 http://www.apache.org/licenses/ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION 1. Definitions. "License" shall mean the terms and conditions for use, reproduction, and distribution as defined by Sections 1 through 9 of this document. "Licensor" shall mean the copyright owner or entity authorized by the copyright owner that is granting the License. "Legal Entity" shall mean the union of the acting entity and all other entities that control, are controlled by, or are under common control with that entity. For the purposes of this definition, "control" means (i) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (ii) ownership of fifty percent (50%) or more of the outstanding shares, or (iii) beneficial ownership of such entity. "You" (or "Your") shall mean an individual or Legal Entity exercising permissions granted by this License. "Source" form shall mean the preferred form for making modifications, including but not limited to software source code, documentation source, and configuration files. "Object" form shall mean any form resulting from mechanical transformation or translation of a Source form, including but not limited to compiled object code, generated documentation, and conversions to other media types. "Work" shall mean the work of authorship, whether in Source or Object form, made available under the License, as indicated by a copyright notice that is included in or attached to the work (an example is provided in the Appendix below). "Derivative Works" shall mean any work, whether in Source or Object form, that is based on (or derived from) the Work and for which the editorial revisions, annotations, elaborations, or other modifications represent, as a whole, an original work of authorship. For the purposes of this License, Derivative Works shall not include works that remain separable from, or merely link (or bind by name) to the interfaces of, the Work and Derivative Works thereof. "Contribution" shall mean any work of authorship, including the original version of the Work and any modifications or additions to that Work or Derivative Works thereof, that is intentionally submitted to Licensor for inclusion in the Work by the copyright owner or by an individual or Legal Entity authorized to submit on behalf of the copyright owner. For the purposes of this definition, "submitted" means any form of electronic, verbal, or written communication sent to the Licensor or its representatives, including but not limited to communication on electronic mailing lists, source code control systems, and issue tracking systems that are managed by, or on behalf of, the Licensor for the purpose of discussing and improving the Work, but excluding communication that is conspicuously marked or otherwise designated in writing by the copyright owner as "Not a Contribution." "Contributor" shall mean Licensor and any individual or Legal Entity on behalf of whom a Contribution has been received by Licensor and subsequently incorporated within the Work. 2. Grant of Copyright License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable copyright license to reproduce, prepare Derivative Works of, publicly display, publicly perform, sublicense, and distribute the Work and such Derivative Works in Source or Object form. 3. Grant of Patent License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable (except as stated in this section) patent license to make, have made, use, offer to sell, sell, import, and otherwise transfer the Work, where such license applies only to those patent claims licensable by such Contributor that are necessarily infringed by their Contribution(s) alone or by combination of their Contribution(s) with the Work to which such Contribution(s) was submitted. If You institute patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Work or a Contribution incorporated within the Work constitutes direct or contributory patent infringement, then any patent licenses granted to You under this License for that Work shall terminate as of the date such litigation is filed. 4. Redistribution. You may reproduce and distribute copies of the Work or Derivative Works thereof in any medium, with or without modifications, and in Source or Object form, provided that You meet the following conditions: (a) You must give any other recipients of the Work or Derivative Works a copy of this License; and (b) You must cause any modified files to carry prominent notices stating that You changed the files; and (c) You must retain, in the Source form of any Derivative Works that You distribute, all copyright, patent, trademark, and attribution notices from the Source form of the Work, excluding those notices that do not pertain to any part of the Derivative Works; and (d) If the Work includes a "NOTICE" text file as part of its distribution, then any Derivative Works that You distribute must include a readable copy of the attribution notices contained within such NOTICE file, excluding those notices that do not pertain to any part of the Derivative Works, in at least one of the following places: within a NOTICE text file distributed as part of the Derivative Works; within the Source form or documentation, if provided along with the Derivative Works; or, within a display generated by the Derivative Works, if and wherever such third-party notices normally appear. The contents of the NOTICE file are for informational purposes only and do not modify the License. You may add Your own attribution notices within Derivative Works that You distribute, alongside or as an addendum to the NOTICE text from the Work, provided that such additional attribution notices cannot be construed as modifying the License. You may add Your own copyright statement to Your modifications and may provide additional or different license terms and conditions for use, reproduction, or distribution of Your modifications, or for any such Derivative Works as a whole, provided Your use, reproduction, and distribution of the Work otherwise complies with the conditions stated in this License. 5. Submission of Contributions. Unless You explicitly state otherwise, any Contribution intentionally submitted for inclusion in the Work by You to the Licensor shall be under the terms and conditions of this License, without any additional terms or conditions. Notwithstanding the above, nothing herein shall supersede or modify the terms of any separate license agreement you may have executed with Licensor regarding such Contributions. 6. Trademarks. This License does not grant permission to use the trade names, trademarks, service marks, or product names of the Licensor, except as required for reasonable and customary use in describing the origin of the Work and reproducing the content of the NOTICE file. 7. Disclaimer of Warranty. Unless required by applicable law or agreed to in writing, Licensor provides the Work (and each Contributor provides its Contributions) on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied, including, without limitation, any warranties or conditions of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. You are solely responsible for determining the appropriateness of using or redistributing the Work and assume any risks associated with Your exercise of permissions under this License. 8. Limitation of Liability. In no event and under no legal theory, whether in tort (including negligence), contract, or otherwise, unless required by applicable law (such as deliberate and grossly negligent acts) or agreed to in writing, shall any Contributor be liable to You for damages, including any direct, indirect, special, incidental, or consequential damages of any character arising as a result of this License or out of the use or inability to use the Work (including but not limited to damages for loss of goodwill, work stoppage, computer failure or malfunction, or any and all other commercial damages or losses), even if such Contributor has been advised of the possibility of such damages. 9. Accepting Warranty or Additional Liability. While redistributing the Work or Derivative Works thereof, You may choose to offer, and charge a fee for, acceptance of support, warranty, indemnity, or other liability obligations and/or rights consistent with this License. However, in accepting such obligations, You may act only on Your own behalf and on Your sole responsibility, not on behalf of any other Contributor, and only if You agree to indemnify, defend, and hold each Contributor harmless for any liability incurred by, or claims asserted against, such Contributor by reason of your accepting any such warranty or additional liability. END OF TERMS AND CONDITIONS APPENDIX: How to apply the Apache License to your work. To apply the Apache License to your work, attach the following boilerplate notice, with the fields enclosed by brackets "[]" replaced with your own identifying information. (Don't include the brackets!) The text should be enclosed in the appropriate comment syntax for the file format. We also recommend that a file or class name and description of purpose be included on the same "printed page" as the copyright notice for easier identification within third-party archives. Copyright [yyyy] [name of copyright owner] Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. crystal-facet-uml-1.63.3/README.md000066400000000000000000000045711500562027500164300ustar00rootroot00000000000000 ![ScreenShot](documentation/user_manual/1_introduction_banner.svg) crystal-facet-uml ============= crystal-facet-uml creates sysml/uml diagrams to document system and software architecture. Like a crystal shows different facets of the same thing, this application shows different views of the same system. ![ScreenShot](documentation/user_manual/screenshot_1.png) As software architect, you create a set of diagrams describing use-cases, requirements, structural views, behavioral and deployment views. These views show selected elements and their relationships. crystal-facet-uml keeps element names and element hierarchies consistent. This tool runs on your local PC. It stores the model data in a json-based file which can be stored in git, branched and merged together with your source code. crystal-facet-uml exports diagrams in svg, pdf, ps and png formats which can be used in text processing systems like DocBook, html, LaTeX. ![ScreenShot](documentation/user_manual/screenshot_2.png) ![ScreenShot](documentation/user_manual/screenshot_3.png) How to use this program is described in the [User Manual](https://andreaswarnke.de/crystal-facet-uml/crystal-facet-uml_documentation.pdf) . Install crystal-facet-uml ----------- This section describes how to install a binary package. Debian/Ubuntu/Raspbian: > sudo apt install crystal-facet-uml openSuSE: > sudo zypper addrepo https://download.opensuse.org/repositories/devel:/tools/openSUSE_Tumbleweed devel_tools_tumble > # or sudo zypper addrepo https://download.opensuse.org/repositories/devel:/tools/15.5 devel_tools_15.5 > sudo zypper refresh > sudo zypper install crystal-facet-uml Windows/wine: Fetch a prebuild binary version from e.g. https://www.heise.de/download/product/crystal-facet-uml/ or https://sourceforge.net/projects/crystal-facet-uml/ and unpack it: > unzip crystal-facet-uml_1.x.0-1_win64.zip How to build from source ----------- Building from source is described in [./build](build) . About ----------- > Version: see META_VERSION_STR in [meta_version.inl](main/include/meta/meta_version.inl) > > Author and Copyright: 2016-2025 Andreas Warnke > > License: Apache 2.0 License crystal-facet-uml-1.63.3/build/000077500000000000000000000000001500562027500162415ustar00rootroot00000000000000crystal-facet-uml-1.63.3/build/README.md000066400000000000000000000036131500562027500175230ustar00rootroot00000000000000 Build crystal-facet-uml ============= How to build from source ----------- Building from source is described in this section. debian/ubuntu/raspberry-os: > sudo apt install gcc cmake make > > sudo apt install libgtk-4-dev libsqlite3-dev > > sudo apt install devscripts # for debian build, includes build-essential > > sudo apt install yamllint # for debian script checker, possibly not needed > > sudo apt install debsigs # for signing debian packages, possibly not needed > > sudo apt install dblatex xmlto librsvg2-bin # for user documentation, e.g. rsvg-convert > > sudo apt install doxygen # for source code documentation > > sudo apt install lcov # for reporting test coverage > > sudo apt install curl # for installing rust > > curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh # for running qualification tests or icon_artist resource generator > mkdir my_build && cd my_build > > cmake -DCMAKE_BUILD_TYPE=Release ../crystal-facet-uml/ # adapt the source directory path > > make crystal-facet-uml > > sudo make install openSuSE: > sudo zypper install gcc cmake > > sudo zypper install gtk4-devel sqlite3-devel > > sudo zypper install devscripts # for debian build, includes build-essential > > sudo zypper install dblatex xmlto # for user documentation > > sudo zypper install doxygen # for source code documentation > > sudo zypper install fakeroot # to build debian archives > > sudo zypper install debhelper # to build debian archives > > sudo zypper install lcov # for reporting test coverage > > curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh # for running qualification tests or icon_artist resource generator > mkdir my_build && cd my_build > > cmake -DCMAKE_BUILD_TYPE=Release ../crystal-facet-uml/ # adapt the source directory path > > make crystal-facet-uml > > sudo make install windows: > see [./msys2/README.md](msys2) crystal-facet-uml-1.63.3/build/examples/000077500000000000000000000000001500562027500200575ustar00rootroot00000000000000crystal-facet-uml-1.63.3/build/examples/Makefile000066400000000000000000000131761500562027500215270ustar00rootroot00000000000000.PHONY: all all: all_export_test mouse_droid/mouse_droid.pdf mouse_droid/mouse_droid.html quality/quality.pdf quality/quality.html self_architecture/self_architecture.pdf self_architecture/self_architecture.html pencil_tests/pencil_tests.html info ARCDIR=../../documentation/architecture SRCDIR=../../documentation/examples INSTALLDIR=../../documentation/examples mouse_droid/mouse_droid.html: $(SRCDIR)/mouse_droid.cfuJ mkdir -p mouse_droid crystal-facet-uml -e $(SRCDIR)/mouse_droid.cfuJ html mouse_droid mouse_droid/mouse_droid.pdf: $(SRCDIR)/mouse_droid.cfuJ mkdir -p mouse_droid crystal-facet-uml -e $(SRCDIR)/mouse_droid.cfuJ docbook mouse_droid [ ! -f /home/andi/Downloads/docbook.xsd ] || xmllint --noout --schema /home/andi/Downloads/docbook.xsd mouse_droid/mouse_droid.xml (cd mouse_droid && dblatex mouse_droid.xml) quality/quality.html: $(SRCDIR)/quality.cfuJ mkdir -p quality crystal-facet-uml -e $(SRCDIR)/quality.cfuJ html quality quality/quality.pdf: $(SRCDIR)/quality.cfuJ mkdir -p quality crystal-facet-uml -e $(SRCDIR)/quality.cfuJ docbook quality [ ! -f /home/andi/Downloads/docbook.xsd ] || xmllint --noout --schema /home/andi/Downloads/docbook.xsd quality/quality.xml (cd quality && dblatex quality.xml) self_architecture/self_architecture.html: $(ARCDIR)/self_architecture.cfuJ mkdir -p self_architecture crystal-facet-uml -e $(ARCDIR)/self_architecture.cfuJ html self_architecture self_architecture/self_architecture.pdf: $(ARCDIR)/self_architecture.cfuJ mkdir -p self_architecture crystal-facet-uml -e $(ARCDIR)/self_architecture.cfuJ docbook self_architecture [ ! -f /home/andi/Downloads/docbook.xsd ] || xmllint --noout --schema /home/andi/Downloads/docbook.xsd self_architecture/self_architecture (cd self_architecture && dblatex self_architecture.xml) pencil_tests/pencil_tests.html: $(SRCDIR)/pencil_tests.cfuJ mkdir -p pencil_tests crystal-facet-uml -e $(SRCDIR)/pencil_tests.cfuJ html pencil_tests .PHONY: all_export_test all_export_test: export_test/export_test_08_block.xmi export_test/export_test_10_constraint.xmi export_test/export_test_11_class.xmi export_test/export_test_11_component.xmi export_test/ export_test/export_test_12_package.xmi export_test/export_test_12_profile.xmi export_test/export_test_14_state.xmi export_test/export_test_15_activity.xmi export_test/export_test_16_requirement.xmi export_test/export_test_17_sequence.xmi export_test/export_test_17_interaction.xmi export_test/export_test_18_usecase.xmi export_test/export_test_19_deployment.xmi export_test/export_test_08_block.xmi: $(SRCDIR)/export_test_08_block.cfuJ mkdir -p export_test crystal-facet-uml -e $(SRCDIR)/export_test_08_block.cfuJ xmi export_test export_test/export_test_11_class.xmi: $(SRCDIR)/export_test_11_class.cfuJ mkdir -p export_test crystal-facet-uml -e $(SRCDIR)/export_test_11_class.cfuJ xmi export_test export_test/export_test_10_constraint.xmi: $(SRCDIR)/export_test_10_constraint.cfuJ mkdir -p export_test crystal-facet-uml -e $(SRCDIR)/export_test_10_constraint.cfuJ xmi export_test export_test/export_test_11_component.xmi: $(SRCDIR)/export_test_11_component.cfuJ mkdir -p export_test crystal-facet-uml -e $(SRCDIR)/export_test_11_component.cfuJ xmi export_test export_test/export_test_12_package.xmi: $(SRCDIR)/export_test_12_package.cfuJ mkdir -p export_test crystal-facet-uml -e $(SRCDIR)/export_test_12_package.cfuJ xmi export_test export_test/export_test_12_profile.xmi: $(SRCDIR)/export_test_12_profile.cfuJ mkdir -p export_test crystal-facet-uml -e $(SRCDIR)/export_test_12_profile.cfuJ xmi export_test export_test/export_test_14_state.xmi: $(SRCDIR)/export_test_14_state.cfuJ mkdir -p export_test crystal-facet-uml -e $(SRCDIR)/export_test_14_state.cfuJ xmi export_test export_test/export_test_15_activity.xmi: $(SRCDIR)/export_test_15_activity.cfuJ mkdir -p export_test crystal-facet-uml -e $(SRCDIR)/export_test_15_activity.cfuJ xmi export_test export_test/export_test_16_requirement.xmi: $(SRCDIR)/export_test_16_requirement.cfuJ mkdir -p export_test crystal-facet-uml -e $(SRCDIR)/export_test_16_requirement.cfuJ xmi export_test export_test/export_test_17_sequence.xmi: $(SRCDIR)/export_test_17_sequence.cfuJ mkdir -p export_test crystal-facet-uml -e $(SRCDIR)/export_test_17_sequence.cfuJ xmi export_test export_test/export_test_17_interaction.xmi: $(SRCDIR)/export_test_17_interaction.cfuJ mkdir -p export_test crystal-facet-uml -e $(SRCDIR)/export_test_17_interaction.cfuJ xmi export_test export_test/export_test_18_usecase.xmi: $(SRCDIR)/export_test_18_usecase.cfuJ mkdir -p export_test crystal-facet-uml -e $(SRCDIR)/export_test_18_usecase.cfuJ xmi export_test export_test/export_test_19_deployment.xmi: $(SRCDIR)/export_test_19_deployment.cfuJ mkdir -p export_test crystal-facet-uml -e $(SRCDIR)/export_test_19_deployment.cfuJ xmi export_test .PHONY: info info: @printf "== call \\e[33;1m make install \\e[0m to update the files in folder ../../documentation/examples ==\n" .PHONY: install install: all_export_test cp -frv export_test $(INSTALLDIR)/ .PHONY: clean clean: rm -fr mouse_droid quality pencil_tests export_test self_architecture # Copyright 2021-2025 Andreas Warnke # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. crystal-facet-uml-1.63.3/build/icon_artist/000077500000000000000000000000001500562027500205575ustar00rootroot00000000000000crystal-facet-uml-1.63.3/build/icon_artist/Cargo.toml000066400000000000000000000003261500562027500225100ustar00rootroot00000000000000[package] name = "icon-artist" version = "0.2.0" # Rust edition: edition = "2021" # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html [dependencies] raqote = "0.8.5" crystal-facet-uml-1.63.3/build/icon_artist/architecture.cfuJ000066400000000000000000000764441500562027500240710ustar00rootroot00000000000000{ "head": { "encoding": "utf-8", "structure_format": "rfc-8259 w/o hexadecimal escapes", "format": "cfu-json", "major_version": 1, "minor_version": 1, "generator_name": "crystal-facet-uml", "generator_version": "1.47.0" } , "views": [ { "diagram": { "id": 1, "diagram_type": 10, "type": "UMLUseCaseDiagram", "name": "icon-artist overview", "description": [ "" ], "list_order": 0, "display_flags": 0, "uuid": "e1252287-b973-4ef8-b83e-18bc0a4658d4", "diagramelements": [ { "id": 1, "display_flags": 0, "classifier_name": "icon-artist", "node": "31707716-bf0d-44e2-94a3-1305d5c5315e", "uuid": "46a8baea-c4fe-4502-b7c9-a275b306dc85" }, { "id": 2, "display_flags": 0, "classifier_name": "documentation editor", "node": "1436c2c7-73fd-402e-b44c-a36f3bcc32fa", "uuid": "88ada4bb-934b-490a-9178-c847b3bdda1f" }, { "id": 3, "display_flags": 0, "classifier_name": "generate set of svg-images with svg-paths", "node": "fde446de-0fbe-4596-a13a-220455e92670", "uuid": "214c37d8-1bb7-4b89-895d-181ae67ee6a1" }, { "id": 4, "display_flags": 0, "classifier_name": "generate docbook showing the svg-paths as text", "node": "893cc0c5-0b2c-4e33-bc81-60ae17132ffa", "uuid": "e5d2b36f-51be-4c96-889b-c39951ada969" }, { "id": 24, "display_flags": 0, "classifier_name": "generate GdkPixBuf images", "node": "7853ef51-4d9e-4ecc-9c64-31f73676c0a3", "uuid": "1274937b-2a2a-4b9c-bab9-07a75bfaf081" } ] } }, { "diagram": { "id": 2, "diagram_type": 14, "type": "UMLInteractionDiagram/communication", "name": "Context", "description": [ "" ], "list_order": 32768, "display_flags": 0, "parent_name": "icon-artist overview", "parent": "e1252287-b973-4ef8-b83e-18bc0a4658d4", "uuid": "f304387c-6d1f-4eb0-937a-862e04bda216", "diagramelements": [ { "id": 5, "display_flags": 0, "classifier_name": "icon-artist", "node": "5852a6ad-fa1a-473f-a76e-e091ce60aa58", "uuid": "ec5df933-1220-4538-b34a-c3cd973ff501" }, { "id": 6, "display_flags": 0, "classifier_name": "documentation editor", "node": "fbd1efc8-b7c8-4150-9912-dc4a122d5d0d", "uuid": "61dddae9-f494-4a58-b6a8-8694b85ad07f" }, { "id": 7, "display_flags": 0, "classifier_name": "svg-icons for documentation", "node": "e90d54ec-7894-47fc-8fcb-893ff449e344", "uuid": "80e4d944-c1f6-4bc3-91d4-cc4b94de781e" }, { "id": 8, "display_flags": 0, "classifier_name": "docbook showing text of svg-path elements", "node": "f608ca6e-2c76-486b-bc97-724756bef806", "uuid": "3f6ec17f-5ff3-4c50-bb4a-9f6796cde64e" } ] } }, { "diagram": { "id": 3, "diagram_type": 31, "type": "UMLComponentDiagram", "name": "Structure", "description": [ "" ], "list_order": 65536, "display_flags": 0, "parent_name": "icon-artist overview", "parent": "e1252287-b973-4ef8-b83e-18bc0a4658d4", "uuid": "63f4dcb1-f928-4138-b65b-430cdb62ab54", "diagramelements": [ { "id": 9, "display_flags": 0, "classifier_name": "icon-artist", "node": "31707716-bf0d-44e2-94a3-1305d5c5315e", "uuid": "4f8708d7-8ade-4edc-89c9-1961cded973c" }, { "id": 10, "display_flags": 0, "classifier_name": "render", "node": "ec0de729-88f4-429f-9b10-f0762a4183c7", "uuid": "b5c6ca90-bebc-4472-b120-fbf2c7bb2afd" }, { "id": 11, "display_flags": 0, "classifier_name": "model", "node": "41102a65-f6a8-4e51-a884-2afa4e222de0", "uuid": "95c164a0-1c35-4fdc-9ca1-02af0a6676cb" }, { "id": 12, "display_flags": 0, "classifier_name": "icon_writer", "node": "f0d393cd-2646-4369-b429-4b09712bdb49", "uuid": "a0b2c62d-3c56-4600-9c74-701347b2b624" }, { "id": 13, "display_flags": 0, "classifier_name": "icon_data", "node": "5c91a819-3ba8-4214-b2be-ae0454889a5b", "uuid": "24c77134-ba5c-480b-a047-fd72bb4aaac0" }, { "id": 14, "display_flags": 0, "classifier_name": "render_svg", "node": "0da9c5cf-40ea-410c-8c08-845c2a08df79", "uuid": "c1e7ef04-f34e-4ef4-bfa2-adc6016854db" }, { "id": 15, "display_flags": 0, "classifier_name": "geometry", "node": "18040e78-ed42-4c92-9742-e89b147cd8d5", "uuid": "5e0a7a11-085a-4324-8c4e-755cfb90c6c6" }, { "id": 20, "display_flags": 0, "classifier_name": "main", "node": "4ea42b29-386f-4db4-bb5d-a5087524f0cb", "uuid": "7fb3e036-096d-46a1-b4a8-7311eedd02bf" }, { "id": 21, "display_flags": 0, "classifier_name": "gui_icon", "node": "3b7f5dbb-47c6-4ed1-80e7-a6af17bbe55c", "uuid": "fe009fe1-7162-48be-adef-ab5c12b448b5" }, { "id": 22, "display_flags": 0, "classifier_name": "icon", "node": "bfc86773-796f-4f50-a7ed-ba4ced0e6564", "uuid": "b24eab9d-1910-4347-90a3-2fec239828d0" } ] } }, { "diagram": { "id": 4, "diagram_type": 14, "type": "UMLInteractionDiagram/communication", "name": "Behavior", "description": [ "" ], "list_order": 98304, "display_flags": 0, "parent_name": "icon-artist overview", "parent": "e1252287-b973-4ef8-b83e-18bc0a4658d4", "uuid": "4b054cc3-99dd-44d1-a41d-78b06c8066fc", "diagramelements": [ { "id": 16, "display_flags": 0, "classifier_name": "icon_writer", "node": "348addb8-501f-4761-b846-b5e17b9f1a96", "uuid": "b647bf11-e80c-4946-9d8b-c2313d8d0498" }, { "id": 17, "display_flags": 0, "classifier_name": "icon_data", "node": "19e782c2-4792-4011-b3db-ca4a88d70a23", "uuid": "ed7db7ba-bbed-4003-8b06-767ebee10268" }, { "id": 18, "display_flags": 0, "classifier_name": "render_svg", "node": "aca5b62d-23e2-4011-808a-9c3389b41616", "uuid": "a02c49ad-f524-4820-a64f-9b251f320f95" }, { "id": 19, "display_flags": 0, "classifier_name": "main", "node": "7fbb0c9c-fcc0-4fc0-ac4a-16c77757ea84", "uuid": "a499210f-74b9-478e-ac14-56777295ef30" }, { "id": 23, "display_flags": 33554432, "display_tags": "GrayOut", "classifier_name": "gui_icon", "node": "4488908d-db57-479c-882d-af210f5b2c01", "uuid": "77fa724a-8bb2-4750-8c08-1bf9308e47ed" } ] } } ] , "nodes": [ { "classifier": { "id": 1, "main_type": 102, "type": "Component", "name": "icon-artist", "description": [ "" ], "x_order": -873942120, "y_order": -578347165, "list_order": -411071867, "uuid": "31707716-bf0d-44e2-94a3-1305d5c5315e", "features": [ { "id": 1, "main_type": 3, "type": "Lifeline", "key": "", "description": [ "" ], "list_order": 0, "uuid": "5852a6ad-fa1a-473f-a76e-e091ce60aa58" }, { "id": 5, "main_type": 2, "type": "Port", "key": "main()", "description": [ "" ], "list_order": 484181088, "uuid": "0f576371-50da-499e-b965-891127882c24" } ] } }, { "classifier": { "id": 2, "main_type": 100, "type": "Actor", "name": "documentation editor", "description": [ "" ], "x_order": -1635827412, "y_order": -732780842, "list_order": -782230759, "uuid": "1436c2c7-73fd-402e-b44c-a36f3bcc32fa", "features": [ { "id": 2, "main_type": 3, "type": "Lifeline", "key": "", "description": [ "" ], "list_order": 0, "uuid": "fbd1efc8-b7c8-4150-9912-dc4a122d5d0d" } ] } }, { "classifier": { "id": 3, "main_type": 101, "type": "UseCase", "name": "generate set of svg-images with svg-paths", "description": [ "" ], "x_order": -845832921, "y_order": -782230759, "list_order": -368194158, "uuid": "fde446de-0fbe-4596-a13a-220455e92670", "features": [ ] } }, { "classifier": { "id": 4, "main_type": 101, "type": "UseCase", "name": "generate docbook showing the svg-paths as text", "description": [ "" ], "x_order": 949409084, "y_order": -782230759, "list_order": -376384566, "uuid": "893cc0c5-0b2c-4e33-bc81-60ae17132ffa", "features": [ ] } }, { "classifier": { "id": 5, "main_type": 127, "type": "Artifact", "name": "svg-icons for documentation", "description": [ "" ], "x_order": 833429315, "y_order": -732780842, "list_order": -732780842, "uuid": "162686e4-d0d5-4460-b4a3-3fede23bf93d", "features": [ { "id": 3, "main_type": 3, "type": "Lifeline", "key": "", "description": [ "" ], "list_order": 0, "uuid": "e90d54ec-7894-47fc-8fcb-893ff449e344" } ] } }, { "classifier": { "id": 6, "main_type": 127, "type": "Artifact", "name": "docbook showing text of svg-path elements", "description": [ "" ], "x_order": 833429315, "y_order": -411071867, "list_order": -411071867, "uuid": "47f1d6d5-28c8-41bc-a838-d71380907487", "features": [ { "id": 4, "main_type": 3, "type": "Lifeline", "key": "", "description": [ "" ], "list_order": 0, "uuid": "f608ca6e-2c76-486b-bc97-724756bef806" } ] } }, { "classifier": { "id": 7, "main_type": 121, "type": "Component", "name": "render", "description": [ "" ], "x_order": -921600509, "y_order": -608600552, "list_order": -608600552, "uuid": "ec0de729-88f4-429f-9b10-f0762a4183c7", "features": [ ] } }, { "classifier": { "id": 8, "main_type": 121, "type": "Component", "name": "model", "description": [ "" ], "x_order": 32981326, "y_order": -623707360, "list_order": -623707360, "uuid": "41102a65-f6a8-4e51-a884-2afa4e222de0", "features": [ ] } }, { "classifier": { "id": 9, "main_type": 125, "type": "Class", "name": "icon_writer", "description": [ "" ], "x_order": -1171633862, "y_order": -8454772, "list_order": -693209781, "uuid": "f0d393cd-2646-4369-b429-4b09712bdb49", "features": [ { "id": 6, "main_type": 3, "type": "Lifeline", "key": "", "description": [ "" ], "list_order": 0, "uuid": "348addb8-501f-4761-b846-b5e17b9f1a96" } ] } }, { "classifier": { "id": 10, "main_type": 125, "type": "Class", "name": "icon_data", "description": [ "A set of icons, each can draw itself into a VecRenderer" ], "x_order": 129583284, "y_order": -8454772, "list_order": -623707360, "uuid": "5c91a819-3ba8-4214-b2be-ae0454889a5b", "features": [ { "id": 7, "main_type": 3, "type": "Lifeline", "key": "", "description": [ "" ], "list_order": 0, "uuid": "19e782c2-4792-4011-b3db-ca4a88d70a23" } ] } }, { "classifier": { "id": 11, "main_type": 125, "type": "Class", "name": "render_svg", "description": [ "A VecRenderer transforms drawing commands into svg output." ], "x_order": -1171633862, "y_order": 124360990, "list_order": 124360990, "uuid": "0da9c5cf-40ea-410c-8c08-845c2a08df79", "features": [ { "id": 8, "main_type": 3, "type": "Lifeline", "key": "", "description": [ "" ], "list_order": 0, "uuid": "aca5b62d-23e2-4011-808a-9c3389b41616" } ] } }, { "classifier": { "id": 12, "main_type": 124, "type": "Package", "name": "geometry", "description": [ "A collection of geometric objects and drawing directives" ], "x_order": 129583284, "y_order": 124360990, "list_order": -542227524, "uuid": "18040e78-ed42-4c92-9742-e89b147cd8d5", "features": [ ] } }, { "classifier": { "id": 13, "main_type": 125, "type": "Class", "name": "main", "description": [ "" ], "x_order": -1171633862, "y_order": -1301637532, "list_order": -1301637532, "uuid": "4ea42b29-386f-4db4-bb5d-a5087524f0cb", "features": [ { "id": 9, "main_type": 3, "type": "Lifeline", "key": "", "description": [ "" ], "list_order": 0, "uuid": "7fbb0c9c-fcc0-4fc0-ac4a-16c77757ea84" }, { "id": 10, "main_type": 1, "type": "Operation", "key": "main()", "description": [ "" ], "list_order": 32768, "uuid": "55cb9067-a7e4-441a-820c-13d5e21f0766" } ] } }, { "classifier": { "id": 14, "main_type": 125, "type": "Class", "name": "gui_icon", "description": [ "" ], "x_order": 129583284, "y_order": -1301637532, "list_order": 31265024, "uuid": "3b7f5dbb-47c6-4ed1-80e7-a6af17bbe55c", "features": [ { "id": 11, "main_type": 3, "type": "Lifeline", "key": "", "description": [ "" ], "list_order": 0, "uuid": "4488908d-db57-479c-882d-af210f5b2c01" } ] } }, { "classifier": { "id": 15, "main_type": 125, "type": "Class", "name": "icon", "description": [ "" ], "x_order": 639870090, "y_order": 124360990, "list_order": 50186937, "uuid": "bfc86773-796f-4f50-a7ed-ba4ced0e6564", "features": [ ] } }, { "classifier": { "id": 16, "main_type": 101, "type": "UseCase", "name": "generate GdkPixBuf images", "description": [ "" ], "x_order": -289748453, "y_order": -755233055, "list_order": -755233055, "uuid": "7853ef51-4d9e-4ecc-9c64-31f73676c0a3", "features": [ ] } } ] , "edges": [ { "relationship": { "id": 1, "main_type": 300, "type": "Association", "name": "", "description": [ "" ], "list_order": -368194158, "from_classifier_name": "icon-artist", "to_classifier_name": "generate set of svg-images with svg-paths", "from_node": "31707716-bf0d-44e2-94a3-1305d5c5315e", "to_node": "fde446de-0fbe-4596-a13a-220455e92670", "uuid": "e1673a74-f7b6-43d3-ba7f-afcf06c72d65" } }, { "relationship": { "id": 2, "main_type": 300, "type": "Association", "name": "", "description": [ "" ], "list_order": -376384566, "from_classifier_name": "icon-artist", "to_classifier_name": "generate docbook showing the svg-paths as text", "from_node": "31707716-bf0d-44e2-94a3-1305d5c5315e", "to_node": "893cc0c5-0b2c-4e33-bc81-60ae17132ffa", "uuid": "36204ace-9364-4151-a20b-51f84841aa08" } }, { "relationship": { "id": 6, "main_type": 221, "type": "Message", "name": "generate self-explaining icons", "description": [ "" ], "list_order": 65536, "from_classifier_name": "icon-artist", "from_feature_key": "", "to_classifier_name": "svg-icons for documentation", "to_feature_key": "", "from_node": "5852a6ad-fa1a-473f-a76e-e091ce60aa58", "to_node": "e90d54ec-7894-47fc-8fcb-893ff449e344", "uuid": "81995180-12b6-4631-bd26-11f2aad9a57a" } }, { "relationship": { "id": 7, "main_type": 221, "type": "Message", "name": "generate svg-path elements for usage", "description": [ "" ], "list_order": 98304, "from_classifier_name": "icon-artist", "from_feature_key": "", "to_classifier_name": "docbook showing text of svg-path elements", "to_feature_key": "", "from_node": "5852a6ad-fa1a-473f-a76e-e091ce60aa58", "to_node": "f608ca6e-2c76-486b-bc97-724756bef806", "uuid": "25ed6055-5ac5-499d-88e8-0a27e997f7b1" } }, { "relationship": { "id": 8, "main_type": 300, "type": "Association", "name": "", "description": [ "" ], "list_order": -608600552, "from_classifier_name": "icon-artist", "to_classifier_name": "render", "from_node": "31707716-bf0d-44e2-94a3-1305d5c5315e", "to_node": "ec0de729-88f4-429f-9b10-f0762a4183c7", "uuid": "2688f4ef-c8b0-437a-91fe-714e3068a904" } }, { "relationship": { "id": 9, "main_type": 300, "type": "Association", "name": "", "description": [ "" ], "list_order": -623707360, "from_classifier_name": "icon-artist", "to_classifier_name": "model", "from_node": "31707716-bf0d-44e2-94a3-1305d5c5315e", "to_node": "41102a65-f6a8-4e51-a884-2afa4e222de0", "uuid": "1785e076-88f3-49a0-b08d-bffc5d0ff6de" } }, { "relationship": { "id": 23, "main_type": 300, "type": "Association", "name": "", "description": [ "" ], "list_order": 124426526, "from_classifier_name": "icon-artist", "to_classifier_name": "main", "from_node": "31707716-bf0d-44e2-94a3-1305d5c5315e", "to_node": "4ea42b29-386f-4db4-bb5d-a5087524f0cb", "uuid": "7a12b64d-643f-4db9-9b78-f6c0bdfee29c" } }, { "relationship": { "id": 25, "main_type": 200, "type": "Association", "name": "", "description": [ "" ], "list_order": 124492062, "from_classifier_name": "icon-artist", "from_feature_key": "main()", "to_classifier_name": "main", "to_feature_key": "main()", "from_node": "0f576371-50da-499e-b965-891127882c24", "to_node": "55cb9067-a7e4-441a-820c-13d5e21f0766", "uuid": "1aef99c1-97dd-4b7b-a4cc-a291833eed1a" } }, { "relationship": { "id": 30, "main_type": 300, "type": "Association", "name": "", "description": [ "" ], "list_order": -755233055, "from_classifier_name": "icon-artist", "to_classifier_name": "generate GdkPixBuf images", "from_node": "31707716-bf0d-44e2-94a3-1305d5c5315e", "to_node": "7853ef51-4d9e-4ecc-9c64-31f73676c0a3", "uuid": "f7e89b0f-c851-47f5-b647-b34f6e8ee065" } }, { "relationship": { "id": 3, "main_type": 200, "type": "Association", "name": "", "description": [ "" ], "list_order": 32768, "from_classifier_name": "documentation editor", "to_classifier_name": "generate set of svg-images with svg-paths", "from_node": "1436c2c7-73fd-402e-b44c-a36f3bcc32fa", "to_node": "fde446de-0fbe-4596-a13a-220455e92670", "uuid": "9324417c-0256-42b3-878b-f5b20412e582" } }, { "relationship": { "id": 5, "main_type": 221, "type": "Message", "name": "trigger generation of icons", "description": [ "" ], "list_order": 32768, "from_classifier_name": "documentation editor", "from_feature_key": "", "to_classifier_name": "icon-artist", "to_feature_key": "", "from_node": "fbd1efc8-b7c8-4150-9912-dc4a122d5d0d", "to_node": "5852a6ad-fa1a-473f-a76e-e091ce60aa58", "uuid": "7fc36a80-3b23-4807-8e94-eac8f7354d28" } }, { "relationship": { "id": 19, "main_type": 200, "type": "Association", "name": "", "description": [ "" ], "list_order": 65536, "from_classifier_name": "documentation editor", "to_classifier_name": "generate docbook showing the svg-paths as text", "from_node": "1436c2c7-73fd-402e-b44c-a36f3bcc32fa", "to_node": "893cc0c5-0b2c-4e33-bc81-60ae17132ffa", "uuid": "307a03aa-abde-484c-80e3-0d10564b916a" } }, { "relationship": { "id": 31, "main_type": 200, "type": "Association", "name": "", "description": [ "" ], "list_order": 98304, "from_classifier_name": "documentation editor", "to_classifier_name": "generate GdkPixBuf images", "from_node": "1436c2c7-73fd-402e-b44c-a36f3bcc32fa", "to_node": "7853ef51-4d9e-4ecc-9c64-31f73676c0a3", "uuid": "8dc93418-30ae-4bdb-b3a1-b9b3b83a2311" } }, { "relationship": { "id": 10, "main_type": 300, "type": "Association", "name": "", "description": [ "" ], "list_order": -8454772, "from_classifier_name": "render", "to_classifier_name": "icon_writer", "from_node": "ec0de729-88f4-429f-9b10-f0762a4183c7", "to_node": "f0d393cd-2646-4369-b429-4b09712bdb49", "uuid": "c048cba7-7adb-4202-9075-a3123e65983a" } }, { "relationship": { "id": 12, "main_type": 300, "type": "Association", "name": "", "description": [ "" ], "list_order": 124360990, "from_classifier_name": "render", "to_classifier_name": "render_svg", "from_node": "ec0de729-88f4-429f-9b10-f0762a4183c7", "to_node": "0da9c5cf-40ea-410c-8c08-845c2a08df79", "uuid": "ea197f16-640a-4772-a21e-258963dedaa4" } }, { "relationship": { "id": 11, "main_type": 300, "type": "Association", "name": "", "description": [ "" ], "list_order": -623707360, "from_classifier_name": "model", "to_classifier_name": "icon_data", "from_node": "41102a65-f6a8-4e51-a884-2afa4e222de0", "to_node": "5c91a819-3ba8-4214-b2be-ae0454889a5b", "uuid": "06443332-f08d-49c4-ac28-73fc2d41b608" } }, { "relationship": { "id": 14, "main_type": 300, "type": "Association", "name": "", "description": [ "" ], "list_order": -542227524, "from_classifier_name": "model", "to_classifier_name": "geometry", "from_node": "41102a65-f6a8-4e51-a884-2afa4e222de0", "to_node": "18040e78-ed42-4c92-9742-e89b147cd8d5", "uuid": "ff2b6781-e558-43b0-ae8f-e92314f45b16" } }, { "relationship": { "id": 26, "main_type": 300, "type": "Association", "name": "", "description": [ "" ], "list_order": 31265024, "from_classifier_name": "model", "to_classifier_name": "gui_icon", "from_node": "41102a65-f6a8-4e51-a884-2afa4e222de0", "to_node": "3b7f5dbb-47c6-4ed1-80e7-a6af17bbe55c", "uuid": "37216886-61b3-4ee5-a1b8-027154c7af96" } }, { "relationship": { "id": 27, "main_type": 300, "type": "Association", "name": "", "description": [ "" ], "list_order": 50186937, "from_classifier_name": "model", "to_classifier_name": "icon", "from_node": "41102a65-f6a8-4e51-a884-2afa4e222de0", "to_node": "bfc86773-796f-4f50-a7ed-ba4ced0e6564", "uuid": "843f5c85-4c9d-455e-821e-bb1956e5dd11" } }, { "relationship": { "id": 15, "main_type": 221, "type": "Message", "name": "3b. icon.generate()", "description": [ "" ], "list_order": 403828622, "from_classifier_name": "icon_writer", "from_feature_key": "", "to_classifier_name": "icon_data", "to_feature_key": "", "from_node": "348addb8-501f-4761-b846-b5e17b9f1a96", "to_node": "19e782c2-4792-4011-b3db-ca4a88d70a23", "uuid": "dfb93016-fb40-4864-9dd8-31464823bf6a" } }, { "relationship": { "id": 16, "main_type": 221, "type": "Message", "name": "3a. create renderer for nice icons", "description": [ "" ], "list_order": 107792115, "from_classifier_name": "icon_writer", "from_feature_key": "", "to_classifier_name": "render_svg", "to_feature_key": "", "from_node": "348addb8-501f-4761-b846-b5e17b9f1a96", "to_node": "aca5b62d-23e2-4011-808a-9c3389b41616", "uuid": "7758991a-e54f-40e4-ba33-65542e4691f8" } }, { "relationship": { "id": 17, "main_type": 221, "type": "Message", "name": "4a. create renderer for docbook with svg-path", "description": [ "" ], "list_order": 952366855, "from_classifier_name": "icon_writer", "from_feature_key": "", "to_classifier_name": "render_svg", "to_feature_key": "", "from_node": "348addb8-501f-4761-b846-b5e17b9f1a96", "to_node": "aca5b62d-23e2-4011-808a-9c3389b41616", "uuid": "28285f64-1cc0-4a85-ad93-3c588b47aec2" } }, { "relationship": { "id": 18, "main_type": 221, "type": "Message", "name": "4b. icon.generate()", "description": [ "" ], "list_order": 1248403362, "from_classifier_name": "icon_writer", "from_feature_key": "", "to_classifier_name": "icon_data", "to_feature_key": "", "from_node": "348addb8-501f-4761-b846-b5e17b9f1a96", "to_node": "19e782c2-4792-4011-b3db-ca4a88d70a23", "uuid": "ad0d3d27-babf-4dcc-9ff7-2343cd120927" } }, { "relationship": { "id": 28, "main_type": 211, "type": "Realization", "name": "", "description": [ "" ], "list_order": 1248436130, "from_classifier_name": "icon_data", "to_classifier_name": "icon", "from_node": "5c91a819-3ba8-4214-b2be-ae0454889a5b", "to_node": "bfc86773-796f-4f50-a7ed-ba4ced0e6564", "uuid": "845156dc-3951-4898-bb7a-90228fb600a4" } }, { "relationship": { "id": 21, "main_type": 221, "type": "Message", "name": "1. get_icons", "description": [ "" ], "list_order": -1098121302, "from_classifier_name": "main", "from_feature_key": "", "to_classifier_name": "icon_data", "to_feature_key": "", "from_node": "7fbb0c9c-fcc0-4fc0-ac4a-16c77757ea84", "to_node": "19e782c2-4792-4011-b3db-ca4a88d70a23", "uuid": "386be11e-2ef3-4720-b5d0-edcf6b98e9c6" } }, { "relationship": { "id": 22, "main_type": 221, "type": "Message", "name": "2. generate_files", "description": [ "" ], "list_order": -462513508, "from_classifier_name": "main", "from_feature_key": "", "to_classifier_name": "icon_writer", "to_feature_key": "", "from_node": "7fbb0c9c-fcc0-4fc0-ac4a-16c77757ea84", "to_node": "348addb8-501f-4761-b846-b5e17b9f1a96", "uuid": "a1d26167-b0fd-4418-91d9-ce240f1db469" } }, { "relationship": { "id": 29, "main_type": 211, "type": "Realization", "name": "", "description": [ "" ], "list_order": 1248468898, "from_classifier_name": "gui_icon", "to_classifier_name": "icon", "from_node": "3b7f5dbb-47c6-4ed1-80e7-a6af17bbe55c", "to_node": "bfc86773-796f-4f50-a7ed-ba4ced0e6564", "uuid": "b97d26d1-0ad9-4acc-8304-df615179f009" } } ] } crystal-facet-uml-1.63.3/build/icon_artist/make.sh000077500000000000000000000015161500562027500220360ustar00rootroot00000000000000#!/bin/sh find . -name '*.rs' | xargs rustfmt cargo build ; echo "ERROR: $?" echo "consider running rustup update" echo "view source documentation using cargo doc && chromium-browser target/doc/icon_artist/index.html" echo "run program by e.g. cargo run -- -h" # Copyright 2023-2025 Andreas Warnke # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. crystal-facet-uml-1.63.3/build/icon_artist/src/000077500000000000000000000000001500562027500213465ustar00rootroot00000000000000crystal-facet-uml-1.63.3/build/icon_artist/src/icon_data/000077500000000000000000000000001500562027500232675ustar00rootroot00000000000000crystal-facet-uml-1.63.3/build/icon_artist/src/icon_data/gui_file_icon.rs000066400000000000000000000354461500562027500264440ustar00rootroot00000000000000//! The module provides functions to render an icon to vector graphics. use crate::model::icon::IconSource; use crate::stream_if::geometry; use crate::stream_if::geometry::DrawDirective::Close; use crate::stream_if::geometry::DrawDirective::CloseRel; use crate::stream_if::geometry::DrawDirective::CurveRel; use crate::stream_if::geometry::DrawDirective::Line; use crate::stream_if::geometry::DrawDirective::LineRel; use crate::stream_if::geometry::DrawDirective::Move; use crate::stream_if::geometry::DrawDirective::MoveRel; use crate::stream_if::geometry::Offset; use crate::stream_if::geometry::Point; use crate::stream_if::geometry::Rect; use crate::stream_if::path_renderer::PathRenderer; /// The view rectangle of each icon const ICON_VIEW_RECT: Rect = Rect { left: 0.0, top: 0.0, width: 32.0, height: 32.0, }; /// green fill color static GREEN: geometry::Color = geometry::Color { red: 0x0, green: 0xff, blue: 0x99, }; /// amber fill color static AMBER: geometry::Color = geometry::Color { red: 0xff, green: 0xcc, blue: 0x88, }; /// black color static BLACK: geometry::Color = geometry::Color { red: 0x0, green: 0x0, blue: 0x0, }; /// white color static WHITE: geometry::Color = geometry::Color { red: 0xff, green: 0xff, blue: 0xff, }; /// gray color static GRAY: geometry::Color = geometry::Color { red: 0x7f, green: 0x7f, blue: 0x7f, }; /// black pen static BLACK_PEN: geometry::Pen = geometry::Pen { color: BLACK, width: 1.0, }; /// white pen static WHITE_PEN: geometry::Pen = geometry::Pen { color: WHITE, width: 1.0, }; const BEZIER_CTRL_POINT_FOR_90_DEGREE_CIRCLE: f32 = 0.552284749831; /// The function defines the draw directives for the file symbols contour /// fn get_db_storage_contour() -> [geometry::DrawDirective; 9] { let x_rad: f32 = 10.0; let y_rad: f32 = 4.0; let height: f32 = 22.0; let center_x: f32 = 16.0; [ MoveRel(Offset { dx: center_x - x_rad, dy: center_x - 0.5 * height, }), CurveRel( Offset { dx: 0.0, dy: -y_rad * BEZIER_CTRL_POINT_FOR_90_DEGREE_CIRCLE, }, Offset { dx: x_rad - x_rad * BEZIER_CTRL_POINT_FOR_90_DEGREE_CIRCLE, dy: -y_rad, }, Offset { dx: x_rad, dy: -y_rad, }, ), CurveRel( Offset { dx: x_rad * BEZIER_CTRL_POINT_FOR_90_DEGREE_CIRCLE, dy: 0.0, }, Offset { dx: x_rad, dy: y_rad - y_rad * BEZIER_CTRL_POINT_FOR_90_DEGREE_CIRCLE, }, Offset { dx: x_rad, dy: y_rad, }, ), LineRel(Offset { dx: 0.0, dy: height, }), CurveRel( Offset { dx: 0.0, dy: y_rad * BEZIER_CTRL_POINT_FOR_90_DEGREE_CIRCLE, }, Offset { dx: -x_rad + x_rad * BEZIER_CTRL_POINT_FOR_90_DEGREE_CIRCLE, dy: y_rad, }, Offset { dx: -x_rad, dy: y_rad, }, ), CurveRel( Offset { dx: -x_rad * BEZIER_CTRL_POINT_FOR_90_DEGREE_CIRCLE, dy: 0.0, }, Offset { dx: -x_rad, dy: -y_rad + y_rad * BEZIER_CTRL_POINT_FOR_90_DEGREE_CIRCLE, }, Offset { dx: -x_rad, dy: -y_rad, }, ), LineRel(Offset { dx: 0.0, dy: -height, }), CurveRel( Offset { dx: 0.0, dy: y_rad * BEZIER_CTRL_POINT_FOR_90_DEGREE_CIRCLE, }, Offset { dx: x_rad - x_rad * BEZIER_CTRL_POINT_FOR_90_DEGREE_CIRCLE, dy: y_rad, }, Offset { dx: x_rad, dy: y_rad, }, ), CurveRel( Offset { dx: x_rad * BEZIER_CTRL_POINT_FOR_90_DEGREE_CIRCLE, dy: 0.0, }, Offset { dx: x_rad, dy: -y_rad + y_rad * BEZIER_CTRL_POINT_FOR_90_DEGREE_CIRCLE, }, Offset { dx: x_rad, dy: -y_rad, }, ), ] } /// The function defines the draw directives for the file symbols shadows /// fn get_db_storage_shadows() -> [geometry::DrawDirective; 12] { let x_rad: f32 = 10.0; let y_rad: f32 = 4.0; let height: f32 = 22.0; let center_x: f32 = 16.0; let step1_angle: f32 = std::f32::consts::PI * 1.15; let step1_dx = step1_angle.cos() * x_rad; let step1_dy = step1_angle.sin() * -y_rad; let step2_angle: f32 = std::f32::consts::PI * 1.3; let step2_dx = step2_angle.cos() * x_rad; let step2_dy = step2_angle.sin() * -y_rad; let step3_angle: f32 = std::f32::consts::PI * 1.8; let step3_dx = step3_angle.cos() * x_rad; let step3_dy = step3_angle.sin() * -y_rad; [ MoveRel(Offset { dx: center_x - x_rad, dy: 16.0 - 0.5 * height, }), LineRel(Offset { dx: x_rad + step1_dx, dy: step1_dy, }), LineRel(Offset { dx: step2_dx - step1_dx, dy: step2_dy - step1_dy, }), LineRel(Offset { dx: 0.0, dy: height, }), LineRel(Offset { dx: -step2_dx + step1_dx, dy: -step2_dy + step1_dy, }), LineRel(Offset { dx: -step1_dx - x_rad, dy: -step1_dy, }), CloseRel, MoveRel(Offset { dx: 2.0 * x_rad, dy: 0.0, }), LineRel(Offset { dx: -x_rad + step3_dx, dy: step3_dy, }), LineRel(Offset { dx: 0.0, dy: height, }), LineRel(Offset { dx: -step3_dx + x_rad, dy: -step3_dy, }), CloseRel, ] } /// The function defines the draw directives for the file symbols reflection /// fn get_db_storage_reflection() -> [geometry::DrawDirective; 5] { let x_rad: f32 = 10.0; let y_rad: f32 = 4.0; let height: f32 = 22.0; let center_x: f32 = 16.0; let step1_angle: f32 = std::f32::consts::PI * 1.5; let step1_dx = step1_angle.cos() * x_rad; let step1_dy = step1_angle.sin() * -y_rad; let step2_angle: f32 = std::f32::consts::PI * 1.6; let step2_dx = step2_angle.cos() * x_rad; let step2_dy = step2_angle.sin() * -y_rad; [ MoveRel(Offset { dx: center_x + step1_dx, dy: 16.0 - 0.5 * height + step1_dy, }), LineRel(Offset { dx: step2_dx - step1_dx, dy: step2_dy - step1_dy, }), LineRel(Offset { dx: 0.0, dy: height, }), LineRel(Offset { dx: -step2_dx + step1_dx, dy: -step2_dy + step1_dy, }), CloseRel, ] } /// The function generates a new-file icon to vector graphics drawing directives /// /// # Panics /// /// This function panics if PathRenderer cannot write to the output sink. /// pub fn generate_file_new(out: &mut dyn PathRenderer) -> () { /* background */ let icon_segs: [geometry::DrawDirective; 9] = get_db_storage_contour(); out.render_path(&icon_segs, &Some(BLACK_PEN), &None); /* plus symbol */ let plus_sym: [geometry::DrawDirective; 4] = [ Move(Point { x: 12.5, y: 19.0 }), Line(Point { x: 19.5, y: 19.0 }), Move(Point { x: 16.0, y: 15.5 }), Line(Point { x: 16.0, y: 22.5 }), ]; out.render_path(&plus_sym, &Some(BLACK_PEN), &None); } /// The function generates an open-file icon to vector graphics drawing directives /// /// # Panics /// /// This function panics if PathRenderer cannot write to the output sink. /// pub fn generate_file_open(out: &mut dyn PathRenderer) -> () { /* background */ let icon_segs: [geometry::DrawDirective; 12] = get_db_storage_shadows(); out.render_path(&icon_segs, &None, &Some(GRAY)); let icon_segs: [geometry::DrawDirective; 5] = get_db_storage_reflection(); out.render_path(&icon_segs, &None, &Some(WHITE)); /* contour */ let icon_segs: [geometry::DrawDirective; 9] = get_db_storage_contour(); out.render_path(&icon_segs, &Some(BLACK_PEN), &None); } /// The function generates a save-file icon to vector graphics drawing directives /// /// # Panics /// /// This function panics if PathRenderer cannot write to the output sink. /// pub fn generate_file_save(out: &mut dyn PathRenderer) -> () { /* background */ let icon_segs: [geometry::DrawDirective; 12] = get_db_storage_shadows(); out.render_path(&icon_segs, &None, &Some(GRAY)); let icon_segs: [geometry::DrawDirective; 5] = get_db_storage_reflection(); out.render_path(&icon_segs, &None, &Some(WHITE)); /* contour */ let icon_segs: [geometry::DrawDirective; 9] = get_db_storage_contour(); out.render_path(&icon_segs, &Some(BLACK_PEN), &None); /* asterisk symbol */ let unsaved_sym: [geometry::DrawDirective; 16] = [ MoveRel(Offset { dx: 19.5, dy: 11.5 }), LineRel(Offset { dx: 3.0, dy: 0.0 }), LineRel(Offset { dx: 0.0, dy: 7.0 }), LineRel(Offset { dx: 8.0, dy: -2.0 }), LineRel(Offset { dx: 0.0, dy: 3.0 }), LineRel(Offset { dx: -7.0, dy: 2.0 }), LineRel(Offset { dx: 4.0, dy: 7.0 }), LineRel(Offset { dx: -3.0, dy: 1.0 }), LineRel(Offset { dx: -3.5, dy: -6.0 }), LineRel(Offset { dx: -3.5, dy: 6.0 }), LineRel(Offset { dx: -3.0, dy: -1.0 }), LineRel(Offset { dx: 4.0, dy: -7.0 }), LineRel(Offset { dx: -7.0, dy: -2.0 }), LineRel(Offset { dx: 0.0, dy: -3.0 }), LineRel(Offset { dx: 8.0, dy: 2.0 }), CloseRel, ]; out.render_path(&unsaved_sym, &Some(WHITE_PEN), &Some(GRAY)); } /// The function generates a saved-file icon to vector graphics drawing directives /// /// # Panics /// /// This function panics if PathRenderer cannot write to the output sink. /// pub fn generate_file_saved(out: &mut dyn PathRenderer) -> () { /* background */ let icon_segs: [geometry::DrawDirective; 12] = get_db_storage_shadows(); out.render_path(&icon_segs, &None, &Some(GRAY)); let icon_segs: [geometry::DrawDirective; 5] = get_db_storage_reflection(); out.render_path(&icon_segs, &None, &Some(WHITE)); /* contour */ let icon_segs: [geometry::DrawDirective; 9] = get_db_storage_contour(); out.render_path(&icon_segs, &Some(BLACK_PEN), &None); /* ok symbol */ let ok_sym: [geometry::DrawDirective; 8] = [ Move(Point { x: 13.0, y: 20.0 }), Line(Point { x: 17.0, y: 20.0 }), Line(Point { x: 18.5, y: 23.5 }), Line(Point { x: 24.0, y: 12.0 }), Line(Point { x: 25.0, y: 12.5 }), Line(Point { x: 21.0, y: 26.5 }), Line(Point { x: 16.0, y: 27.0 }), Close, ]; out.render_path(&ok_sym, &Some(BLACK_PEN), &Some(GREEN)); } /// The function generates an unsaved-file icon to vector graphics drawing directives /// /// # Panics /// /// This function panics if PathRenderer cannot write to the output sink. /// pub fn generate_file_unsaved(out: &mut dyn PathRenderer) -> () { /* background */ let icon_segs: [geometry::DrawDirective; 12] = get_db_storage_shadows(); out.render_path(&icon_segs, &None, &Some(GRAY)); let icon_segs: [geometry::DrawDirective; 5] = get_db_storage_reflection(); out.render_path(&icon_segs, &None, &Some(WHITE)); /* contour */ let icon_segs: [geometry::DrawDirective; 9] = get_db_storage_contour(); out.render_path(&icon_segs, &Some(BLACK_PEN), &None); /* asterisk symbol */ let unsaved_sym: [geometry::DrawDirective; 16] = [ MoveRel(Offset { dx: 19.5, dy: 11.5 }), LineRel(Offset { dx: 3.0, dy: 0.0 }), LineRel(Offset { dx: 0.0, dy: 7.0 }), LineRel(Offset { dx: 8.0, dy: -2.0 }), LineRel(Offset { dx: 0.0, dy: 3.0 }), LineRel(Offset { dx: -7.0, dy: 2.0 }), LineRel(Offset { dx: 4.0, dy: 7.0 }), LineRel(Offset { dx: -3.0, dy: 1.0 }), LineRel(Offset { dx: -3.5, dy: -6.0 }), LineRel(Offset { dx: -3.5, dy: 6.0 }), LineRel(Offset { dx: -3.0, dy: -1.0 }), LineRel(Offset { dx: 4.0, dy: -7.0 }), LineRel(Offset { dx: -7.0, dy: -2.0 }), LineRel(Offset { dx: 0.0, dy: -3.0 }), LineRel(Offset { dx: 8.0, dy: 2.0 }), CloseRel, ]; out.render_path(&unsaved_sym, &Some(BLACK_PEN), &Some(AMBER)); } /// The function generates an export-files icon to vector graphics drawing directives /// /// # Panics /// /// This function panics if PathRenderer cannot write to the output sink. /// pub fn generate_file_export(out: &mut dyn PathRenderer) -> () { /* background */ let icon_segs: [geometry::DrawDirective; 12] = get_db_storage_shadows(); out.render_path(&icon_segs, &None, &Some(GRAY)); let icon_segs: [geometry::DrawDirective; 5] = get_db_storage_reflection(); out.render_path(&icon_segs, &None, &Some(WHITE)); /* contour */ let icon_segs: [geometry::DrawDirective; 9] = get_db_storage_contour(); out.render_path(&icon_segs, &Some(BLACK_PEN), &None); /* out symbol */ let out_sym: [geometry::DrawDirective; 8] = [ MoveRel(Offset { dx: 13.0, dy: 16.0 }), LineRel(Offset { dx: 10.0, dy: 0.0 }), LineRel(Offset { dx: 0.0, dy: -5.0 }), LineRel(Offset { dx: 6.0, dy: 8.0 }), LineRel(Offset { dx: -6.0, dy: 8.0 }), LineRel(Offset { dx: 0.0, dy: -5.0 }), LineRel(Offset { dx: -10.0, dy: 0.0 }), CloseRel, ]; out.render_path(&out_sym, &Some(BLACK_PEN), &Some(GREEN)); } /// The function returns an array of IconSource /// pub fn get_icons() -> &'static [IconSource<'static>] { &[ IconSource { name: "file_new", viewport: ICON_VIEW_RECT, generate: generate_file_new, }, IconSource { name: "file_open", viewport: ICON_VIEW_RECT, generate: generate_file_open, }, IconSource { name: "file_save", viewport: ICON_VIEW_RECT, generate: generate_file_save, }, IconSource { name: "file_saved", viewport: ICON_VIEW_RECT, generate: generate_file_saved, }, IconSource { name: "file_unsaved", viewport: ICON_VIEW_RECT, generate: generate_file_unsaved, }, IconSource { name: "file_export", viewport: ICON_VIEW_RECT, generate: generate_file_export, }, ] } crystal-facet-uml-1.63.3/build/icon_artist/src/icon_data/gui_view_icon.rs000066400000000000000000000341351500562027500264710ustar00rootroot00000000000000//! The module provides functions to render an icon to vector graphics. use super::shape::get_circle_abs; use crate::model::icon::IconSource; use crate::stream_if::geometry; use crate::stream_if::geometry::DrawDirective::Close; use crate::stream_if::geometry::DrawDirective::Curve; use crate::stream_if::geometry::DrawDirective::CurveRel; use crate::stream_if::geometry::DrawDirective::Line; use crate::stream_if::geometry::DrawDirective::LineRel; use crate::stream_if::geometry::DrawDirective::Move; use crate::stream_if::geometry::DrawDirective::MoveRel; use crate::stream_if::geometry::Offset; use crate::stream_if::geometry::Point; use crate::stream_if::geometry::Rect; use crate::stream_if::path_renderer::PathRenderer; /// The view rectangle of each icon const ICON_VIEW_RECT: Rect = Rect { left: 0.0, top: 0.0, width: 32.0, height: 32.0, }; /// green fill color static GREEN: geometry::Color = geometry::Color { red: 0x0, green: 0xff, blue: 0x99, }; /// black color static BLACK: geometry::Color = geometry::Color { red: 0x0, green: 0x0, blue: 0x0, }; /// white color static WHITE: geometry::Color = geometry::Color { red: 0xff, green: 0xff, blue: 0xff, }; /// black pen static BLACK_PEN: geometry::Pen = geometry::Pen { color: BLACK, width: 1.0, }; /// The function defines the draw directives for the view mode background /// /// # Arguments /// /// * `pos` - Position of the view button: 0..3 /// fn get_view_ground(pos: i32) -> [geometry::DrawDirective; 5] { let left_y = 18.0 + (((pos * 4) - 7) as f32).abs(); let right_y = 18.0 + (((pos * 4) - 5) as f32).abs(); let middle_y = left_y.min(right_y); [ Move(Point { x: 0.0, y: left_y }), Curve( Point { x: 10.0, y: middle_y, }, Point { x: 22.0, y: middle_y, }, Point { x: 32.0, y: right_y, }, ), Line(Point { x: 32.0, y: 32.0 }), Line(Point { x: 0.0, y: 32.0 }), Close, ] } /// The function generates a magnifying glass icon to vector graphics drawing directives /// /// # Panics /// /// This function panics if PathRenderer cannot write to the output sink. /// pub fn generate_view_search(out: &mut dyn PathRenderer) -> () { /* background */ let icon_segs: [geometry::DrawDirective; 5] = get_view_ground(0); out.render_path(&icon_segs, &None, &Some(WHITE)); /* circle */ let icon_segs: [geometry::DrawDirective; 5] = get_circle_abs(Point { x: 19.25, y: 12.0 }, 7.5, 7.5); out.render_path(&icon_segs, &Some(BLACK_PEN), &Some(GREEN)); let icon_segs: [geometry::DrawDirective; 4] = [ MoveRel(Offset { dx: 16.0, dy: 19.0 }), LineRel(Offset { dx: -3.0, dy: 10.0 }), LineRel(Offset { dx: 2.0, dy: 0.6 }), LineRel(Offset { dx: 3.0, dy: -10.0 }), ]; out.render_path(&icon_segs, &Some(BLACK_PEN), &None); } /// The function generates a steering wheel of ship navigation to vector graphics drawing directives /// /// # Panics /// /// This function panics if PathRenderer cannot write to the output sink. /// pub fn generate_view_navigate(out: &mut dyn PathRenderer) -> () { /* background */ let icon_segs: [geometry::DrawDirective; 5] = get_view_ground(1); out.render_path(&icon_segs, &None, &Some(WHITE)); /* spoke of wheel */ let r2: f32 = 15.0; let r1: f32 = 11.0; let cx: f32 = 16.0; let cy: f32 = 16.0; let mut icon_segs: [geometry::DrawDirective; 40] = [Close; 40]; for index in 0..10 { let alpha: f32 = std::f32::consts::PI / 5.0 * (index as f32); let dx = alpha.cos(); let dy = alpha.sin(); icon_segs[index * 4 + 0] = Move(Point { x: cx, y: cy }); icon_segs[index * 4 + 1] = LineRel(Offset { dx: r2 * dx, dy: r2 * dy, }); icon_segs[index * 4 + 2] = MoveRel(Offset { dx: (r1 - r2) * dx, dy: (r1 - r2) * dy, }); let beta: f32 = std::f32::consts::PI / 5.0 * ((index + 1) as f32); let n_dx = beta.cos(); let n_dy = beta.sin(); icon_segs[index * 4 + 3] = LineRel(Offset { dx: (-r1) * dx + r1 * n_dx, dy: (-r1) * dy + r1 * n_dy, }); } out.render_path(&icon_segs, &Some(BLACK_PEN), &None); /* rim of wheel */ let icon_segs: [geometry::DrawDirective; 5] = get_circle_abs(Point { x: cx, y: cy }, 11.0, 11.0); out.render_path(&icon_segs, &Some(BLACK_PEN), &None); } /// The function generates a hand icon to vector graphics drawing directives /// /// # Panics /// /// This function panics if PathRenderer cannot write to the output sink. /// pub fn generate_view_edit(out: &mut dyn PathRenderer) -> () { /* background */ let icon_segs: [geometry::DrawDirective; 5] = get_view_ground(2); out.render_path(&icon_segs, &None, &Some(WHITE)); let icon_segs: [geometry::DrawDirective; 16] = [ MoveRel(Offset { dx: 12.945591, dy: 29.3417, }), CurveRel( Offset { dx: 0.0, dy: 0.0 }, Offset { dx: 0.513702, dy: -3.916, }, Offset { dx: -0.09381, dy: -5.347, }, ), CurveRel( Offset { dx: -0.607512, dy: -1.4311, }, Offset { dx: -1.838417, dy: -0.5705, }, Offset { dx: -2.814258, dy: -2.8143, }, ), CurveRel( Offset { dx: -0.9758418, dy: -2.2438, }, Offset { dx: -1.627765, dy: -10.592, }, Offset { dx: -0.3752347, dy: -10.6942, }, ), CurveRel( Offset { dx: 1.2525297, dy: -0.1022, }, Offset { dx: 1.9699807, dy: 7.5985, }, Offset { dx: 1.9699807, dy: 7.5985, }, ), CurveRel( Offset { dx: 0.0, dy: 0.0 }, Offset { dx: -0.374371, dy: -13.7912, }, Offset { dx: 1.031895, dy: -13.696, }, ), CurveRel( Offset { dx: 1.406266, dy: 0.095, }, Offset { dx: 1.219512, dy: 11.0694, }, Offset { dx: 1.219512, dy: 11.0694, }, ), CurveRel( Offset { dx: 0.0, dy: 0.0 }, Offset { dx: 0.516942, dy: -12.5406, }, Offset { dx: 1.594746, dy: -12.5704, }, ), CurveRel( Offset { dx: 1.077804, dy: -0.03, }, Offset { dx: 1.031896, dy: 12.2889, }, Offset { dx: 1.031896, dy: 12.2889, }, ), CurveRel( Offset { dx: 0.0, dy: 0.0 }, Offset { dx: 0.613873, dy: -10.7697, }, Offset { dx: 1.594746, dy: -10.4127, }, ), CurveRel( Offset { dx: 0.980873, dy: 0.357, }, Offset { dx: 0.75047, dy: 11.4446, }, Offset { dx: 0.75047, dy: 11.4446, }, ), CurveRel( Offset { dx: 0.0, dy: 0.0 }, Offset { dx: 0.16798, dy: -7.6202, }, Offset { dx: 1.219511, dy: -7.6923, }, ), CurveRel( Offset { dx: 1.051531, dy: -0.072, }, Offset { dx: 1.266578, dy: 8.5419, }, Offset { dx: 0.938087, dy: 11.0695, }, ), CurveRel( Offset { dx: -0.328491, dy: 2.5275, }, Offset { dx: -1.151965, dy: 2.3082, }, Offset { dx: -1.40713, dy: 3.9399, }, ), CurveRel( Offset { dx: -0.255165, dy: 1.6317, }, Offset { dx: 0.187616, dy: 5.7223, }, Offset { dx: 0.187616, dy: 5.7223, }, ), Close, ]; out.render_path(&icon_segs, &Some(BLACK_PEN), &Some(GREEN)); } /// The function generates a growing plant icon to vector graphics drawing directives /// /// # Panics /// /// This function panics if PathRenderer cannot write to the output sink. /// pub fn generate_view_create(out: &mut dyn PathRenderer) -> () { /* background */ let icon_segs: [geometry::DrawDirective; 5] = get_view_ground(3); out.render_path(&icon_segs, &None, &Some(WHITE)); let icon_segs: [geometry::DrawDirective; 15] = [ MoveRel(Offset { dx: 15.97781, dy: 30.0081, }), LineRel(Offset { dx: 0.07836, dy: -5.2683, }), CurveRel( Offset { dx: 0.0, dy: 0.0 }, Offset { dx: 0.178263, dy: -3.5108, }, Offset { dx: 4.217509, dy: -5.3197, }, ), CurveRel( Offset { dx: 4.039247, dy: -1.8089, }, Offset { dx: 4.002077, dy: 0.5815, }, Offset { dx: 1.061699, dy: 2.775, }, ), CurveRel( Offset { dx: -2.940378, dy: 2.1934, }, Offset { dx: -5.506003, dy: 2.665, }, Offset { dx: -5.506003, dy: 2.665, }, ), CurveRel( Offset { dx: 0.0, dy: 0.0 }, Offset { dx: -0.730453, dy: -4.9278, }, Offset { dx: -4.028792, dy: -6.6615, }, ), CurveRel( Offset { dx: -3.2983386, dy: -1.7337, }, Offset { dx: -2.9281036, dy: 0.5468, }, Offset { dx: -0.8382, dy: 3.2441, }, ), CurveRel( Offset { dx: 2.089904, dy: 2.6973, }, Offset { dx: 4.945349, dy: 3.2033, }, Offset { dx: 4.945349, dy: 3.2033, }, ), LineRel(Offset { dx: -0.172165, dy: -9.6788, }), CurveRel( Offset { dx: 0.0, dy: 0.0 }, Offset { dx: -0.172379, dy: -1.7078, }, Offset { dx: -1.995904, dy: -2.934, }, ), CurveRel( Offset { dx: -1.823526, dy: -1.2263, }, Offset { dx: -3.108662, dy: -0.2453, }, Offset { dx: -1.428661, dy: 1.6621, }, ), CurveRel( Offset { dx: 1.680001, dy: 1.9075, }, Offset { dx: 3.494646, dy: 1.0572, }, Offset { dx: 3.494646, dy: 1.0572, }, ), CurveRel( Offset { dx: 0.0, dy: 0.0 }, Offset { dx: -0.758347, dy: -1.9473, }, Offset { dx: 2.025709, dy: -3.7533, }, ), CurveRel( Offset { dx: 2.784055, dy: -1.806, }, Offset { dx: 2.369392, dy: 0.7466, }, Offset { dx: 0.713489, dy: 2.1585, }, ), CurveRel( Offset { dx: -1.655904, dy: 1.4118, }, Offset { dx: -2.981447, dy: 1.7423, }, Offset { dx: -2.981447, dy: 1.7423, }, ), ]; out.render_path(&icon_segs, &Some(BLACK_PEN), &Some(GREEN)); } /// The function returns an array of IconSource /// pub fn get_icons() -> &'static [IconSource<'static>] { &[ IconSource { name: "view_search", viewport: ICON_VIEW_RECT, generate: generate_view_search, }, IconSource { name: "view_navigate", viewport: ICON_VIEW_RECT, generate: generate_view_navigate, }, IconSource { name: "view_edit", viewport: ICON_VIEW_RECT, generate: generate_view_edit, }, IconSource { name: "view_create", viewport: ICON_VIEW_RECT, generate: generate_view_create, }, ] } crystal-facet-uml-1.63.3/build/icon_artist/src/icon_data/mod.rs000066400000000000000000000013741500562027500244210ustar00rootroot00000000000000//! This module provides a static data model to be rendered. pub mod gui_file_icon; pub mod gui_view_icon; pub mod shape; pub mod stereotype_icon; pub mod type_class_icon; pub mod type_diag_icon; /* Copyright 2023-2025 Andreas Warnke Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. */ crystal-facet-uml-1.63.3/build/icon_artist/src/icon_data/shape.rs000066400000000000000000000230721500562027500247410ustar00rootroot00000000000000//! The module geometry provides a couple of geometric data structures. use crate::stream_if::geometry::DrawDirective; use crate::stream_if::geometry::Offset; use crate::stream_if::geometry::Point; use crate::stream_if::geometry::Rect; /// control point distance to approximate an arc by cubic bezier curves const ARC_APPROX: f32 = 0.552284749831; /// The function defines the control points for a circle in absolute coordinates /// /// # Arguments /// /// * `center` - The absolute coordinate of the center /// * `rx` - The radius in x-direction /// * `ry` - The radius in y-direction /// pub fn get_circle_abs(center: Point, rx: f32, ry: f32) -> [DrawDirective; 5] { let ctrlpnt_dx: f32 = rx * ARC_APPROX; /* control point distance x */ let ctrlpnt_dy: f32 = ry * ARC_APPROX; /* control point distance y */ let cx = center.x; let cy = center.y; [ DrawDirective::Move(Point { x: cx - rx, y: cy }), DrawDirective::Curve( Point { x: cx - rx, y: cy - ctrlpnt_dy, }, Point { x: cx - ctrlpnt_dx, y: cy - ry, }, Point { x: cx, y: cy - ry }, ), DrawDirective::Symmetric( Point { x: cx + rx, y: cy - ctrlpnt_dy, }, Point { x: cx + rx, y: cy }, ), DrawDirective::Symmetric( Point { x: cx + ctrlpnt_dx, y: cy + ry, }, Point { x: cx, y: cy + ry }, ), DrawDirective::Symmetric( Point { x: cx - rx, y: cy + ctrlpnt_dy, }, Point { x: cx - rx, y: cy }, ), ] } /// The function defines the control points for a circle in relative offsets /// /// # Arguments /// /// * `center` - The relative offset of the center /// * `rx` - The radius in x-direction /// * `ry` - The radius in y-direction /// pub fn get_circle_rel(center: Offset, rx: f32, ry: f32) -> [DrawDirective; 5] { let ctrlpnt_dx: f32 = rx * ARC_APPROX; /* control point distance x */ let ctrlpnt_dy: f32 = ry * ARC_APPROX; /* control point distance y */ let c_dx = center.dx; let c_dy = center.dy; [ DrawDirective::MoveRel(Offset { dx: c_dx - rx, dy: c_dy, }), DrawDirective::CurveRel( Offset { dx: 0.0, dy: (-ctrlpnt_dy), }, Offset { dx: rx - ctrlpnt_dx, dy: (-ry), }, Offset { dx: rx, dy: (-ry) }, ), DrawDirective::SymmetricRel( Offset { dx: rx, dy: ry - ctrlpnt_dy, }, Offset { dx: rx, dy: ry }, ), DrawDirective::SymmetricRel( Offset { dx: (-rx) + ctrlpnt_dx, dy: ry, }, Offset { dx: (-rx), dy: ry }, ), DrawDirective::SymmetricRel( Offset { dx: (-rx), dy: (-ry) + ctrlpnt_dy, }, Offset { dx: (-rx), dy: (-ry), }, ), ] } /// The function defines the control points for a rounded rectangle in relative offsets /// /// # Arguments /// /// * `top_left` - The relative offset of the top left corner /// * `width` - The width of the rectangle /// * `height` - The height of the rectangle /// * `r` - The radius of the corners in x- and y-directions /// pub fn get_rounded_rect_rel( top_left: Offset, width: f32, height: f32, r: f32, ) -> [DrawDirective; 9] { let ctrlpnt_dx: f32 = r * ARC_APPROX; /* control point distance x */ let ctrlpnt_dy: f32 = r * ARC_APPROX; /* control point distance y */ [ DrawDirective::MoveRel(Offset { dx: top_left.dx, dy: top_left.dy + r, }), DrawDirective::CurveRel( Offset { dx: 0.0, dy: -ctrlpnt_dy, }, Offset { dx: r - ctrlpnt_dx, dy: -r, }, Offset { dx: r, dy: -r }, ), DrawDirective::LineRel(Offset { dx: width - 2.0 * r, dy: 0.0, }), DrawDirective::CurveRel( Offset { dx: ctrlpnt_dx, dy: 0.0, }, Offset { dx: r, dy: r - ctrlpnt_dy, }, Offset { dx: r, dy: r }, ), DrawDirective::LineRel(Offset { dx: 0.0, dy: height - 2.0 * r, }), DrawDirective::CurveRel( Offset { dx: 0.0, dy: ctrlpnt_dy, }, Offset { dx: ctrlpnt_dx - r, dy: r, }, Offset { dx: -r, dy: r }, ), DrawDirective::LineRel(Offset { dx: 2.0 * r - width, dy: 0.0, }), DrawDirective::CurveRel( Offset { dx: -ctrlpnt_dx, dy: 0.0, }, Offset { dx: -r, dy: ctrlpnt_dy - r, }, Offset { dx: -r, dy: -r }, ), DrawDirective::CloseRel, ] } /// The function defines the control points for a rounded rectangle in absolute offsets /// /// # Arguments /// /// * `bounds` - The absolute coordinates of the rectangle /// * `r` - The radius of the corners in x- and y-directions /// pub fn get_rounded_rect_abs(bounds: Rect, r: f32) -> [DrawDirective; 9] { let ctrlpnt_dx: f32 = r * ARC_APPROX; /* control point distance x */ let ctrlpnt_dy: f32 = r * ARC_APPROX; /* control point distance y */ let left = bounds.left; let top = bounds.top; let right = bounds.right(); let bottom = bounds.bottom(); [ DrawDirective::Move(Point { x: left, y: top + r, }), DrawDirective::Curve( Point { x: left, y: top + r - ctrlpnt_dy, }, Point { x: left + r - ctrlpnt_dx, y: top, }, Point { x: left + r, y: top, }, ), DrawDirective::Line(Point { x: right - r, y: top, }), DrawDirective::Curve( Point { x: right - r + ctrlpnt_dx, y: top, }, Point { x: right, y: top + r - ctrlpnt_dy, }, Point { x: right, y: top + r, }, ), DrawDirective::Line(Point { x: right, y: bottom - r, }), DrawDirective::Curve( Point { x: right, y: bottom - r + ctrlpnt_dy, }, Point { x: right - r + ctrlpnt_dx, y: bottom, }, Point { x: right - r, y: bottom, }, ), DrawDirective::Line(Point { x: left + r, y: bottom, }), DrawDirective::Curve( Point { x: left + r - ctrlpnt_dx, y: bottom, }, Point { x: left, y: bottom - r + ctrlpnt_dy, }, Point { x: left, y: bottom - r, }, ), DrawDirective::Close, ] } /// The function defines the path points for a rectangle in relative offsets /// /// # Arguments /// /// * `top_left` - The relative offset of the top left corner /// * `width` - The width of the rectangle /// * `height` - The height of the rectangle /// pub fn get_rect_rel(top_left: Offset, width: f32, height: f32) -> [DrawDirective; 5] { [ DrawDirective::MoveRel(Offset { dx: top_left.dx, dy: top_left.dy, }), DrawDirective::LineRel(Offset { dx: width, dy: 0.0 }), DrawDirective::LineRel(Offset { dx: 0.0, dy: height, }), DrawDirective::LineRel(Offset { dx: -width, dy: 0.0, }), DrawDirective::CloseRel, ] } /// The function defines the path points for a rectangle in absolute offsets /// /// # Arguments /// /// * `bounds` - The absolute coordinates of the rectangle /// pub fn get_rect_abs(bounds: Rect) -> [DrawDirective; 5] { let left = bounds.left; let top = bounds.top; let right = bounds.right(); let bottom = bounds.bottom(); [ DrawDirective::Move(Point { x: left, y: top }), DrawDirective::Line(Point { x: right, y: top }), DrawDirective::Line(Point { x: right, y: bottom, }), DrawDirective::Line(Point { x: left, y: bottom }), DrawDirective::Close, ] } /* Copyright 2023-2025 Andreas Warnke Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. */ crystal-facet-uml-1.63.3/build/icon_artist/src/icon_data/stereotype_icon.rs000066400000000000000000000555571500562027500270710ustar00rootroot00000000000000//! The module provides functions to render an icon to vector graphics. use super::shape::get_circle_abs; use super::shape::get_circle_rel; use crate::model::icon::IconSource; use crate::stream_if::geometry; use crate::stream_if::geometry::DrawDirective::Close; use crate::stream_if::geometry::DrawDirective::CloseRel; use crate::stream_if::geometry::DrawDirective::Continue; use crate::stream_if::geometry::DrawDirective::ContinueRel; use crate::stream_if::geometry::DrawDirective::Curve; use crate::stream_if::geometry::DrawDirective::CurveRel; use crate::stream_if::geometry::DrawDirective::Line; use crate::stream_if::geometry::DrawDirective::LineRel; use crate::stream_if::geometry::DrawDirective::Move; use crate::stream_if::geometry::DrawDirective::MoveRel; use crate::stream_if::geometry::DrawDirective::SymmetricRel; use crate::stream_if::geometry::Offset; use crate::stream_if::geometry::Point; use crate::stream_if::geometry::Rect; use crate::stream_if::path_renderer::PathRenderer; /// The view rectangle of each icon const ICON_VIEW_RECT: Rect = Rect { left: 0.0, top: 0.0, width: 32.0, height: 32.0, }; /// blue color static BLUE: geometry::Color = geometry::Color { red: 0x0, green: 0x0, blue: 0x99, }; /// red color static RED: geometry::Color = geometry::Color { red: 0xcc, green: 0x0, blue: 0x0, }; /// green color static GREEN: geometry::Color = geometry::Color { red: 0x0, green: 0xaa, blue: 0x0, }; /// light gray color static LIGHT_GRAY: geometry::Color = geometry::Color { red: 0xcc, green: 0xcc, blue: 0xcc, }; /// light blue color static LIGHT_BLUE: geometry::Color = geometry::Color { red: 0x0, green: 0x0, blue: 0xdd, }; /// blue pen static BLUE_PEN: geometry::Pen = geometry::Pen { color: BLUE, width: 1.0, }; /// green pen static GREEN_PEN: geometry::Pen = geometry::Pen { color: GREEN, width: 1.0, }; /// red pen static RED_PEN: geometry::Pen = geometry::Pen { color: RED, width: 1.0, }; /// The function generates a database icon to vector graphics drawing directives /// /// # Panics /// /// This function panics if PathRenderer cannot write to the output sink. /// pub fn generate_deploy_database(out: &mut dyn PathRenderer) -> () { let rx: f32 = 12.0; /* radius x-direction */ let ry: f32 = 4.0; /* radius y-direction */ let ctrlpnt_dx: f32 = rx * 0.5625; /* control point distance x */ let ctrlpnt_dy: f32 = ry * 0.5625; /* control point distance y */ /* bottom cylinder */ let icon_segs: [geometry::DrawDirective; 5] = [ MoveRel(Offset { dx: 4.0, dy: 1.0 + ry, }), LineRel(Offset { dx: 0.0, dy: 30.0 - (2.0 * ry), }), CurveRel( Offset { dx: 0.0, dy: ctrlpnt_dy, }, Offset { dx: rx - ctrlpnt_dx, dy: ry, }, Offset { dx: rx, dy: ry }, ), SymmetricRel( Offset { dx: rx, dy: (-ry) + ctrlpnt_dy, }, Offset { dx: rx, dy: (-ry) }, ), LineRel(Offset { dx: 0.0, dy: (-30.0) + (2.0 * ry), }), ]; out.render_path(&icon_segs, &None, &None); /* top circle */ let icon_segs: [geometry::DrawDirective; 5] = get_circle_rel( Offset { dx: 16.0, dy: 1.0 + ry, }, rx, ry, ); out.render_path(&icon_segs, &None, &None); } /// The function generates a local-pc icon to vector graphics drawing directives /// /// # Panics /// /// This function panics if PathRenderer cannot write to the output sink. /// pub fn generate_deploy_local(out: &mut dyn PathRenderer) -> () { /* border line */ let icon_segs: [geometry::DrawDirective; 7] = [ MoveRel(Offset { dx: 1.0, dy: 23.0 }), LineRel(Offset { dx: 16.0, dy: 8.0 }), LineRel(Offset { dx: 8.0, dy: -6.0 }), LineRel(Offset { dx: 3.0, dy: -11.0 }), LineRel(Offset { dx: -16.0, dy: -7.0, }), LineRel(Offset { dx: -2.0, dy: 11.0 }), CloseRel, ]; out.render_path(&icon_segs, &None, &None); /* keyboard */ let icon_segs: [geometry::DrawDirective; 5] = [ MoveRel(Offset { dx: 5.0, dy: 23.0 }), LineRel(Offset { dx: 11.5, dy: 5.5 }), LineRel(Offset { dx: 5.0, dy: -3.5 }), LineRel(Offset { dx: -11.0, dy: -5.2, }), CloseRel, ]; out.render_path(&icon_segs, &None, &Some(LIGHT_GRAY)); /* screen */ let icon_segs: [geometry::DrawDirective; 5] = [ MoveRel(Offset { dx: 11.5, dy: 17.0 }), LineRel(Offset { dx: 12.5, dy: 6.0 }), LineRel(Offset { dx: 2.0, dy: -8.0 }), LineRel(Offset { dx: -12.8, dy: -6.0, }), CloseRel, ]; out.render_path(&icon_segs, &None, &Some(LIGHT_BLUE)); } /// The function generates a cloud icon to vector graphics drawing directives /// /// # Panics /// /// This function panics if PathRenderer cannot write to the output sink. /// pub fn generate_deploy_cloud(out: &mut dyn PathRenderer) -> () { /* bottom cylinder */ let icon_segs: [geometry::DrawDirective; 5] = [ MoveRel(Offset { dx: 3.0, dy: 22.0 }), CurveRel( Offset { dx: -3.0, dy: -3.0 }, Offset { dx: 3.0, dy: -9.0 }, Offset { dx: 6.0, dy: -6.0 }, ), CurveRel( Offset { dx: 0.0, dy: -5.0 }, Offset { dx: 8.0, dy: -6.0 }, Offset { dx: 9.0, dy: -1.0 }, ), CurveRel( Offset { dx: 7.0, dy: -2.0 }, Offset { dx: 14.0, dy: 4.0 }, Offset { dx: 11.0, dy: 7.0 }, ), CloseRel, ]; out.render_path(&icon_segs, &None, &None); } /// The function generates ECB entity icon to vector graphics drawing directives /// /// # Panics /// /// This function panics if PathRenderer cannot write to the output sink. /// pub fn generate_ecb_entity(out: &mut dyn PathRenderer) -> () { /* circle */ let icon_segs: [geometry::DrawDirective; 5] = get_circle_abs(Point { x: 18.0, y: 18.0 }, 12.0, 12.0); out.render_path(&icon_segs, &None, &None); /* bottom cylinder */ let icon_segs: [geometry::DrawDirective; 2] = [ Move(Point { x: 7.0, y: 30.5 }), Line(Point { x: 29.0, y: 30.5 }), ]; out.render_path(&icon_segs, &None, &None); } /// The function generates ECB control icon to vector graphics drawing directives /// /// # Panics /// /// This function panics if PathRenderer cannot write to the output sink. /// pub fn generate_ecb_control(out: &mut dyn PathRenderer) -> () { /* circle */ let icon_segs: [geometry::DrawDirective; 5] = get_circle_abs(Point { x: 18.0, y: 18.0 }, 12.0, 12.0); out.render_path(&icon_segs, &None, &None); /* bottom cylinder */ let icon_segs: [geometry::DrawDirective; 3] = [ Move(Point { x: 22.0, y: 1.0 }), Line(Point { x: 17.0, y: 6.0 }), Line(Point { x: 22.0, y: 11.0 }), ]; out.render_path(&icon_segs, &None, &None); } /// The function generates ECB boundary icon to vector graphics drawing directives /// /// # Panics /// /// This function panics if PathRenderer cannot write to the output sink. /// pub fn generate_ecb_boundary(out: &mut dyn PathRenderer) -> () { /* circle */ let icon_segs: [geometry::DrawDirective; 5] = get_circle_abs(Point { x: 18.0, y: 18.0 }, 12.0, 12.0); out.render_path(&icon_segs, &None, &None); /* bottom cylinder */ let icon_segs: [geometry::DrawDirective; 4] = [ Move(Point { x: 1.0, y: 9.0 }), Line(Point { x: 1.0, y: 27.0 }), Move(Point { x: 1.0, y: 18.0 }), Line(Point { x: 6.0, y: 18.0 }), ]; out.render_path(&icon_segs, &None, &None); } /// The function generates a GSN goal icon to vector graphics drawing directives /// /// # Panics /// /// This function panics if PathRenderer cannot write to the output sink. /// pub fn generate_gsn_goal(out: &mut dyn PathRenderer) -> () { let icon_segs: [geometry::DrawDirective; 5] = [ Move(Point { x: 1.0, y: 7.0 }), Line(Point { x: 31.0, y: 7.0 }), Line(Point { x: 31.0, y: 25.0 }), Line(Point { x: 1.0, y: 25.0 }), Close, ]; out.render_path(&icon_segs, &Some(BLUE_PEN), &None); } /// The function generates a GSN context icon to vector graphics drawing directives /// /// # Panics /// /// This function panics if PathRenderer cannot write to the output sink. /// pub fn generate_gsn_context(out: &mut dyn PathRenderer) -> () { let icon_segs: [geometry::DrawDirective; 5] = [ Move(Point { x: 8.0, y: 25.0 }), Curve( Point { x: 0.0, y: 25.0 }, Point { x: 0.0, y: 7.0 }, Point { x: 8.0, y: 7.0 }, ), Line(Point { x: 24.0, y: 7.0 }), Curve( Point { x: 32.0, y: 7.0 }, Point { x: 32.0, y: 25.0 }, Point { x: 24.0, y: 25.0 }, ), Close, ]; out.render_path(&icon_segs, &Some(BLUE_PEN), &None); } /// The function generates a GSN strategy icon to vector graphics drawing directives /// /// # Panics /// /// This function panics if PathRenderer cannot write to the output sink. /// pub fn generate_gsn_strategy(out: &mut dyn PathRenderer) -> () { let icon_segs: [geometry::DrawDirective; 5] = [ Move(Point { x: 7.0, y: 7.0 }), Line(Point { x: 31.0, y: 7.0 }), Line(Point { x: 25.0, y: 25.0 }), Line(Point { x: 1.0, y: 25.0 }), Close, ]; out.render_path(&icon_segs, &Some(BLUE_PEN), &None); } /// The function generates a GSN assumption icon to vector graphics drawing directives /// /// # Panics /// /// This function panics if PathRenderer cannot write to the output sink. /// pub fn generate_gsn_assumption(out: &mut dyn PathRenderer) -> () { /* ellipsis */ let icon_segs: [geometry::DrawDirective; 5] = get_circle_abs(Point { x: 16.0, y: 10.0 }, 15.0, 8.0); out.render_path(&icon_segs, &Some(BLUE_PEN), &None); /* A-character */ let icon_segs: [geometry::DrawDirective; 5] = [ Move(Point { x: 24.0, y: 25.0 }), Line(Point { x: 26.5, y: 19.0 }), Line(Point { x: 29.0, y: 25.0 }), Move(Point { x: 24.75, y: 23.5 }), Line(Point { x: 28.25, y: 23.5 }), ]; out.render_path(&icon_segs, &Some(BLUE_PEN), &None); } /// The function generates a GSN justification icon to vector graphics drawing directives /// /// # Panics /// /// This function panics if PathRenderer cannot write to the output sink. /// pub fn generate_gsn_justification(out: &mut dyn PathRenderer) -> () { let icon_segs: [geometry::DrawDirective; 5] = get_circle_abs(Point { x: 16.0, y: 10.0 }, 15.0, 8.0); out.render_path(&icon_segs, &Some(BLUE_PEN), &None); /* J-character */ let icon_segs: [geometry::DrawDirective; 4] = [ Move(Point { x: 25.0, y: 24.0 }), Curve( Point { x: 25.0, y: 26.0 }, Point { x: 29.0, y: 26.0 }, Point { x: 29.0, y: 24.0 }, ), Line(Point { x: 29.0, y: 19.0 }), Line(Point { x: 25.0, y: 19.0 }), ]; out.render_path(&icon_segs, &Some(BLUE_PEN), &None); } /// The function generates a GSN solution icon to vector graphics drawing directives /// /// # Panics /// /// This function panics if PathRenderer cannot write to the output sink. /// pub fn generate_gsn_solution(out: &mut dyn PathRenderer) -> () { let icon_segs: [geometry::DrawDirective; 5] = get_circle_abs(Point { x: 16.0, y: 16.0 }, 15.0, 15.0); out.render_path(&icon_segs, &Some(BLUE_PEN), &None); } /// The function generates a buffer icon of queueing theory to vector graphics drawing directives /// /// # Panics /// /// This function panics if PathRenderer cannot write to the output sink. /// pub fn generate_queue_buffer(out: &mut dyn PathRenderer) -> () { /* box */ let icon_segs: [geometry::DrawDirective; 4] = [ Move(Point { x: 1.0, y: 8.0 }), Line(Point { x: 31.0, y: 8.0 }), Line(Point { x: 31.0, y: 24.0 }), Line(Point { x: 1.0, y: 24.0 }), ]; out.render_path(&icon_segs, &None, &None); /* 3 elements */ let icon_segs: [geometry::DrawDirective; 6] = [ Move(Point { x: 13.0, y: 8.0 }), Line(Point { x: 13.0, y: 24.0 }), Move(Point { x: 19.0, y: 8.0 }), Line(Point { x: 19.0, y: 24.0 }), Move(Point { x: 25.0, y: 8.0 }), Line(Point { x: 25.0, y: 24.0 }), ]; out.render_path(&icon_segs, &None, &None); } /// The function generates a server icon of queueing theory to vector graphics drawing directives /// /// # Panics /// /// This function panics if PathRenderer cannot write to the output sink. /// pub fn generate_queue_server(out: &mut dyn PathRenderer) -> () { let icon_segs: [geometry::DrawDirective; 5] = get_circle_abs(Point { x: 16.0, y: 16.0 }, 15.0, 15.0); out.render_path(&icon_segs, &None, &None); } /// The function generates a queue icon of queueing theory to vector graphics drawing directives /// /// # Panics /// /// This function panics if PathRenderer cannot write to the output sink. /// pub fn generate_queue_queue(out: &mut dyn PathRenderer) -> () { /* box */ let icon_segs: [geometry::DrawDirective; 4] = [ Move(Point { x: 1.0, y: 11.0 }), Line(Point { x: 18.5, y: 11.0 }), Line(Point { x: 18.5, y: 21.0 }), Line(Point { x: 1.0, y: 21.0 }), ]; out.render_path(&icon_segs, &None, &None); /* 3 elements */ let icon_segs: [geometry::DrawDirective; 6] = [ Move(Point { x: 8.0, y: 11.0 }), Line(Point { x: 8.0, y: 21.0 }), Move(Point { x: 11.5, y: 11.0 }), Line(Point { x: 11.5, y: 21.0 }), Move(Point { x: 15.0, y: 11.0 }), Line(Point { x: 15.0, y: 21.0 }), ]; out.render_path(&icon_segs, &None, &None); /* circle */ let icon_segs: [geometry::DrawDirective; 5] = get_circle_abs(Point { x: 26.0, y: 16.0 }, 5.0, 5.0); out.render_path(&icon_segs, &None, &None); } /// The function generates a rationale/decision icon to vector graphics drawing directives /// /// # Panics /// /// This function panics if PathRenderer cannot write to the output sink. /// pub fn generate_reason_decision(out: &mut dyn PathRenderer) -> () { /* two trays */ let icon_segs: [geometry::DrawDirective; 13] = [ MoveRel(Offset { dx: 8.0, dy: 12.0 }), LineRel(Offset { dx: -4.0, dy: 7.0 }), ContinueRel(Offset { dx: 1.0, dy: 1.0 }), ContinueRel(Offset { dx: 6.0, dy: 0.0 }), ContinueRel(Offset { dx: 1.0, dy: -1.0 }), ContinueRel(Offset { dx: -4.0, dy: -7.0 }), LineRel(Offset { dx: 8.0, dy: -4.0 }), ContinueRel(Offset { dx: 9.0, dy: 0.0 }), LineRel(Offset { dx: -4.0, dy: 7.0 }), ContinueRel(Offset { dx: 1.0, dy: 1.0 }), ContinueRel(Offset { dx: 6.0, dy: 0.0 }), ContinueRel(Offset { dx: 1.0, dy: -1.0 }), ContinueRel(Offset { dx: -4.0, dy: -7.0 }), ]; out.render_path(&icon_segs, &None, &None); /* stand and scale */ let icon_segs: [geometry::DrawDirective; 4] = [ MoveRel(Offset { dx: 15.0, dy: 5.0 }), LineRel(Offset { dx: 1.0, dy: 3.0 }), MoveRel(Offset { dx: 0.0, dy: 2.0 }), LineRel(Offset { dx: 0.0, dy: 17.0 }), ]; out.render_path(&icon_segs, &None, &None); } /// The function generates a rationale/chosen icon to vector graphics drawing directives /// /// # Panics /// /// This function panics if PathRenderer cannot write to the output sink. /// pub fn generate_reason_chosen(out: &mut dyn PathRenderer) -> () { /* rejected tray */ let icon_segs: [geometry::DrawDirective; 4] = [ MoveRel(Offset { dx: 1.0, dy: 24.0 }), ContinueRel(Offset { dx: 4.0, dy: 4.0 }), ContinueRel(Offset { dx: 22.0, dy: 0.0 }), ContinueRel(Offset { dx: 4.0, dy: -4.0 }), ]; out.render_path(&icon_segs, &None, &None); /* minus */ let icon_segs: [geometry::DrawDirective; 5] = get_circle_rel(Offset { dx: 16.0, dy: 17.0 }, 8.0, 8.0); out.render_path(&icon_segs, &Some(GREEN_PEN), &None); let icon_segs: [geometry::DrawDirective; 4] = [ MoveRel(Offset { dx: 11.0, dy: 17.0 }), LineRel(Offset { dx: 10.0, dy: 0.0 }), MoveRel(Offset { dx: -5.0, dy: -5.0 }), LineRel(Offset { dx: 0.0, dy: 10.0 }), ]; out.render_path(&icon_segs, &Some(GREEN_PEN), &None); } /// The function generates a rationale/rejected icon to vector graphics drawing directives /// /// # Panics /// /// This function panics if PathRenderer cannot write to the output sink. /// pub fn generate_reason_rejected(out: &mut dyn PathRenderer) -> () { /* rejected tray */ let icon_segs: [geometry::DrawDirective; 4] = [ MoveRel(Offset { dx: 1.0, dy: 24.0 }), ContinueRel(Offset { dx: 4.0, dy: 4.0 }), ContinueRel(Offset { dx: 22.0, dy: 0.0 }), ContinueRel(Offset { dx: 4.0, dy: -4.0 }), ]; out.render_path(&icon_segs, &None, &None); /* minus */ let icon_segs: [geometry::DrawDirective; 5] = get_circle_rel(Offset { dx: 16.0, dy: 17.0 }, 8.0, 8.0); out.render_path(&icon_segs, &Some(RED_PEN), &None); let icon_segs: [geometry::DrawDirective; 2] = [ MoveRel(Offset { dx: 11.0, dy: 17.0 }), LineRel(Offset { dx: 10.0, dy: 0.0 }), ]; out.render_path(&icon_segs, &Some(RED_PEN), &None); } /// The function generates a object flow icon to vector graphics drawing directives /// /// # Panics /// /// This function panics if PathRenderer cannot write to the output sink. /// pub fn generate_flow_object(out: &mut dyn PathRenderer) -> () { let icon_segs: [geometry::DrawDirective; 7] = [ Move(Point { x: 32.0, y: 32.0 }), Move(Point { x: 0.0, y: 0.0 }), Move(Point { x: 5.0, y: 5.0 }), Continue(Point { x: 27.0, y: 5.0 }), Continue(Point { x: 27.0, y: 27.0 }), Continue(Point { x: 5.0, y: 27.0 }), Close, ]; out.render_path(&icon_segs, &None, &None); } /// The function generates an control flow icon to vector graphics drawing directives /// /// # Panics /// /// This function panics if PathRenderer cannot write to the output sink. /// pub fn generate_flow_control(out: &mut dyn PathRenderer) -> () { let icon_segs: [geometry::DrawDirective; 15] = [ Move(Point { x: 1.0, y: 16.0 }), LineRel(Offset { dx: 2.0, dy: 0.0 }), MoveRel(Offset { dx: 3.0, dy: 0.0 }), LineRel(Offset { dx: 2.0, dy: 0.0 }), MoveRel(Offset { dx: 3.0, dy: 0.0 }), LineRel(Offset { dx: 2.0, dy: 0.0 }), MoveRel(Offset { dx: 3.0, dy: 0.0 }), LineRel(Offset { dx: 2.0, dy: 0.0 }), MoveRel(Offset { dx: 3.0, dy: 0.0 }), LineRel(Offset { dx: 2.0, dy: 0.0 }), MoveRel(Offset { dx: 3.0, dy: 0.0 }), LineRel(Offset { dx: 3.5, dy: 0.0 }), Move(Point { x: 25.0, y: 13.0 }), LineRel(Offset { dx: 5.0, dy: 3.0 }), LineRel(Offset { dx: -5.0, dy: 3.0 }), ]; out.render_path(&icon_segs, &None, &None); } /// The function generates an error flow icon to vector graphics drawing directives /// /// # Panics /// /// This function panics if PathRenderer cannot write to the output sink. /// pub fn generate_flow_exception(out: &mut dyn PathRenderer) -> () { let icon_segs: [geometry::DrawDirective; 7] = [ Move(Point { x: 1.0, y: 9.0 }), Continue(Point { x: 27.0, y: 9.0 }), Continue(Point { x: 1.0, y: 23.0 }), Continue(Point { x: 30.0, y: 23.0 }), Move(Point { x: 26.0, y: 20.0 }), Continue(Point { x: 31.0, y: 23.0 }), Continue(Point { x: 26.0, y: 26.0 }), ]; out.render_path(&icon_segs, &None, &None); } /// The function returns an array of IconSource /// pub fn get_icons() -> &'static [IconSource<'static>] { &[ IconSource { name: "deploy_database", viewport: ICON_VIEW_RECT, generate: generate_deploy_database, }, IconSource { name: "deploy_local", viewport: ICON_VIEW_RECT, generate: generate_deploy_local, }, IconSource { name: "deploy_cloud", viewport: ICON_VIEW_RECT, generate: generate_deploy_cloud, }, IconSource { name: "ecb_entity", viewport: ICON_VIEW_RECT, generate: generate_ecb_entity, }, IconSource { name: "ecb_control", viewport: ICON_VIEW_RECT, generate: generate_ecb_control, }, IconSource { name: "ecb_boundary", viewport: ICON_VIEW_RECT, generate: generate_ecb_boundary, }, IconSource { name: "gsn_goal", viewport: ICON_VIEW_RECT, generate: generate_gsn_goal, }, IconSource { name: "gsn_context", viewport: ICON_VIEW_RECT, generate: generate_gsn_context, }, IconSource { name: "gsn_strategy", viewport: ICON_VIEW_RECT, generate: generate_gsn_strategy, }, IconSource { name: "gsn_assumption", viewport: ICON_VIEW_RECT, generate: generate_gsn_assumption, }, IconSource { name: "gsn_justification", viewport: ICON_VIEW_RECT, generate: generate_gsn_justification, }, IconSource { name: "gsn_solution", viewport: ICON_VIEW_RECT, generate: generate_gsn_solution, }, IconSource { name: "queue_buffer", viewport: ICON_VIEW_RECT, generate: generate_queue_buffer, }, IconSource { name: "queue_server", viewport: ICON_VIEW_RECT, generate: generate_queue_server, }, IconSource { name: "queue_queue", viewport: ICON_VIEW_RECT, generate: generate_queue_queue, }, IconSource { name: "reason_decision", viewport: ICON_VIEW_RECT, generate: generate_reason_decision, }, IconSource { name: "reason_chosen", viewport: ICON_VIEW_RECT, generate: generate_reason_chosen, }, IconSource { name: "reason_rejected", viewport: ICON_VIEW_RECT, generate: generate_reason_rejected, }, IconSource { name: "flow_object", viewport: ICON_VIEW_RECT, generate: generate_flow_object, }, IconSource { name: "flow_control", viewport: ICON_VIEW_RECT, generate: generate_flow_control, }, IconSource { name: "flow_exception", viewport: ICON_VIEW_RECT, generate: generate_flow_exception, }, ] } crystal-facet-uml-1.63.3/build/icon_artist/src/icon_data/type_class_icon.rs000066400000000000000000000142461500562027500270220ustar00rootroot00000000000000//! The module provides functions to render an icon to vector graphics. use super::shape::get_circle_abs; use crate::model::icon::IconSource; use crate::stream_if::geometry; use crate::stream_if::geometry::DrawDirective::Close; use crate::stream_if::geometry::DrawDirective::CurveRel; use crate::stream_if::geometry::DrawDirective::LineRel; use crate::stream_if::geometry::DrawDirective::Move; use crate::stream_if::geometry::Offset; use crate::stream_if::geometry::Point; use crate::stream_if::geometry::Rect; use crate::stream_if::path_renderer::PathRenderer; /// The view rectangle of each icon const ICON_VIEW_RECT: Rect = Rect { left: 0.0, top: 0.0, width: 32.0, height: 24.0, }; /// gray line color static GRAY: geometry::Color = geometry::Color { red: 0x7f, green: 0x7f, blue: 0x7f, }; /// gray pen static GRAY_PEN: geometry::Pen = geometry::Pen { color: GRAY, width: 1.0, }; /// The function generates a gear wheel to vector graphics drawing directives /// pub fn generate_type_clas_stereotype(out: &mut dyn PathRenderer) -> () { /* spoke of wheel */ let r3: f32 = 11.0; let r2: f32 = 10.0; let r1: f32 = 8.5; let cx: f32 = 16.0; let cy: f32 = 12.0; let mut icon_segs: [geometry::DrawDirective; 61] = [Close; 61]; icon_segs[0] = Move(Point { x: cx + r2, y: cy }); for index in 0..10 { let alpha: f32 = std::f32::consts::PI / 5.0 * (index as f32); let a_dx = alpha.cos(); let a_dy = alpha.sin(); let beta: f32 = std::f32::consts::PI / 5.0 * ((index as f32) + 0.05); let b_dx = beta.cos(); let b_dy = beta.sin(); let gamma: f32 = std::f32::consts::PI / 5.0 * ((index as f32) + 0.5); let g_dx = gamma.cos(); let g_dy = gamma.sin(); let delta: f32 = std::f32::consts::PI / 5.0 * ((index as f32) + 0.55); let d_dx = delta.cos(); let d_dy = delta.sin(); let epsilon: f32 = std::f32::consts::PI / 5.0 * ((index as f32) + 0.65); let e_dx = epsilon.cos(); let e_dy = epsilon.sin(); let zeta: f32 = std::f32::consts::PI / 5.0 * ((index as f32) + 0.9); let z_dx = zeta.cos(); let z_dy = zeta.sin(); let omega: f32 = std::f32::consts::PI / 5.0 * ((index as f32) + 1.0); let o_dx = omega.cos(); let o_dy = omega.sin(); icon_segs[index * 6 + 1] = LineRel(Offset { dx: (-r2) * a_dx + r1 * b_dx, dy: (-r2) * a_dy + r1 * b_dy, }); icon_segs[index * 6 + 2] = LineRel(Offset { dx: (-r1) * b_dx + r1 * g_dx, dy: (-r1) * b_dy + r1 * g_dy, }); icon_segs[index * 6 + 3] = LineRel(Offset { dx: (-r1) * g_dx + r2 * d_dx, dy: (-r1) * g_dy + r2 * d_dy, }); icon_segs[index * 6 + 4] = LineRel(Offset { dx: (-r2) * d_dx + r3 * e_dx, dy: (-r2) * d_dy + r3 * e_dy, }); icon_segs[index * 6 + 5] = LineRel(Offset { dx: (-r3) * e_dx + r3 * z_dx, dy: (-r3) * e_dy + r3 * z_dy, }); icon_segs[index * 6 + 6] = LineRel(Offset { dx: (-r3) * z_dx + r2 * o_dx, dy: (-r3) * z_dy + r2 * o_dy, }); } out.render_path(&icon_segs, &Some(GRAY_PEN), &None); /* rim of wheel */ let icon_segs: [geometry::DrawDirective; 5] = get_circle_abs(Point { x: cx, y: cy }, 2.0, 2.0); out.render_path(&icon_segs, &Some(GRAY_PEN), &None); } /// The function generates a flower image to vector graphics drawing directives /// /// # Panics /// /// This function panics if PathRenderer cannot write to the output sink. /// pub fn generate_type_clas_image(out: &mut dyn PathRenderer) -> () { /* flower leaves */ let r3: f32 = 11.0; let r2: f32 = 9.0; let r1: f32 = 4.25; let cx: f32 = 16.0; let cy: f32 = 12.0; let mut icon_segs: [geometry::DrawDirective; 21] = [Close; 21]; icon_segs[0] = Move(Point { x: cx + r1, y: cy }); for index in 0..10 { let alpha: f32 = std::f32::consts::PI / 5.0 * (index as f32); let a_dx = alpha.cos(); let a_dy = alpha.sin(); let beta: f32 = std::f32::consts::PI / 5.0 * ((index as f32) + 0.3); let b_dx = beta.cos(); let b_dy = beta.sin(); let gamma: f32 = std::f32::consts::PI / 5.0 * ((index as f32) + 0.5); let g_dx = gamma.cos(); let g_dy = gamma.sin(); let delta: f32 = std::f32::consts::PI / 5.0 * ((index as f32) + 0.7); let d_dx = delta.cos(); let d_dy = delta.sin(); let omega: f32 = std::f32::consts::PI / 5.0 * ((index as f32) + 1.0); let o_dx = omega.cos(); let o_dy = omega.sin(); icon_segs[index * 2 + 1] = CurveRel( Offset { dx: (-r1) * a_dx + r2 * a_dx, dy: (-r1) * a_dy + r2 * a_dy, }, Offset { dx: (-r1) * a_dx + r3 * b_dx, dy: (-r1) * a_dy + r3 * b_dy, }, Offset { dx: (-r1) * a_dx + r3 * g_dx, dy: (-r1) * a_dy + r3 * g_dy, }, ); icon_segs[index * 2 + 2] = CurveRel( Offset { dx: (-r3) * g_dx + r3 * d_dx, dy: (-r3) * g_dy + r3 * d_dy, }, Offset { dx: (-r3) * g_dx + r2 * o_dx, dy: (-r3) * g_dy + r2 * o_dy, }, Offset { dx: (-r3) * g_dx + r1 * o_dx, dy: (-r3) * g_dy + r1 * o_dy, }, ); } out.render_path(&icon_segs, &Some(GRAY_PEN), &None); /* flower center */ let icon_segs: [geometry::DrawDirective; 5] = get_circle_abs(Point { x: cx, y: cy }, 3.25, 3.25); out.render_path(&icon_segs, &Some(GRAY_PEN), &None); } /// The function returns an array of IconSource /// pub fn get_icons() -> &'static [IconSource<'static>] { &[ IconSource { name: "type_clas_stereotype", viewport: ICON_VIEW_RECT, generate: generate_type_clas_stereotype, }, IconSource { name: "type_clas_image", viewport: ICON_VIEW_RECT, generate: generate_type_clas_image, }, ] } crystal-facet-uml-1.63.3/build/icon_artist/src/icon_data/type_diag_icon.rs000066400000000000000000000704151500562027500266210ustar00rootroot00000000000000//! The module provides functions to render an icon to vector graphics. use super::shape::get_circle_abs; use super::shape::get_rect_abs; use super::shape::get_rounded_rect_abs; use crate::model::icon::IconSource; use crate::stream_if::geometry; use crate::stream_if::geometry::DrawDirective::Close; use crate::stream_if::geometry::DrawDirective::CloseRel; use crate::stream_if::geometry::DrawDirective::Curve; use crate::stream_if::geometry::DrawDirective::CurveRel; use crate::stream_if::geometry::DrawDirective::Line; use crate::stream_if::geometry::DrawDirective::LineRel; use crate::stream_if::geometry::DrawDirective::Move; use crate::stream_if::geometry::Offset; use crate::stream_if::geometry::Point; use crate::stream_if::geometry::Rect; use crate::stream_if::path_renderer::PathRenderer; /// The view rectangle of each icon const ICON_VIEW_RECT: Rect = Rect { left: 0.0, top: 0.0, width: 32.0, height: 24.0, }; /// icon center x const CX: f32 = 16.0; /// icon center y const CY: f32 = 12.0; /// gray line color static GRAY: geometry::Color = geometry::Color { red: 0x7f, green: 0x7f, blue: 0x7f, }; /// half line width const HALFLINE: f32 = 0.5; /// gray pen static GRAY_PEN: geometry::Pen = geometry::Pen { color: GRAY, width: 1.0, }; /// gray bold pen static GRAY_THICK_PEN: geometry::Pen = geometry::Pen { color: GRAY, width: 2.0, }; /// The function generates a type_diag_activity /// pub fn generate_type_diag_activity(out: &mut dyn PathRenderer) -> () { let icon_segs_start: [geometry::DrawDirective; 2] = [ Move(Point { x: 0.0, y: CY - HALFLINE, }), LineRel(Offset { dx: 3.0, dy: 0.0 }), ]; out.render_path(&icon_segs_start, &Some(GRAY_PEN), &None); let icon_segs_start: [geometry::DrawDirective; 2] = [ Move(Point { x: 29.0, y: CY - HALFLINE, }), LineRel(Offset { dx: 3.0, dy: 0.0 }), ]; out.render_path(&icon_segs_start, &Some(GRAY_PEN), &None); let icon_segs_fork: [geometry::DrawDirective; 2] = [ Move(Point { x: 5.0, y: CY - 7.0, }), LineRel(Offset { dx: 0.0, dy: 13.0 }), ]; out.render_path(&icon_segs_fork, &Some(GRAY_THICK_PEN), &None); let icon_segs_join: [geometry::DrawDirective; 2] = [ Move(Point { x: 27.0, y: CY - 7.0, }), LineRel(Offset { dx: 0.0, dy: 13.0 }), ]; out.render_path(&icon_segs_join, &Some(GRAY_THICK_PEN), &None); let icon_segs_act1: [geometry::DrawDirective; 9] = get_rounded_rect_abs( Rect { left: CX - 6.0 - HALFLINE, top: 3.0 - HALFLINE, width: 13.0, height: 7.0, }, 3.0, ); out.render_path(&icon_segs_act1, &Some(GRAY_PEN), &None); let icon_segs_act2: [geometry::DrawDirective; 9] = get_rounded_rect_abs( Rect { left: CX - 6.0 - HALFLINE, top: 14.0 - HALFLINE, width: 13.0, height: 7.0, }, 3.0, ); out.render_path(&icon_segs_act2, &Some(GRAY_PEN), &None); } /// The function generates a type_diag_block /// pub fn generate_type_diag_block(out: &mut dyn PathRenderer) -> () { let icon_segs_left: [geometry::DrawDirective; 5] = get_rect_abs(Rect { left: 2.0, top: 2.0, width: 10.0, height: 20.0, }); out.render_path(&icon_segs_left, &Some(GRAY_THICK_PEN), &None); let icon_segs_right: [geometry::DrawDirective; 5] = get_rect_abs(Rect { left: 20.0, top: 2.0, width: 10.0, height: 20.0, }); out.render_path(&icon_segs_right, &Some(GRAY_THICK_PEN), &None); let icon_segs_link: [geometry::DrawDirective; 4] = [ Move(Point { x: 14.0, y: CY + 3.0 + HALFLINE, }), Line(Point { x: 18.0, y: CY + 3.0 + HALFLINE, }), Move(Point { x: 14.0, y: CY - 3.0 - HALFLINE, }), Line(Point { x: 18.0, y: CY - 3.0 - HALFLINE, }), ]; out.render_path(&icon_segs_link, &Some(GRAY_PEN), &None); } /// The function generates a type_diag_box /// pub fn generate_type_diag_box(out: &mut dyn PathRenderer) -> () { let icon_segs_left: [geometry::DrawDirective; 5] = get_rect_abs(Rect { left: 2.0, top: 8.0, width: 7.0, height: 7.0, }); out.render_path(&icon_segs_left, &Some(GRAY_THICK_PEN), &None); let icon_segs_mid: [geometry::DrawDirective; 5] = get_rect_abs(Rect { left: 13.0, top: 15.0, width: 7.0, height: 7.0, }); out.render_path(&icon_segs_mid, &Some(GRAY_THICK_PEN), &None); let icon_segs_right: [geometry::DrawDirective; 5] = get_rect_abs(Rect { left: 24.0, top: 2.0, width: 7.0, height: 7.0, }); out.render_path(&icon_segs_right, &Some(GRAY_THICK_PEN), &None); } /// The function generates a type_diag_class /// pub fn generate_type_diag_class(out: &mut dyn PathRenderer) -> () { let icon_segs_left: [geometry::DrawDirective; 5] = get_rect_abs(Rect { left: 2.0 - HALFLINE, top: 16.0 - HALFLINE, width: 6.0, height: 6.0, }); out.render_path(&icon_segs_left, &Some(GRAY_PEN), &None); let icon_segs_mid: [geometry::DrawDirective; 5] = get_rect_abs(Rect { left: 13.0 - HALFLINE, top: 2.0 - HALFLINE, width: 6.0, height: 6.0, }); out.render_path(&icon_segs_mid, &Some(GRAY_PEN), &None); let icon_segs_right: [geometry::DrawDirective; 5] = get_rect_abs(Rect { left: 24.0 - HALFLINE, top: 16.0 - HALFLINE, width: 6.0, height: 6.0, }); out.render_path(&icon_segs_right, &Some(GRAY_PEN), &None); let icon_segs_link: [geometry::DrawDirective; 4] = [ Move(Point { x: CX - HALFLINE, y: 11.0, }), LineRel(Offset { dx: 4.5, dy: 6.0 }), LineRel(Offset { dx: -9.0, dy: 0.0 }), CloseRel, ]; out.render_path(&icon_segs_link, &Some(GRAY_THICK_PEN), &None); } /// The function generates a type_diag_communication /// pub fn generate_type_diag_communication(out: &mut dyn PathRenderer) -> () { let icon_segs_top: [geometry::DrawDirective; 5] = get_rect_abs(Rect { left: CX - 4.0 - HALFLINE, top: 2.0 - HALFLINE, width: 9.0, height: 6.0, }); out.render_path(&icon_segs_top, &Some(GRAY_PEN), &None); let icon_segs_bottom: [geometry::DrawDirective; 5] = get_rect_abs(Rect { left: CX - 4.0 - HALFLINE, top: 16.0 + HALFLINE, width: 9.0, height: 6.0, }); out.render_path(&icon_segs_bottom, &Some(GRAY_PEN), &None); let icon_segs_right: [geometry::DrawDirective; 3] = [ Move(Point { x: CX + 9.0, y: 5.0, }), CurveRel( Offset { dx: 6.0, dy: 1.0 }, Offset { dx: 6.0, dy: 11.0 }, Offset { dx: 1.0, dy: 14.0 }, ), LineRel(Offset { dx: 4.0, dy: 0.0 }), ]; out.render_path(&icon_segs_right, &Some(GRAY_THICK_PEN), &None); let icon_segs_left: [geometry::DrawDirective; 3] = [ Move(Point { x: CX - 9.0, y: 19.0, }), CurveRel( Offset { dx: -6.0, dy: -1.0 }, Offset { dx: -6.0, dy: -11.0, }, Offset { dx: -1.0, dy: -14.0, }, ), LineRel(Offset { dx: -4.0, dy: 0.0 }), ]; out.render_path(&icon_segs_left, &Some(GRAY_THICK_PEN), &None); } /// The function generates a type_diag_component /// pub fn generate_type_diag_component(out: &mut dyn PathRenderer) -> () { let icon_segs_left_port: [geometry::DrawDirective; 5] = get_rect_abs(Rect { left: CX - 8.0, top: CY - 3.0, width: 5.0, height: 5.0, }); out.render_path(&icon_segs_left_port, &Some(GRAY_THICK_PEN), &None); let icon_segs_right_port: [geometry::DrawDirective; 5] = get_rect_abs(Rect { left: CX + 3.0, top: CY - 3.0, width: 5.0, height: 5.0, }); out.render_path(&icon_segs_right_port, &Some(GRAY_THICK_PEN), &None); let icon_segs_mid: [geometry::DrawDirective; 2] = [ Move(Point { x: CX - 1.0, y: CY - HALFLINE, }), Line(Point { x: CX + 1.0, y: CY - HALFLINE, }), ]; out.render_path(&icon_segs_mid, &Some(GRAY_PEN), &None); let icon_segs_left: [geometry::DrawDirective; 6] = [ Move(Point { x: CX - 6.0 + HALFLINE, y: CY + 4.0, }), LineRel(Offset { dx: 0.0, dy: 2.0 + HALFLINE, }), LineRel(Offset { dx: -9.0, dy: 0.0 }), LineRel(Offset { dx: 0.0, dy: -14.0 }), LineRel(Offset { dx: 9.0, dy: 0.0 }), LineRel(Offset { dx: 0.0, dy: 2.0 + HALFLINE, }), ]; out.render_path(&icon_segs_left, &Some(GRAY_PEN), &None); let icon_segs_right: [geometry::DrawDirective; 6] = [ Move(Point { x: CX + 6.0 - HALFLINE, y: CY + 4.0, }), LineRel(Offset { dx: 0.0, dy: 2.0 + HALFLINE, }), LineRel(Offset { dx: 9.0, dy: 0.0 }), LineRel(Offset { dx: 0.0, dy: -14.0 }), LineRel(Offset { dx: -9.0, dy: 0.0 }), LineRel(Offset { dx: 0.0, dy: 2.0 + HALFLINE, }), ]; out.render_path(&icon_segs_right, &Some(GRAY_PEN), &None); } /// The function generates a type_diag_composite /// pub fn generate_type_diag_composite(out: &mut dyn PathRenderer) -> () { let icon_segs_outer_port: [geometry::DrawDirective; 5] = get_rect_abs(Rect { left: 2.0, top: CY - 3.0, width: 5.0, height: 5.0, }); out.render_path(&icon_segs_outer_port, &Some(GRAY_THICK_PEN), &None); let icon_segs_inner_port: [geometry::DrawDirective; 5] = get_rect_abs(Rect { left: CX - 3.0, top: CY - 3.0, width: 5.0, height: 5.0, }); out.render_path(&icon_segs_inner_port, &Some(GRAY_THICK_PEN), &None); let icon_segs_conn: [geometry::DrawDirective; 2] = [ Move(Point { x: 9.0, y: CY - HALFLINE, }), Line(Point { x: 11.0, y: CY - HALFLINE, }), ]; out.render_path(&icon_segs_conn, &Some(GRAY_PEN), &None); let icon_segs_outer: [geometry::DrawDirective; 6] = [ Move(Point { x: 4.0 + HALFLINE, y: CY + 4.0, }), LineRel(Offset { dx: 0.0, dy: 5.0 + HALFLINE, }), LineRel(Offset { dx: 26.0, dy: 0.0 }), LineRel(Offset { dx: 0.0, dy: -20.0 }), LineRel(Offset { dx: -26.0, dy: 0.0 }), LineRel(Offset { dx: 0.0, dy: 5.0 + HALFLINE, }), ]; out.render_path(&icon_segs_outer, &Some(GRAY_PEN), &None); let icon_segs_inner: [geometry::DrawDirective; 6] = [ Move(Point { x: CX + 0.0 - HALFLINE, y: CY + 4.0, }), LineRel(Offset { dx: 0.0, dy: 2.0 + HALFLINE, }), LineRel(Offset { dx: 12.0, dy: 0.0 }), LineRel(Offset { dx: 0.0, dy: -14.0 }), LineRel(Offset { dx: -12.0, dy: 0.0 }), LineRel(Offset { dx: 0.0, dy: 2.0 + HALFLINE, }), ]; out.render_path(&icon_segs_inner, &Some(GRAY_PEN), &None); } /// The function generates a type_diag_deployment /// pub fn generate_type_diag_deployment(out: &mut dyn PathRenderer) -> () { let icon_segs_component: [geometry::DrawDirective; 5] = get_rect_abs(Rect { left: CX - 5.0 - HALFLINE, top: 1.0 + HALFLINE, width: 11.0, height: 4.0, }); out.render_path(&icon_segs_component, &Some(GRAY_PEN), &None); let icon_segs_device: [geometry::DrawDirective; 5] = get_rect_abs(Rect { left: CX - 13.0, top: 12.0, width: 23.0, height: 10.0, }); out.render_path(&icon_segs_device, &Some(GRAY_THICK_PEN), &None); let icon_segs_inner: [geometry::DrawDirective; 5] = [ Move(Point { x: CX - 13.0, y: 12.0, }), LineRel(Offset { dx: 3.0 + HALFLINE, dy: -3.0 - HALFLINE, }), LineRel(Offset { dx: 23.0, dy: 0.0 }), LineRel(Offset { dx: 0.0, dy: 10.0 }), LineRel(Offset { dx: -3.0 - HALFLINE, dy: 3.0 + HALFLINE, }), ]; out.render_path(&icon_segs_inner, &Some(GRAY_PEN), &None); } /// The function generates a type_diag_internal /// pub fn generate_type_diag_internal(out: &mut dyn PathRenderer) -> () { let icon_segs_outer: [geometry::DrawDirective; 5] = get_rect_abs(Rect { left: CX - 11.0, top: 2.0, width: 22.0, height: 20.0, }); out.render_path(&icon_segs_outer, &Some(GRAY_THICK_PEN), &None); let icon_segs_inner: [geometry::DrawDirective; 5] = get_rect_abs(Rect { left: CX - 5.0, top: 5.0, width: 10.0, height: 14.0, }); out.render_path(&icon_segs_inner, &Some(GRAY_THICK_PEN), &None); } /// The function generates a type_diag_list /// pub fn generate_type_diag_list(out: &mut dyn PathRenderer) -> () { let icon_segs_inner: [geometry::DrawDirective; 6] = [ Move(Point { x: CX - 11.0, y: CY - 7.0, }), Line(Point { x: CX + 11.0, y: CY - 7.0, }), Move(Point { x: CX - 11.0, y: CY, }), Line(Point { x: CX + 11.0, y: CY, }), Move(Point { x: CX - 11.0, y: CY + 7.0, }), Line(Point { x: CX + 11.0, y: CY + 7.0, }), ]; out.render_path(&icon_segs_inner, &Some(GRAY_THICK_PEN), &None); } /// The function generates a type_diag_overview /// pub fn generate_type_diag_overview(out: &mut dyn PathRenderer) -> () { let icon_segs_left_circle: [geometry::DrawDirective; 4] = [ Move(Point { x: CX - 5.5, y: CY - 1.5, }), CurveRel( Offset { dx: -1.0, dy: -3.0 }, Offset { dx: -5.5, dy: -3.0 }, Offset { dx: -5.5, dy: 1.5 }, ), CurveRel( Offset { dx: 0.0, dy: 4.5 }, Offset { dx: 6.0, dy: 4.5 }, Offset { dx: 6.0, dy: 0.0 }, ), LineRel(Offset { dx: 2.0, dy: 2.0 }), ]; out.render_path(&icon_segs_left_circle, &Some(GRAY_PEN), &None); let icon_segs_right_circle: [geometry::DrawDirective; 4] = [ Move(Point { x: CX + 5.5, y: CY + 1.5, }), CurveRel( Offset { dx: 1.0, dy: 3.0 }, Offset { dx: 5.5, dy: 3.0 }, Offset { dx: 5.5, dy: -1.5 }, ), CurveRel( Offset { dx: 0.0, dy: -4.5 }, Offset { dx: -6.0, dy: -4.5 }, Offset { dx: -6.0, dy: 0.0 }, ), LineRel(Offset { dx: -2.0, dy: -2.0 }), ]; out.render_path(&icon_segs_right_circle, &Some(GRAY_PEN), &None); let icon_segs_top: [geometry::DrawDirective; 3] = [ Move(Point { x: CX + 8.0, y: CY - 7.0, }), Curve( Point { x: CX + 3.5, y: CY - 7.0 - 4.5, }, Point { x: CX - 2.5, y: CY - 7.0 - 4.5, }, Point { x: CX - 7.0, y: CY - 7.0, }, ), Line(Point { x: CX - 6.0, y: CY - 11.0, }), ]; out.render_path(&icon_segs_top, &Some(GRAY_THICK_PEN), &None); let icon_segs_bottom: [geometry::DrawDirective; 3] = [ Move(Point { x: CX - 8.0, y: CY + 7.0, }), Curve( Point { x: CX - 3.5, y: CY + 7.0 + 4.5, }, Point { x: CX + 2.5, y: CY + 7.0 + 4.5, }, Point { x: CX + 7.0, y: CY + 7.0, }, ), Line(Point { x: CX + 6.0, y: CY + 11.0, }), ]; out.render_path(&icon_segs_bottom, &Some(GRAY_THICK_PEN), &None); } /// The function generates a type_diag_package /// pub fn generate_type_diag_package(out: &mut dyn PathRenderer) -> () { let icon_segs_box: [geometry::DrawDirective; 6] = [ Move(Point { x: CX - 10.0 + 8.0, y: 3.0, }), Line(Point { x: CX - 10.0, y: 9.0, }), Line(Point { x: CX - 10.0, y: 22.0, }), Line(Point { x: CX + 10.0, y: 22.0, }), Line(Point { x: CX + 10.0, y: 9.0, }), Line(Point { x: CX + 10.0 - 6.0, y: 1.0, }), ]; out.render_path(&icon_segs_box, &Some(GRAY_THICK_PEN), &None); let icon_segs_border: [geometry::DrawDirective; 2] = [ Move(Point { x: CX - 10.0 + 2.0, y: 9.0 + HALFLINE, }), Line(Point { x: CX + 10.0 - 2.0, y: 9.0 + HALFLINE, }), ]; out.render_path(&icon_segs_border, &Some(GRAY_PEN), &None); } /// The function generates a type_diag_parametric /// pub fn generate_type_diag_parametric(out: &mut dyn PathRenderer) -> () { let icon_segs_equation: [geometry::DrawDirective; 9] = get_rounded_rect_abs( Rect { left: CX - 6.0 - HALFLINE, top: CY - 6.0 - HALFLINE, width: 13.0, height: 13.0, }, 3.0, ); out.render_path(&icon_segs_equation, &Some(GRAY_PEN), &None); let icon_segs_in1: [geometry::DrawDirective; 5] = get_rect_abs(Rect { left: CX - 6.0 - HALFLINE, top: CY - 4.0 - HALFLINE, width: 3.0, height: 3.0, }); out.render_path(&icon_segs_in1, &Some(GRAY_PEN), &None); let icon_segs_in2: [geometry::DrawDirective; 5] = get_rect_abs(Rect { left: CX - 6.0 - HALFLINE, top: CY + 1.0 + HALFLINE, width: 3.0, height: 3.0, }); out.render_path(&icon_segs_in2, &Some(GRAY_PEN), &None); let icon_segs_out: [geometry::DrawDirective; 5] = get_rect_abs(Rect { left: CX + 4.0 - HALFLINE, top: CY - 1.0 - HALFLINE, width: 3.0, height: 3.0, }); out.render_path(&icon_segs_out, &Some(GRAY_PEN), &None); let icon_segs_lines: [geometry::DrawDirective; 6] = [ Move(Point { x: CX - 15.0, y: CY - 3.0, }), Line(Point { x: CX - 8.0, y: CY - 3.0, }), Move(Point { x: CX - 15.0, y: CY + 3.0, }), Line(Point { x: CX - 8.0, y: CY + 3.0, }), Move(Point { x: CX + 8.0, y: CY }), Line(Point { x: CX + 15.0, y: CY, }), ]; out.render_path(&icon_segs_lines, &Some(GRAY_THICK_PEN), &None); } /// The function generates a type_diag_profile /// pub fn generate_type_diag_profile(out: &mut dyn PathRenderer) -> () { let icon_segs_left_circle: [geometry::DrawDirective; 5] = get_circle_abs(Point { x: 9.0, y: 15.0 }, 6.0, 6.0); out.render_path(&icon_segs_left_circle, &Some(GRAY_THICK_PEN), &None); let icon_segs_right_circle: [geometry::DrawDirective; 5] = get_circle_abs(Point { x: 25.0, y: 6.0 }, 4.0, 4.0); out.render_path(&icon_segs_right_circle, &Some(GRAY_THICK_PEN), &None); let icon_segs_lines: [geometry::DrawDirective; 4] = [ Move(Point { x: 11.0, y: 7.5 }), Line(Point { x: 20.0, y: 3.0 }), Move(Point { x: 24.0, y: 12.0 }), Line(Point { x: 16.0, y: 18.0 }), ]; out.render_path(&icon_segs_lines, &Some(GRAY_PEN), &None); } /// The function generates a type_diag_requirement /// pub fn generate_type_diag_requirement(out: &mut dyn PathRenderer) -> () { let icon_segs_goal: [geometry::DrawDirective; 6] = [ Move(Point { x: 10.0, y: 23.0 }), Line(Point { x: 10.0, y: 1.0 }), Move(Point { x: 13.0, y: 3.0 }), Line(Point { x: 23.0, y: 6.0 + HALFLINE, }), Line(Point { x: 13.0, y: 10.0 }), Close, ]; out.render_path(&icon_segs_goal, &Some(GRAY_THICK_PEN), &None); } /// The function generates a type_diag_sequence /// pub fn generate_type_diag_sequence(out: &mut dyn PathRenderer) -> () { let icon_segs_arrows: [geometry::DrawDirective; 9] = [ Move(Point { x: CX - 10.0, y: 3.0, }), Line(Point { x: CX + 9.0, y: 6.0, }), Line(Point { x: CX + 6.0, y: 3.0, }), Move(Point { x: CX + 10.0, y: 10.0, }), Line(Point { x: CX - 9.0, y: 13.0, }), Line(Point { x: CX - 6.0, y: 10.0, }), Move(Point { x: CX - 10.0, y: 17.0, }), Line(Point { x: CX + 9.0, y: 20.0, }), Line(Point { x: CX + 6.0, y: 17.0, }), ]; out.render_path(&icon_segs_arrows, &Some(GRAY_THICK_PEN), &None); let icon_segs_lifelines: [geometry::DrawDirective; 4] = [ Move(Point { x: CX - 13.0 - HALFLINE, y: 1.0, }), Line(Point { x: CX - 13.0 - HALFLINE, y: 23.0, }), Move(Point { x: CX + 13.0 + HALFLINE, y: 1.0, }), Line(Point { x: CX + 13.0 + HALFLINE, y: 23.0, }), ]; out.render_path(&icon_segs_lifelines, &Some(GRAY_PEN), &None); } /// The function generates a type_diag_state /// pub fn generate_type_diag_state(out: &mut dyn PathRenderer) -> () { let icon_segs_left_circle: [geometry::DrawDirective; 5] = get_circle_abs(Point { x: 5.0, y: CY }, 3.0, 3.0); out.render_path(&icon_segs_left_circle, &Some(GRAY_THICK_PEN), &None); let icon_segs_right_circle: [geometry::DrawDirective; 5] = get_circle_abs(Point { x: 21.0, y: CY }, 9.0, 9.0); out.render_path(&icon_segs_right_circle, &Some(GRAY_THICK_PEN), &None); let icon_segs_inner_circle: [geometry::DrawDirective; 5] = get_circle_abs(Point { x: 19.0, y: CY }, 3.0, 3.0); out.render_path(&icon_segs_inner_circle, &Some(GRAY_THICK_PEN), &None); } /// The function generates a type_diag_timing /// pub fn generate_type_diag_timing(out: &mut dyn PathRenderer) -> () { let icon_segs_arrows: [geometry::DrawDirective; 10] = [ Move(Point { x: 1.0, y: 20.0 }), Line(Point { x: 6.0, y: 20.0 }), Line(Point { x: 6.0, y: 15.0 }), Line(Point { x: 11.0, y: 15.0 }), Line(Point { x: 11.0, y: 10.0 }), Line(Point { x: 16.0, y: 10.0 }), Line(Point { x: 16.0, y: 5.0 }), Line(Point { x: 26.0, y: 5.0 }), Line(Point { x: 26.0, y: 20.0 }), Line(Point { x: 31.0, y: 20.0 }), ]; out.render_path(&icon_segs_arrows, &Some(GRAY_THICK_PEN), &None); } /// The function generates a type_diag_usecase /// pub fn generate_type_diag_usecase(out: &mut dyn PathRenderer) -> () { let icon_segs_body: [geometry::DrawDirective; 21] = [ Move(Point { x: 8.0, y: 22.0 + HALFLINE, }), Line(Point { x: 3.0, y: 22.0 + HALFLINE, }), Line(Point { x: 4.0, y: 18.0 }), Line(Point { x: 3.0, y: 13.0 }), Line(Point { x: 4.0, y: 10.5 }), Line(Point { x: 2.0, y: 10.0 }), Line(Point { x: 2.0, y: 6.0 }), Line(Point { x: 4.0, y: 5.0 }), Line(Point { x: 3.0, y: 3.0 - HALFLINE, }), Line(Point { x: 5.0, y: 2.0 - HALFLINE, }), Line(Point { x: 6.0, y: 3.0 }), Line(Point { x: 5.5, y: 5.0 }), Line(Point { x: 6.0, y: 6.0 }), Line(Point { x: 6.0, y: 8.0 + HALFLINE, }), Line(Point { x: 7.0 + HALFLINE, y: 8.0 + HALFLINE, }), Line(Point { x: 7.0 + HALFLINE, y: 11.0, }), Line(Point { x: 6.5, y: 10.8 }), Line(Point { x: 6.0, y: 13.0 }), Line(Point { x: 6.5, y: 17.0 }), Line(Point { x: 6.0, y: 21.0 }), Close, ]; out.render_path(&icon_segs_body, &Some(GRAY_PEN), &None); let icon_segs_use_case: [geometry::DrawDirective; 5] = get_circle_abs( Point { x: 21.0, y: CY - 6.0, }, 9.0, 4.0, ); out.render_path(&icon_segs_use_case, &Some(GRAY_THICK_PEN), &None); /* let icon_segs_use_case2: [geometry::DrawDirective; 5] = get_circle_abs(Point { x: 21.0, y: CY + 6.0 }, 9.0, 4.0); out.render_path(&icon_segs_use_case2, &Some(GRAY_THICK_PEN), &None); */ } /// The function returns an array of IconSource /// pub fn get_icons() -> &'static [IconSource<'static>] { &[ IconSource { name: "type_diag_activity", viewport: ICON_VIEW_RECT, generate: generate_type_diag_activity, }, IconSource { name: "type_diag_block", viewport: ICON_VIEW_RECT, generate: generate_type_diag_block, }, IconSource { name: "type_diag_box", viewport: ICON_VIEW_RECT, generate: generate_type_diag_box, }, IconSource { name: "type_diag_class", viewport: ICON_VIEW_RECT, generate: generate_type_diag_class, }, IconSource { name: "type_diag_communication", viewport: ICON_VIEW_RECT, generate: generate_type_diag_communication, }, IconSource { name: "type_diag_component", viewport: ICON_VIEW_RECT, generate: generate_type_diag_component, }, IconSource { name: "type_diag_composite", viewport: ICON_VIEW_RECT, generate: generate_type_diag_composite, }, IconSource { name: "type_diag_deployment", viewport: ICON_VIEW_RECT, generate: generate_type_diag_deployment, }, IconSource { name: "type_diag_internal", viewport: ICON_VIEW_RECT, generate: generate_type_diag_internal, }, IconSource { name: "type_diag_list", viewport: ICON_VIEW_RECT, generate: generate_type_diag_list, }, IconSource { name: "type_diag_overview", viewport: ICON_VIEW_RECT, generate: generate_type_diag_overview, }, IconSource { name: "type_diag_package", viewport: ICON_VIEW_RECT, generate: generate_type_diag_package, }, IconSource { name: "type_diag_parametric", viewport: ICON_VIEW_RECT, generate: generate_type_diag_parametric, }, IconSource { name: "type_diag_profile", viewport: ICON_VIEW_RECT, generate: generate_type_diag_profile, }, IconSource { name: "type_diag_requirement", viewport: ICON_VIEW_RECT, generate: generate_type_diag_requirement, }, IconSource { name: "type_diag_sequence", viewport: ICON_VIEW_RECT, generate: generate_type_diag_sequence, }, IconSource { name: "type_diag_state", viewport: ICON_VIEW_RECT, generate: generate_type_diag_state, }, IconSource { name: "type_diag_timing", viewport: ICON_VIEW_RECT, generate: generate_type_diag_timing, }, IconSource { name: "type_diag_usecase", viewport: ICON_VIEW_RECT, generate: generate_type_diag_usecase, }, ] } crystal-facet-uml-1.63.3/build/icon_artist/src/main.rs000066400000000000000000000067321500562027500226500ustar00rootroot00000000000000#![warn(missing_docs)] //! This crate renders svg files for the icons in icon_data. pub mod icon_data; pub mod model; pub mod render; pub mod stream_if; use icon_data::gui_file_icon; use icon_data::gui_view_icon; use icon_data::stereotype_icon; use icon_data::type_class_icon; use icon_data::type_diag_icon; use model::icon::IconSource; use render::icon_writer; use render::icon_writer::FileType; use std::env; static OUT_DIR_STEREO: &'static str = "../../documentation/user_manual/4_stereotypes"; static OUT_DIR_GUI: &'static str = "../../gui/source/resources"; /// The main function defines parameters and starts the icon_writer. fn main() { let args: Vec = env::args().collect(); for argument in args { let arg = argument.as_str(); if arg == "-f" { let gui_file_icons: &'static [IconSource<'static>] = gui_file_icon::get_icons(); icon_writer::generate_files(gui_file_icons, FileType::Svg, OUT_DIR_GUI); icon_writer::generate_files(gui_file_icons, FileType::PixBuf, OUT_DIR_GUI); println!("Generated files have been written to '{}'.", OUT_DIR_GUI); } if arg == "-v" { let gui_view_icons: &'static [IconSource<'static>] = gui_view_icon::get_icons(); icon_writer::generate_files(gui_view_icons, FileType::Svg, OUT_DIR_GUI); icon_writer::generate_files(gui_view_icons, FileType::PixBuf, OUT_DIR_GUI); println!("Generated files have been written to '{}'.", OUT_DIR_GUI); } if arg == "-d" { let type_diag_icons: &'static [IconSource<'static>] = type_diag_icon::get_icons(); icon_writer::generate_files(type_diag_icons, FileType::Svg, OUT_DIR_GUI); icon_writer::generate_files(type_diag_icons, FileType::PixBuf, OUT_DIR_GUI); println!("Generated files have been written to '{}'.", OUT_DIR_GUI); } if arg == "-c" { let type_class_icons: &'static [IconSource<'static>] = type_class_icon::get_icons(); icon_writer::generate_files(type_class_icons, FileType::Svg, OUT_DIR_GUI); icon_writer::generate_files(type_class_icons, FileType::PixBuf, OUT_DIR_GUI); println!("Generated files have been written to '{}'.", OUT_DIR_GUI); } if arg == "-s" { let stereo_icons: &'static [IconSource<'static>] = stereotype_icon::get_icons(); icon_writer::generate_files(stereo_icons, FileType::Svg, OUT_DIR_STEREO); icon_writer::generate_files(stereo_icons, FileType::IndexOfSvg, OUT_DIR_STEREO); println!("Generated files have been written to '{}'.", OUT_DIR_STEREO); } if arg == "-h" { println!("options are"); println!("-f file icons"); println!("-v view icons"); println!("-d diagram icons"); println!("-c classifier icons"); println!("-s stereotype"); } } } /* Copyright 2023-2025 Andreas Warnke Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. */ crystal-facet-uml-1.63.3/build/icon_artist/src/model/000077500000000000000000000000001500562027500224465ustar00rootroot00000000000000crystal-facet-uml-1.63.3/build/icon_artist/src/model/icon.rs000066400000000000000000000007201500562027500237430ustar00rootroot00000000000000//! The module provides functions to render an icon to vector graphics. use crate::stream_if::geometry::Rect; use crate::stream_if::path_renderer::PathRenderer; /// Defines the data needed to render an icon pub struct IconSource<'my_lifespan> { /// The name pub name: &'my_lifespan str, /// The rectangle that defines the visible region pub viewport: Rect, /// The generator function pub generate: fn(out: &mut dyn PathRenderer) -> (), } crystal-facet-uml-1.63.3/build/icon_artist/src/model/mod.rs000066400000000000000000000012031500562027500235670ustar00rootroot00000000000000//! This module provides a static data model to be rendered. pub mod icon; /* Copyright 2023-2025 Andreas Warnke Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. */ crystal-facet-uml-1.63.3/build/icon_artist/src/render/000077500000000000000000000000001500562027500226255ustar00rootroot00000000000000crystal-facet-uml-1.63.3/build/icon_artist/src/render/icon_writer.rs000066400000000000000000000117011500562027500255170ustar00rootroot00000000000000//! The module creates a VecRenderer per icon //! and passes it to icon_data for rendering. use super::render_c::CRenderer; use super::render_svg::VecRenderer; use crate::model::icon::IconSource; use std::fs; use std::fs::File; use std::io::Write; use std::path::PathBuf; /// creates a parent directory and a file in it /// /// # Arguments /// /// * `out_dir` - The directory where files shall be written to /// * `file_name` - The filename of the file to be created /// /// # Panics /// /// This function panics if the the file cannot be created. /// fn open_file_to_write(out_dir: &str, file_name: &str) -> File { /* create the output directory, panic in case an error occured */ fs::create_dir_all(out_dir).unwrap(); /* create the file, panic in case an error occured */ let mut file_to_use = PathBuf::from(out_dir); file_to_use.push(file_name); File::create(&file_to_use).unwrap() } /// The function writes a starting para tag to the docbook out file. /// /// # Panics /// /// This function panics if the vector graphics cannot be written to a file. /// fn write_db_header(out: &mut File) -> () { write!(out, "\n").expect("Error at writing file"); write!(out, " \n").expect("Error at writing file"); write!(out, " Stereotype images\n").expect("Error at writing file"); } /// The function writes a ending para tag to the docbook out file. /// /// # Panics /// /// This function panics if the vector graphics cannot be written to a file. /// fn write_db_footer(out: &mut File) -> () { write!(out, " \n").expect("Error at writing file"); write!(out, "\n").expect("Error at writing file"); } /// The function writes a icon entry to the docbook out file. /// /// # Panics /// /// This function panics if the vector graphics cannot be written to a file. /// fn write_db_icon_entry(icon: &IconSource, out: &mut File) -> () { write!(out, " \n").expect("Error at writing file"); write!(out, " {}\n", icon.name).expect("Error at writing file"); write!(out, " \n ").expect("Error at writing file"); write!( out, "\ \ \ \ ", icon.name ) .expect("Error at writing file"); write!(out, "\n \n").expect("Error at writing file"); write!(out, " \n").expect("Error at writing file"); write!(out, " \n").expect("Error at writing file"); write!(out, " \n").expect("Error at writing file"); } /// Defines the possible filetypes to generate #[derive(Debug, Copy, Clone, PartialEq)] pub enum FileType { /// A set of standalone svg images. Svg, /// An index file in docbook format. IndexOfSvg, /// A c struct coontainnig pixbuf data. PixBuf, } /// The function creates a file for each icon and triggers the rendering /// of the icon as vector graphics drawing directives to the file. /// /// # Arguments /// /// * `icons` - The list of images to be rendered /// * `out_type` - The output format /// * `out_dir` - The output directory where to export the generated images to /// /// # Panics /// /// This function panics if the vector graphics cannot be written to a file. /// pub fn generate_files(icons: &[IconSource], out_type: FileType, out_dir: &str) -> () { if out_type == FileType::IndexOfSvg { let mut db_file = open_file_to_write(out_dir, &"stereotype_images.xml"); write_db_header(&mut db_file); for icon in icons { /* write an image reference to a docbook file */ write_db_icon_entry(icon, &mut db_file); } write_db_footer(&mut db_file); } if out_type == FileType::Svg { for icon in icons { /* render an svg file */ let file_name: String = icon.name.to_owned() + ".svg"; let mut svg_file = open_file_to_write(out_dir, &file_name); let mut v_render = VecRenderer { output_file: &mut svg_file, force_colors: true, }; v_render.header(&icon.viewport); (icon.generate)(&mut v_render); v_render.footer(); } } if out_type == FileType::PixBuf { /* write some c files */ for icon in icons { /* render a c file */ let file_name: String = icon.name.to_owned() + ".c"; let mut c_file = open_file_to_write(out_dir, &file_name); let mut c_render = CRenderer::new(&mut c_file, &icon.name, &icon.viewport); (icon.generate)(&mut c_render); c_render.write_cimpl(); } } } crystal-facet-uml-1.63.3/build/icon_artist/src/render/mod.rs000066400000000000000000000014651500562027500237600ustar00rootroot00000000000000//! The module render defines functions that render the vector_model and dyn_data. // Many thanks to the author of the inspiring web page https://cetra3.github.io/blog/drawing-svg-graphs-rust/ pub mod icon_writer; pub mod render_c; pub mod render_svg; /* Copyright 2023-2025 Andreas Warnke Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. */ crystal-facet-uml-1.63.3/build/icon_artist/src/render/render_c.rs000066400000000000000000000241031500562027500247540ustar00rootroot00000000000000//! The module provides functions to generate gdk pixbuf c-source files. use crate::stream_if::geometry; use crate::stream_if::geometry::DrawDirective; use crate::stream_if::geometry::Offset; use crate::stream_if::geometry::Point; use crate::stream_if::geometry::Rect; use crate::stream_if::path_renderer::PathRenderer; use raqote; use std::fs::File; use std::io::Write; /// Defines a pixmap renderer that produces c code pub struct CRenderer<'my_lifespan> { /// The file that is open for writing output_file: &'my_lifespan mut File, /// The icon name from which a c-struct name is derived icon_name: &'my_lifespan str, /// The target canvas of the 2d drawing library dt: raqote::DrawTarget, } /// The CRenderer struct provides some methods to write c header and footer impl<'my_lifespan> CRenderer<'my_lifespan> { /// The function new initializes a CRenderer /// /// # Arguments /// /// * `output_file` - The file in which to write c code /// * `icon_name` - The c struct name /// * `viewport` - The drawing rectangle bounds /// /// # Panics /// /// Depends on library calls. /// pub(super) fn new( output_file: &'my_lifespan mut File, icon_name: &'my_lifespan str, viewport: &'my_lifespan Rect, ) -> CRenderer<'my_lifespan> { CRenderer { output_file: output_file, icon_name: icon_name, dt: raqote::DrawTarget::new(viewport.width as i32, viewport.height as i32), } } /// The function write_cimpl converts the graphics drawing to c format /// /// # Arguments /// /// * `view` - The bounding box of the visible area /// /// # Panics /// /// This function panics if the vector graphics cannot be written to a file. /// pub(super) fn write_cimpl(self: &mut Self) -> () { let buf = self.dt.get_data(); write!( self.output_file, "\ /* generated by icon_artist */ static const struct {{ guint width; guint height; guint bytes_per_pixel; /* 2:RGB16, 3:RGB, 4:RGBA */ guint8 pixel_data[{3}*4]; }} {0} = {{ {1}, {2}, 4, {{ \ ", self.icon_name, self.dt.width(), self.dt.height(), buf.len() ) .expect("Error at writing file"); let mut pix_in_line: u32 = 0; for pixel in buf { let a = (pixel >> 24) & 0xffu32; let r = (pixel >> 16) & 0xffu32; let g = (pixel >> 8) & 0xffu32; let b = (pixel >> 0) & 0xffu32; write!(self.output_file, "{:>3},{:>3},{:>3},{:>3},", r, g, b, a) .expect("Error at writing file"); pix_in_line += 1; if pix_in_line > 7 { /* lines are 140 characters wide */ pix_in_line = 0; write!(self.output_file, "\n ",).expect("Error at writing file"); } else { /* only a sigle space*/ write!(self.output_file, " ",).expect("Error at writing file"); } } write!(self.output_file, "}}\n}};\n",).expect("Error at writing file"); /* debug */ /* * let filename = self.icon_name.to_owned() + ".png"; * self.dt.write_png(filename).unwrap(); */ } } /// The CRenderer struct provides some methods that implement a PathRenderer impl<'my_lifespan> PathRenderer for CRenderer<'my_lifespan> { /// The function render_path converts the vector graphics drawing directive path /// to a pixmap in c format /// # Arguments /// /// * `segs` - The segments of the path /// * `stroke` - The foreground color and width by which the path is stroked /// * `fill` - The background color by which the path is filled /// /// # Panics /// /// Depends on library calls. /// fn render_path( self: &mut Self, segs: &[DrawDirective], stroke: &Option, fill: &Option, ) -> () { let mut section_start = Point { x: 0.0, y: 0.0 }; let mut cursor = Point { x: 0.0, y: 0.0 }; let mut direction = Offset { dx: 0.0, dy: 0.0 }; let mut pb = raqote::PathBuilder::new(); for seg in segs { match seg { DrawDirective::Move(target) => { pb.move_to(target.x, target.y); /* update cursor and direction */ direction = Offset::delta(cursor, *target); cursor = *target; section_start = *target; } DrawDirective::MoveRel(offset) => { let target = Point::add(cursor, *offset); pb.move_to(target.x, target.y); /* update cursor and direction */ direction = *offset; cursor = target; section_start = target; } DrawDirective::Line(target) => { pb.line_to(target.x, target.y); /* update cursor and direction */ direction = Offset::delta(cursor, *target); cursor = *target; } DrawDirective::LineRel(offset) => { let target = Point::add(cursor, *offset); pb.line_to(target.x, target.y); /* update cursor and direction */ direction = *offset; cursor = target; } DrawDirective::Continue(target) => { /* assume last operation was a line */ pb.line_to(target.x, target.y); /* update cursor and direction */ direction = Offset::delta(cursor, *target); cursor = *target; } DrawDirective::ContinueRel(offset) => { /* assume last operation was a line */ let target = Point::add(cursor, *offset); pb.line_to(target.x, target.y); /* update cursor and direction */ direction = *offset; cursor = target; } DrawDirective::Curve(p1, p2, target) => { pb.cubic_to(p1.x, p1.y, p2.x, p2.y, target.x, target.y); /* update cursor and direction */ direction = Offset::delta(*p2, *target); cursor = *target; } DrawDirective::CurveRel(o_p1, o_p2, offset) => { let p1 = Point::add(cursor, *o_p1); let p2 = Point::add(cursor, *o_p2); let target = Point::add(cursor, *offset); pb.cubic_to(p1.x, p1.y, p2.x, p2.y, target.x, target.y); /* update cursor and direction */ direction = Offset::delta(p2, target); cursor = target; } DrawDirective::Symmetric(p2, target) => { let p1 = Point::add(cursor, direction); pb.cubic_to(p1.x, p1.y, p2.x, p2.y, target.x, target.y); /* update cursor and direction */ direction = Offset::delta(*p2, *target); cursor = *target; } DrawDirective::SymmetricRel(o_p2, offset) => { let p1 = Point::add(cursor, direction); let p2 = Point::add(cursor, *o_p2); let target = Point::add(cursor, *offset); pb.cubic_to(p1.x, p1.y, p2.x, p2.y, target.x, target.y); /* update cursor and direction */ cursor = target; direction = Offset::delta(p2, target); } DrawDirective::Close => { pb.close(); /* update cursor and direction */ direction = Offset::delta(cursor, section_start); cursor = section_start; } DrawDirective::CloseRel => { pb.close(); /* update cursor and direction */ direction = Offset::delta(cursor, section_start); cursor = section_start; } } } let path = pb.finish(); match fill { Some(ground_color) => { let options = raqote::DrawOptions { blend_mode: raqote::BlendMode::SrcOver, alpha: 1.0, antialias: raqote::AntialiasMode::None, }; self.dt.fill( &path, &raqote::Source::Solid(raqote::SolidSource { r: ground_color.red, g: ground_color.green, b: ground_color.blue, a: 0xff, }), &options, ); } None => {} } match stroke { Some(pen) => { let options = raqote::DrawOptions { blend_mode: raqote::BlendMode::SrcOver, alpha: 1.0, antialias: raqote::AntialiasMode::Gray, }; self.dt.stroke( &path, &raqote::Source::Solid(raqote::SolidSource { r: pen.color.red, g: pen.color.green, b: pen.color.blue, a: 0xff, }), &raqote::StrokeStyle { cap: raqote::LineCap::Round, join: raqote::LineJoin::Round, width: pen.width, miter_limit: 0.0, dash_array: vec![], dash_offset: 0.0, }, &options, ); } None => {} } } } crystal-facet-uml-1.63.3/build/icon_artist/src/render/render_svg.rs000066400000000000000000000212151500562027500253320ustar00rootroot00000000000000//! The module provides functions to generate svg files. use crate::stream_if::geometry::Color; use crate::stream_if::geometry::DrawDirective; use crate::stream_if::geometry::Pen; use crate::stream_if::geometry::Rect; use crate::stream_if::path_renderer::PathRenderer; use std::fs::File; use std::io::Write; /// This is the rounding unit value for absolute coordinates. /// This unit has an exact representation in both binary and decimal. const ABS_UNIT: f32 = 0.125; /// This is the rounding unit value for relative coordinates. /// It has higher precision than ABS_UNIT to keep the sum of errors low. /// This unit has an exact representation in both binary and decimal. const REL_UNIT: f32 = 0.0625; /// Defines a vector renderer pub struct VecRenderer<'my_lifespan> { /// The file that is open for writing pub output_file: &'my_lifespan mut File, /// default colors are black stroke and white fill if requested pub force_colors: bool, } /// The VecRenderer struct provides some methods to write svg header and footer impl<'my_lifespan> VecRenderer<'my_lifespan> { /// The function header converts the vector graphics drawing directive header to svg format /// /// # Arguments /// /// * `view` - The bounding box of the visible area /// /// # Panics /// /// This function panics if the vector graphics cannot be written to a file. /// pub(super) fn header(self: &mut Self, view: &Rect) -> () { write!( self.output_file, "\ \ ", view.left, view.top, view.width, view.height ) .expect("Error at writing file"); } /// The function footer converts the vector graphics drawing directive footer to svg format /// /// # Panics /// /// This function panics if the vector graphics cannot be written to a file. /// pub(super) fn footer(self: &mut Self) -> () { write!(self.output_file, "\n\n").expect("Error at writing file"); } } /// The VecRenderer struct provides some methods that implement a PathRenderer impl<'my_lifespan> PathRenderer for VecRenderer<'my_lifespan> { /// The function render_path converts the vector graphics drawing directive path /// to svg format /// # Arguments /// /// * `segs` - The segments of the path /// * `stroke` - The foreground color and width by which the path is stroked /// * `fill` - The background color by which the path is filled /// /// # Panics /// /// This function panics if the vector graphics cannot be written to a file. /// fn render_path( self: &mut Self, segs: &[DrawDirective], stroke: &Option, fill: &Option, ) -> () { write!(self.output_file, " { write!(self.output_file, "stroke=\"#{}\" ", pen.color.to_svg()) .expect("Error at writing file"); write!(self.output_file, "stroke-width=\"{}\" ", pen.width) .expect("Error at writing file"); } (None, Some(_), _) => { write!(self.output_file, "stroke=\"none\" ").expect("Error at writing file"); } (None, None, true) => { write!(self.output_file, "stroke=\"black\" ").expect("Error at writing file"); } (None, None, false) => {} } match (fill, self.force_colors) { (Some(color), _) => { write!(self.output_file, "fill=\"#{}\" ", color.to_svg()) .expect("Error at writing file"); } (None, true) => { write!(self.output_file, "fill=\"none\" ").expect("Error at writing file"); } (None, false) => {} } write!(self.output_file, "d=\"").expect("Error at writing file"); for seg in segs { match seg { DrawDirective::Move(target) => { write!( self.output_file, "M {},{} ", target.round_x(ABS_UNIT), target.round_y(ABS_UNIT) ) } DrawDirective::MoveRel(offset) => { write!( self.output_file, "m {},{} ", offset.round_dx(REL_UNIT), offset.round_dy(REL_UNIT) ) } DrawDirective::Line(target) => { write!( self.output_file, "L {},{} ", target.round_x(ABS_UNIT), target.round_y(ABS_UNIT) ) } DrawDirective::LineRel(offset) => { write!( self.output_file, "l {},{} ", offset.round_dx(REL_UNIT), offset.round_dy(REL_UNIT) ) } DrawDirective::Continue(target) => { write!( self.output_file, "{},{} ", target.round_x(ABS_UNIT), target.round_y(ABS_UNIT) ) } DrawDirective::ContinueRel(offset) => { write!( self.output_file, "{},{} ", offset.round_dx(REL_UNIT), offset.round_dy(REL_UNIT) ) } DrawDirective::Curve(p1, p2, target) => { write!( self.output_file, "C {},{} {},{} {},{} ", p1.round_x(ABS_UNIT), p1.round_y(ABS_UNIT), p2.round_x(ABS_UNIT), p2.round_y(ABS_UNIT), target.round_x(ABS_UNIT), target.round_y(ABS_UNIT) ) } DrawDirective::CurveRel(o_p1, o_p2, offset) => { write!( self.output_file, "c {},{} {},{} {},{} ", o_p1.round_dx(REL_UNIT), o_p1.round_dy(REL_UNIT), o_p2.round_dx(REL_UNIT), o_p2.round_dy(REL_UNIT), offset.round_dx(REL_UNIT), offset.round_dy(REL_UNIT) ) } DrawDirective::Symmetric(p2, target) => { write!( self.output_file, "S {},{} {},{} ", p2.round_x(ABS_UNIT), p2.round_y(ABS_UNIT), target.round_x(ABS_UNIT), target.round_y(ABS_UNIT) ) } DrawDirective::SymmetricRel(o_p2, offset) => { write!( self.output_file, "s {},{} {},{} ", o_p2.round_dx(REL_UNIT), o_p2.round_dy(REL_UNIT), offset.round_dx(REL_UNIT), offset.round_dy(REL_UNIT) ) } DrawDirective::Close => { write!(self.output_file, "Z ") } DrawDirective::CloseRel => { write!(self.output_file, "z ") } } .expect("Error at writing file"); } write!(self.output_file, "\" />").expect("Error at writing file"); } } /* Copyright 2023-2025 Andreas Warnke Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. */ crystal-facet-uml-1.63.3/build/icon_artist/src/stream_if/000077500000000000000000000000001500562027500233175ustar00rootroot00000000000000crystal-facet-uml-1.63.3/build/icon_artist/src/stream_if/geometry.rs000066400000000000000000000126661500562027500255330ustar00rootroot00000000000000//! The module geometry provides a couple of geometric data structures. /// Defines a point #[derive(Debug, Copy, Clone, PartialEq)] pub struct Point { /// The x-coordinate pub x: f32, /// The y-coordinate pub y: f32, } /// Defines an delta offset #[derive(Debug, Copy, Clone, PartialEq)] pub struct Offset { /// The x-coordinate offset pub dx: f32, /// The y-coordinate offset pub dy: f32, } /// The Point struct provides some methods impl Point { /// rounds the x coordinate to a multiple of unit pub fn round_x(self: &Self, unit: f32) -> f32 { (self.x / unit).round() * unit } /// rounds the y coordinate to a multiple of unit pub fn round_y(self: &Self, unit: f32) -> f32 { (self.y / unit).round() * unit } /// adds an offset to a point, returns a new point pub fn add(position: Point, delta: Offset) -> Point { Point { x: position.x + delta.dx, y: position.y + delta.dy, } } } /// The Offset struct provides some methods impl Offset { /// rounds the x coordinate to a multiple of unit pub fn round_dx(self: &Self, unit: f32) -> f32 { (self.dx / unit).round() * unit } /// rounds the y coordinate to a multiple of unit pub fn round_dy(self: &Self, unit: f32) -> f32 { (self.dy / unit).round() * unit } /// determines the offset between two points, returns an offset pub fn delta(from: Point, to: Point) -> Offset { Offset { dx: to.x - from.x, dy: to.y - from.y, } } } /// Defines the possible kinds of drawing irectived within paths #[derive(Debug, Copy, Clone, PartialEq)] pub enum DrawDirective { /// A move moves the actual cursor without drawing a line. /// A move separates subpaths. Move(Point), /// A move moves the actual cursor without drawing a line. /// A move separates subpaths. MoveRel(Offset), /// A line draws a straight line and moves the cursor. Line(Point), /// A line draws a straight line and moves the cursor. LineRel(Offset), /// A continuation of the previous line with a single point as parameter. Continue(Point), /// A continuation of the previous line with a single offset as parameter. ContinueRel(Offset), /// A curve draws a curved line and moves the cursor. Curve(Point, Point, Point), /// A curve draws a curved line and moves the cursor. CurveRel(Offset, Offset, Offset), /// A symmetric curve continues a previous Curve, /// assuming a symmetric first control point, /// draws a curved line and moves the cursor. Symmetric(Point, Point), /// A symmetric curve continues a previous Curve, /// assuming a symmetric first control point, /// draws a curved line and moves the cursor. SymmetricRel(Offset, Offset), /// Close the subpath by drawing a straight line and moving the cursor. Close, /// Close the subpath by drawing a straight line and moving the cursor. /// CloseRel is identical to Close, it may be a matter of style to close a path /// in a similar way as drawing it. CloseRel, } /// Defines a rectangle #[derive(Debug, Copy, Clone, PartialEq)] pub struct Rect { /// The left x-coordinate pub left: f32, /// The top y-coordinate, note that lower values refer to higher coordinates (more to the top) pub top: f32, /// The width pub width: f32, /// The height pub height: f32, } /// The Rect struct provides some methods impl Rect { /// calculates the width pub fn right(self: &Self) -> f32 { self.left + self.width } /// calculates the height pub fn bottom(self: &Self) -> f32 { self.top + self.height } /// calculates the x_center pub fn x_center(self: &Self) -> f32 { self.left + (self.width / 2.0) } /// calculates the y_center pub fn y_center(self: &Self) -> f32 { self.top + (self.height / 2.0) } } /// Defines a color #[derive(Debug, Copy, Clone, PartialEq)] pub struct Color { /// The red part pub red: u8, /// The green part pub green: u8, /// The blue part pub blue: u8, } /// The Color struct provides some methods impl Color { /// calculates the width pub fn to_svg(self: &Self) -> String { format!("{:02x}{:02x}{:02x}", self.red, self.green, self.blue) } /// calculates a brigher color, starting from the current color pub fn brighter(self: &Self) -> Color { Color { red: (0xff - ((0xff - self.red) as u16 * 7) / 8) as u8, green: (0xff - ((0xff - self.green) as u16 * 7) / 8) as u8, blue: (0xff - ((0xff - self.blue) as u16 * 7) / 8) as u8, } } } /// Defines an stroke color and width #[derive(Debug, Copy, Clone, PartialEq)] pub struct Pen { /// The color of the stroke pub color: Color, /// The width of the stroke pub width: f32, } /* Copyright 2023-2025 Andreas Warnke Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. */ crystal-facet-uml-1.63.3/build/icon_artist/src/stream_if/mod.rs000066400000000000000000000013311500562027500244420ustar00rootroot00000000000000//! This module provides interfaces that allow //! a drawing source to stream multiple drawing paths to a drawing sink. pub mod geometry; pub mod path_renderer; /* Copyright 2024-2025 Andreas Warnke Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. */ crystal-facet-uml-1.63.3/build/icon_artist/src/stream_if/path_renderer.rs000066400000000000000000000027271500562027500265170ustar00rootroot00000000000000//! The module geometry provides a couple of geometric data structures. use crate::stream_if::geometry::Color; use crate::stream_if::geometry::DrawDirective; use crate::stream_if::geometry::Pen; /// A path renderer is an object that provides a function to /// draw a path. /// /// # Lifetimes /// /// * `'all_testing` refers to the lifetime of `TestSuite` and `TestCase` /// objects: They exist during the whole test run. /// pub trait PathRenderer { /// This function renders a path; it is called by a drawing source /// and implemented by a drawing sink (renderer). /// /// # Arguments /// /// * `segs` - A list of drawing directives which is a path /// * `stroke_color_width` - A stroke color and width /// * `fill_color` - A fill color fn render_path( self: &mut Self, segs: &[DrawDirective], stroke: &Option, fill: &Option, ) -> (); } /* Copyright 2024-2025 Andreas Warnke Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. */ crystal-facet-uml-1.63.3/build/msys2/000077500000000000000000000000001500562027500173165ustar00rootroot00000000000000crystal-facet-uml-1.63.3/build/msys2/README.md000066400000000000000000000021041500562027500205720ustar00rootroot00000000000000 crystal-facet-uml - build for windows using msys2 ============= How to build from source ----------- install msys2. update the package databases: > pacman -Syu install packages using pacman: > pacman -S git > > pacman -S mingw-w64-ucrt-x86_64-sqlite3 > > pacman -S mingw-w64-ucrt-x86_64-gtk4 > > pacman -S mingw-w64-ucrt-x86_64-gcc > > pacman -S make > > pacman -S cmake > > pacman -S mingw-w64-ucrt-x86_64-7zip get crystal-facet-uml: > git clone https://github.com/awarnke/crystal-facet-uml.git build (adapt the path to the source code ../crystal-facet-uml): > mkdir -p tmp > > windres ../crystal-facet-uml/build/msys2/crystal-facet-uml.rc -O coff -o tmp/crystal-facet-uml.res > > cmake -DCOMPILE_IN_LINKER_FLAG="tmp/crystal-facet-uml.res" -DCOMPILE_IN_SOURCE_FILE="tmp/crystal-facet-uml.res" \\\ > -DCMAKE_C_FLAGS="-mwindows" -DCMAKE_BUILD_TYPE=Release ../crystal-facet-uml > > make --debug=p -j12 deploy: > make msys2_deploy see also https://www.gtk.org/docs/installations/windows run: > append 'C:/msys64/mingw64/share' to XDG_DATA_HOME and XDG_DATA_DIRS if needed crystal-facet-uml-1.63.3/build/msys2/crystal-facet-uml.rc000066400000000000000000000000731500562027500232000ustar00rootroot00000000000000id ICON "../../gui/source/resources/crystal_facet_uml.ico" crystal-facet-uml-1.63.3/build/msys2/deploy.sh000077500000000000000000000033621500562027500211550ustar00rootroot00000000000000#!/bin/sh echo call parameters: \"SOURCE_DIR BUILD_DIR\" echo SELF: \"${0}\" echo SOURCE_DIR: \"${1}\" echo BUILD_DIR: \"${2}\" . ${1}/main/include/meta/meta_version.inl VERSIONSTR=${META_VERSION_STR} echo version: ${VERSIONSTR} # create a deployment directory mkdir -p crystal-facet-uml cp ${1}/installation/crystal-facet-uml_documentation.pdf crystal-facet-uml/ cp ${1}/installation/win/* crystal-facet-uml/ cp ${1}/documentation/examples/mouse_droid.cfuJ crystal-facet-uml/crystal-facet-uml_mod5g-example.cfuJ cp ${1}/LICENSE.txt crystal-facet-uml/crystal-facet-uml_LICENSE.txt ${1}/build/msys2/fetch_licenses.sh | tee crystal-facet-uml/LICENSES_of_3rd_party.txt mkdir -p crystal-facet-uml/bin cp crystal-facet-uml.exe crystal-facet-uml/bin/ cp test_crystal-facet-uml.exe crystal-facet-uml/bin/ ldd crystal-facet-uml.exe | grep -e ' /ucrt64' | sed -e 's/^[^/]*\(\S*\).*$/\1/' | xargs cp -t crystal-facet-uml/bin/ cp /ucrt64/bin/gdbus.exe crystal-facet-uml/bin/ mkdir -p crystal-facet-uml/share/glib-2.0/schemas cp /ucrt64/share/glib-2.0/schemas/gschemas.compiled crystal-facet-uml/share/glib-2.0/schemas/ # zip 7z a crystal-facet-uml_${VERSIONSTR}-1_win64.zip crystal-facet-uml # Copyright 2025-2025 Andreas Warnke # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. crystal-facet-uml-1.63.3/build/msys2/fetch_licenses.sh000077500000000000000000000011561500562027500226360ustar00rootroot00000000000000#!/bin/sh for file in $( ldd crystal-facet-uml.exe | grep -e ' /ucrt64' | sed -e 's/^[^/]*\(\S*\).*$/\1/' ) do echo $file pkg=$( pacman -Qo $file | sed -e 's/^\S* \S* \S* \S* \(\S*\).*$/\1/' 2>&1 ) echo $pkg pacman -Qi $pkg echo -- done file2=/ucrt64/bin/gdbus.exe echo $file2 pkg2=$( pacman -Qo $file2 | sed -e 's/^\S* \S* \S* \S* \(\S*\).*$/\1/' 2>&1 ) echo $pkg2 pacman -Qi $pkg2 echo -- file3=/ucrt64/share/glib-2.0/schemas/org.gtk.gtk4.Settings.FileChooser.gschema.xml echo $file3 pkg3=$( pacman -Qo $file3 | sed -e 's/^\S* \S* \S* \S* \(\S*\).*$/\1/' 2>&1 ) echo $pkg3 pacman -Qi $pkg3 echo -- crystal-facet-uml-1.63.3/build/qualification_test/000077500000000000000000000000001500562027500221305ustar00rootroot00000000000000crystal-facet-uml-1.63.3/build/qualification_test/Cargo.toml000066400000000000000000000003361500562027500240620ustar00rootroot00000000000000[package] name = "qualification_test" version = "0.1.0" edition = "2021" # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html [dependencies] exitcode = "1.1.2" regex = "1.5.4" crystal-facet-uml-1.63.3/build/qualification_test/README.md000066400000000000000000000027721500562027500234170ustar00rootroot00000000000000 Qualification Tests ============= Goal ----------- Qualification tests shall test the integrated software in the intended operation environment. Strategy ----------- Manual and automatic test cases shall be performed. It is expected that many releases will have to be tested, therefore automatic test cases are preferable. The software shall be tested on multiple processor architectures and operating systems. To achieve this, the qemu and wine emulation environments are preferred tools. How To ----------- qemu: Create an empty disk > qemu-img create debian-testing_20GB.img 20G To install an OS from an .iso image, you may adapt and use the following script: > #!/bin/sh > CD=debian-testing-amd64-netinst.iso > DISK=debian-testing_20GB.img > NDEV=e1000 > echo "ensure that the configured subnet 192.168.76.x is distinct from your local network." > qemu-system-x86_64 \ > -drive file=${DISK},format=raw,index=0,media=disk \ > -cdrom ${CD} \ > -m 4096M \ > -boot order=dc \ > -netdev user,id=mynet0,net=192.168.76.0/24,dhcpstart=192.168.76.9 \ > -device ${NDEV},netdev=mynet0 After installing, remove the -cdrom * and -boot * parameters In case of testing this program remotely, you may want to forward the X11 display: To forward X11 via ssh, the client needs the -X parameter passed to the ssh command, the server needs X11Forwarding yes specified in /etc/ssh/sshd_config . automated tests: > [run_q_test.sh](./run_q_test.sh) crystal-facet-uml-1.63.3/build/qualification_test/run_q_test.sh000077500000000000000000000017511500562027500246560ustar00rootroot00000000000000#!/bin/sh rm -fr Makefile cmake_install.cmake CMakeFiles/ CMakeCache.txt cmake ../.. -DCMAKE_BUILD_TYPE=Release cmake --build . -j --target crystal-facet-uml --config Release find . -name '*.rs' | xargs rustfmt cargo run ./crystal-facet-uml ./tmp ; echo "ERROR: $?" echo "consider running rustup update" echo "view source documentation using cargo doc && chromium-browser target/doc/qualification_test/index.html" # Copyright 2022-2025 Andreas Warnke # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. crystal-facet-uml-1.63.3/build/qualification_test/src/000077500000000000000000000000001500562027500227175ustar00rootroot00000000000000crystal-facet-uml-1.63.3/build/qualification_test/src/main.rs000066400000000000000000000045611500562027500242170ustar00rootroot00000000000000//! This crate performs qualification tests on a binary executable //! of crystal-facet-uml. //! //! # Examples //! //! Run the test cases by calling `cargo run` from the current directory. #![warn(missing_docs)] pub mod suite_cli; pub mod suite_gui; pub mod test_tool; use suite_cli::suite::SuiteCli; use suite_gui::suite::SuiteGui; use test_tool::test_result::TestResult; use test_tool::test_runner; extern crate exitcode; use std::env; /// Runs all test suites and returns true if all cases succeeded. fn run_all_suites(exe_to_test: &str, temp_dir: &str) -> bool { let mut result: TestResult = TestResult { failed: 0, total: 0, }; let suite_1 = SuiteCli::new(exe_to_test, temp_dir); result += test_runner::run(&suite_1); let suite_2 = SuiteGui::new(exe_to_test, temp_dir); result += test_runner::run(&suite_2); println!("______________________________"); println!( "TEST RESULT: {}/{} tests failed.", result.failed, result.total ); result.failed == 0 } /// Parses the command line parameters, uses these to configure the test /// environment, runs the test cases and returns 0 in case of success. fn main() { let err_code; println!("This is the qualification test for crystal-facet-uml."); let args: Vec = env::args().collect(); if args.len() != 3 { println!(" please call this program with 2 parameters:"); println!(" {} EXE_TO_TEST TEMP_DIRECTORY", args[0]); err_code = exitcode::USAGE; } else { println!("{:?}", args); err_code = match run_all_suites(&args[1], &args[2]) { true => exitcode::OK, false => exitcode::SOFTWARE, }; } /* When on stable branch, one can replace the exitcode by std::process::ExitCode */ std::process::exit(err_code) } /* Copyright 2022-2025 Andreas Warnke Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. */ crystal-facet-uml-1.63.3/build/qualification_test/src/suite_cli/000077500000000000000000000000001500562027500246775ustar00rootroot00000000000000crystal-facet-uml-1.63.3/build/qualification_test/src/suite_cli/fixture.rs000066400000000000000000000065001500562027500267340ustar00rootroot00000000000000//! This module implements a TestFixture (test environment) for testing the //! command line interface of crystal-facet-uml. use std::fs::File; use std::io::Write; use std::path::PathBuf; /// An enumeration to define access permissions #[derive(Debug, Copy, Clone, PartialEq)] pub(super) enum Permissions { ReadOnly, ReadWrite, } /// A test fixture allows to access the test environment; /// it consists of paths to the executable under test and to a directory to /// store temporary data /// /// # Lifetimes /// /// * `'my_life` refers to the lifetime of a `TestFixture`: This is set up /// for the duration of executing one test case. /// #[derive(Debug, Copy, Clone, PartialEq)] pub struct FixtureCli<'my_life> { pub(super) exe_to_test: &'my_life str, pub(super) temp_dir: &'my_life str, } /// The `FixtureCli` test fixture comes with a constructor impl<'a, 'b, 'my_life> FixtureCli<'my_life> { /// Defines a test fixture (the test environment) for command line tests /// /// # Arguments /// /// * `exe_to_test` - A path to the executable to be tested /// * `temp_dir` - A path to a directory that exists and can be used for testing /// pub fn new(exe_to_test: &'a str, temp_dir: &'b str) -> FixtureCli<'my_life> where 'a: 'my_life, 'b: 'my_life, { FixtureCli { exe_to_test: exe_to_test, temp_dir: temp_dir, } } /// Creates a file in the `temp_dir` directory /// /// # Arguments /// /// * `self` - The test fixture describing the test environment /// * `file_name` - A file name of a file to be created /// * `file_contents` - A string that is written to the newly created file as utf-8 /// * `perm` - Access permissions to apply to the newly created file /// /// # Panics /// /// This function panics if the test environment causes errors. /// pub(super) fn create_file( self: &'my_life Self, file_name: &'a str, file_contents: &'b str, perm: Permissions, ) -> () { /* create the file to import, panic in case an error occured */ let mut file_path = PathBuf::from(self.temp_dir); file_path.push(file_name); let file_path_as_string: String = file_path.into_os_string().into_string().unwrap(); { let mut file_handle = File::create(&file_path_as_string).unwrap(); write!(file_handle, "{}", file_contents).expect("File could not be written"); let mut file_perms = file_handle.metadata().expect("no metadata").permissions(); file_perms.set_readonly(perm == Permissions::ReadOnly); file_handle .set_permissions(file_perms) .expect("cannot set read/write flag"); } } } /* Copyright 2022-2025 Andreas Warnke Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. */ crystal-facet-uml-1.63.3/build/qualification_test/src/suite_cli/mod.rs000066400000000000000000000013551500562027500260300ustar00rootroot00000000000000//! This module tests the command line interface of a binary executable //! of crystal-facet-uml. mod fixture; pub mod suite; mod test_help; mod test_importexport; mod test_repair; /* Copyright 2022-2025 Andreas Warnke Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. */ crystal-facet-uml-1.63.3/build/qualification_test/src/suite_cli/suite.rs000066400000000000000000000104641500562027500264030ustar00rootroot00000000000000//! This module implements a TestSuite for testing the command line interface //! of crystal-facet-uml. use super::fixture::FixtureCli; use super::test_help::testcase_help; use super::test_help::testcase_version; use super::test_importexport::testcase_import_to_new_cfu1; use super::test_repair; use crate::test_tool::test_case::TestCase; use crate::test_tool::test_suite::TestSuite; use std::fs; /// A test suite consists of a name, a test fixture and an array of test cases /// /// # Lifetimes /// /// * `'all_testing` refers to the lifetime of `TestSuite` and `TestCase` /// objects: They exist during the whole test run. /// * `'during_run` refers to the lifetime of a `TestFixture`: This is set up /// for the duration of executing one single test case. /// pub struct SuiteCli<'all_testing, 'during_run> where 'all_testing: 'during_run, { name: &'all_testing str, exe_to_test: &'all_testing str, temp_dir: &'all_testing str, cases: [TestCase<'all_testing, FixtureCli<'during_run>>; 7], } /// The `SuiteCli` test suite comes with a constructor impl<'all_testing, 'during_run, 'a, 'b> SuiteCli<'all_testing, 'during_run> where 'all_testing: 'during_run, 'a: 'all_testing, 'b: 'all_testing, { /// Defines all test cases in this test suite /// /// # Arguments /// /// * `exe_to_test` - A path to the executable to be tested /// * `temp_dir` - A path to a directory that exists and can be used for testing /// pub fn new(exe_to_test: &'a str, temp_dir: &'b str) -> SuiteCli<'all_testing, 'during_run> { SuiteCli { name: "SuiteCli", exe_to_test: exe_to_test, temp_dir: temp_dir, cases: [ TestCase::new("testcase_version", testcase_version), TestCase::new("testcase_help", testcase_help), TestCase::new( "testcase_repair_new_cfu1", test_repair::testcase_repair_new_cfu1, ), TestCase::new( "testcase_test_new_cfu1", test_repair::testcase_test_new_cfu1, ), TestCase::new( "testcase_repair_json_rw", test_repair::testcase_repair_json_rw, ), TestCase::new("testcase_test_json_ro", test_repair::testcase_test_json_ro), TestCase::new("testcase_import_to_new_cfu1", testcase_import_to_new_cfu1), ], } } } /// The `SuiteCli` test suite implements the `TestSuite` trait impl<'all_testing, 'during_run> TestSuite<'all_testing, FixtureCli<'during_run>> for SuiteCli<'all_testing, 'during_run> where 'all_testing: 'during_run, { /// The name of the test suite fn name(self: &'all_testing Self) -> &'all_testing str { self.name } /// Creates a test directory /// /// Panics if the test environment reports errors. fn setup(self: &'all_testing Self) -> FixtureCli<'during_run> where 'all_testing: 'during_run, { let environment = FixtureCli::new(self.exe_to_test, self.temp_dir); /* create the temp directory, panic in case an error occured */ fs::create_dir_all(environment.temp_dir).unwrap(); environment } /// Removes the test directory /// /// Panics if the test environment reports errors. fn teardown(self: &'all_testing Self, environment: FixtureCli<'during_run>) -> () { /* delete the temp directory in case of successful test result, panic in case an error occured */ fs::remove_dir_all(environment.temp_dir).unwrap(); } fn testcases( self: &'all_testing Self, ) -> &'all_testing [TestCase<'all_testing, FixtureCli<'during_run>>] { &self.cases } } /* Copyright 2022-2025 Andreas Warnke Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. */ crystal-facet-uml-1.63.3/build/qualification_test/src/suite_cli/test_help.rs000066400000000000000000000063071500562027500272420ustar00rootroot00000000000000use super::fixture::FixtureCli; use regex::Regex; use std::process::Stdio; /// Test that requesting the version is possible. /// /// # Arguments /// /// * `environment` - A test fixture stating the test environment /// /// # Errors /// /// This function returns `Err()` if the result string does not look like a version. /// /// # Panics /// /// This function panics if the test environment causes errors. /// pub(super) fn testcase_version(environment: &mut FixtureCli) -> Result<(), ()> { let output = match std::process::Command::new(environment.exe_to_test) .args(&["-v"]) .output() { Ok(output) => output, Err(err) => panic!("Err at running process: {}", err), }; let stdout = match std::string::String::from_utf8(output.stdout) { Ok(stdout) => stdout, Err(err) => panic!("Err at translating output: {}", err), }; /* check if the returned string looks valid */ let expected_pattern = Regex::new(r"^\s*\d+\.\d+\.\d+-?\w*\s*$").unwrap(); let success = expected_pattern.is_match(&stdout); /* check that the exit code is 0 */ let exit_ok: bool = output.status.success(); print!("testcase_version: <<{}>>:{}\n", stdout, stdout.len()); if success && exit_ok { Result::Ok(()) } else { Result::Err(()) } } /// Test that requesting a help string is possible. /// /// # Arguments /// /// * `environment` - A test fixture stating the test environment /// /// # Errors /// /// This function returns `Err()` if the result string does not look like a help string. /// /// # Panics /// /// This function panics if the test environment causes errors. /// pub(super) fn testcase_help(environment: &mut FixtureCli) -> Result<(), ()> { let process = match std::process::Command::new(environment.exe_to_test) .args(&["-h"]) .stdout(Stdio::piped()) .spawn() { Ok(process) => process, Err(err) => panic!("Err at running process: {}", err), }; let output = match process.wait_with_output() { Ok(output) => output, Err(err) => panic!("Err at retrieving output: {}", err), }; let stdout = match std::string::String::from_utf8(output.stdout) { Ok(stdout) => stdout, Err(err) => panic!("Err at translating output: {}", err), }; /* check if the returned string looks valid */ let success = (stdout.len() >= 200) && (stdout.len() <= 1000); /* check that the exit code is 0 */ let exit_ok: bool = output.status.success(); println!("testcase_help: <<{}>>:{}", stdout, stdout.len()); if success && exit_ok { Result::Ok(()) } else { Result::Err(()) } } /* Copyright 2022-2025 Andreas Warnke Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. */ crystal-facet-uml-1.63.3/build/qualification_test/src/suite_cli/test_importexport.rs000066400000000000000000000057611500562027500310710ustar00rootroot00000000000000use super::fixture::FixtureCli; use std::fs::File; use std::io::Write; use std::path::PathBuf; use std::process::Command; /// A string containing valid json format but no model data static JSON_EMPTY_CONTENT: &'static str = "\ { \"head\": { \"encoding\": \"utf-8\" } , \"views\": [ ] , \"nodes\": [ ] , \"edges\": [ ] } "; /// Test that importing to a newly created sqlite3 based format is possible. /// /// # Arguments /// /// * `environment` - A test fixture stating the test environment /// /// # Errors /// /// This function returns `Err()` if the test case produced an unexpected result /// /// # Panics /// /// This function panics if the test environment causes errors. /// pub(super) fn testcase_import_to_new_cfu1(environment: &mut FixtureCli) -> Result<(), ()> { /* create the db_to_use_param string, panic in case an error occured */ let mut db_to_use = PathBuf::from(environment.temp_dir); db_to_use.push("sqlite3_db.cfu1"); let db_to_use_param = db_to_use.into_os_string().into_string().unwrap(); /* create the file to import, panic in case an error occured */ let mut json_to_use = PathBuf::from(environment.temp_dir); json_to_use.push("json.txt"); let json_to_use_param = json_to_use.into_os_string().into_string().unwrap(); { let mut json_file = File::create(&json_to_use_param).unwrap(); write!(json_file, "{}", JSON_EMPTY_CONTENT).expect("File could not be written"); let mut json_perms = json_file.metadata().expect("no metadata").permissions(); json_perms.set_readonly(true); json_file .set_permissions(json_perms) .expect("cannot set readonly flag"); } let output1 = Command::new(environment.exe_to_test) .args(&["-i", &db_to_use_param, "add", &json_to_use_param]) .output() .expect("Err at running process"); let stdout1 = match std::string::String::from_utf8(output1.stdout) { Ok(stdout) => stdout, Err(_err) => return Result::Err(()), }; /* check if the returned string looks as expected */ let as_expected1 = stdout1.contains(" errors: \t\t\t\t\t\t\t: 0"); /* check that the exit code is 0 */ let exit_ok1: bool = output1.status.success(); print!( "testcase_import_to_new_cfu1: <<{}>>:{}\n", stdout1, stdout1.len() ); if as_expected1 && exit_ok1 { Result::Ok(()) } else { Result::Err(()) } } /* Copyright 2022-2025 Andreas Warnke Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. */ crystal-facet-uml-1.63.3/build/qualification_test/src/suite_cli/test_repair.rs000066400000000000000000000133071500562027500275720ustar00rootroot00000000000000use super::fixture::FixtureCli; use std::path::PathBuf; use std::process::Command; /// A switch to distinguish test and repair modes #[derive(Debug, Copy, Clone, PartialEq)] enum Repair { TestOnly, TestAndRepair, } /// A string containing valid json format but the crystal-facet-uml model is damaged static JSON_BAD_CONTENT: &'static str = "\ { \"head\": { \"encoding\": \"utf-8\" } , \"views\": [ ] , \"nodes\": [ { \"classifier\": { \"id\": 1, \"main_type\": 121, \"type\": \"Component\", \"stereotype\": \"subsystem\", \"name\": \"AngleSteering\", \"uuid\": \"8190a2ed-df2e-4427-8ebb-0272cd62149a\", \"features\": [ ] } } ] , \"edges\": [ ] } "; /// Test that creating an sqlite3 based format is possible and can be repaired. /// /// # Arguments /// /// * `environment` - A test fixture stating the test environment /// /// # Errors /// /// This function returns `Err()` if the test case produced an unexpected result /// /// # Panics /// /// This function panics if the test environment causes errors. /// pub(super) fn testcase_repair_new_cfu1(environment: &mut FixtureCli) -> Result<(), ()> { test_repair_or_test( Repair::TestAndRepair, "sqlite3_db.cfu1", "Errors found: 1", environment, ) } /// Test that creating an sqlite3 based format is not done with -t option. /// /// # Arguments /// /// * `environment` - A test fixture stating the test environment /// /// # Errors /// /// This function returns `Err()` if the test case produced an unexpected result /// /// # Panics /// /// This function panics if the test environment causes errors. /// pub(super) fn testcase_test_new_cfu1(environment: &mut FixtureCli) -> Result<(), ()> { test_repair_or_test( Repair::TestOnly, "sqlite3_db.cfu1", "error opening database_file", environment, ) } /// Test that repairing an existing, writeable json file is possible. /// /// # Arguments /// /// * `environment` - A test fixture stating the test environment /// /// # Errors /// /// This function returns `Err()` if the test case produced an unexpected result /// /// # Panics /// /// This function panics if the test environment causes errors. /// pub(super) fn testcase_repair_json_rw(environment: &mut FixtureCli) -> Result<(), ()> { environment.create_file( "test.cfuJ", JSON_BAD_CONTENT, super::fixture::Permissions::ReadWrite, ); test_repair_or_test( Repair::TestAndRepair, "test.cfuJ", "Errors fixed: 1", environment, ) } /// Test that testing an existing, read-only json file is possible. /// /// # Arguments /// /// * `environment` - A test fixture stating the test environment /// /// # Errors /// /// This function returns `Err()` if the test case produced an unexpected result /// /// # Panics /// /// This function panics if the test environment causes errors. /// pub(super) fn testcase_test_json_ro(environment: &mut FixtureCli) -> Result<(), ()> { environment.create_file( "test.cfuJ", JSON_BAD_CONTENT, super::fixture::Permissions::ReadOnly, ); test_repair_or_test( Repair::TestOnly, "test.cfuJ", "Errors found: 2", environment, ) } /// Test that creating an sqlite3 based format is possible and can be repaired. /// /// # Arguments /// /// * `repair` - Indicator if the test case shall repair or only test the database /// * `file_name` - Filename to use for test case /// * `expected_output` - String that is expected to be contained in the output /// * `environment` - A test fixture stating the test environment /// /// # Errors /// /// This function returns `Err()` if the test case produced an unexpected result /// /// # Panics /// /// This function panics if the test environment causes errors. /// fn test_repair_or_test( repair: Repair, file_name: &str, expected_output: &str, environment: &mut FixtureCli, ) -> Result<(), ()> { /* create the db_to_use_param string, panic in case an error occured */ let mut db_to_use = PathBuf::from(environment.temp_dir); db_to_use.push(file_name); let db_to_use_param = db_to_use.into_os_string().into_string().unwrap(); let repair_param: &str = match repair { Repair::TestOnly => "-t", Repair::TestAndRepair => "-r", }; let output = Command::new(environment.exe_to_test) .args(&[repair_param, &db_to_use_param]) .output() .expect("Err at running process"); let stdout = match std::string::String::from_utf8(output.stdout) { Ok(stdout) => stdout, Err(_err) => return Result::Err(()), }; /* check if the returned string looks as expected */ /* 1 error should be found which is the missing root diagram */ let as_expected = stdout.contains(expected_output); /* check that the exit code is 0 */ let exit_ok: bool = output.status.success(); print!("stdout: <<{}>>:{}\n", stdout, stdout.len()); if as_expected && !exit_ok { Result::Ok(()) } else { Result::Err(()) } } /* Copyright 2022-2025 Andreas Warnke Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. */ crystal-facet-uml-1.63.3/build/qualification_test/src/suite_gui/000077500000000000000000000000001500562027500247145ustar00rootroot00000000000000crystal-facet-uml-1.63.3/build/qualification_test/src/suite_gui/mod.rs000066400000000000000000000012531500562027500260420ustar00rootroot00000000000000//! This module tests the graphical user interface of a binary executable //! of crystal-facet-uml. pub mod suite; /* Copyright 2022-2025 Andreas Warnke Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. */ crystal-facet-uml-1.63.3/build/qualification_test/src/suite_gui/suite.rs000066400000000000000000000045151500562027500264200ustar00rootroot00000000000000//! This module implements a TestSuite for testing the graphical user interface //! of crystal-facet-uml. use crate::test_tool::test_case::TestCase; use crate::test_tool::test_suite::TestSuite; /// A test suite consists of a name, a test fixture and an array of test cases /// /// # Lifetimes /// /// * `'all_testing` refers to the lifetime of `TestSuite` and `TestCase` /// objects: They exist during the whole test run. /// pub struct SuiteGui<'all_testing> { name: &'all_testing str, cases: [TestCase<'all_testing, ()>; 0], } /// A test suite comes with a constructor impl<'all_testing, 'a, 'b> SuiteGui<'all_testing> where 'a: 'all_testing, 'b: 'all_testing, { /// Defines all test cases in this test suite /// /// # Arguments /// /// * `exe_to_test` - A path to the executable to be tested /// * `temp_dir` - A path to a directory that exists and can be used for testing /// pub fn new(_exe_to_test: &'a str, _temp_dir: &'b str) -> SuiteGui<'all_testing> { SuiteGui { name: "SuiteGui", cases: [], } } } /// The `SuiteGui` test suite implements the `TestSuite` trait impl<'all_testing> TestSuite<'all_testing, ()> for SuiteGui<'all_testing> { /// The name of the test suite fn name(self: &'all_testing Self) -> &'all_testing str { self.name } /// Creates a test directory /// /// Panics if the test environment reports errors. fn setup(self: &'all_testing Self) -> () { () } /// Removes the test directory /// /// Panics if the test environment reports errors. fn teardown(self: &'all_testing Self, _environment: ()) -> () {} fn testcases(self: &'all_testing Self) -> &'all_testing [TestCase<'all_testing, ()>] { &self.cases } } /* Copyright 2022-2025 Andreas Warnke Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. */ crystal-facet-uml-1.63.3/build/qualification_test/src/test_tool/000077500000000000000000000000001500562027500247335ustar00rootroot00000000000000crystal-facet-uml-1.63.3/build/qualification_test/src/test_tool/mod.rs000066400000000000000000000014061500562027500260610ustar00rootroot00000000000000//! This module provides a generic test framework to setup //! test environments of test suites and to run their test cases. pub mod test_case; pub mod test_result; pub mod test_runner; pub mod test_suite; /* Copyright 2022-2025 Andreas Warnke Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. */ crystal-facet-uml-1.63.3/build/qualification_test/src/test_tool/test_case.rs000066400000000000000000000036661500562027500272660ustar00rootroot00000000000000//! This module implements a TestCase that is run in a generic test //! environment TestFixture /// A test case consists of a name and a run function. /// /// # Lifetimes /// /// * `'all_testing` refers to the lifetime of `TestSuite` and `TestCase` /// objects: They exist during the whole test run. /// /// # Generics /// /// * `TestFixture` is a generic test environment. The exact type may differ /// between different `TestSuite`s. /// pub struct TestCase<'all_testing, TestFixture> { pub(super) name: &'all_testing str, pub(super) run: fn(environment: &mut TestFixture) -> Result<(), ()>, } /// The `TestCase` struct comes with a constructor impl<'all_testing, TestFixture> TestCase<'all_testing, TestFixture> { /// Defines a test fixture (the test environment) /// /// # Arguments /// /// * `name` - Name of the test case /// * `run` - Function to call when the test case shall be run. /// This function may panic in case of an error in the test environment; /// it shall return `Result::Err(())` if the test case did not produce /// the expected observation, `Result::Ok(())` in case of success. /// pub fn new( name: &'static str, run: fn(environment: &mut TestFixture) -> Result<(), ()>, ) -> TestCase<'all_testing, TestFixture> { TestCase { name: name, run: run, } } } /* Copyright 2022-2025 Andreas Warnke Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. */ crystal-facet-uml-1.63.3/build/qualification_test/src/test_tool/test_result.rs000066400000000000000000000040671500562027500276650ustar00rootroot00000000000000//! This module implements a TestResult to collect statistics on a performed //! test run use std::ops::Add; use std::ops::AddAssign; /// A TestResult is a set of statistical data on a performed test run #[derive(Debug, Copy, Clone, PartialEq)] pub struct TestResult { /// The number of failed test cases in a test run pub failed: u32, /// The number of total test cases in a test run pub total: u32, } /// The Add trait on a TestResult allows to combine the test results of /// several sets of performed test cases impl Add for TestResult { type Output = Self; fn add(self, other: Self) -> Self::Output { Self { failed: self.failed + other.failed, total: self.total + other.total, } } } /// The AddAssign trait on a TestResult allows to combine the test results of /// several sets of performed test cases impl AddAssign for TestResult { fn add_assign(&mut self, other: Self) { *self = Self { failed: self.failed + other.failed, total: self.total + other.total, } } } /// The AddAssign trait on a TestResult and a Result allows to add the result /// of a single performed test case impl AddAssign> for TestResult { fn add_assign(&mut self, other: Result<(), ()>) { let other_failed: u32 = match other { Ok(_) => 0, Err(_) => 1, }; *self = Self { failed: self.failed + other_failed, total: self.total + 1, } } } /* Copyright 2022-2025 Andreas Warnke Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. */ crystal-facet-uml-1.63.3/build/qualification_test/src/test_tool/test_runner.rs000066400000000000000000000042031500562027500276500ustar00rootroot00000000000000//! This module implements a test runner which sets up test fixtures, runs test //! cases and collects statistics on test results for one TestSuite use super::test_result::TestResult; use super::test_suite::TestSuite; /// A test runner provides a run function which executes all test cases in the /// provided test suite /// /// # Arguments /// /// * `suite` - The test suite to execute /// /// # Lifetimes /// /// * `'all_testing` refers to the lifetime of `TestSuite` and `TestCase` /// objects: They exist during the whole test run. /// /// # Generics /// /// * `TestFixture` is a generic test environment. The exact type may differ /// between different `TestSuite`s. /// pub fn run<'all_testing, TestFixture>( suite: &'all_testing (dyn TestSuite<'all_testing, TestFixture> + 'all_testing), ) -> TestResult { let mut result: TestResult = TestResult { failed: 0, total: 0, }; println!( " [__ {} __]", suite.name() ); for case in suite.testcases() { println!( " [__ > {} __]", case.name ); let mut environment = suite.setup(); let testcase_result = (case.run)(&mut environment); result += testcase_result; suite.teardown(environment); println!( " [__ > {}: {} __]\n", case.name, match testcase_result { Ok(()) => "Ok", Err(()) => "Err", } ); } result } /* Copyright 2022-2025 Andreas Warnke Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. */ crystal-facet-uml-1.63.3/build/qualification_test/src/test_tool/test_suite.rs000066400000000000000000000036371500562027500275020ustar00rootroot00000000000000//! This module implements a test suite which sets up test //! fixtures (test environments) and provides a list of test cases. use super::test_case::TestCase; /// A test suite is an object that provides functions to /// setup a `TestFixture` (test environment) for each test case, /// to run each test case and to tear down the test fixtures. /// /// # Lifetimes /// /// * `'all_testing` refers to the lifetime of `TestSuite` and `TestCase` /// objects: They exist during the whole test run. /// /// # Generics /// /// * `TestFixture` is a generic test environment. The exact type may differ /// between different `TestSuite`s. /// pub trait TestSuite<'all_testing, TestFixture> { /// The name of this test suite fn name(self: &'all_testing Self) -> &'all_testing str; /// This function sets up the test environment (`TestFixture`) for the test /// cases in this test suite. fn setup(self: &'all_testing Self) -> TestFixture; /// This function cleans up the test environment (`TestFixture`) for the /// test cases in this test suite. /// /// # Arguments /// /// * `environment` - A test fixture to be cleaned up fn teardown(self: &'all_testing Self, environment: TestFixture) -> (); /// List of test cases in this test suite fn testcases(self: &'all_testing Self) -> &'all_testing [TestCase<'all_testing, TestFixture>]; } /* Copyright 2022-2025 Andreas Warnke Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. */ crystal-facet-uml-1.63.3/build/source_code_doc/000077500000000000000000000000001500562027500213605ustar00rootroot00000000000000crystal-facet-uml-1.63.3/build/source_code_doc/Doxyfile000066400000000000000000003054131500562027500230740ustar00rootroot00000000000000# Doxyfile 1.8.8 # This file describes the settings to be used by the documentation system # doxygen (www.doxygen.org) for a project. # # All text after a double hash (##) is considered a comment and is placed in # front of the TAG it is preceding. # # All text after a single hash (#) is considered a comment and will be ignored. # The format is: # TAG = value [value, ...] # For lists, items can also be appended using: # TAG += value [value, ...] # Values that contain spaces should be placed between quotes (\" \"). #--------------------------------------------------------------------------- # Project related configuration options #--------------------------------------------------------------------------- # This tag specifies the encoding used for all characters in the config file # that follow. The default is UTF-8 which is also the encoding used for all text # before the first occurrence of this tag. Doxygen uses libiconv (or the iconv # built into libc) for the transcoding. See http://www.gnu.org/software/libiconv # for the list of possible encodings. # The default value is: UTF-8. DOXYFILE_ENCODING = UTF-8 # The PROJECT_NAME tag is a single word (or a sequence of words surrounded by # double-quotes, unless you are using Doxywizard) that should identify the # project for which the documentation is generated. This name is used in the # title of most generated pages and in a few other places. # The default value is: My Project. PROJECT_NAME = crystal-facet-uml # The PROJECT_NUMBER tag can be used to enter a project or revision number. This # could be handy for archiving the generated documentation or if some version # control system is used. #PROJECT_NUMBER = set from external script, empty otherwise # Using the PROJECT_BRIEF tag one can provide an optional one line description # for a project that appears at the top of each page and should give viewer a # quick idea about the purpose of the project. Keep the description short. PROJECT_BRIEF = # With the PROJECT_LOGO tag one can specify an logo or icon that is included in # the documentation. The maximum height of the logo should not exceed 55 pixels # and the maximum width should not exceed 200 pixels. Doxygen will copy the logo # to the output directory. PROJECT_LOGO = # The OUTPUT_DIRECTORY tag is used to specify the (relative or absolute) path # into which the generated documentation will be written. If a relative path is # entered, it will be relative to the location where doxygen was started. If # left blank the current directory will be used. OUTPUT_DIRECTORY = doc # If the CREATE_SUBDIRS tag is set to YES, then doxygen will create 4096 sub- # directories (in 2 levels) under the output directory of each output format and # will distribute the generated files over these directories. Enabling this # option can be useful when feeding doxygen a huge amount of source files, where # putting all generated files in the same directory would otherwise causes # performance problems for the file system. # The default value is: NO. CREATE_SUBDIRS = NO # If the ALLOW_UNICODE_NAMES tag is set to YES, doxygen will allow non-ASCII # characters to appear in the names of generated files. If set to NO, non-ASCII # characters will be escaped, for example _xE3_x81_x84 will be used for Unicode # U+3044. # The default value is: NO. ALLOW_UNICODE_NAMES = NO # The OUTPUT_LANGUAGE tag is used to specify the language in which all # documentation generated by doxygen is written. Doxygen will use this # information to generate all constant output in the proper language. # Possible values are: Afrikaans, Arabic, Armenian, Brazilian, Catalan, Chinese, # Chinese-Traditional, Croatian, Czech, Danish, Dutch, English (United States), # Esperanto, Farsi (Persian), Finnish, French, German, Greek, Hungarian, # Indonesian, Italian, Japanese, Japanese-en (Japanese with English messages), # Korean, Korean-en (Korean with English messages), Latvian, Lithuanian, # Macedonian, Norwegian, Persian (Farsi), Polish, Portuguese, Romanian, Russian, # Serbian, Serbian-Cyrillic, Slovak, Slovene, Spanish, Swedish, Turkish, # Ukrainian and Vietnamese. # The default value is: English. OUTPUT_LANGUAGE = English # If the BRIEF_MEMBER_DESC tag is set to YES doxygen will include brief member # descriptions after the members that are listed in the file and class # documentation (similar to Javadoc). Set to NO to disable this. # The default value is: YES. BRIEF_MEMBER_DESC = YES # If the REPEAT_BRIEF tag is set to YES doxygen will prepend the brief # description of a member or function before the detailed description # # Note: If both HIDE_UNDOC_MEMBERS and BRIEF_MEMBER_DESC are set to NO, the # brief descriptions will be completely suppressed. # The default value is: YES. REPEAT_BRIEF = YES # This tag implements a quasi-intelligent brief description abbreviator that is # used to form the text in various listings. Each string in this list, if found # as the leading text of the brief description, will be stripped from the text # and the result, after processing the whole list, is used as the annotated # text. Otherwise, the brief description is used as-is. If left blank, the # following values are used ($name is automatically replaced with the name of # the entity):The $name class, The $name widget, The $name file, is, provides, # specifies, contains, represents, a, an and the. ABBREVIATE_BRIEF = # If the ALWAYS_DETAILED_SEC and REPEAT_BRIEF tags are both set to YES then # doxygen will generate a detailed section even if there is only a brief # description. # The default value is: NO. ALWAYS_DETAILED_SEC = NO # If the INLINE_INHERITED_MEMB tag is set to YES, doxygen will show all # inherited members of a class in the documentation of that class as if those # members were ordinary class members. Constructors, destructors and assignment # operators of the base classes will not be shown. # The default value is: NO. INLINE_INHERITED_MEMB = NO # If the FULL_PATH_NAMES tag is set to YES doxygen will prepend the full path # before files name in the file list and in the header files. If set to NO the # shortest path that makes the file name unique will be used # The default value is: YES. FULL_PATH_NAMES = NO # The STRIP_FROM_PATH tag can be used to strip a user-defined part of the path. # Stripping is only done if one of the specified strings matches the left-hand # part of the path. The tag can be used to show relative paths in the file list. # If left blank the directory from which doxygen is run is used as the path to # strip. # # Note that you can specify absolute paths here, but also relative paths, which # will be relative from the directory where doxygen is started. # This tag requires that the tag FULL_PATH_NAMES is set to YES. STRIP_FROM_PATH = # The STRIP_FROM_INC_PATH tag can be used to strip a user-defined part of the # path mentioned in the documentation of a class, which tells the reader which # header file to include in order to use a class. If left blank only the name of # the header file containing the class definition is used. Otherwise one should # specify the list of include paths that are normally passed to the compiler # using the -I flag. STRIP_FROM_INC_PATH = # If the SHORT_NAMES tag is set to YES, doxygen will generate much shorter (but # less readable) file names. This can be useful is your file systems doesn't # support long names like on DOS, Mac, or CD-ROM. # The default value is: NO. SHORT_NAMES = NO # If the JAVADOC_AUTOBRIEF tag is set to YES then doxygen will interpret the # first line (until the first dot) of a Javadoc-style comment as the brief # description. If set to NO, the Javadoc-style will behave just like regular Qt- # style comments (thus requiring an explicit @brief command for a brief # description.) # The default value is: NO. JAVADOC_AUTOBRIEF = NO # If the QT_AUTOBRIEF tag is set to YES then doxygen will interpret the first # line (until the first dot) of a Qt-style comment as the brief description. If # set to NO, the Qt-style will behave just like regular Qt-style comments (thus # requiring an explicit \brief command for a brief description.) # The default value is: NO. QT_AUTOBRIEF = NO # The MULTILINE_CPP_IS_BRIEF tag can be set to YES to make doxygen treat a # multi-line C++ special comment block (i.e. a block of //! or /// comments) as # a brief description. This used to be the default behavior. The new default is # to treat a multi-line C++ comment block as a detailed description. Set this # tag to YES if you prefer the old behavior instead. # # Note that setting this tag to YES also means that rational rose comments are # not recognized any more. # The default value is: NO. MULTILINE_CPP_IS_BRIEF = NO # If the INHERIT_DOCS tag is set to YES then an undocumented member inherits the # documentation from any documented member that it re-implements. # The default value is: YES. INHERIT_DOCS = YES # If the SEPARATE_MEMBER_PAGES tag is set to YES, then doxygen will produce a # new page for each member. If set to NO, the documentation of a member will be # part of the file/class/namespace that contains it. # The default value is: NO. SEPARATE_MEMBER_PAGES = NO # The TAB_SIZE tag can be used to set the number of spaces in a tab. Doxygen # uses this value to replace tabs by spaces in code fragments. # Minimum value: 1, maximum value: 16, default value: 4. TAB_SIZE = 8 # This tag can be used to specify a number of aliases that act as commands in # the documentation. An alias has the form: # name=value # For example adding # "sideeffect=@par Side Effects:\n" # will allow you to put the command \sideeffect (or @sideeffect) in the # documentation, which will result in a user-defined paragraph with heading # "Side Effects:". You can put \n's in the value part of an alias to insert # newlines. ALIASES = # Set the OPTIMIZE_OUTPUT_FOR_C tag to YES if your project consists of C sources # only. Doxygen will then generate output that is more tailored for C. For # instance, some of the names that are used will be different. The list of all # members will be omitted, etc. # The default value is: NO. OPTIMIZE_OUTPUT_FOR_C = YES # Set the OPTIMIZE_OUTPUT_JAVA tag to YES if your project consists of Java or # Python sources only. Doxygen will then generate output that is more tailored # for that language. For instance, namespaces will be presented as packages, # qualified scopes will look different, etc. # The default value is: NO. OPTIMIZE_OUTPUT_JAVA = NO # Set the OPTIMIZE_FOR_FORTRAN tag to YES if your project consists of Fortran # sources. Doxygen will then generate output that is tailored for Fortran. # The default value is: NO. OPTIMIZE_FOR_FORTRAN = NO # Set the OPTIMIZE_OUTPUT_VHDL tag to YES if your project consists of VHDL # sources. Doxygen will then generate output that is tailored for VHDL. # The default value is: NO. OPTIMIZE_OUTPUT_VHDL = NO # Doxygen selects the parser to use depending on the extension of the files it # parses. With this tag you can assign which parser to use for a given # extension. Doxygen has a built-in mapping, but you can override or extend it # using this tag. The format is ext=language, where ext is a file extension, and # language is one of the parsers supported by doxygen: IDL, Java, Javascript, # C#, C, C++, D, PHP, Objective-C, Python, Fortran (fixed format Fortran: # FortranFixed, free formatted Fortran: FortranFree, unknown formatted Fortran: # Fortran. In the later case the parser tries to guess whether the code is fixed # or free formatted code, this is the default for Fortran type files), VHDL. For # instance to make doxygen treat .inc files as Fortran files (default is PHP), # and .f files as C (default is Fortran), use: inc=Fortran f=C. # # Note For files without extension you can use no_extension as a placeholder. # # Note that for custom extensions you also need to set FILE_PATTERNS otherwise # the files are not read by doxygen. EXTENSION_MAPPING = # If the MARKDOWN_SUPPORT tag is enabled then doxygen pre-processes all comments # according to the Markdown format, which allows for more readable # documentation. See http://daringfireball.net/projects/markdown/ for details. # The output of markdown processing is further processed by doxygen, so you can # mix doxygen, HTML, and XML commands with Markdown formatting. Disable only in # case of backward compatibilities issues. # The default value is: YES. MARKDOWN_SUPPORT = YES # When enabled doxygen tries to link words that correspond to documented # classes, or namespaces to their corresponding documentation. Such a link can # be prevented in individual cases by by putting a % sign in front of the word # or globally by setting AUTOLINK_SUPPORT to NO. # The default value is: YES. AUTOLINK_SUPPORT = YES # If you use STL classes (i.e. std::string, std::vector, etc.) but do not want # to include (a tag file for) the STL sources as input, then you should set this # tag to YES in order to let doxygen match functions declarations and # definitions whose arguments contain STL classes (e.g. func(std::string); # versus func(std::string) {}). This also make the inheritance and collaboration # diagrams that involve STL classes more complete and accurate. # The default value is: NO. BUILTIN_STL_SUPPORT = NO # If you use Microsoft's C++/CLI language, you should set this option to YES to # enable parsing support. # The default value is: NO. CPP_CLI_SUPPORT = NO # Set the SIP_SUPPORT tag to YES if your project consists of sip (see: # http://www.riverbankcomputing.co.uk/software/sip/intro) sources only. Doxygen # will parse them like normal C++ but will assume all classes use public instead # of private inheritance when no explicit protection keyword is present. # The default value is: NO. SIP_SUPPORT = NO # For Microsoft's IDL there are propget and propput attributes to indicate # getter and setter methods for a property. Setting this option to YES will make # doxygen to replace the get and set methods by a property in the documentation. # This will only work if the methods are indeed getting or setting a simple # type. If this is not the case, or you want to show the methods anyway, you # should set this option to NO. # The default value is: YES. IDL_PROPERTY_SUPPORT = YES # If member grouping is used in the documentation and the DISTRIBUTE_GROUP_DOC # tag is set to YES, then doxygen will reuse the documentation of the first # member in the group (if any) for the other members of the group. By default # all members of a group must be documented explicitly. # The default value is: NO. DISTRIBUTE_GROUP_DOC = NO # Set the SUBGROUPING tag to YES to allow class member groups of the same type # (for instance a group of public functions) to be put as a subgroup of that # type (e.g. under the Public Functions section). Set it to NO to prevent # subgrouping. Alternatively, this can be done per class using the # \nosubgrouping command. # The default value is: YES. SUBGROUPING = YES # When the INLINE_GROUPED_CLASSES tag is set to YES, classes, structs and unions # are shown inside the group in which they are included (e.g. using \ingroup) # instead of on a separate page (for HTML and Man pages) or section (for LaTeX # and RTF). # # Note that this feature does not work in combination with # SEPARATE_MEMBER_PAGES. # The default value is: NO. INLINE_GROUPED_CLASSES = NO # When the INLINE_SIMPLE_STRUCTS tag is set to YES, structs, classes, and unions # with only public data fields or simple typedef fields will be shown inline in # the documentation of the scope in which they are defined (i.e. file, # namespace, or group documentation), provided this scope is documented. If set # to NO, structs, classes, and unions are shown on a separate page (for HTML and # Man pages) or section (for LaTeX and RTF). # The default value is: NO. INLINE_SIMPLE_STRUCTS = NO # When TYPEDEF_HIDES_STRUCT tag is enabled, a typedef of a struct, union, or # enum is documented as struct, union, or enum with the name of the typedef. So # typedef struct TypeS {} TypeT, will appear in the documentation as a struct # with name TypeT. When disabled the typedef will appear as a member of a file, # namespace, or class. And the struct will be named TypeS. This can typically be # useful for C code in case the coding convention dictates that all compound # types are typedef'ed and only the typedef is referenced, never the tag name. # The default value is: NO. TYPEDEF_HIDES_STRUCT = NO # The size of the symbol lookup cache can be set using LOOKUP_CACHE_SIZE. This # cache is used to resolve symbols given their name and scope. Since this can be # an expensive process and often the same symbol appears multiple times in the # code, doxygen keeps a cache of pre-resolved symbols. If the cache is too small # doxygen will become slower. If the cache is too large, memory is wasted. The # cache size is given by this formula: 2^(16+LOOKUP_CACHE_SIZE). The valid range # is 0..9, the default is 0, corresponding to a cache size of 2^16=65536 # symbols. At the end of a run doxygen will report the cache usage and suggest # the optimal cache size from a speed point of view. # Minimum value: 0, maximum value: 9, default value: 0. LOOKUP_CACHE_SIZE = 0 #--------------------------------------------------------------------------- # Build related configuration options #--------------------------------------------------------------------------- # If the EXTRACT_ALL tag is set to YES doxygen will assume all entities in # documentation are documented, even if no documentation was available. Private # class members and static file members will be hidden unless the # EXTRACT_PRIVATE respectively EXTRACT_STATIC tags are set to YES. # Note: This will also disable the warnings about undocumented members that are # normally produced when WARNINGS is set to YES. # The default value is: NO. EXTRACT_ALL = YES # If the EXTRACT_PRIVATE tag is set to YES all private members of a class will # be included in the documentation. # The default value is: NO. EXTRACT_PRIVATE = NO # If the EXTRACT_PACKAGE tag is set to YES all members with package or internal # scope will be included in the documentation. # The default value is: NO. EXTRACT_PACKAGE = NO # If the EXTRACT_STATIC tag is set to YES all static members of a file will be # included in the documentation. # The default value is: NO. EXTRACT_STATIC = YES # If the EXTRACT_LOCAL_CLASSES tag is set to YES classes (and structs) defined # locally in source files will be included in the documentation. If set to NO # only classes defined in header files are included. Does not have any effect # for Java sources. # The default value is: YES. EXTRACT_LOCAL_CLASSES = YES # This flag is only useful for Objective-C code. When set to YES local methods, # which are defined in the implementation section but not in the interface are # included in the documentation. If set to NO only methods in the interface are # included. # The default value is: NO. EXTRACT_LOCAL_METHODS = NO # If this flag is set to YES, the members of anonymous namespaces will be # extracted and appear in the documentation as a namespace called # 'anonymous_namespace{file}', where file will be replaced with the base name of # the file that contains the anonymous namespace. By default anonymous namespace # are hidden. # The default value is: NO. EXTRACT_ANON_NSPACES = NO # If the HIDE_UNDOC_MEMBERS tag is set to YES, doxygen will hide all # undocumented members inside documented classes or files. If set to NO these # members will be included in the various overviews, but no documentation # section is generated. This option has no effect if EXTRACT_ALL is enabled. # The default value is: NO. HIDE_UNDOC_MEMBERS = NO # If the HIDE_UNDOC_CLASSES tag is set to YES, doxygen will hide all # undocumented classes that are normally visible in the class hierarchy. If set # to NO these classes will be included in the various overviews. This option has # no effect if EXTRACT_ALL is enabled. # The default value is: NO. HIDE_UNDOC_CLASSES = NO # If the HIDE_FRIEND_COMPOUNDS tag is set to YES, doxygen will hide all friend # (class|struct|union) declarations. If set to NO these declarations will be # included in the documentation. # The default value is: NO. HIDE_FRIEND_COMPOUNDS = NO # If the HIDE_IN_BODY_DOCS tag is set to YES, doxygen will hide any # documentation blocks found inside the body of a function. If set to NO these # blocks will be appended to the function's detailed documentation block. # The default value is: NO. HIDE_IN_BODY_DOCS = NO # The INTERNAL_DOCS tag determines if documentation that is typed after a # \internal command is included. If the tag is set to NO then the documentation # will be excluded. Set it to YES to include the internal documentation. # The default value is: NO. INTERNAL_DOCS = NO # If the CASE_SENSE_NAMES tag is set to NO then doxygen will only generate file # names in lower-case letters. If set to YES upper-case letters are also # allowed. This is useful if you have classes or files whose names only differ # in case and if your file system supports case sensitive file names. Windows # and Mac users are advised to set this option to NO. # The default value is: system dependent. CASE_SENSE_NAMES = YES # If the HIDE_SCOPE_NAMES tag is set to NO then doxygen will show members with # their full class and namespace scopes in the documentation. If set to YES the # scope will be hidden. # The default value is: NO. HIDE_SCOPE_NAMES = NO # If the SHOW_INCLUDE_FILES tag is set to YES then doxygen will put a list of # the files that are included by a file in the documentation of that file. # The default value is: YES. SHOW_INCLUDE_FILES = YES # If the SHOW_GROUPED_MEMB_INC tag is set to YES then Doxygen will add for each # grouped member an include statement to the documentation, telling the reader # which file to include in order to use the member. # The default value is: NO. SHOW_GROUPED_MEMB_INC = NO # If the FORCE_LOCAL_INCLUDES tag is set to YES then doxygen will list include # files with double quotes in the documentation rather than with sharp brackets. # The default value is: NO. FORCE_LOCAL_INCLUDES = NO # If the INLINE_INFO tag is set to YES then a tag [inline] is inserted in the # documentation for inline members. # The default value is: YES. INLINE_INFO = YES # If the SORT_MEMBER_DOCS tag is set to YES then doxygen will sort the # (detailed) documentation of file and class members alphabetically by member # name. If set to NO the members will appear in declaration order. # The default value is: YES. SORT_MEMBER_DOCS = YES # If the SORT_BRIEF_DOCS tag is set to YES then doxygen will sort the brief # descriptions of file, namespace and class members alphabetically by member # name. If set to NO the members will appear in declaration order. Note that # this will also influence the order of the classes in the class list. # The default value is: NO. SORT_BRIEF_DOCS = NO # If the SORT_MEMBERS_CTORS_1ST tag is set to YES then doxygen will sort the # (brief and detailed) documentation of class members so that constructors and # destructors are listed first. If set to NO the constructors will appear in the # respective orders defined by SORT_BRIEF_DOCS and SORT_MEMBER_DOCS. # Note: If SORT_BRIEF_DOCS is set to NO this option is ignored for sorting brief # member documentation. # Note: If SORT_MEMBER_DOCS is set to NO this option is ignored for sorting # detailed member documentation. # The default value is: NO. SORT_MEMBERS_CTORS_1ST = NO # If the SORT_GROUP_NAMES tag is set to YES then doxygen will sort the hierarchy # of group names into alphabetical order. If set to NO the group names will # appear in their defined order. # The default value is: NO. SORT_GROUP_NAMES = NO # If the SORT_BY_SCOPE_NAME tag is set to YES, the class list will be sorted by # fully-qualified names, including namespaces. If set to NO, the class list will # be sorted only by class name, not including the namespace part. # Note: This option is not very useful if HIDE_SCOPE_NAMES is set to YES. # Note: This option applies only to the class list, not to the alphabetical # list. # The default value is: NO. SORT_BY_SCOPE_NAME = NO # If the STRICT_PROTO_MATCHING option is enabled and doxygen fails to do proper # type resolution of all parameters of a function it will reject a match between # the prototype and the implementation of a member function even if there is # only one candidate or it is obvious which candidate to choose by doing a # simple string match. By disabling STRICT_PROTO_MATCHING doxygen will still # accept a match between prototype and implementation in such cases. # The default value is: NO. STRICT_PROTO_MATCHING = NO # The GENERATE_TODOLIST tag can be used to enable ( YES) or disable ( NO) the # todo list. This list is created by putting \todo commands in the # documentation. # The default value is: YES. GENERATE_TODOLIST = YES # The GENERATE_TESTLIST tag can be used to enable ( YES) or disable ( NO) the # test list. This list is created by putting \test commands in the # documentation. # The default value is: YES. GENERATE_TESTLIST = YES # The GENERATE_BUGLIST tag can be used to enable ( YES) or disable ( NO) the bug # list. This list is created by putting \bug commands in the documentation. # The default value is: YES. GENERATE_BUGLIST = YES # The GENERATE_DEPRECATEDLIST tag can be used to enable ( YES) or disable ( NO) # the deprecated list. This list is created by putting \deprecated commands in # the documentation. # The default value is: YES. GENERATE_DEPRECATEDLIST= YES # The ENABLED_SECTIONS tag can be used to enable conditional documentation # sections, marked by \if ... \endif and \cond # ... \endcond blocks. ENABLED_SECTIONS = # The MAX_INITIALIZER_LINES tag determines the maximum number of lines that the # initial value of a variable or macro / define can have for it to appear in the # documentation. If the initializer consists of more lines than specified here # it will be hidden. Use a value of 0 to hide initializers completely. The # appearance of the value of individual variables and macros / defines can be # controlled using \showinitializer or \hideinitializer command in the # documentation regardless of this setting. # Minimum value: 0, maximum value: 10000, default value: 30. MAX_INITIALIZER_LINES = 30 # Set the SHOW_USED_FILES tag to NO to disable the list of files generated at # the bottom of the documentation of classes and structs. If set to YES the list # will mention the files that were used to generate the documentation. # The default value is: YES. SHOW_USED_FILES = YES # Set the SHOW_FILES tag to NO to disable the generation of the Files page. This # will remove the Files entry from the Quick Index and from the Folder Tree View # (if specified). # The default value is: YES. SHOW_FILES = YES # Set the SHOW_NAMESPACES tag to NO to disable the generation of the Namespaces # page. This will remove the Namespaces entry from the Quick Index and from the # Folder Tree View (if specified). # The default value is: YES. SHOW_NAMESPACES = YES # The FILE_VERSION_FILTER tag can be used to specify a program or script that # doxygen should invoke to get the current version for each file (typically from # the version control system). Doxygen will invoke the program by executing (via # popen()) the command command input-file, where command is the value of the # FILE_VERSION_FILTER tag, and input-file is the name of an input file provided # by doxygen. Whatever the program writes to standard output is used as the file # version. For an example see the documentation. FILE_VERSION_FILTER = # The LAYOUT_FILE tag can be used to specify a layout file which will be parsed # by doxygen. The layout file controls the global structure of the generated # output files in an output format independent way. To create the layout file # that represents doxygen's defaults, run doxygen with the -l option. You can # optionally specify a file name after the option, if omitted DoxygenLayout.xml # will be used as the name of the layout file. # # Note that if you run doxygen from a directory containing a file called # DoxygenLayout.xml, doxygen will parse it automatically even if the LAYOUT_FILE # tag is left empty. LAYOUT_FILE = # The CITE_BIB_FILES tag can be used to specify one or more bib files containing # the reference definitions. This must be a list of .bib files. The .bib # extension is automatically appended if omitted. This requires the bibtex tool # to be installed. See also http://en.wikipedia.org/wiki/BibTeX for more info. # For LaTeX the style of the bibliography can be controlled using # LATEX_BIB_STYLE. To use this feature you need bibtex and perl available in the # search path. See also \cite for info how to create references. CITE_BIB_FILES = #--------------------------------------------------------------------------- # Configuration options related to warning and progress messages #--------------------------------------------------------------------------- # The QUIET tag can be used to turn on/off the messages that are generated to # standard output by doxygen. If QUIET is set to YES this implies that the # messages are off. # The default value is: NO. QUIET = NO # The WARNINGS tag can be used to turn on/off the warning messages that are # generated to standard error ( stderr) by doxygen. If WARNINGS is set to YES # this implies that the warnings are on. # # Tip: Turn warnings on while writing the documentation. # The default value is: YES. WARNINGS = YES # If the WARN_IF_UNDOCUMENTED tag is set to YES, then doxygen will generate # warnings for undocumented members. If EXTRACT_ALL is set to YES then this flag # will automatically be disabled. # The default value is: YES. WARN_IF_UNDOCUMENTED = YES # If the WARN_IF_DOC_ERROR tag is set to YES, doxygen will generate warnings for # potential errors in the documentation, such as not documenting some parameters # in a documented function, or documenting parameters that don't exist or using # markup commands wrongly. # The default value is: YES. WARN_IF_DOC_ERROR = YES # This WARN_NO_PARAMDOC option can be enabled to get warnings for functions that # are documented, but have no documentation for their parameters or return # value. If set to NO doxygen will only warn about wrong or incomplete parameter # documentation, but not about the absence of documentation. # The default value is: NO. WARN_NO_PARAMDOC = YES # The WARN_FORMAT tag determines the format of the warning messages that doxygen # can produce. The string should contain the $file, $line, and $text tags, which # will be replaced by the file and line number from which the warning originated # and the warning text. Optionally the format may contain $version, which will # be replaced by the version of the file (if it could be obtained via # FILE_VERSION_FILTER) # The default value is: $file:$line: $text. WARN_FORMAT = "$file:$line: $text" # The WARN_LOGFILE tag can be used to specify a file to which warning and error # messages should be written. If left blank the output is written to standard # error (stderr). WARN_LOGFILE = #--------------------------------------------------------------------------- # Configuration options related to the input files #--------------------------------------------------------------------------- # The INPUT tag is used to specify the files and/or directories that contain # documented source files. You may enter file names like myfile.cpp or # directories like /usr/src/myproject. Separate the files or directories with # spaces. # Note: If this tag is empty the current directory is searched. INPUT = ./source_code_doc.txt \ ../../documentation/architecture/coding_guidelines.txt \ ../../documentation/architecture/lessons_learned.txt \ ../../ctrl \ ../../data \ ../../gui \ ../../main \ ../../io \ ../../pencil \ ../../test_fw \ ../../u8stream # This tag can be used to specify the character encoding of the source files # that doxygen parses. Internally doxygen uses the UTF-8 encoding. Doxygen uses # libiconv (or the iconv built into libc) for the transcoding. See the libiconv # documentation (see: http://www.gnu.org/software/libiconv) for the list of # possible encodings. # The default value is: UTF-8. INPUT_ENCODING = UTF-8 # If the value of the INPUT tag contains directories, you can use the # FILE_PATTERNS tag to specify one or more wildcard patterns (like *.cpp and # *.h) to filter out the source-files in the directories. If left blank the # following patterns are tested:*.c, *.cc, *.cxx, *.cpp, *.c++, *.java, *.ii, # *.ixx, *.ipp, *.i++, *.inl, *.idl, *.ddl, *.odl, *.h, *.hh, *.hxx, *.hpp, # *.h++, *.cs, *.d, *.php, *.php4, *.php5, *.phtml, *.inc, *.m, *.markdown, # *.md, *.mm, *.dox, *.py, *.f90, *.f, *.for, *.tcl, *.vhd, *.vhdl, *.ucf, # *.qsf, *.as and *.js. FILE_PATTERNS = # The RECURSIVE tag can be used to specify whether or not subdirectories should # be searched for input files as well. # The default value is: NO. RECURSIVE = YES # The EXCLUDE tag can be used to specify files and/or directories that should be # excluded from the INPUT source files. This way you can easily exclude a # subdirectory from a directory tree whose root is specified with the INPUT tag. # # Note that relative paths are relative to the directory from which doxygen is # run. EXCLUDE = # The EXCLUDE_SYMLINKS tag can be used to select whether or not files or # directories that are symbolic links (a Unix file system feature) are excluded # from the input. # The default value is: NO. EXCLUDE_SYMLINKS = NO # If the value of the INPUT tag contains directories, you can use the # EXCLUDE_PATTERNS tag to specify one or more wildcard patterns to exclude # certain files from those directories. # # Note that the wildcards are matched against the file with absolute path, so to # exclude all test directories for example use the pattern */test/* EXCLUDE_PATTERNS = # The EXCLUDE_SYMBOLS tag can be used to specify one or more symbol names # (namespaces, classes, functions, etc.) that should be excluded from the # output. The symbol name can be a fully qualified name, a word, or if the # wildcard * is used, a substring. Examples: ANamespace, AClass, # AClass::ANamespace, ANamespace::*Test # # Note that the wildcards are matched against the file with absolute path, so to # exclude all test directories use the pattern */test/* EXCLUDE_SYMBOLS = # The EXAMPLE_PATH tag can be used to specify one or more files or directories # that contain example code fragments that are included (see the \include # command). # also used for verbinclude EXAMPLE_PATH = # If the value of the EXAMPLE_PATH tag contains directories, you can use the # EXAMPLE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp and # *.h) to filter out the source-files in the directories. If left blank all # files are included. EXAMPLE_PATTERNS = # If the EXAMPLE_RECURSIVE tag is set to YES then subdirectories will be # searched for input files to be used with the \include or \dontinclude commands # irrespective of the value of the RECURSIVE tag. # The default value is: NO. EXAMPLE_RECURSIVE = NO # The IMAGE_PATH tag can be used to specify one or more files or directories # that contain images that are to be included in the documentation (see the # \image command). IMAGE_PATH = ../../documentation/user_manual ../../gui/source # The INPUT_FILTER tag can be used to specify a program that doxygen should # invoke to filter for each input file. Doxygen will invoke the filter program # by executing (via popen()) the command: # # # # where is the value of the INPUT_FILTER tag, and is the # name of an input file. Doxygen will then use the output that the filter # program writes to standard output. If FILTER_PATTERNS is specified, this tag # will be ignored. # # Note that the filter must not add or remove lines; it is applied before the # code is scanned, but not when the output code is generated. If lines are added # or removed, the anchors will not be placed correctly. INPUT_FILTER = # The FILTER_PATTERNS tag can be used to specify filters on a per file pattern # basis. Doxygen will compare the file name with each pattern and apply the # filter if there is a match. The filters are a list of the form: pattern=filter # (like *.cpp=my_cpp_filter). See INPUT_FILTER for further information on how # filters are used. If the FILTER_PATTERNS tag is empty or if none of the # patterns match the file name, INPUT_FILTER is applied. FILTER_PATTERNS = # If the FILTER_SOURCE_FILES tag is set to YES, the input filter (if set using # INPUT_FILTER ) will also be used to filter the input files that are used for # producing the source files to browse (i.e. when SOURCE_BROWSER is set to YES). # The default value is: NO. FILTER_SOURCE_FILES = NO # The FILTER_SOURCE_PATTERNS tag can be used to specify source filters per file # pattern. A pattern will override the setting for FILTER_PATTERN (if any) and # it is also possible to disable source filtering for a specific pattern using # *.ext= (so without naming a filter). # This tag requires that the tag FILTER_SOURCE_FILES is set to YES. FILTER_SOURCE_PATTERNS = # If the USE_MDFILE_AS_MAINPAGE tag refers to the name of a markdown file that # is part of the input, its contents will be placed on the main page # (index.html). This can be useful if you have a project on for instance GitHub # and want to reuse the introduction page also for the doxygen output. USE_MDFILE_AS_MAINPAGE = #--------------------------------------------------------------------------- # Configuration options related to source browsing #--------------------------------------------------------------------------- # If the SOURCE_BROWSER tag is set to YES then a list of source files will be # generated. Documented entities will be cross-referenced with these sources. # # Note: To get rid of all source code in the generated output, make sure that # also VERBATIM_HEADERS is set to NO. # The default value is: NO. SOURCE_BROWSER = NO # Setting the INLINE_SOURCES tag to YES will include the body of functions, # classes and enums directly into the documentation. # The default value is: NO. INLINE_SOURCES = NO # Setting the STRIP_CODE_COMMENTS tag to YES will instruct doxygen to hide any # special comment blocks from generated source code fragments. Normal C, C++ and # Fortran comments will always remain visible. # The default value is: YES. STRIP_CODE_COMMENTS = YES # If the REFERENCED_BY_RELATION tag is set to YES then for each documented # function all documented functions referencing it will be listed. # The default value is: NO. REFERENCED_BY_RELATION = YES # If the REFERENCES_RELATION tag is set to YES then for each documented function # all documented entities called/used by that function will be listed. # The default value is: NO. REFERENCES_RELATION = YES # If the REFERENCES_LINK_SOURCE tag is set to YES and SOURCE_BROWSER tag is set # to YES, then the hyperlinks from functions in REFERENCES_RELATION and # REFERENCED_BY_RELATION lists will link to the source code. Otherwise they will # link to the documentation. # The default value is: YES. REFERENCES_LINK_SOURCE = YES # If SOURCE_TOOLTIPS is enabled (the default) then hovering a hyperlink in the # source code will show a tooltip with additional information such as prototype, # brief description and links to the definition and documentation. Since this # will make the HTML file larger and loading of large files a bit slower, you # can opt to disable this feature. # The default value is: YES. # This tag requires that the tag SOURCE_BROWSER is set to YES. SOURCE_TOOLTIPS = YES # If the USE_HTAGS tag is set to YES then the references to source code will # point to the HTML generated by the htags(1) tool instead of doxygen built-in # source browser. The htags tool is part of GNU's global source tagging system # (see http://www.gnu.org/software/global/global.html). You will need version # 4.8.6 or higher. # # To use it do the following: # - Install the latest version of global # - Enable SOURCE_BROWSER and USE_HTAGS in the config file # - Make sure the INPUT points to the root of the source tree # - Run doxygen as normal # # Doxygen will invoke htags (and that will in turn invoke gtags), so these # tools must be available from the command line (i.e. in the search path). # # The result: instead of the source browser generated by doxygen, the links to # source code will now point to the output of htags. # The default value is: NO. # This tag requires that the tag SOURCE_BROWSER is set to YES. USE_HTAGS = NO # If the VERBATIM_HEADERS tag is set the YES then doxygen will generate a # verbatim copy of the header file for each class for which an include is # specified. Set to NO to disable this. # See also: Section \class. # The default value is: YES. VERBATIM_HEADERS = YES #--------------------------------------------------------------------------- # Configuration options related to the alphabetical class index #--------------------------------------------------------------------------- # If the ALPHABETICAL_INDEX tag is set to YES, an alphabetical index of all # compounds will be generated. Enable this if the project contains a lot of # classes, structs, unions or interfaces. # The default value is: YES. ALPHABETICAL_INDEX = NO # In case all classes in a project start with a common prefix, all classes will # be put under the same header in the alphabetical index. The IGNORE_PREFIX tag # can be used to specify a prefix (or a list of prefixes) that should be ignored # while generating the index headers. # This tag requires that the tag ALPHABETICAL_INDEX is set to YES. IGNORE_PREFIX = #--------------------------------------------------------------------------- # Configuration options related to the HTML output #--------------------------------------------------------------------------- # If the GENERATE_HTML tag is set to YES doxygen will generate HTML output # The default value is: YES. GENERATE_HTML = YES # The HTML_OUTPUT tag is used to specify where the HTML docs will be put. If a # relative path is entered the value of OUTPUT_DIRECTORY will be put in front of # it. # The default directory is: html. # This tag requires that the tag GENERATE_HTML is set to YES. HTML_OUTPUT = html # The HTML_FILE_EXTENSION tag can be used to specify the file extension for each # generated HTML page (for example: .htm, .php, .asp). # The default value is: .html. # This tag requires that the tag GENERATE_HTML is set to YES. HTML_FILE_EXTENSION = .html # The HTML_HEADER tag can be used to specify a user-defined HTML header file for # each generated HTML page. If the tag is left blank doxygen will generate a # standard header. # # To get valid HTML the header file that includes any scripts and style sheets # that doxygen needs, which is dependent on the configuration options used (e.g. # the setting GENERATE_TREEVIEW). It is highly recommended to start with a # default header using # doxygen -w html new_header.html new_footer.html new_stylesheet.css # YourConfigFile # and then modify the file new_header.html. See also section "Doxygen usage" # for information on how to generate the default header that doxygen normally # uses. # Note: The header is subject to change so you typically have to regenerate the # default header when upgrading to a newer version of doxygen. For a description # of the possible markers and block names see the documentation. # This tag requires that the tag GENERATE_HTML is set to YES. HTML_HEADER = # The HTML_FOOTER tag can be used to specify a user-defined HTML footer for each # generated HTML page. If the tag is left blank doxygen will generate a standard # footer. See HTML_HEADER for more information on how to generate a default # footer and what special commands can be used inside the footer. See also # section "Doxygen usage" for information on how to generate the default footer # that doxygen normally uses. # This tag requires that the tag GENERATE_HTML is set to YES. HTML_FOOTER = # The HTML_STYLESHEET tag can be used to specify a user-defined cascading style # sheet that is used by each HTML page. It can be used to fine-tune the look of # the HTML output. If left blank doxygen will generate a default style sheet. # See also section "Doxygen usage" for information on how to generate the style # sheet that doxygen normally uses. # Note: It is recommended to use HTML_EXTRA_STYLESHEET instead of this tag, as # it is more robust and this tag (HTML_STYLESHEET) will in the future become # obsolete. # This tag requires that the tag GENERATE_HTML is set to YES. HTML_STYLESHEET = # The HTML_EXTRA_STYLESHEET tag can be used to specify additional user-defined # cascading style sheets that are included after the standard style sheets # created by doxygen. Using this option one can overrule certain style aspects. # This is preferred over using HTML_STYLESHEET since it does not replace the # standard style sheet and is therefor more robust against future updates. # Doxygen will copy the style sheet files to the output directory. # Note: The order of the extra stylesheet files is of importance (e.g. the last # stylesheet in the list overrules the setting of the previous ones in the # list). For an example see the documentation. # This tag requires that the tag GENERATE_HTML is set to YES. HTML_EXTRA_STYLESHEET = # The HTML_EXTRA_FILES tag can be used to specify one or more extra images or # other source files which should be copied to the HTML output directory. Note # that these files will be copied to the base HTML output directory. Use the # $relpath^ marker in the HTML_HEADER and/or HTML_FOOTER files to load these # files. In the HTML_STYLESHEET file, use the file name only. Also note that the # files will be copied as-is; there are no commands or markers available. # This tag requires that the tag GENERATE_HTML is set to YES. HTML_EXTRA_FILES = # The HTML_COLORSTYLE_HUE tag controls the color of the HTML output. Doxygen # will adjust the colors in the stylesheet and background images according to # this color. Hue is specified as an angle on a colorwheel, see # http://en.wikipedia.org/wiki/Hue for more information. For instance the value # 0 represents red, 60 is yellow, 120 is green, 180 is cyan, 240 is blue, 300 # purple, and 360 is red again. # Minimum value: 0, maximum value: 359, default value: 220. # This tag requires that the tag GENERATE_HTML is set to YES. HTML_COLORSTYLE_HUE = 220 # The HTML_COLORSTYLE_SAT tag controls the purity (or saturation) of the colors # in the HTML output. For a value of 0 the output will use grayscales only. A # value of 255 will produce the most vivid colors. # Minimum value: 0, maximum value: 255, default value: 100. # This tag requires that the tag GENERATE_HTML is set to YES. HTML_COLORSTYLE_SAT = 100 # The HTML_COLORSTYLE_GAMMA tag controls the gamma correction applied to the # luminance component of the colors in the HTML output. Values below 100 # gradually make the output lighter, whereas values above 100 make the output # darker. The value divided by 100 is the actual gamma applied, so 80 represents # a gamma of 0.8, The value 220 represents a gamma of 2.2, and 100 does not # change the gamma. # Minimum value: 40, maximum value: 240, default value: 80. # This tag requires that the tag GENERATE_HTML is set to YES. HTML_COLORSTYLE_GAMMA = 80 # If the HTML_TIMESTAMP tag is set to YES then the footer of each generated HTML # page will contain the date and time when the page was generated. Setting this # to NO can help when comparing the output of multiple runs. # The default value is: YES. # This tag requires that the tag GENERATE_HTML is set to YES. HTML_TIMESTAMP = YES # If the HTML_DYNAMIC_SECTIONS tag is set to YES then the generated HTML # documentation will contain sections that can be hidden and shown after the # page has loaded. # The default value is: NO. # This tag requires that the tag GENERATE_HTML is set to YES. HTML_DYNAMIC_SECTIONS = NO # With HTML_INDEX_NUM_ENTRIES one can control the preferred number of entries # shown in the various tree structured indices initially; the user can expand # and collapse entries dynamically later on. Doxygen will expand the tree to # such a level that at most the specified number of entries are visible (unless # a fully collapsed tree already exceeds this amount). So setting the number of # entries 1 will produce a full collapsed tree by default. 0 is a special value # representing an infinite number of entries and will result in a full expanded # tree by default. # Minimum value: 0, maximum value: 9999, default value: 100. # This tag requires that the tag GENERATE_HTML is set to YES. HTML_INDEX_NUM_ENTRIES = 100 # If the GENERATE_DOCSET tag is set to YES, additional index files will be # generated that can be used as input for Apple's Xcode 3 integrated development # environment (see: http://developer.apple.com/tools/xcode/), introduced with # OSX 10.5 (Leopard). To create a documentation set, doxygen will generate a # Makefile in the HTML output directory. Running make will produce the docset in # that directory and running make install will install the docset in # ~/Library/Developer/Shared/Documentation/DocSets so that Xcode will find it at # startup. See http://developer.apple.com/tools/creatingdocsetswithdoxygen.html # for more information. # The default value is: NO. # This tag requires that the tag GENERATE_HTML is set to YES. GENERATE_DOCSET = NO # This tag determines the name of the docset feed. A documentation feed provides # an umbrella under which multiple documentation sets from a single provider # (such as a company or product suite) can be grouped. # The default value is: Doxygen generated docs. # This tag requires that the tag GENERATE_DOCSET is set to YES. DOCSET_FEEDNAME = "Doxygen generated docs" # This tag specifies a string that should uniquely identify the documentation # set bundle. This should be a reverse domain-name style string, e.g. # com.mycompany.MyDocSet. Doxygen will append .docset to the name. # The default value is: org.doxygen.Project. # This tag requires that the tag GENERATE_DOCSET is set to YES. DOCSET_BUNDLE_ID = org.doxygen.Project # The DOCSET_PUBLISHER_ID tag specifies a string that should uniquely identify # the documentation publisher. This should be a reverse domain-name style # string, e.g. com.mycompany.MyDocSet.documentation. # The default value is: org.doxygen.Publisher. # This tag requires that the tag GENERATE_DOCSET is set to YES. DOCSET_PUBLISHER_ID = org.doxygen.Publisher # The DOCSET_PUBLISHER_NAME tag identifies the documentation publisher. # The default value is: Publisher. # This tag requires that the tag GENERATE_DOCSET is set to YES. DOCSET_PUBLISHER_NAME = Publisher # If the GENERATE_HTMLHELP tag is set to YES then doxygen generates three # additional HTML index files: index.hhp, index.hhc, and index.hhk. The # index.hhp is a project file that can be read by Microsoft's HTML Help Workshop # (see: http://www.microsoft.com/en-us/download/details.aspx?id=21138) on # Windows. # # The HTML Help Workshop contains a compiler that can convert all HTML output # generated by doxygen into a single compiled HTML file (.chm). Compiled HTML # files are now used as the Windows 98 help format, and will replace the old # Windows help format (.hlp) on all Windows platforms in the future. Compressed # HTML files also contain an index, a table of contents, and you can search for # words in the documentation. The HTML workshop also contains a viewer for # compressed HTML files. # The default value is: NO. # This tag requires that the tag GENERATE_HTML is set to YES. GENERATE_HTMLHELP = NO # The CHM_FILE tag can be used to specify the file name of the resulting .chm # file. You can add a path in front of the file if the result should not be # written to the html output directory. # This tag requires that the tag GENERATE_HTMLHELP is set to YES. CHM_FILE = # The HHC_LOCATION tag can be used to specify the location (absolute path # including file name) of the HTML help compiler ( hhc.exe). If non-empty # doxygen will try to run the HTML help compiler on the generated index.hhp. # The file has to be specified with full path. # This tag requires that the tag GENERATE_HTMLHELP is set to YES. HHC_LOCATION = # The GENERATE_CHI flag controls if a separate .chi index file is generated ( # YES) or that it should be included in the master .chm file ( NO). # The default value is: NO. # This tag requires that the tag GENERATE_HTMLHELP is set to YES. GENERATE_CHI = NO # The CHM_INDEX_ENCODING is used to encode HtmlHelp index ( hhk), content ( hhc) # and project file content. # This tag requires that the tag GENERATE_HTMLHELP is set to YES. CHM_INDEX_ENCODING = # The BINARY_TOC flag controls whether a binary table of contents is generated ( # YES) or a normal table of contents ( NO) in the .chm file. Furthermore it # enables the Previous and Next buttons. # The default value is: NO. # This tag requires that the tag GENERATE_HTMLHELP is set to YES. BINARY_TOC = NO # The TOC_EXPAND flag can be set to YES to add extra items for group members to # the table of contents of the HTML help documentation and to the tree view. # The default value is: NO. # This tag requires that the tag GENERATE_HTMLHELP is set to YES. TOC_EXPAND = NO # If the GENERATE_QHP tag is set to YES and both QHP_NAMESPACE and # QHP_VIRTUAL_FOLDER are set, an additional index file will be generated that # can be used as input for Qt's qhelpgenerator to generate a Qt Compressed Help # (.qch) of the generated HTML documentation. # The default value is: NO. # This tag requires that the tag GENERATE_HTML is set to YES. GENERATE_QHP = NO # If the QHG_LOCATION tag is specified, the QCH_FILE tag can be used to specify # the file name of the resulting .qch file. The path specified is relative to # the HTML output folder. # This tag requires that the tag GENERATE_QHP is set to YES. QCH_FILE = # The QHP_NAMESPACE tag specifies the namespace to use when generating Qt Help # Project output. For more information please see Qt Help Project / Namespace # (see: http://qt-project.org/doc/qt-4.8/qthelpproject.html#namespace). # The default value is: org.doxygen.Project. # This tag requires that the tag GENERATE_QHP is set to YES. QHP_NAMESPACE = org.doxygen.Project # The QHP_VIRTUAL_FOLDER tag specifies the namespace to use when generating Qt # Help Project output. For more information please see Qt Help Project / Virtual # Folders (see: http://qt-project.org/doc/qt-4.8/qthelpproject.html#virtual- # folders). # The default value is: doc. # This tag requires that the tag GENERATE_QHP is set to YES. QHP_VIRTUAL_FOLDER = doc # If the QHP_CUST_FILTER_NAME tag is set, it specifies the name of a custom # filter to add. For more information please see Qt Help Project / Custom # Filters (see: http://qt-project.org/doc/qt-4.8/qthelpproject.html#custom- # filters). # This tag requires that the tag GENERATE_QHP is set to YES. QHP_CUST_FILTER_NAME = # The QHP_CUST_FILTER_ATTRS tag specifies the list of the attributes of the # custom filter to add. For more information please see Qt Help Project / Custom # Filters (see: http://qt-project.org/doc/qt-4.8/qthelpproject.html#custom- # filters). # This tag requires that the tag GENERATE_QHP is set to YES. QHP_CUST_FILTER_ATTRS = # The QHP_SECT_FILTER_ATTRS tag specifies the list of the attributes this # project's filter section matches. Qt Help Project / Filter Attributes (see: # http://qt-project.org/doc/qt-4.8/qthelpproject.html#filter-attributes). # This tag requires that the tag GENERATE_QHP is set to YES. QHP_SECT_FILTER_ATTRS = # The QHG_LOCATION tag can be used to specify the location of Qt's # qhelpgenerator. If non-empty doxygen will try to run qhelpgenerator on the # generated .qhp file. # This tag requires that the tag GENERATE_QHP is set to YES. QHG_LOCATION = # If the GENERATE_ECLIPSEHELP tag is set to YES, additional index files will be # generated, together with the HTML files, they form an Eclipse help plugin. To # install this plugin and make it available under the help contents menu in # Eclipse, the contents of the directory containing the HTML and XML files needs # to be copied into the plugins directory of eclipse. The name of the directory # within the plugins directory should be the same as the ECLIPSE_DOC_ID value. # After copying Eclipse needs to be restarted before the help appears. # The default value is: NO. # This tag requires that the tag GENERATE_HTML is set to YES. GENERATE_ECLIPSEHELP = NO # A unique identifier for the Eclipse help plugin. When installing the plugin # the directory name containing the HTML and XML files should also have this # name. Each documentation set should have its own identifier. # The default value is: org.doxygen.Project. # This tag requires that the tag GENERATE_ECLIPSEHELP is set to YES. ECLIPSE_DOC_ID = org.doxygen.Project # If you want full control over the layout of the generated HTML pages it might # be necessary to disable the index and replace it with your own. The # DISABLE_INDEX tag can be used to turn on/off the condensed index (tabs) at top # of each HTML page. A value of NO enables the index and the value YES disables # it. Since the tabs in the index contain the same information as the navigation # tree, you can set this option to YES if you also set GENERATE_TREEVIEW to YES. # The default value is: NO. # This tag requires that the tag GENERATE_HTML is set to YES. DISABLE_INDEX = NO # The GENERATE_TREEVIEW tag is used to specify whether a tree-like index # structure should be generated to display hierarchical information. If the tag # value is set to YES, a side panel will be generated containing a tree-like # index structure (just like the one that is generated for HTML Help). For this # to work a browser that supports JavaScript, DHTML, CSS and frames is required # (i.e. any modern browser). Windows users are probably better off using the # HTML help feature. Via custom stylesheets (see HTML_EXTRA_STYLESHEET) one can # further fine-tune the look of the index. As an example, the default style # sheet generated by doxygen has an example that shows how to put an image at # the root of the tree instead of the PROJECT_NAME. Since the tree basically has # the same information as the tab index, you could consider setting # DISABLE_INDEX to YES when enabling this option. # The default value is: NO. # This tag requires that the tag GENERATE_HTML is set to YES. GENERATE_TREEVIEW = NO # The ENUM_VALUES_PER_LINE tag can be used to set the number of enum values that # doxygen will group on one line in the generated HTML documentation. # # Note that a value of 0 will completely suppress the enum values from appearing # in the overview section. # Minimum value: 0, maximum value: 20, default value: 4. # This tag requires that the tag GENERATE_HTML is set to YES. ENUM_VALUES_PER_LINE = 4 # If the treeview is enabled (see GENERATE_TREEVIEW) then this tag can be used # to set the initial width (in pixels) of the frame in which the tree is shown. # Minimum value: 0, maximum value: 1500, default value: 250. # This tag requires that the tag GENERATE_HTML is set to YES. TREEVIEW_WIDTH = 250 # When the EXT_LINKS_IN_WINDOW option is set to YES doxygen will open links to # external symbols imported via tag files in a separate window. # The default value is: NO. # This tag requires that the tag GENERATE_HTML is set to YES. EXT_LINKS_IN_WINDOW = NO # Use this tag to change the font size of LaTeX formulas included as images in # the HTML documentation. When you change the font size after a successful # doxygen run you need to manually remove any form_*.png images from the HTML # output directory to force them to be regenerated. # Minimum value: 8, maximum value: 50, default value: 10. # This tag requires that the tag GENERATE_HTML is set to YES. FORMULA_FONTSIZE = 10 # Use the FORMULA_TRANPARENT tag to determine whether or not the images # generated for formulas are transparent PNGs. Transparent PNGs are not # supported properly for IE 6.0, but are supported on all modern browsers. # # Note that when changing this option you need to delete any form_*.png files in # the HTML output directory before the changes have effect. # The default value is: YES. # This tag requires that the tag GENERATE_HTML is set to YES. FORMULA_TRANSPARENT = YES # Enable the USE_MATHJAX option to render LaTeX formulas using MathJax (see # http://www.mathjax.org) which uses client side Javascript for the rendering # instead of using prerendered bitmaps. Use this if you do not have LaTeX # installed or if you want to formulas look prettier in the HTML output. When # enabled you may also need to install MathJax separately and configure the path # to it using the MATHJAX_RELPATH option. # The default value is: NO. # This tag requires that the tag GENERATE_HTML is set to YES. USE_MATHJAX = NO # When MathJax is enabled you can set the default output format to be used for # the MathJax output. See the MathJax site (see: # http://docs.mathjax.org/en/latest/output.html) for more details. # Possible values are: HTML-CSS (which is slower, but has the best # compatibility), NativeMML (i.e. MathML) and SVG. # The default value is: HTML-CSS. # This tag requires that the tag USE_MATHJAX is set to YES. MATHJAX_FORMAT = HTML-CSS # When MathJax is enabled you need to specify the location relative to the HTML # output directory using the MATHJAX_RELPATH option. The destination directory # should contain the MathJax.js script. For instance, if the mathjax directory # is located at the same level as the HTML output directory, then # MATHJAX_RELPATH should be ../mathjax. The default value points to the MathJax # Content Delivery Network so you can quickly see the result without installing # MathJax. However, it is strongly recommended to install a local copy of # MathJax from http://www.mathjax.org before deployment. # The default value is: http://cdn.mathjax.org/mathjax/latest. # This tag requires that the tag USE_MATHJAX is set to YES. MATHJAX_RELPATH = http://cdn.mathjax.org/mathjax/latest # The MATHJAX_EXTENSIONS tag can be used to specify one or more MathJax # extension names that should be enabled during MathJax rendering. For example # MATHJAX_EXTENSIONS = TeX/AMSmath TeX/AMSsymbols # This tag requires that the tag USE_MATHJAX is set to YES. MATHJAX_EXTENSIONS = # The MATHJAX_CODEFILE tag can be used to specify a file with javascript pieces # of code that will be used on startup of the MathJax code. See the MathJax site # (see: http://docs.mathjax.org/en/latest/output.html) for more details. For an # example see the documentation. # This tag requires that the tag USE_MATHJAX is set to YES. MATHJAX_CODEFILE = # When the SEARCHENGINE tag is enabled doxygen will generate a search box for # the HTML output. The underlying search engine uses javascript and DHTML and # should work on any modern browser. Note that when using HTML help # (GENERATE_HTMLHELP), Qt help (GENERATE_QHP), or docsets (GENERATE_DOCSET) # there is already a search function so this one should typically be disabled. # For large projects the javascript based search engine can be slow, then # enabling SERVER_BASED_SEARCH may provide a better solution. It is possible to # search using the keyboard; to jump to the search box use + S # (what the is depends on the OS and browser, but it is typically # , /