vst3sdk-3.7.10.14+~4.13.3/000077500000000000000000000000001461511344400143515ustar00rootroot00000000000000vst3sdk-3.7.10.14+~4.13.3/.editorconfig000066400000000000000000000003371461511344400170310ustar00rootroot00000000000000root = true [*] charset = utf-8 end_of_line = insert_final_newline = true vc_generate_documentation_comments = doxygen_slash_star [*.{c,h,cpp,hpp,m,mm}] indent_style = tab indent_size = 4 trim_trailing_whitespace = true vst3sdk-3.7.10.14+~4.13.3/.gitattributes000066400000000000000000000000301461511344400172350ustar00rootroot00000000000000* text=auto *.sh eol=lf vst3sdk-3.7.10.14+~4.13.3/.github/000077500000000000000000000000001461511344400157115ustar00rootroot00000000000000vst3sdk-3.7.10.14+~4.13.3/.github/actions/000077500000000000000000000000001461511344400173515ustar00rootroot00000000000000vst3sdk-3.7.10.14+~4.13.3/.github/actions/cmake/000077500000000000000000000000001461511344400204315ustar00rootroot00000000000000vst3sdk-3.7.10.14+~4.13.3/.github/actions/cmake/action.yml000066400000000000000000000022131461511344400224270ustar00rootroot00000000000000name: 'cmake' description: 'cmake VSTGUI' inputs: source-dir: description: 'Source Directory' required: 'true' default: '' build-dir: description: 'Build Directory' required: 'true' default: '' build-type: description: 'cmake build type' required: 'true' default: 'Debug' build-vstgui-standalone: description: 'build VSTGUI standalone and examples' required: 'false' default: OFF enable-deprecated-methods: description: 'enable deprecated VSTGUI methods' required: 'false' default: ON runs: using: "composite" steps: - name: Create Build Environment shell: bash run: cmake -E make_directory "${{inputs.build-dir}}" - name: Configure CMake shell: bash working-directory: ${{inputs.build-dir}} run: cmake -S "${{inputs.source-dir}}" -B "${{inputs.build-dir}}" -DCMAKE_BUILD_TYPE=${{inputs.build-type}} -DVSTGUI_STANDALONE=${{inputs.build-vstgui-standalone}} -DVSTGUI_ENABLE_DEPRECATED_METHODS=${{inputs.enable-deprecated-methods}} - name: Build shell: bash working-directory: ${{inputs.build-dir}} run: cmake --build . --config ${{inputs.build-type}} vst3sdk-3.7.10.14+~4.13.3/.github/workflows/000077500000000000000000000000001461511344400177465ustar00rootroot00000000000000vst3sdk-3.7.10.14+~4.13.3/.github/workflows/cmake_linux.yml000066400000000000000000000016311461511344400227710ustar00rootroot00000000000000name: Linux build on: [push] jobs: build: runs-on: ${{ matrix.os }} strategy: matrix: os: [ubuntu-20.04, ubuntu-22.04] steps: - uses: actions/checkout@v3 - run: sudo apt-get update - run: sudo apt-get install libx11-dev libx11-xcb-dev libxcb-util-dev libxcb-cursor-dev libxcb-keysyms1-dev libxcb-xkb-dev libxkbcommon-dev libxkbcommon-x11-dev libfontconfig1-dev libcairo2-dev libfreetype6-dev libpango1.0-dev - uses: ./.github/actions/cmake with: source-dir: '${{github.workspace}}' build-dir: '${{github.workspace}}/build' build-type: 'Debug' build-vstgui-standalone: OFF - uses: ./.github/actions/cmake with: source-dir: '${{github.workspace}}' build-dir: '${{github.workspace}}/build-non-deprecated' build-type: 'Debug' build-vstgui-standalone: OFF enable-deprecated-methods: OFF vst3sdk-3.7.10.14+~4.13.3/.github/workflows/cmake_macos.yml000066400000000000000000000012101461511344400227250ustar00rootroot00000000000000name: macOS Build on: [push] jobs: build: runs-on: ${{ matrix.os }} strategy: matrix: os: [macos-11, macos-12] steps: - uses: actions/checkout@v3 - uses: ./.github/actions/cmake with: source-dir: '${{github.workspace}}' build-dir: '${{github.workspace}}/build' build-type: 'Debug' build-vstgui-standalone: ON - uses: ./.github/actions/cmake with: source-dir: '${{github.workspace}}' build-dir: '${{github.workspace}}/build-non-deprecated' build-type: 'Debug' build-vstgui-standalone: ON enable-deprecated-methods: OFF vst3sdk-3.7.10.14+~4.13.3/.github/workflows/cmake_windows.yml000066400000000000000000000012221461511344400233200ustar00rootroot00000000000000name: Windows build on: [push] jobs: build: runs-on: ${{ matrix.os }} strategy: matrix: os: [windows-2019, windows-2022] steps: - uses: actions/checkout@v3 - uses: ./.github/actions/cmake with: source-dir: '${{github.workspace}}' build-dir: '${{github.workspace}}/build' build-type: 'Debug' build-vstgui-standalone: ON - uses: ./.github/actions/cmake with: source-dir: '${{github.workspace}}' build-dir: '${{github.workspace}}/build-non-deprecated' build-type: 'Debug' build-vstgui-standalone: ON enable-deprecated-methods: OFF vst3sdk-3.7.10.14+~4.13.3/.gitignore000066400000000000000000000027151461511344400163460ustar00rootroot00000000000000vstgui/ide/xcode4/build vstgui/ide/xcode4/DerivedData vstgui/ide/xcode4/vstgui.xcodeproj/xcuserdata vstgui/tests/uidescription vst3/mac/build vstgui/tests/uidescription vst3/mac/DerivedData vstgui/tests/uidescription vst3/mac/uidescription test.xcodeproj/xcuserdata vstgui/tests/unittest/lcov/out vstgui-coverage.info vstgui/tests/uidescription vst3/mac/uidescription test.xcodeproj/project.xcworkspace vstgui/tests/ios standalone/build vstgui/tests/ios standalone/DerivedData vstgui/tests/ios standalone/iOS Standalone.xcodeproj/project.xcworkspace vstgui/tests/ios standalone/iOS Standalone.xcodeproj/xcuserdata vstgui/ide/visualstudio/vs2015/build *.VC.opendb vstgui/tests/uidescription vst3/win/x64 vstgui/tests/uidescription vst3/win/Win32 vstgui/ide/xcode4/vstgui.xcodeproj/project.xcworkspace vstgui/ide/visualstudio/vs2013/build vstgui.opensdf vstgui/tests/standalone/mac/build vstgui/tests/standalone/mac/DerivedData vstgui/tests/standalone/mac/VSTGUIStandalone.xcodeproj/project.xcworkspace vstgui/tests/standalone/mac/VSTGUIStandalone.xcodeproj/xcuserdata vstgui/tests/standalone/win/vs2015/x64 *.vcxproj.user vstgui/tests/standalone/win/vs2015/.vs vstgui/CMakeFiles CMakeCache.txt compile_commands.json vstgui.sdf vstgui.v12.suo vstgui/ide/visualstudio/vs2015/.vs vstgui/build vstgui/tests/uidescription vst3/win/.vs vstgui/Documentation/html /vstgui/uidescription/editing/editoruidesc.h CMakeLists.txt.user build vstgui/gdk vstgui/gdkmm vstgui/gtk vstgui/.vscode/ipch .vs vst3sdk-3.7.10.14+~4.13.3/CMakeLists.txt000066400000000000000000000006321461511344400171120ustar00rootroot00000000000000########################################################################################## cmake_minimum_required(VERSION 3.5) if(NOT PROJECT_NAME) set(CMAKE_OSX_DEPLOYMENT_TARGET 10.14 CACHE STRING "") project(vstgui) set(VSTGUI_MAIN_PROJECT_BUILD 1) if(CMAKE_CONFIGURATION_TYPES) set(CMAKE_CONFIGURATION_TYPES Debug Release ReleaseLTO) endif() endif() add_subdirectory(vstgui) vst3sdk-3.7.10.14+~4.13.3/LICENSE000066400000000000000000000035021461511344400153560ustar00rootroot00000000000000//----------------------------------------------------------------------------- // VSTGUI LICENSE // (c) 2022, Steinberg Media Technologies, All Rights Reserved //----------------------------------------------------------------------------- // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: // // * Redistributions of source code must retain the above copyright notice, // this list of conditions and the following disclaimer. // * Redistributions in binary form must reproduce the above copyright notice, // this list of conditions and the following disclaimer in the documentation // and/or other materials provided with the distribution. // * Neither the name of the Steinberg Media Technologies nor the names of its // contributors may be used to endorse or promote products derived from this // software without specific prior written permission. // // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED // WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. // IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, // INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, // BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF // LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE // OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED // OF THE POSSIBILITY OF SUCH DAMAGE. //----------------------------------------------------------------------------- vst3sdk-3.7.10.14+~4.13.3/README.md000066400000000000000000000053131461511344400156320ustar00rootroot00000000000000# VSTGUI ![macOS Build](https://github.com/steinbergmedia/vstgui/workflows/macOS%20Build/badge.svg?branch=develop) ![Windows build](https://github.com/steinbergmedia/vstgui/workflows/Windows%20build/badge.svg?branch=develop) ![Linux build](https://github.com/steinbergmedia/vstgui/workflows/Linux%20build/badge.svg?branch=develop) **VSTGUI** is a user interface toolkit mainly for audio plug-ins (VST, AAX, AudioUnit, etc...) and it is designed for working well with **VST 3** plug-ins and its wrappers like **AU**, **AAX**, ... ## History - First developed inhouse of Steinberg Media Technologies (around 1998) for their first VST plug-ins. - Later added as binary libraries to the official VST SDK. - VSTGUI is open source since May 2003. ## System requirements Supported OS: - Microsoft Windows 10/11 - Apple macOS 10.12-12 - Apple iOS 9-15 - Linux (Preview) Supported IDE: - Visual Studio 2017/2019/2022 - minimum Xcode 10.1 - Qt Creator - Visual Studio Code ## Contributing For bug reports and features requests, please use github or visit the [VST Developer Forum](https://sdk.steinberg.net) ## License BSD style VSTGUI LICENSE (c) Steinberg Media Technologies, All Rights Reserved Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. * Neither the name of the Steinberg Media Technologies nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. vst3sdk-3.7.10.14+~4.13.3/vstgui/000077500000000000000000000000001461511344400156725ustar00rootroot00000000000000vst3sdk-3.7.10.14+~4.13.3/vstgui/.clang-format000066400000000000000000000064541461511344400202560ustar00rootroot00000000000000#Language: Cpp AccessModifierOffset: -4 AlignAfterOpenBracket: Align AlignConsecutiveAssignments: false AlignConsecutiveDeclarations: false AlignEscapedNewlines: Right AlignOperands: true AlignTrailingComments: true AllowAllParametersOfDeclarationOnNextLine: true AllowShortBlocksOnASingleLine: false AllowShortCaseLabelsOnASingleLine: false AllowShortFunctionsOnASingleLine: true AllowShortIfStatementsOnASingleLine: false AllowShortLambdasOnASingleLine: Inline AllowShortLoopsOnASingleLine: false AlwaysBreakAfterReturnType: None AlwaysBreakBeforeMultilineStrings: false AlwaysBreakTemplateDeclarations: true BinPackArguments: true BinPackParameters: true BreakBeforeBraces: Custom BraceWrapping: AfterCaseLabel: true AfterClass: true AfterControlStatement: true AfterEnum: true AfterFunction: true AfterNamespace: false AfterObjCDeclaration: true AfterStruct: true AfterUnion: true AfterExternBlock: true BeforeCatch: true BeforeElse: true # BeforeLambdaBody: false IndentBraces: false SplitEmptyFunction: true SplitEmptyRecord: true SplitEmptyNamespace: true BreakBeforeBinaryOperators: None BreakBeforeInheritanceComma: true BreakBeforeTernaryOperators: true BreakConstructorInitializers: BeforeComma BreakAfterJavaFieldAnnotations: false BreakInheritanceList: AfterComma BreakStringLiterals: true ColumnLimit: 100 # CommentPragmas: '^ IWYU pragma:' CompactNamespaces: false ConstructorInitializerAllOnOneLineOrOnePerLine: true ConstructorInitializerIndentWidth: 0 ContinuationIndentWidth: 4 Cpp11BracedListStyle: true DerivePointerAlignment: false DisableFormat: false ExperimentalAutoDetectBinPacking: false FixNamespaceComments: false # ForEachMacros: # - foreach # - Q_FOREACH # - BOOST_FOREACH IncludeBlocks: Preserve # IncludeCategories: # - Regex: '^"(llvm|llvm-c|clang|clang-c)/' # Priority: 2 # - Regex: '^(<|"(gtest|gmock|isl|json)/)' # Priority: 3 # - Regex: '.*' # Priority: 1 # IncludeIsMainRegex: '(Test)?$' IndentCaseLabels: true IndentPPDirectives: None IndentWidth: 4 IndentWrappedFunctionNames: true JavaScriptQuotes: Leave JavaScriptWrapImports: true KeepEmptyLinesAtTheStartOfBlocks: true MacroBlockBegin: '' MacroBlockEnd: '' MaxEmptyLinesToKeep: 1 NamespaceIndentation: None ObjCBlockIndentWidth: 4 ObjCSpaceAfterProperty: false ObjCSpaceBeforeProtocolList: false PenaltyBreakAssignment: 2 PenaltyBreakBeforeFirstCallParameter: 19 PenaltyBreakComment: 300 PenaltyBreakFirstLessLess: 120 PenaltyBreakString: 1000 PenaltyExcessCharacter: 1000000 PenaltyReturnTypeOnItsOwnLine: 80 PointerAlignment: Left ReflowComments: true SortIncludes: false SortUsingDeclarations: false SpaceAfterCStyleCast: false SpaceAfterTemplateKeyword: false SpaceBeforeAssignmentOperators: true SpaceBeforeCpp11BracedList: true SpaceBeforeInheritanceColon: true SpaceBeforeParens: Always SpaceBeforeRangeBasedForLoopColon: true SpaceInEmptyParentheses: false SpacesBeforeTrailingComments: 1 SpacesInAngles: false SpacesInContainerLiterals: false SpacesInCStyleCastParentheses: false SpacesInParentheses: false SpacesInSquareBrackets: false Standard: Cpp11 TabWidth: 4 UseTab: Always vst3sdk-3.7.10.14+~4.13.3/vstgui/.vscode/000077500000000000000000000000001461511344400172335ustar00rootroot00000000000000vst3sdk-3.7.10.14+~4.13.3/vstgui/.vscode/c_cpp_properties.json000066400000000000000000000023071461511344400234700ustar00rootroot00000000000000{ "configurations": [ { "name": "Linux/macOS", "browse": { "path": [ "${workspaceFolder}" ], "limitSymbolsToIncludedHeaders": true }, "includePath": [ "${workspaceFolder}" ], "defines": [], "compilerPath": "/usr/bin/clang", "cStandard": "c11", "cppStandard": "c++17", "compileCommands": "${config:cmake.buildDirectory}/compile_commands.json", "intelliSenseMode": "clang-x64", "configurationProvider": "vector-of-bool.cmake-tools" }, { "name": "Windows", "browse": { "path": [ "${workspaceFolder}" ], "limitSymbolsToIncludedHeaders": true }, "includePath": [ "${workspaceFolder}" ], "defines": [], "cStandard": "c11", "cppStandard": "c++17", "intelliSenseMode": "msvc-x64", "configurationProvider": "vector-of-bool.cmake-tools" } ], "version": 4 } vst3sdk-3.7.10.14+~4.13.3/vstgui/.vscode/launch.json000066400000000000000000000034131461511344400214010ustar00rootroot00000000000000{ // Use IntelliSense to learn about possible attributes. // Hover to view descriptions of existing attributes. // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387 "version": "0.2.0", "configurations": [ { "name": "Windows Standalone", "type": "cppvsdbg", "request": "launch", "program": "${config:cmake.buildDirectory}/Debug/standalone.exe", "args": [], "stopAtEntry": false, "cwd": "${workspaceFolder}", "environment": [], "externalConsole": true }, { "name": "Linux standalone", "type": "cppdbg", "request": "launch", "program": "${config:cmake.buildDirectory}/Debug/standalone/standalone", "args": [], "stopAtEntry": false, "cwd": "${workspaceFolder}", "environment": [ { "name": "LD_LIBRARY_PATH", "value": "/home/scheffle/tmp/gtk+3.0-3.22.11/debian/build/shared/gdk/.libs;/home/scheffle/tmp/gtkmm3.0-3.22.0/gdk/gdkmm/.libs;/home/scheffle/tmp/cairomm-1.12.0/debian/libcairomm-1.0-1v5/usr/lib/x86_64-linux-gnu" }, // { // "name": "DISPLAY", // "value": ":9" // } ], "externalConsole": false, "MIMode": "lldb", "setupCommands": [ { "description": "Enable pretty-printing for gdb", "text": "-enable-pretty-printing", "ignoreFailures": true } ] }, { "name": "macOS standalone", "type": "cppdbg", "request": "launch", "program": "${config:cmake.buildDirectory}/Debug/standalone.app/Contents/MacOS/standalone", "args": [], "stopAtEntry": false, "cwd": "${workspaceFolder}", "environment": [], "externalConsole": false, "MIMode": "lldb", "setupCommands": [ { "description": "Enable pretty-printing for gdb", "text": "-enable-pretty-printing", "ignoreFailures": true } ] } ] } vst3sdk-3.7.10.14+~4.13.3/vstgui/.vscode/settings.json000066400000000000000000000021641461511344400217710ustar00rootroot00000000000000{ "files.associations": { "deque": "cpp", "vector": "cpp", "*.tcc": "cpp", "fstream": "cpp", "valarray": "cpp", "array": "cpp", "chrono": "cpp", "functional": "cpp", "ratio": "cpp", "type_traits": "cpp", "tuple": "cpp", "utility": "cpp", "atomic": "cpp", "bitset": "cpp", "cctype": "cpp", "clocale": "cpp", "cmath": "cpp", "complex": "cpp", "condition_variable": "cpp", "cstdarg": "cpp", "cstddef": "cpp", "cstdint": "cpp", "cstdio": "cpp", "cstdlib": "cpp", "cstring": "cpp", "ctime": "cpp", "cwchar": "cpp", "cwctype": "cpp", "list": "cpp", "unordered_map": "cpp", "exception": "cpp", "initializer_list": "cpp", "iosfwd": "cpp", "iostream": "cpp", "istream": "cpp", "limits": "cpp", "memory": "cpp", "mutex": "cpp", "new": "cpp", "ostream": "cpp", "sstream": "cpp", "stdexcept": "cpp", "streambuf": "cpp", "system_error": "cpp", "thread": "cpp", "typeinfo": "cpp" }, "cmake.configureOnOpen": true, "files.insertFinalNewline": true, "files.trimFinalNewlines": true, "files.trimTrailingWhitespace": true, "editor.insertSpaces": false }vst3sdk-3.7.10.14+~4.13.3/vstgui/CMakeLists.txt000066400000000000000000000125641461511344400204420ustar00rootroot00000000000000########################################################################################## cmake_minimum_required(VERSION 3.5) if(NOT PROJECT_NAME) set(CMAKE_OSX_DEPLOYMENT_TARGET 10.14 CACHE STRING "") project(vstgui) set(VSTGUI_MAIN_PROJECT_BUILD 1) endif() list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_LIST_DIR}/cmake/modules/") include(vstgui_init) ########################################################################################## function(vstgui_set_cxx_version target version) target_compile_features(${target} PUBLIC cxx_std_${version}) set_property(TARGET ${target} PROPERTY CXX_STANDARD ${version}) set_property(TARGET ${target} PROPERTY CXX_STANDARD_REQUIRED ON) set_property(TARGET ${target} PROPERTY CMAKE_CXX_STANDARD_REQUIRED ON) if(APPLE) target_compile_options(${target} PUBLIC "-stdlib=libc++") endif() endfunction(vstgui_set_cxx_version target version) ########################################################################################## function(vstgui_source_group_by_folder target) if(CMAKE_CONFIGURATION_TYPES) set(SOURCE_GROUP_DELIMITER "/") set(last_dir "") set(files "") foreach(file ${${target}_sources}) get_filename_component(dir "${file}" DIRECTORY) string(FIND "${dir}" ${target} isTargetFolder) if(${isTargetFolder} EQUAL 0) string(LENGTH ${target} offset) string(SUBSTRING "${dir}" ${offset} -1 dir) endif(${isTargetFolder} EQUAL 0) if(NOT "${dir}" STREQUAL "${last_dir}") if(files) source_group("${last_dir}" FILES ${files}) endif(files) set(files "") endif(NOT "${dir}" STREQUAL "${last_dir}") set(files ${files} ${file}) set(last_dir "${dir}") endforeach(file) if(files) source_group("${last_dir}" FILES ${files}) endif(files) endif(CMAKE_CONFIGURATION_TYPES) endfunction(vstgui_source_group_by_folder) ########################################################################################## if(LINUX) find_package(X11 REQUIRED) find_package(Freetype REQUIRED) find_package(PkgConfig REQUIRED) pkg_check_modules(LIBXCB REQUIRED xcb) pkg_check_modules(LIBXCB_UTIL REQUIRED xcb-util) pkg_check_modules(LIBXCB_CURSOR REQUIRED xcb-cursor) pkg_check_modules(LIBXCB_KEYSYMS REQUIRED xcb-keysyms) pkg_check_modules(LIBXCB_XKB REQUIRED xcb-xkb) pkg_check_modules(LIBXKB_COMMON REQUIRED xkbcommon) pkg_check_modules(LIBXKB_COMMON_X11 REQUIRED xkbcommon-x11) pkg_check_modules(GLIB REQUIRED glib-2.0) pkg_check_modules(CAIRO REQUIRED cairo) pkg_check_modules(PANGO REQUIRED pangocairo pangoft2) pkg_check_modules(FONTCONFIG REQUIRED fontconfig) set(LINUX_LIBRARIES ${X11_LIBRARIES} ${FREETYPE_LIBRARIES} ${LIBXCB_LIBRARIES} ${LIBXCB_UTIL_LIBRARIES} ${LIBXCB_CURSOR_LIBRARIES} ${LIBXCB_KEYSYMS_LIBRARIES} ${LIBXCB_XKB_LIBRARIES} ${LIBXKB_COMMON_LIBRARIES} ${LIBXKB_COMMON_X11_LIBRARIES} ${GLIB_LIBRARIES} ${CAIRO_LIBRARIES} ${PANGO_LIBRARIES} ${FONTCONFIG_LIBRARIES} dl ) endif() ########################################################################################## if(NOT CMAKE_CONFIGURATION_TYPES) if(NOT CMAKE_BUILD_TYPE) set(CMAKE_BUILD_TYPE Debug) endif() message(STATUS "Build type: ${CMAKE_BUILD_TYPE}") endif() if(VSTGUI_MAIN_PROJECT_BUILD) message(STATUS "Building only vstgui") set(CMAKE_RUNTIME_OUTPUT_DIRECTORY $<$:${CMAKE_BINARY_DIR}/Debug/>$<$:${CMAKE_BINARY_DIR}/Release/>$<$:${CMAKE_BINARY_DIR}/ReleaseLTO/> ) set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY $<$:${CMAKE_BINARY_DIR}/Debug/libs/>$<$:${CMAKE_BINARY_DIR}/Release/libs/>$<$:${CMAKE_BINARY_DIR}/ReleaseLTO/libs/> ) set(CMAKE_LIBRARY_OUTPUT_DIRECTORY $<$:${CMAKE_BINARY_DIR}/Debug/libs>$<$:${CMAKE_BINARY_DIR}/Release/libs>$<$:${CMAKE_BINARY_DIR}/ReleaseLTO/libs> ) endif() ########################################################################################## add_subdirectory(lib) add_subdirectory(uidescription) if(LINUX) set(VSTGUI_DISABLE_UNITTESTS 1) endif() if(NOT DEFINED VSTGUI_STANDALONE) option(VSTGUI_STANDALONE "VSTGUI Standalone library" ON) if(NOT DEFINED VSTGUI_STANDALONE_EXAMPLES) option(VSTGUI_STANDALONE_EXAMPLES "VSTGUI Standalone examples" ON) endif() endif() if(NOT VSTGUI_STANDALONE AND VSTGUI_STANDALONE_EXAMPLES) set(VSTGUI_STANDALONE_EXAMPLES OFF) endif() if(NOT DEFINED VSTGUI_TOOLS) option(VSTGUI_TOOLS "Build VSTGUI Tools" ON) endif() if(VSTGUI_STANDALONE) add_subdirectory(standalone) if(NOT VSTGUI_DISABLE_UNITTESTS) add_subdirectory(tests/gfxtest) add_subdirectory(tests/base64codecspeed) endif() endif() if(NOT VSTGUI_DISABLE_UNITTESTS) add_subdirectory(tests) endif() if(VSTGUI_TOOLS) add_subdirectory(tools) endif() get_directory_property(hasParent PARENT_DIRECTORY) if(hasParent) set(VSTGUI_COMPILE_DEFINITIONS ${VSTGUI_COMPILE_DEFINITIONS} PARENT_SCOPE) set(VSTGUI_LTO_COMPILER_FLAGS ${VSTGUI_LTO_COMPILER_FLAGS} PARENT_SCOPE) endif() vst3sdk-3.7.10.14+~4.13.3/vstgui/Changelog000066400000000000000000002133611461511344400175120ustar00rootroot000000000000002015-11-28 arne * more unit tests (now 38% line coverage) * remove inefficient bitmap pixel accessor reverse iteration * fix removing first subview of CSplitView not removing the first split separator view * a few little updates to the documentation and a short section about HiDPI support 2015-11-25 arne * unit tests for CControl and CXYPad * fix value calculation in CXYPad * Cocoa: set double click on buttons only if click count == 2 not when more * unit tests for CCheckbox, CKickButton, COnOffButton, CTextButton, CSegmentButton * unit test line coverage now at 36% 2015-11-22 arne * move enum DragResult out of CView * some CFrame unit tests * fix two bugs in CFrame found during unit test writing * unit test line coverage up to 34.6% * add possibility to add a new view in the UIDesc editor via double click or right click with popup menu from the view data browser * fix compiling in non c++11 mode and fix compiling for iOS 2015-11-20 arne * quartz: fix a transformation issue when pixel aligning rects and fix transformation issues for paths 2015-11-07 arne * make unit tests work in release mode * more unit tests (31.3% line coverage now) * remove unused code 2015-11-04 arne * change vstgui_assert to actually work with Visual Studio * add vstgui and unittest projects for VS 2015 * fix a few errors/issues with VS 2015 * fix scaled bitmap drawing with Direct2D * make Direct2D render target accessible to the outside so that they can set it if they want to... * optimization for CGDrawContext::drawLines * use unordered_map for ViewRegistry for faster lookup 2015-11-01 arne * more unit tests (30.7% line coverage now) * fix for found bug in CSliderCreator * move createView method into IUIDecription interface so that UIViewSwitchContainer does not need a UIDescription object * fix warnings/errors on windows 2015-10-31 arne * more unit tests (23% line coverage now) 2015-10-28 arne * introduce vstgui_assert which replaces the normal assert function, mainly for testing purposes * add a new flag to CView to indicate if a view is added to a container view * remove duplicate code to add a view to a view container * add more unit tests and streamline code coverage report to exclude uninteresting stuff 2015-10-27 arne * more unit tests (18.4% line coverage) which found the following issues : * fix: CMemoryStream cannot rewind and read again (no way to know how many bytes were written before) * fix: UIDescription tags could not be specified with OSType strings * fix: UIViewFactory::collectRegisteredViewNames may not work correctly when using with a base class name filter 2015-10-24 arne * refactor Animation::ExchangeViewAnimation to better test it * add a bunch of unit tests (coverage now : 6.4% lines) * fix view container listener viewRemoved not called * write script for better unit test build workflow 2015-10-23 arne * add text truncate mode to CSegmentButton * workaround Apple bug in CocoaFileSelector which generates double file extensions when a temporary UTI is used * add missing override method declarations * fix access violation when opening the uidescription editor in debug mode * make code coverage work with Xcode 7 2015-08-19 arne * support VS 2015 * fix a possible nullptr access 2015-07-26 arne * make zooming in UIDescription Editor step-less 2015-06-25 arne * make sure that when creating an exchange animation the new view is not visible all time * add IViewContainerListener interface and some use of it * make sure that the view is completely redrawn in all cases * fix decode scale factor from name if name does not include a file extension and also make sure that scaled bitmaps are processed 2015-06-24 arne * Direct2D: don’t draw if clip is empty * move setZoomFactor from VST3Editor to CFrame 2015-06-07 arne * make CAnimKnob work with normalized values 2015-05-31 arne * update bitmap when a shadow view container is drawn scaled 2015-05-28 arne * fix layer drawing after transform matrix fix * add documentation 2015-05-20 arne * fix CGraphicsTransform matrix * change the way the mouse cursor is set on Win32 2015-05-19 arne * fix Win7 issue when building with the Win 8 SDK 2015-05-17 arne * fix transformed graphics path drawing * fix memory leaks 2015-05-14 arne * fix compile errors with Visual Studio 2010 * fix quartz text path after HiDPI changes * fix crash in d2d text path creation 2015-05-03 arne * add some contribution classes: - Mac BoxBlur filter which uses CoreImage (GPU) - compressed UIDescription file support * deprecated methods support should be off per default 2015-04-22 arne * make Cocoa menu behave the same as the Carbon one and allowing to set a checkmark on the sub menu (thanks to Steve Duda for the fix) * allow to set ui description file path for better development integration 2015-03-11 arne * fix too early unload of the D2D libraries when multiple frame objects are created 2015-01-04 arne * fix layer size when placed into scroll view * fix mac 32 bit release build 2014-12-24 arne * fix getVisibleSize if a transform is set on the view container * minor change to inform viewlisteners of view remove before the parent is set to zero and move some methods from UIDescription into its interface 2014-12-19 arne * fix CViewContainer::getViewsAt () returns wrong result when deep is active * add DispatchList for listeners to dispatch events so that listeners can unregister it self while in dispatch * add IControlListener dispatchlist to CControl * optimize invalidRect * fix cursor issue on Windows * fix VUMeter when min or max not normalized * move IContextMenuController from VST3Editor to IController so that it can always be used 2014-09-17 arne * changed method signature of the various getViewAt/getViewsAt/getContainerAt methods They all have an options argument now instead of multiple bool arguments to refine the options which views should be returned 2014-09-15 arne * moved IPlatformFont and IFontPainter into lib/platform/iplatformfont.h * use DirectWrite for IPlatformFont::getAllPlatformFontFamilies(..) when available 2014-09-14 arne * fix CShadowViewContainer drawing on Windows and use a gaussian blur approximation instead of a simple box blur * fix some more Direct2D and Quartz pixel drawing issues * fix iOS compilation issues * fix compilation issues with OS X 10.6 SDK 2014-09-07 arne * moved platform implementation of CVSTGUITimer into its own files 2014-09-05 arne * fix some Direct2D and Quartz pixel drawing issues * enable more compiler warnings and fix issues * add methods to CDrawContext to draw IPlatform strings for better performance * renamed CControlListener to VSTGUI::IControlListener and moved into its own header file * add forwarding header : vstguifwd.h and minimize includes 2014-08-23 arne * moved CScrollbar into its own file * Direct2D and Quartz nearly draw the same pixels now when drawing in integral mode 2014-08-20 arne * add CFrame::kDefaultKnobMode static variable to set the knob mode for the case when the VSTGUIEditorInterface does not provide one * first part to make the Direct2D and Quartz backend draw exactly the same 2014-08-14 arne * reversed DrawMode kIntegralMode style. Now the regular case is to draw pixel alligned. * add CRect::extend method 2014-08-10 arne * add two more ExchangeViewAnimation styles 2014-08-06 arne * add c++11 lambda alternative for Animation finished message 2014-08-03 arne * add new Control: CSegmentButton * changed Direct2D termination to not depend on __try __except (thanks to Andreas Persson) 2014-08-01 arne * add CGraphicsPath::pixelAlign to align the path to pixel boundaries 2014-07-24 arne * CTextButton and CGradientView now takes CGradient objects instead of colors and start offsets. 2014-07-09 arne * support drawing the best CBitmap representation according to the scale factor in the D2D backend * support setting a transform matrix on CFrame directly 2014-05-27 arne * add Matrix Transformation support to CViewContainer to draw contents transformed (works at least for scaling, rotation will not work) * add drawBitmapNinePartTiled and fillRectWithBitmap methods to CDrawContext 2014-05-09 arne * improve D2D drawing performance * fix buttons parameter on mouse up for Windows 2014-05-01 arne * add Matrix Transformation support to CDrawContext and remove setOffset() getOffset() from it. * redesign integral draw mode to draw pixel aligned * removed setClipRect inside of CDrawContext::drawString() to support drawing rotated strings (clip rect needs to be set from outside now) 2014-04-21 arne * add support for drawing high resolution bitmaps on Retina Displays 2014-04-20 arne * add initial Mac OS X Retina Display support * add CDrawContext::Transform to transform any of the CDrawContext draw commands * add CDrawContext::drawLine and mark the old methods (moveTo, lineTo) as deprecated * add CDrawContext::drawLines which takes a vector of point pairs and mark the old method as deprecated * add CDrawContext::drawPolygon which takes a vector of points and mark the old method as deprecated 2014-04-13 arne * fix a few issues found with -fsanitize=undefined-trap * some refactorings * add virtual key code to CMenuItem * add UTF8StringView helper class * fix CDataBrowser selection change via key input (modifier was not checked) 2014-04-02 arne * fix double click style for CTextEdit * UIDescription: add variable substitution for all attributes when creating views (thanks to Wolfram Franke for the inital version) 2014-03-29 arne * add c++11 lambda alternatives for callbacks in CFileSelector::run(), CVSTGUITimer, CParamDisplay::setValueToStringFunction, CTextEdit::setStringToValueFunction and CCommandMenuItem::setActions * some changes to UIDescritpion interfaces to use more const methods 2014-02-21 arne * add CBaseObject::beforeDelete() virtual method, which will be called directly before the object is deleted. * add IViewListener::viewWillDelete () method 2014-02-19 arne * fix CDrawContext::restoreGlobalState on Direct2D * rewrite CDrawContextState to use the stack instead of the heap to store them 2014-02-05 arne * add IViewListener interface/adapter 2014-01-22 arne * CDrawContext::createTextPath(..) implementation for Direct2D and GDI+ 2014-01-02 arne * add CDrawContext::createTextPath(..) and Quartz implementation * add text rotation to CParamDisplay * fix console output message about font creation on OS X 10.9 2013-12-30 arne * change CGradient to support more than only a start and end color * add CDrawContext::fillRadialGradient method * added a debug message when the gradient draw methods are used with GDI+ as they produce different results than the Direct2D and Quartz implementations * fix fractional mouse wheel messages on Windows 2013-12-20 arne * removed ATSUI font handling as CoreText is supported since 10.5 * optimize string drawing on Mac OS X by caching the CoreText Line between calls to getStringWidth and drawString * add support for adding a custom view to the split view separator * fix compiling with the Mac OS X 10.6 SDK == VSTGUI 4.2 Release == 2013-10-21 arne * removed support for Mac OS X 10.4 * add CLayeredViewContainer + platform implementation for iOS and OSX (QuartzCore is now required) * CGraphicsPath::hitTest implementation for D2D and GDI+ 2013-10-18 arne * add relative touch mode to CSlider 2013-10-15 yvan * remove warning for missing casting (double to float) * change #include to #include 2013-10-14 arne * add onMouseCancel () to CView to support touch canceling and maybe later ESC-Key canceling of mouse tracking * implement onMouseCancel() on a few of controls 2013-10-04 arne * add path hit testing support into CView * add hitTest method to CGraphicsPath (Quartz implementation only currently) * add CSlider::kAlwaysUseZoomFactor to make the zoom modifier mode the default 2013-09-10 arne * add iOS CTextEdit support * add experimental COpenGLView support for iOS (currently not enabled) 2013-08-06 arne * add iOS support (without CTextEdit and COptionMenu support for now) * add multi-touch support (iOS implementation only for now) 2013-05-29 arne * fix crash in IDependecy::changed when a dependent is removed while iterating the depentents list * add icon drawing to CTextButton * change CDrawMode to be a class and add kIntegralMode to draw exactly at integer coordinates this is a better fix than the previous aliasing drawing fix for quartz * always draw bitmaps on integer coordinates with Direct2D * add better focus path for CKnob when drawing with the corona style * add frameWidth to CParamDisplay * fix a crash when the CFrame object is destroyed when in mouse down * changed CView::getVisibleSize() to CView::getVisibleViewSize() to silent compiler warning * created constructor methods for view containers without CFrame argument (which was not used anymore). Moved the old ones into deprecated. * add first unit tests 2013-02-10 arne * add multi selection style to CDataBrowser * introduce CDataBrowser::Cell position description and change some methods which deals with cells to use it. * rename IDataBrowser to IDataBrowserDelegate * changed drag method signatures of IDataBrowserDelegate to include cell mouse position * fix some aliasing drawing issues with Quartz caused by non integral coordinates * CGradientView check with Direct2D (still needs check with GDI+) * mark CFrame::doIdleStuff and CControl::doIdleStuff deprecated as it is not used anymore * replace CDragContainer with IDataPackage. Add CDragContainerHelper class to make porting code easier 2013-01-04 arne * fix a few issues introduces due to calling beginEdit() and endEdit() only once in CControl * [quartz] use global color space for Gradient colors, so that these colors are identical to the colors when drawing strokres or fills * changed method signature CViewContainer::getVisibleSize() to take a const rect reference * fix rare crash in CTooltipSupport * fix a redraw issue which may happens when removing a modal view * add CGradientView (experimental, Direct2D and GDI+ drawing needs check) 2012-11-28 arne * replaced all occurrences of reinterpret_cast with proper replacements * changed drawing order of CDataBrowser, now it paints row by row not column by column * add a new template method to CViewContainer to find children by class type * remember edit state in CControl so that sub classes can ask if they are currently in edit mode (between beginEdit() and endEdit()) 2012-11-24 arne * add new argument to CViewContainer::getViewAt () to allow to get only the mouse enabled view at that position * changed CViewContainer::getViewsAt () result container to std::list > * add c++11 override keyword with override * remove last usage of isTypeOf() and add VSTGUI_ENABLE_OLD_CLASS_TYPE_INFO macro which enables the old class type info mechanism (defaults to be enabled). If turned off generated code size is smaller. 2012-11-22 arne * fix issues when compiling in c++11 mode * implement page up/down key handling in CDataBrowser * change scrollbar look to use round borders * mouse wheel messages are now only dispatched to mouse enabled views * make sure CTextLabel does not handle the mouse wheel message * small optimization for drawing strings on Mac * fix issue that the OpenGL view does not draw on Windows when used on another thread than the main thread * fix issue where the VST3Editor does not update the option menu when bound to a vst 3 parameter * implement binding a vst 3 parameter to a CTextLabel in VST3Editor * replace custom linked list for child views in CViewContainer by a std::list * add UTI to CFileExtension * fix CCheckBox drawing on Windows when coordinates are not rounded to whole integers * fix tooltip timer not stopped when tooltip window was hidden on Cocoa 2012-05-17 arne * add compatibility to compile VSTGUI with Xcode 4.x and Mac OS X SDK 10.7 - This looses the possibility to set the font family for the native text edit field with Carbon 2012-02-27 arne * add drag'n drop handling to CDataBrowser * fix a rare drawing issue with scrollbars in a scrollview * make sure that a call to invalid won't invalidate while in the drawing callback 2012-02-19 arne * add option to include bitmap data into uidesc file * add 2 new platform functions to IPlatformBitmap: createFromMemory(..) and createMemoryPNGRepresentation (..) * the CFrame object should now be created with the constructor CFrame (size, editor) and afterwards opened with the native parent object and a type description of the parent. The old constructor is now deprecated. * add new Bitmap Filter : ScaleLinear 2012-02-11 arne * fix most warnings when building with Clang * fix a few memory leaks in the Cocoa sources * fix a bug calculating a color from HSL * move the ViewIterator template into the CViewContainer class to get rid of the friend declaration 2011-12-13 arne * fix saving UIDescription on Windows * fix finding UIEditController::getEditorDescription * fix compile error with newer Visual Studio compilers 2011-11-25 arne * merge changes from vstgui_400 : 2011-10-11 arne * fix mouse wheel on Mac OS X 10.7 when "natural" scroll direction system setting is used. 2011-10-05 arne * fix possible crash in IDependency::changed() when dependent object removes itself in this call 2011-10-02 arne * fix wrong pixel format on intel Mac OS X * fix performance issue drawing bitmaps with empty clip rect * fix escape key does not end text edit on Windows 2011-08-24 arne * fix bug: control listeners don't get right button click 2011-07-16 arne * implement missing kSelectDirectory in CNewFileSelector for Windows XP * fix issue with COptionMenu and check style for first item for non kPopupStyle on Cocoa 2011-10-08 arne * add pDisabledBackground bitmap to CView and made pBackground a private member to support drawing a different bitmap if the mouse is enabled or disabled * refactored bitmap filters to use a factory * more uidescription editor 2011-09-28 arne * add CShadowViewContainer * fix CSlider vertical drawing (when not using Bitmaps) * add CTextLabel truncate text mode * add UTF8CharacterIterator class for iterating UTF8 strings character by character 2011-09-15 arne * add kAutoHideScrollbars style to CScrollView * more uidescription editor 2011-09-12 arne * added a few simple Bitmap Filters * added a few methods to CColor (toHSL, fromHSL, getLuma, getLightness) * more uidescription editor * more documentation 2011-09-01 arne * support for setting and getting the systems clipboard, see CFrame::setClipboard() and CFrame::getClipboard () * CFrame support for more than one IKeyboardHook (you need to change your call to CFrame::setKeyboardHook() to CFrame::registerKeyboardHook ()) * more uidescription editor 2011-08-27 arne * fix CFrame::advanceNextFocusView() for modal views * add round rect style for CParamDisplay * add kFollowFocusView style for CScrollView * add CTextButton::sizeToFit() * new uidescription editor 2011-08-22 arne * new class CCommandMenuItem * new container view CRowColumnView * add on/off style to CTextButton * remove unused bTextTransparencyEnabled from CParamDisplay * first part of new uidescription editor 2011-07-16 arne * new class COpenGLView + platform implementations for Windows + Mac Cocoa * new style for CScrollView: kOverlayScrollbars (scrollbars are overlayed of the content) * fix a crash when CView::setWantsIdle(false) was called inside CView::onIdle() 2011-07-4 arne * fixes to path arc drawing for Direct2D and GDI+ * fixes to CKnob 2011-07-01 arne * fix horizontal CVUMeter drawing (was reversed) 2011-06-24 arne * make sure that Windows 7 magnification setting is ignored with Direct2D 2011-06-14 arne * change call sequence for CViewContainer::attached(parent) to first call the base class before calling the subviews, so that subviews have access to all parents in attached(..) * make sure animations will be stopped when views are removed and that IAnimationTarget::animationFinished() will only be called once * fix a scroll view issue in makeRectVisible 2011-06-08 arne * VST2.x frame resize implementation (mainly for Windows) * make tutorial compile and work on Windows 2011-06-05 arne * implement missing file drag support for Windows * fix a few warnings with clang 2011-06-03 arne * rearrange some code in AEffGUIEditor and PlugGUIEditor and make it work on Mac OS X 64 bit 2011-05-27 arne * fix a crash when resetting the focus view after a menu popup when that view was removed * add CViewContainer method to enable/disable autosizing 2011-05-26 arne * fix for CView::setVisible(false) not invalidating the view area * fix another scroll view issue 2011-05-22 arne * make CView::getViewSize() non virtual * replace nearly all direct uses of CView::size with CView::getViewSize() * fix a scroll view issues 2011-05-20 arne * replace checks for emptiness of std container from size () > 0 to empty () == false * update copyright year 2011-05-17 arne * fix horizontal auto drag scrolling in CScrollView * prevent transforming a CSplitView or CScrollView to another view in UIEditFrame to fix a crash * define NDEBUG if DEBUG is not defined so that asserts are not triggered in Release builds * more documentation 2011-05-06 arne * add CView idle mechanism * CVuMeter uses CView idle mechanism for smooth meter fallback * CFrame disable invalidating views if CView::kDirtyCallAlwaysOnMainThread is true 2011-04-30 arne * fix CKickButton key down repeat triggering beginEdit more than once * remove usage of isTypeOf("CViewContainer") and instead use dynamic_cast/reinterpret_cast * add assert in CView::attached(CView* parent) that checks that the parent is a CViewContainer, other types are not supported ! * fix drawcontext on windows did not work with globalAlpha other than 1 for fillLinearGradient 2011-04-25 arne * fix a memory leak in CFontChooser * rearrange some code in uidescription * CSplitView docs and fixes 2011-04-22 arne * fix CVuMeter decreaseValue not working as expected * moved all uses of kMsgCheckIfViewContainer into the deprecated macro 2011-04-06 arne * fix control-click in cocoa not a right click * fix an update bug with COptionMenu not setting the value correctly on popup * gdiplus line style implementation 2011-03-29 arne * add immediate text change style to CTextEdit * revert UTF8StringHelper optimization as it does not work under 64 bit * some views does not call setDirty(false) in their draw methods. fixed. * change default fonts on Mac to Arial like on Windows 2011-03-23 arne * added CTextButtton control view class 2011-03-20 arne * removed the sublisteners in CControl and replaced it by IDependency 2011-03-19 arne * new class IDependency see idependency.h for documentation * new IDataBrowser methods: dbAttached(..) and dbRemoved(..) 2011-03-16 arne * CGraphicsPath redesign * fix an issue with CScrollView and focus view drawing 2011-03-11 arne * Direct2D graphics path addArc method implementation. clockwise setting not yet. 2011-03-10 arne * new font face kStrikethroughFace (thanks to Bick Tick for this) * new class CString which holds a platform representation of a UTF8String. The CDrawContext class has one CString so that the platform code does not need to convert a string twice when drawing the string into a rectangle 2011-03-09 arne * CNewFileSelector implementation for Windows XP (thanks to Bick Tick for the implementation) * UTF8StringHelper optimization (only use malloc if more than 128 UTF-8 characters or 64 UTF-16 charachters needs to be translated) * fix drawing issue with Wavelab 7 on Windows (WS_EX_TRANSPARENT is now only set when the parent window has WS_EX_LAYERED style set) * the RGNDATA allocation in WM_PAINT on Windows is now only done when the size of this structure changes, otherwise the memory block will be remembered. * fix file drop on Windows (thanks to Bick Tick to fix this) 2011-03-06 arne * fix CFrame::getViewAt(..) returning wrong view in modal mode * use a template class for the view iterator 2011-03-04 arne * add CDrawContext::createRoundRectGraphicsPath(..) method (thanks to Big Tick for contribution) * add CGraphicsPath::addRoundRect(..) * fix quartz graphics path addArc method 2011-03-03 arne * new static bool CView::kDirtyCallAlwaysOnMainThread. When this is set to true a call to CView::setDirty(true) will call CView::invalidRect (size) instead of setting the dirty flag. This can fix redraw issues for overlapping views, but you must make sure that you never call setDirty() from any other thread than the main thread. The default value is false to maintain the old behavior. * fix: a CScrollView does not write it's subviews to the UIDescription. * a CScrollView will now automatically resize it's container size if it has only one child view and this view was resized. * the default animation classes are now inherited from CBaseObject. * new view container class : CSplitView (documentation will follow) * uiswitchcontroller creator class moved to uiviewcreator.cpp (to allow using vstgui as static library) * added kCViewControllerAttribute which holds the sub controller of a view * new method in CViewContainer to change the Z order of a view * new method CRect::originize () 2011-02-13 arne * merge back changes from VST SDK 3.5: * fix some warnings with some compilers * add CAnimationSplashScreen class * animations can have an optional notification object for receiving a message when the animation has finished 2010-12-05 arne * fix ExchangeViewAnimation 2010-10-15 arne * fix some possible crashes with animations 2010-10-10 arne * add CMouseEventResult as return value to IMouseObserver::onMouseDown and IMouseObserver::onMouseMoved * allow registering of more than one IMouseObserver. CFrame::setMouseObserver renamed to CFrame::registerMouseObserver and CFrame::unregisterMouseObserver * mouse events now propagated to views behind views if the front view does not handle the event and the views transparency flag is set * IPlatformBitmapPixelAccess implementation for Gdiplus 2010-10-03 arne * add buttons parameter to IMouseObserver::onMouseDown and IMouseObserver::onMouseMoved * alphaPremultiply implementation for Direct2D IPlatformBitmapPixelAccess * moved plug-in API specific files into plugin-bindings folder * fix D2DDrawContext::drawPolygon 2010-10-01 arne * rewrite implementation for CView attributes to use std::map instead of a linked list * some fixes and enhancements from Vítězslav Kot * the zoom modifier and default value modifier can now be set with CControl::kZoomModifier and CControl::kDefaultValueModifier * add possibility to load bitmaps from absolute paths via IPlatformBitmap * fix non visible textedit field with Direct2D (because of not using WS_EX_COMPOSITED) 2010-09-25 arne * fix Direct2D issues after installing IE 9 Beta (the new Direct2D version does not like to draw into WS_EX_COMPOSITED windows) 2010-09-23 arne * workaround bug on Mac OS X that PNG images are always decoded when drawn 2010-09-10 arne * add CBitmapPixelAccess class * add support for multi-line tooltips for Cocoa and Windows * fix a crash when CFrame is closed and a modal view was set and an animation was used on this modal view 2010-09-03 arne * add isControlDefaultButton(..) to VSTGUIEditorInterface to customize the buttons which act as setting the default value of controls * removed custom bitmap reader interface 2010-08-04 arne * quartz: draw bitmaps on pixel boundaries * combine D2DBitmap and D2DOffscreenBitmap 2010-07-10 arne * fix invisible state inconsistency of CViewContainer children * send key events only to mouse enabled views * move CGraphicsPath creation into CDrawContext * move CGraphicsPath draw methods into CDrawContext 2010-06-30 arne * added ViewIterator and ReverseViewIterator classes, so that iterating over CViewContainer children are not that expensive * fix modal view handling * fix font creation bug with GDI+ when combining multiple font styles 2010-06-25 arne * Mac 64 bit AEffGUIEditor implementation * Build 32/64 bit universal binary for tutorial project * fix focus issues with Cocoa and text edit fields * fix bugs in CVUMeter 2010-06-08 arne * added CFontChooser class * added GenericStringListDataBrowserSource class * changed key event flow in CFrame. New event flow is : - IKeyboardHook - focus view - parents of focus view (new) - modal view CViewContainer now does not propagate key events to child views * fixing bug 2992884 : CDrawContext::drawString does not work on Mac OSX < 10.5 * fixing bug 2994963 : Mac Carbon option menu - wrong item checked * fixing setMin(..) and setMax(..) for CKnob * consistent names for uidescription files and classes 2010-04-28 arne * changed to use C99 variable types (int8_t, uint8_t, etc) * added CButtonState class which replaces the buttons parameter in CView mouse methods * Auto drag scrolling flag for CScrollView * removed CGraphicsPath::addString method * added some new draw styles to CKnob : - drawing a circle instead of lines for the handle - drawing the value as a corona (with support for inverted value and value from center) * added drawing style to CSlider * simplified stringToValue and valueToString functions for CParamDisplay and CTextEdit 2010-04-09 arne * Direct2D menu icon implementation * fix memory leak in Windows when using icons in menus 2010-04-07 arne * removed COffscreenContext in CViewContainer & CVUMeter as it is not needed there anymore * added IPlatformBitmapPixelAccess for those who needs to alter pixels of a bitmap directly * changed CLineStyle to support more than solid and dotted lines 2010-03-20 arne * add documentation for the animation support * initial Direct2D support for Windows 2010-03-03 arne * redesign for onMouseEntered and onMouseExited in CFrame. The new implementation calls all views on enter or exit. That means if a view is embedded into a viewcontainer and has the same size as its parent if the mouse enters this view the parent will also get a onMouseEntered call. In the previous implementation only the view did get called not its parents * tooltip support is now moved into CFrame and you can enable or disable it via CFrame::enableTooltips (state) 2010-02-21 arne * new animation classes * using mach_absolute_time() instead of TickCount() for IPlatformFrame::getTicks() for Mac OS X * fix drawing bitmaps with globalAlpha value other than 1 on Mac OS X 2010-02-17 arne * new alphaValue member for CView which affects the opaqueness when drawing * new optional virtual methods in CControlListener: controlTagWillChange and controlTagDidChange * added CFrame::close() method. Should be called instead of CFrame::forget() when you want make sure to detach the platform view from its parent * CScrollView draws its border with the background color, not with black anymore * focus handling change: a view which says wantsFocus() gets focus on mouse down now. A control does not set itself as focus view if beginEdit is called. 2010-02-03 arne * implementation for sizeToFit() for all controls * new CView::doDrag() implementation for starting a drag 2010-01-24 arne * added CControl::setValueNormalized() and CControl::getValueNormalized() * added key event handling to CHorizontalSwitch, CVerticalSwitch, CRockerSwitch, CMovieButton * all included controls respect the min and max values (before some only worked between zero and one) * new behaviour in CFrame::onMouseDown(): the focus view will only be resetted if the focus view is a text edit control, otherwise controls are responsible to set itself as focus view on a mouse down * removed CControl::delta variable as it wasn't used anymore (if you used it in any of your custom controls, change your code so that it uses kDoubleClick) * removed CSpecialDigit::getNormValue(), use CControl::getValueNormalized() instead 2010-01-22 arne * CViewContainer::drawBackgroundRect() draws bitmap now with the same size as the size of itself and not the size of the bitmap * IBitmapReader interface for custom bitmap loading (only mac implementation yet, win to come) * updated copyright year to 2010 20010-01-16 arne * changed size for IDataBrowser::dbDrawHeader() to include line width * added CBaseObjectGuard object (it's now safe to remove a view while in mouse or key event methods) * aligning offscreen bitmaps on mac to 16 bytes 2009-12-30 arne * added IViewAddedRemovedObserver as interface for observing the frame when a view is added or removed * code cleanup * added drag support for Windows UIDescription editor * updated some documentation 2009-12-05 arne * more fixes because of bugs from platform abstraction * added sub control listeners to CControl * changed CControl::setValue(value) to CControl::setValue(value, updateSubListeners) * CControl now implements IFocusDrawing * fixing CSlider and CSwitch when using min != 0 and max != 1 * added UIDescription VST3 test 2009-11-24 arne * fixed some bugs introduced with the platform abstraction * added color chooser view (and panel for uidescription) * replaced NAMESPACES makros with namespace VSTGUI 2009-11-20 arne * completed platform abstraction (except the CVSTGUITimer class) * eliminated the following macros : VSTGUI_USES_COREGRAPHICS, GDIPLUS, VSTGUI_USES_UTF8 and VSTGUI_FLOAT_COORDINATES this means: - On Windows VSTGUI now only uses GDI+ as the drawing API - CCoord is of type double - The text drawing methods expects the strings to be in UTF-8 not ASCII * because of the changes above, many classes have some changes, here are the most prominent - CBitmap only has one draw method which actually calls thru to CDrawContext. - CBitmap transparency is gone. Use PNG Bitmaps with an alpha channel to get the same result. - COffscreenContext must be created via the static create method. * the concept behind the platform abstraction is that the platform frame implementation is responsible to create nearly all the necessary platform objects except bitmaps and fonts for now (this may be the next step). this way it should be easier to maintain the source and much easier to add more platform implementations. 2009-11-19 arne * more windows platform abstraction 2009-11-15 arne * first part of platform abstraction for windows 2009-11-14 arne * platform abstraction * mac carbon and cocoa done, windows to be done 2009-10-25 arne * make text edit transparent on windows * add focus navigation to windows text edit control * fix cocoa option menu opening at wrong position sometimes * add new COffscreenContext constructor which doesn't need a CDrawContext for drawing into a bitmap 2009-10-21 arne * fix tutorial project (mac only for now) to work with vstgui 4.0 2009-10-18 arne * added focus drawing support, see IFocusDrawing and CFrame::setFocusDrawingEnabled() * set CFrame::createDrawContext() deprecated * added CFrame::onActivate(bool state) which will be called from the platform view/window when the view/window is activated or deactived. Currently this remembers the focus view on deactivate and set the focus view to zero and resets the focus view when activated. * changed CBitmap::draw() rect argument to be const (dito for drawTransparent and drawAlpha) 2009-09-27 arne * added CNinePartTiledBitmap (original from Wolfram) * moved all destructors into protected for classes which are not allowed to create on the stack * added amalgamation file vstgui_uidescription.cpp for all uidescription files 2009-09-19 arne * splittet vstcontrols.cpp into different files * added CCheckBox control 2009-09-16 arne * major directory change * all main VSTGUI source code went into the lib subdirectory * splittet vstgui.cpp into different files (vstcontrols.cpp should follow) * vstgui.cpp will still be alive but it will be the amalgamation file * removed all deprecated methods and classes * minimum supported system on Mac OS X will be 10.4 (needs check if it's possible to build on 10.4) * minimum supported system on Windows will be Windows XP. (Windows 98 support will be dropped, but not completely done yet) * removed all Quickdraw stuff (was only needed for Mac OS X 10.3) * changed CBitmap (CFrame& frame, CCoord width, CCoord height) to CBitmap (CCoord width, CCoord height) * removed Mac Metrowerks compiler support 2009-09-15 arne * CFontDesc refactored, so that custom Font Renderer could be used * Add global alpha state to CDrawContext * set version to 4.0 2009-07-15 arne * bump version info to 3.6 in all source/header files * merge of vstgui_350 branch changes: 2008-01-14 yvan * add include malloc for windows * remove CBitmap (void* platformBitmap) constructor * GDIPlus is by default enable * add win project for tutorial 2008-01-12 arne * fix a flaw in removing views from containers 2008-01-10 yvan * update copyright and some documentation 2007-12-11 arne * added closePolygon parameter to CDrawContext::drawPolygon. Now you can draw opened and closed polygons. * fix some GDI bugs : - wrong drawing of CDrawContext::drawEllipse - CDrawContext::getStringWidth does not always work * CFileSelector should work now in Unicode mode on Windows * added virtual destructors for IDataBrowser, IScrollbarDrawer 2007-10-12 wolfram * added virtual destructors for IMouseObserver, CControlListener and IMultiBitmapControl 2009-07-02 arne * added numSubPixmaps to IMultiBitmapControl and removed it from its subclasses. * fixed an issue with CDataBrowser where the mouse moved method of the delegate was not called when the scroll view was scrolled via the mouse wheel * added kMsgViewSizeChanged message which is send from a view to its parent when the size changed. * added CFrame accessor method to VSTGUIEditorInterface 2009-06-14 arne * changed focus and popup handling of COptionMenu. When the menu takes focus it doesn't popup anymore. This way you can build full keyboard accessible plug-ins. Now if the menu has focus and the return key is pressed the menu will popup. You may need to change some of your code, if you manually called menu->takeFocs() change it to menu->popup() * added keyboard hook for CFrame (see IKeyboardHook) * added keyboard handling to IDataBrowser * moved background drawing in CParamDisplay in its own method drawBack() and changed drawText() method by removing the newBack parameter * fix CScrollView::makeRectVisible() * fix crash in COptionMenu when calling getEntry(index) with index higher than number of items in menu * fix CViewContainer::addView (view, beforeView) 2009-06-06 arne * make CDataBrowser autosize aware * CScrollView: when there is a new focus view in the scroll view, the scroll view automatically make this view visible now * CScrollView: don't use CViewContainer drawBackgroundRect, instead it draws it itself * CScroolView: fixes to scrolling when used with VSTGUI_FLOAT_COORDINATES * CTabView: autosize fixes * CTabView: tab views are now resized to the size of the tab view minus the size of the tab buttons * CTabView: add a view inset point to add a gap between the tabview and it's children * COnOffButton is now a focus view (if it has focus you can change the value of it with the return key) * CParamDisplay: new CPoint member textInset which is used to inset the size for drawing the text * add tag value to CMenuItem * changed the constructors of CMenuItem * changed CParamDisplay::setBackOffset() to take a const CPoint reference instead of a CPoint reference * added CParamDisplay::getBackOffset() * COptionMenu can now be used simpler for on the fly context menus. (Empty constructor + popup method) * fix CViewContainer::drawBackgroundRect when no background bitmap but a color is drawn (sometimes the context draw state was not as expected) * CFontDesc got some metric methods (only implemented yet for CoreText on Mac OS X) * CDrawContext::drawArc() should now draw exactly the same on Windows and Mac OS X * fixes to the focus handling in CFrame * CViewContainer new method: isChild (CView* view, bool deep) * ResourceStream class can now be used outside of vstgui.cpp * Cocoa: fix for wrong key modifier. CONTROL and COMMAND were swapped * Cocoa: make view click-through * Cocoa: many more bug fixes 2009-05-06 arne * fix: calling GDIPlusGlobals::exit () in the destructor of CBitmap after the platform gdiplus bitmap is destroyed not before * notify all parent views when a view takes or looses focus 2009-04-26 arne * Cocoa drawing now draws all dirty rects seperatly instead of the union rect * added another method to provide the BundleRef on Mac OS X (search for VSTGUI_NEW_BUNDLE_REF_DEFINITION) * removed old unused menu item definitions from vstcontrols.h 2009-03-30 arne * fix CFrame::scrollRect and CScrollView scrolling * Cocoa implementation for CFrame::scrollRect * fix some warnings when building for Mac OS X 10.5 or above 2009-03-08 arne * fix nervous tooltips 2009-02-21 arne * move methods only useable with VST in CFrame into the ENABLE_VST_EXTENSION_IN_VSTGUI macro * can be compiled under Mac OS X 10.4 again 2009-01-02 arne * fix a possible memory leak when compiling Cocoa support in * removed some duplicated code * removed some unused functions in vstgui.cpp (CColor2RGBColor, RGBColor2CColor) * fix bugs in UTF8StringHelper * Windows implementation calls frame->onMouseExited() now when the mouse leaves the window * dropping text on Windows will use unicode text if VSTGUI_USES_UTF8 is enabled * CNewFileSelector implementation for Windows Vista, older Windows versions still needs implementation * implementation for missing COptionMenu features on Windows (Icons & prefix numbers) 2008-12-07 arne * fixes to cocoa tooltip implementation * the platform implementation should call frame->onMouseExited() when the mouse leaves the platform view/window * added onMouseDown(..) to IMouseObserver * fix warnings when building with gcc4.2 2008-12-06 arne * cocoa tooltip implementation * added onMouseMoved(..) to IMouseObserver * small usability improvements to the tooltip implementation * added CView::removeAttribute(..) 2008-10-23 arne * fix crash in CMenuItem::setTitle and CMenuItem::setKey * fix string width calculation with CoreText * make mac compile again if the new fileselector is turned off 2008-10-20 arne * fix key steeling from host in cocoa code 2008-09-09 yvan * fix compilation when LIBPNG is used and win64 2008-09-24 arne * removed the CBitmap (void*) constructor * added CBitmap (CGImageRef) constructor * added CBitmap (GdiPlus::Bitmap*) constructor 2008-07-30 arne * calling invalid instead of setDirty when adding or removing a view from a view container * added #pragma comment( lib, "Gdiplus" ) when GDIPLUS is enabled 2008-07-29 arne * fix bug with setCurrent in COptionMenu and added method getCurrentIndex * fix some warnings on Windows 2008-07-16 arne * complete cocoa implementation * some documentation for the new fileselector class 2008-05-15 wolframfranke * Fixed compilation errors and warnings when compiling for 10.3.9 on the Mac. 2008-04-29 arne * fix mac 64 bit build * eleminate most warnings for mac build 2008-04-27 arne * first part of a new file selector implementation (currently only mac is implemented) * timer class on Mac uses 64 bit safe API now * using double type instead of float for CCoord if VSTGUI_FLOAT_COORDINATES is defined * first part for Cocoa to register objective-c classes on the fly * Cocoa is only available if building for Mac OS X 10.5 or later 2008-04-21 wolframfranke * Fixed memory leak of 1 menuItem in COptionMenu::removeAllEntry (). 2008-03-26 wolframfranke * Fixed crash in COptionMenu when it is empty. * Added virtual destructors for IMouseObserver, CControlListener and IMultiBitmapControl. * Virtualized CParamDisplay::drawText to allow overriding in inherited classes. 2007-11-08 arne * COptionMenuScheme is deprecated * removed CParamDisplay::setTxtFace and getTxtFace * CoreText support for building 64 bit variant on Mac OS X. * refactoring of COptionMenu, menu items have their own class (CMenuItem) with support for Icons. (Windows not completely done yet) Source code changes may occur as item states are not encoded in the title anymore * some cocoa fixes * autosizing support for views 2007-10-16 arne * Cocoa support (except CTooltipSupport and CFileSelector) 2007-10-08 arne * created vstgui_350 branch 2007-10-03 arne * add visible state for CView * onMouseExited wasn't called on Mac OS X when mouse leaves the frame * changed order for setDirty (false) and invalidRect (size) in CView::invalid () which should fix some issues with non drawing updates 2007-08-17 arne * Unicode support for Windows (CFileSelector is not completely done yet) * CDrawContext::drawRect should draw the same now with Quartz and GDI+ * initial fixes to support VSTGUI_FLOAT_COORDINATES for GDI+ (but there a many problems, so it's useless at the moment) 2007-08-05 arne * CSlider should work with non normalized values if you set setMinValue and setMaxValue 2007-07-28 arne * use compositing window on windows only if running under vista * fix a typo in CFrame::getBackBuffer() which leads to screen flicker under Windows XP * use frame window for CFileselector if ENABLE_VST_EXTENSION_IN_VSTGUI is zero * add fix from Julien for Drag&Drop from Internet Explorer 7 * fix Logic 7 white rectangle drawing on editor close 2007-07-01 arne * added new method to CTabView to use custom control as tab switch button 2007-05-20 arne * fixed a bug in CViewContainer::onKeyDown/onKeyUp, method result was always -1 2007-03-31 arne * more on doxygen documentation * changed CTextEdit::setText (char* txt) to CTextEdit::setText (const char* txt) * changed typedef of CViewAttributeID to unsigned int from unsigned long 2007-03-25 arne * fix a TextEdit issue on Windows * fix a CVuMeter issue when using an Offscreen and no background bitmap (thanks to Boris) * CTooltipSupport for Windows (only XP or above) * many GDI+ fixes and enhancements (no need for libpng with GDI+ anymore) 2007-01-23 arne * merged stuff from timo and wolfram (mainly GDI+ stuff) * added some CRect methods 2006-12-15 arne * added copy constructors for all CView classes * changed back order of loose focus message in CTextEdit. Destroying of CTextEdit objects should be done in the parent view not in the controller. * added method CViewContainer::getContainerAt (const CPoint& p, bool deep) which returns the view container at point p. * added method CViewContainer::addView (CView *pView, CView* pBefore) to place a view before another view in the internal list. * added method CRect::unite (const CRect& rect) to unite two rects. * added resizing to view attributes * initial mac 64 bit support 2006-11-30 arne * moved CDrawContext::scollRect to CFrame class * check for null pointer in CScrollView::notify * fix CDrawContext::drawArc on Mac * add inline function MakeCColor to vstgui.h 2006-11-19 arne * more doxygen documentation * fixed a CDataBrowser draw issue * changed most of the control constructors to use const CPoint instead of CPoint * changed drag/drop implementation on Mac OS X to use the Pasteboard Manager (if building for 10.3 or above) 2006-11-02 arne * Implemented Offscreen stuff on Mac OS X without the need of quickdraw (and fix Offscreen drawing on mac with and without quickdraw) * In CTextEdit::looseFocus changed order of loose focus message handling and valueChanged notification so that you can call takeFocus in valueChanged or destroy the textedit control in there. * Fixed memory leak and possible crash in CTextEdit if someone tries to call takeFocus on the textedit while inside valueChanged of the listener. 2006-09-15 arne * Removed Mac OS 9 code and Quickdraw code (also the QUARTZ & MACX macro definition, only MAC is left) * add tab index variable to CTabView * AEffGUIEditor updated for VST 2.4 * Windows 64bit CFileSelector changes * fix: don't propagate mouse move message with button state to views other than the mouse down view if there is one 2006-06-25 arne * fix a crash bug in GDI+ bitmap loader, when the bitmap does not exist 2006-06-23 arne * add new view : CDataBrowser 2006-06-02 arne * add method to CScrollView to show a specific rect 2006-05-10 arne * quartz: moved CBitmap completly to Image I/O in Mac OS X >= 10.4. The downside is, that you can only set the transparent color once. * CBitmap::setTransparentColor needs to be called explicilty now. The default behaviour is now that there's no transparent color initially. * removed BEOS code * when changeing the size of the container in CScrollView another parameter controls if the visible area should stay the same. * new working implementation of CSplashScreen 2006-04-28 arne * more bugfixes for CScrollView * quartz: some changes to line and rect drawing (offset the transformation matrix by 0.5,0.5 for better visibility) * the mouse move message is now propageted to the underlying view even if no mouse button is pressed 2006-04-13 arne * new files vstguidebug.cpp/.h * bitmaps can be loaded by id or by name now * loose focus bugfix (the loose focus message is now propagated threw all parent views as long as the message is not processed) * cleaned up mouseOverView code in CFrame/CViewContainer * bugfix for CFrame::setSize * some bugfixes for CScrollView and CScrollBar 2006-01-15 arne * Font changes: CFont removed. New CFontDesc class for custom fonts. You need to change all references of CFont to CFontRef. * add UTF-8 text drawing with GDI+ * more doxygen docu 2006-01-06 arne * remove old drawing code. VSTGUI draws only when the system calls it to do so. * changed CViewContainer addView and removeView to return a bool value 2005-12-21 arne * new function CDrawContext::scrollRect * minor fixes to CScrollView * fixed 3D drawing in CParamDisplay (was drawing outside its bounds) 2005-12-19 arne * per default USE_NAMESPACE is 1 now if you don't define it * some more deprecated functions in CDrawContext * moved VSTGUIEditorInterface and CDropTarget into VSTGUI namespace 2005-12-16 arne * CControl::getTag() is virtual now * fixed some stuff with CDrawContext inside the DEPRECATED functions * added some more documentation * reorganized GDI+ initialization 2005-12-11 arne * moved mouse methods from CDrawContext to CFrame where it makes sense * added kDoubleClick to button state, so that you don't need the old way to call waitDoubleClick * more GDI+ stuff (it's much faster now) * removed tooltip handling * added mouse observer interface to CFrame (tooltips could be handled this way in a more generic fashion, see the CTooltipSupport class) * renamed CReferenceCounter to CBaseObject and moved the notify method to it * reorganized doxygen documentation * changed implementation of CView::attached and CView::removed. If you overwrite them, always call the super class implementation also. And because of this and the way modal views are handled CSplashScreen needs to be rewritten (not done yet). * added check for unreleased CViews when DEBUG is set 2005-11-22 arne * new handling of deprecated methods (on mac osx with gcc you get a warning now when using these methods) * declared more methods as deprecated * per default deprecated methods are compiled in, you can change this with the macro VSTGUI_ENABLE_DEPRECATED_METHODS=0 * initial support for Unicode (using UTF8 at the moment) * added CView::parentSizeChanged() and CView::getVisibleSize() * fix some mouse wheel coordinate errors * fix problems with ENABLE_VST_EXTENSION_IN_VSTGUI 2005-09-23 arne * proper handling of attached and removed calls of CView (if you overwrite them, always call its parents implementation) * mac: working again with non composited windows * CScrollView uses proper stepping algo (at least if the mac implementation is considered as proper ;-) 2005-09-21 arne * mac: make it compatible again with Mac OS X < 10.4 * mac: complete new mouse handling * adding CVSTGUITimer class, currently needed in CScrollView * win: added new mouse handling * win: first GDI+ stuff (oh it's slow, slow, slow ... needs much work I guess) 2005-09-08 arne * added some kind of tooltip support - if the mouse comes over a view which has a kCViewTooltipAttribute, the tooltip view, which can be set on the frame, is changed to the string in the attribute * fix some stuff with the new mouse handling 2005-09-02 arne * added new interface class for communicating stuff between CFrame and Editor : VSTGUIEditorInterface. * because of this the macro PLUGGUI is obsolete and removed. * specific VST stuff is now enclosed by ENABLE_VST_EXTENSION_IN_VSTGUI like the CFileSelector stuff, where the host is asked about showing a File Chooser. If you need it, define it and set it to 1. * AEffGUIEditor is now subclassed from AEffEditor and VSTGUIEditorInterface (the most common compiler error now is, that you need to include "aeffguieditor.h" in your editor class header) 2005-08-31 arne * new mouse handling (onMouseDown, onMouseUp, onMouseMoved, onMouseEntered, onMouseExited) but the old mouse method is still working, if the new methods are not implemented by the super class * drawing is now triggered by system events, so drawing outside of the draw method is deprecated This means : - all class methods which took a CDrawContext pointer will be changed except the draw methods. - you call view->invalid () instead of view->setDirty (true) from the User Interface thread. - value changes from other threads will be checked on idle and the views are marked invalid. Benefits : - less hacks - less code - cleaner differentiation of drawing and user action. - works better with hosts which don't follow the VST spec. * added controlBeginEdit and controlEndEdit to CControlListener 2005-08-22 arne * branched for 3.0 (vstgui_300) * removed all MOTIF code * some code cleanup * set version to 3.5 ********************************************************************************************************************** VSTGUI 3.0 branch ********************************************************************************************************************** 2005-08-12 arne * initial support for X/Y mouse wheel (currently only macosx, don't know how ms windows handles this) 2005-07-29 arne * bugfix: CDrawContext doesn't remember font style and does not change the font if only the font style changed. * quartz: keyboard event handling works now, so that hosts will get all key events we don't handle. 2005-07-22 arne * quartz: little optimization in CDrawContext::beginCGContext * quartz: cleaned up the event handler * stop advancing focus if the last focusable control has focus. 2005-07-22 arne * fixed a regression bug in AEffGUIEditor, where idle() was not called * only CKnob and CSlider want focus, as they are the only controls handling key strokes. 2005-07-14 arne * moved CFileSelector in its own file * quartz: fixed some bugs with COffscreenContext 2005-07-09 arne * the CView::draw method now draws the background image if it has one. * new CFrame::updatesDisabled method to lock idle updates. * bug fix for overlapping control drawing. * add a style to COnOffButton so that the listener can be called before doIdleStuff is called. 2005-07-02 arne * windows: CFrame uses a backbuffer now when USE_ALPHA_BLEND is on. This fixes a performance issue with some graphic cards. The drawback at the moment is, that drawing can only occur when the CFrame calls the views to draw. You can not draw anymore by creating your own drawcontext. 2005-06-25 arne * adding keyboard focus navigation * add bool bWantsFocus to CView. If this is set the view is included in keyboard focus navigation. 2005-06-24 arne * merge newframe back to main * fixed some gcc warnings 2005-05-13 arne * quartz: if the CFrame is embedded into a window composited window, the setSize(..) method does not resize the window anymore. * quartz: some window compositing fixes * the tabs in a CTabView can be aligned * mac os x: quartz will be used per default now 2005-05-05 arne * added CBitmap::setNoAlpha(..) and CBitmap::getNoAlpha(). You can set this for PNG images which don't have an alpha channel to speed up drawing on windows. * quartz: some window compositing fixes 2005-04-30 arne * windows: with libpng, when a bmp image was loaded, don't use AlphaBlend instead use old BitBlt. * quartz: non png images can be drawn with transparent color again. 2005-04-29 arne * added CTextLabel * mac: the CFrame can be placed into HIScrollViews * mac: using static objects for Quicktime GraphicsImporter to speed up loading of images * mac: using CGImageCreateImageInRect on 10.4 for faster drawing of clipped images 2005-04-11 arne * removed CFrame::isSomethingDirty * added a check in CViewContainer::isDirty if the subview is inside the view container size * fix for overlapping views not drawn everytime * quartz: fix some drawing bugs 2005-03-25 arne * quartz: fix drawing of transparent bitmaps when OLD_TRANSPARENT_BITMAP_MODE is defined * fix a bug for quickdraw's CDrawContext::setClipRect * quartz: on composited windows, the ctextedit creates a native UnicodeTextControl instead of an MLTE Object * a try to fix redraw problems if the system sends a redraw and some views won't get updated completly * changed the implementation of CView Attributes. Documentation removed. Will be updated before the 3.0 release. 2005-03-05 arne * fixed a memory leak on windows with IDropTarget (thanks bigtick) * add automatic initialization of the xpos and ypos vars in the CSpecialDigit constructor (thanks bigtick) 2005-02-18 arne * new coordinate typedef CCoord, so that we have the possibility to change the coordinate system to floating point * small bugfix in CDrawDevice::drawRect 2005-01-04 arne * the following CDrawContext methods have a new optional parameter "CDrawStyle": drawPolygon, drawRect, drawArc, drawEllipse. the draw style is either kDrawStroked, kDrawFilled or kDrawFilledAndStroked. * added another cursor : kCursorHand * fixed some problems compiling the code on microsoft windows. * fixed some problems with alphablending bitmaps on windows. * added example plugguieditor.cpp file to be used for non VST usage. (There's an example AU plug in the drawtest module) * added CTabView class. * changed constructor of AEffGUIEditor to take a void instead of an AudioEffect pointer, so that subclassing either from PluginGUIEditor or AEffGUIEditor is as simple as possible. 2004-11-29 arne * started to clean up the code (check your code, many methods in CView, CViewContainer & CFrame are declared const now) * started to make a better documentation (see the headers), more to come * renamed pEditView in CFrame to pFocusView as well as setEditView to setFocusView and getEditView to getFocusView ;-) * the following methods in CView are now deprecated : setParentView, setFrame, getFrameTopLeftPos * removed old windows drag&drop code * use generic rgb color space for quartz code * fix an issue with quartz and OLD_TRANSPARENT_BITMAP_MODE when the transparency color changed * some drawing optimizations * new method in CDrawContext to draw multiple lines at once : CDrawContext::drawLines () * if you call beginEdit in any CControl class the control will be the focus view now 2004-10-03 arne * added generic attributes interface to the CView class (see CViewAttributes.rtf) * added CFrame::setPosition to change the location of the view inside it's parent view (mac quartz only at the moment) * some mac quartz bugfixes * some bugfixes for CScrollView * added localToFrame and frameToLocal methods to CView * bugfix for CViewContainer::getCurrentView (). Didn't work for nested containers (W.Franke) * quartz: CFrame::getSize returns the size of the mac control now instead of the window * CViewContainer::getViewAt changed so that you can get the deepest view at that position * CControls set now the editView of the frame on beginEdit and set it to zero at endEdit (W.Franke) 2004-08-30 arne **** bump version to 3.0 ! * change CView::getParent to CView::getFrame * correct implementation of beginEdit and endEdit in all CControls, you should change your code of custom controls from getParent->beginEdit (tag) to beginEdit () ;-) * new drawArc method in CDrawContext which takes angels as parameters * added some kind of runtime type information. * mac: changed the kInfinitySymbol to be 'oo' as the mac character is not available in Helvetica * added two new cursor types (kCursorCopy & kCursorNotAllowed). (Currently only for Mac OS X, Windows will follow) * complete new drag & drop implementation. Now all views can react if something is dragged over it. * some fixes to the update methods when drawing with offsets and COffscreenContexts. * mac: the macro 'CARBON' is changed to 'TARGET_API_MAC_CARBON' as this is what the Mac OS itself uses. * mac: compiling with VSTGUI as namespace works now * mac: use current API for creating menus. (fixes some bugs with the old implementation, where you could not create menuitems like "-3db") 2004-08-25 arne * mac: change COptionMenuScheme implementation to be optional as it only works for OSX Version >= 10.3 (macro: MAC_ENABLE_MENU_SCHEME) 2004-08-15 arne * added CView::acceptDrop. On Mac OS this changes the mouse cursor if a view accepts a drop. For Windows there is currently no action. But it should follow. And maybe it will change so that a real tracking is possible. * with the new update mechanism the modal view is now updated first in CFrame::update, to make sure it will be drawn in all circumstances, even if it is transparent and a view below it is dirty. 2004-08-06 arne * quartz: - cache the CGImageRef, so that it is not created every time the CBitmap is drawn. (Performace will be much better with the next os release) - remove the SetPort/GetPort stuff in AEffGUIEditor. It is not needed anymore. 2004-07-30 arne * better streamlined mechanism for CViewContainer::update (you can turn this off, if it does not work for you in vstgui.cpp with the NEW_UPDATE_MECHANISM macro at the top) this is not tested with Containers using offscreens (but should work). This should fix the problem that non-transparent containers were not really nestable. * quartz: removed the focus handlers for now as most hosts does not set the focus back on their windows if someone clicks into it. This way they get all key downs again. * added setListener() to CControl 2004-07-12 arne * quartz: fix a bug in COffscreenContext::copyTo if the offsetScreen point of the context is not at 0:0 2004-06-28 arne * quartz: fix clipping issues * fix a bug in CViewContainer's update method if the container is transparent and embedded into another CViewContainer 2004-06-26 arne * the modal view is now added to the frame like all other views. * added a reference counting class. CView, CBitmap and CDrawContext are subclasses of it. * clip handling is more consistent now. * some quartz changes: - first try to implement CDrawDevice::drawArc (not yet finished) - COffscreenContext is now more implemented, copyTo works in most situations - native mac controls can now be embedded into the frame, but it does only work correct with compositing enabled windows 2004-06-20 arne * AEffGUIEditor::draw will now draw only the rectangle it should, or as in the past the whole editor if no rect is given. * windows: 64 bit compatibility 2004-06-12 arne * CFrame is now subclassed from CViewContainer (thanks Wolfram Franke for the hard work) - One thing to check: CFrame::removeView was declared with (CView *pView, const bool &withForget = false), this has changed to (CView *pView, const bool &withForget = true). So if you have somewhere in your Code frame->removeView (view) you must change it to frame->removeView (view, false). * mac: FDebugPrint implementation for Classic and Mac OS X * changed the CColor unused member variable to be alpha all over the place (no more MS C++ internal compiler error) * macosx: the CFileSelector can now be used to get unix path strings. If vstFileSelect->future[0] is 1 the internal implementation will return unix paths and set vstFileSelect->future[0] to 0. If the host supports openFileSelector vstFileSelect->future[0] will be 1 and the results are in the old FSSpec format. * the CFileSelector is now usable when PLUGGUI is set. * using clipping all over the place * quartz: rechecked the whole graphics drawing functions to work as expected 2004-05-31 arne * mac: COptionMenuScheme works now with QUARTZ (Mac OS X 10.3 and above) * mac: QUARTZ implementation of CDrawContext::drawEllipse and fillEllipse * added a global COptionMenuScheme variable, if set all menues will use it * fix a possible crash in COptionMenu::mouse (thanks Wolfram Franke) 2004-05-22 arne * moved pBackgroundBitmap and its accessors into CView from CViewContainer, CFrame and CControl as suggested by Wolfram Franke * mac: added implementation for quartz CBitmap::CBitmap (CFrame &frame, long width, long height) * windows: prevent a free memory read in UDropTarget::Release (submitted by Justin Caldicott) 2004-04-27 arne * changed CControlListener and added a method to intercept modifier clicks so the listener can decide if the control should handle this click. This makes it easy to implement some kind of 'MIDI Learn' functionality. Note: you need to implement this new method in your CControlListener, otherwise there will be compile errors. If you don't want this feature, just return 0. * changed all controls to support the new CControlListener method. * mac: bugfix for CTextEdit::takeFocus under quartz. * mac: changed fonts from arial to helvetica as on some OS X installations arial is not installed. 2004-04-17 arne * windows: support for alpha blended images like it is on Mac OS X with quartz note: this implementation uses libpng (macro is USE_LIBPNG) * CDrawContext::setClipRect uses the offset now * COptionMenu::getSubMenu added * mac: fixed some quartz drawing stuff * mac: fix for CFrame::getPosition with quartz * mac: removed CARBON_EVENTS macro as it only works with QUARTZ 2004-04-11 arne * CViewContainer should be completely nestable now * mac: implemented the quartz offscreencontext for existing bitmaps 2004-03-23 arne * CTextEdit use the CParamDisplay::stringConvert functions to draw text * Fix of possible crash in CFileSelector::run * CFM Carbon plugs can now draw text antialiased even if the host does not support it (Thanks to Wolfram Franke for this stuff) * mac: added waitDoubleClick and waitDrag with carbon events 2004-03-19 arne * add CView::getFrameTopLeftPos method to get the topleft position of the view relative to the frame * call AEffGUIEditor instead of AudioEffectX for beginEdit and endEdit * mac: small changes to allow to use a CDrawContext on every Window even those without a CFrame 2004-03-01 arne * mac : fix for RGBA Bitmaps on Displays with less than million colors 2004-02-16 arne * mac : fix compile error in CDrawContext::getMouseLocation when compiling for CFM plugs 2004-02-06 arne * mac : focus fix 2004-02-01 arne * add empty CBitmap constructor for easy subclassing * mac : add beginEdit/endEndit hook for AudioUnits * windows : fix for CFrame::setSize for Orion submitted by Ben Allison 2004-01-02 arne * mac: corrected code for right mouse click with carbon events 2003-12-15 arne * fix a typo in COptionMenu::mouse * mac: fix a typo in CDrawContext::setLineStyle * mac: fix for CDrawContext::getMouseLocation problem with DP 4 * mac: on compositing windows the control is now added to the kHIViewWindowContentID if it exists. * mac: should compile on Mac OS X 10.2 again if CARBON_EVENTS are defined. 2003-12-05 arne * fix compile problem of COptionMenu::takeFocus on Windows 2003-12-04 arne * fix for nested CViewContainers * Mac: fix for using vstgui for other than VST ;-) 2003-11-15 arne *************** *** WARNING *** *************** existing code need to be changed !!! You need to change your CView::mouse methods to add the buttons parameter and your calls to CDrawContext::getMouseLocation inside CViews should be changed to call CView::getMouseLocation instead. *************** * fixed the CViewContainer stuff with Quartz. NOTE : I had to change the way how the view can get the current mouse location. It has to ask itself now as the CView class can check if it is embedded into a CViewContainer which the CDrawDevice couldn't. * all mouse methods get another parameter: long buttons Mac Only: * changed the drag and drop stuff for Carbon Events * With CARBON_EVENTS == 1, CFrame acts now like a Mac Toolbox Control. It works even on compositing enabled windows and on non left-top positions. 2003-11-12 arne * Bugfix for CFrame::setSize for hosts which support "audioMasterSizeWindow" submitted by Justus Henkmann (TC Works) 2003-10-10 arne * Bugfix for COptionMenu::addEntry submitted by Nicolas Bronnec 2003-09-18 arne * incorporated Marc Poirier's CTextEdit fixes * quartz: bugfix in drawString, set cliprect so that the text won't draw outside * carbon events: some code cleanup 2003-09-17 arne * Added Carbon Events handling (#define CARBON_EVENTS 1) * Implemented QUARTZ drawing. (#define QUARTZ 1) * CSlider doesn't use a COffscreenContext for drawing on MacOSX anymore Quartz Notes: - Not all graphic operations we use in vstgui have an equivalent in quartz. Currently unsupported are : - all drawing modes except kCopyMode - getPoint () _ floodFill () - copy from Screen to Offscreen - to support alpha drawing on all operations I have made changes to CColor. The 4th variable is now the alpha value where 255 is opaque and 0 is transparent. - transparent bitmap drawing is now handled with the alpha value of the bitmap, if you want the old behaviour turn on OLD_TRANSPARENT_BITMAP_MODE - because of some strange things with CViewContainers while doing mouse downs the drawcontext has an offset which results in wrong drawing. This needs to be fixed !!! vst3sdk-3.7.10.14+~4.13.3/vstgui/Documentation/000077500000000000000000000000001461511344400205035ustar00rootroot00000000000000vst3sdk-3.7.10.14+~4.13.3/vstgui/Documentation/Migrating from 2.3.rtf000066400000000000000000000103241461511344400243500ustar00rootroot00000000000000{\rtf1\mac\ansicpg10000\cocoartf824\cocoasubrtf100 {\fonttbl\f0\fswiss\fcharset77 Helvetica-Bold;\f1\fswiss\fcharset77 Helvetica;} {\colortbl;\red255\green255\blue255;\red255\green0\blue24;} \paperw11900\paperh16840\margl1440\margr1440\vieww21420\viewh15340\viewkind0 \pard\tx566\tx1133\tx1700\tx2267\tx2834\tx3401\tx3968\tx4535\tx5102\tx5669\tx6236\tx6803\ql\qnatural \f0\b\fs38 \cf0 \ul \ulc0 Migrating from VSTGUI 2.3 to VSTGUI 3.0\ \f1\b0\fs22 \ulnone \ \f0\b\fs26 \ul Things you need to change in your code:\ \f1\b0\fs22 \ulnone \ \pard\tx566\tx1133\tx1700\tx2267\tx2834\tx3401\tx3968\tx4535\tx5102\tx5669\tx6236\tx6803\li560\fi-560\ql\qnatural \fs24 \cf0 - CFrame::removeView (CView *pView, const bool &withForget = true) The second parameter (withForget) has changed its default parameter.\ \pard\tx566\tx1133\tx1700\tx2267\tx2834\tx3401\tx3968\tx4535\tx5102\tx5669\tx6236\tx6803\ql\qnatural \cf0 \ - CDrawContext::getMouseLocation (CPoint &point)\ \pard\tx566\tx1133\tx1700\tx2267\tx2834\tx3401\tx3968\tx4535\tx5102\tx5669\tx6236\tx6803\li560\fi-560\ql\qnatural \cf0 This call will always report the global frame coordinate of the mouse. If you need the mouse coordinates relative to a view, use view->getMouseLocation (context, point)\ \pard\tx566\tx1133\tx1700\tx2267\tx2834\tx3401\tx3968\tx4535\tx5102\tx5669\tx6236\tx6803\ql\qnatural \cf0 \ - The following CView methods are deprecated :\ \pard\tx566\tx1133\tx1700\tx2267\tx2834\tx3401\tx3968\tx4535\tx5102\tx5669\tx6236\tx6803\li560\fi-560\ql\qnatural \cf0 virtual void setParentView (CView *pParentView);\ virtual void setFrame (CFrame *pParent);\ virtual void getFrameTopLeftPos (CPoint& topLeft) const;\ \pard\tx566\tx1133\tx1700\tx2267\tx2834\tx3401\tx3968\tx4535\tx5102\tx5669\tx6236\tx6803\ql\qnatural \cf0 \ \pard\tx566\tx1133\tx1700\tx2267\tx2834\tx3401\tx3968\tx4535\tx5102\tx5669\tx6236\tx6803\li140\fi-140\ql\qnatural \cf0 - Don't call frame->beginEdit(..) and frame->endEdit(..) in your subclassed controls. Use the CControl methods beginEdit, endEdit.\ \ - Nearly all getter methods have changed to be const. Check all your subclasses, so that your methods don't hide the inherited virtual functions.\ \pard\tx566\tx1133\tx1700\tx2267\tx2834\tx3401\tx3968\tx4535\tx5102\tx5669\tx6236\tx6803\li140\fi20\ql\qnatural \cf0 This may be the most important methods from CView and CControl\ - CView::checkUpdate ()\ - CView::isDirty ()\ - CControl::getValue ()\ - CControl::getMin ()\ - CControl::getMax ()\ - CControl::getOldValue ()\ - CControl::getDefaultValue ()\ - CControl::getTag ()\ - CControl::getWheelInc ()\ - CControl::getListener ()\ \pard\tx566\tx1133\tx1700\tx2267\tx2834\tx3401\tx3968\tx4535\tx5102\tx5669\tx6236\tx6803\li140\fi-140\ql\qnatural \cf0 \ - Don't call CControl::update (..) anymore to force an control to redraw. Just call CControl::setDirty (true);\ \pard\tx566\tx1133\tx1700\tx2267\tx2834\tx3401\tx3968\tx4535\tx5102\tx5669\tx6236\tx6803\ql\qnatural \cf0 \ \pard\tx565\tx1133\tx1700\tx2266\tx2833\tx3401\tx3967\tx4535\tx5102\tx5669\tx6235\tx6802\ql\qnatural \f0\b\fs26 \cf0 \ul How to use PNG Images on Windows:\ \ \pard\tx565\tx1133\tx1700\tx2266\tx2833\tx3401\tx3967\tx4535\tx5102\tx5669\tx6235\tx6802\ql\qnatural \f1\b0\fs24 \cf0 \ulnone - Download libpng and zlib ({\field{\*\fldinst{HYPERLINK "http://libpng.sourceforge.net/"}}{\fldrslt \cf2 http://libpng.sourceforge.net/}}\cf2 , {\field{\*\fldinst{HYPERLINK "http://www.zlib.net/"}}{\fldrslt http://www.zlib.net/}}\cf0 )\ - Add their sources to your project\ - Define the preprocessor macro: USE_LIBPNG=1\ - add your png images to your rc file like this: \ 128 PNG bmp00128.png\ - rebuild ;-)\ \ \pard\tx565\tx1133\tx1700\tx2266\tx2832\tx3401\tx3967\tx4535\tx5102\tx5669\tx6235\tx6802\ql\qnatural \f0\b\fs26 \cf0 \ul Transparent Bitmaps with QUARTZ on Mac OS X:\ \ \pard\tx565\tx1133\tx1700\tx2266\tx2832\tx3401\tx3967\tx4535\tx5102\tx5669\tx6235\tx6802\ql\qnatural \f1\b0\fs24 \cf0 \ulnone Per default on Mac OS X if you need transparent bitmaps, you should use the alpha channel of a PNG Image. If you need the old behaviour and want to set bitmap->setTransparentColor (someColor) you need to call bitmap->setNoAlpha (true); (This actually is only necessary for PNG images, all other images will get the noAlpha state per default)\ \ }vst3sdk-3.7.10.14+~4.13.3/vstgui/Documentation/README.md000066400000000000000000000004111461511344400217560ustar00rootroot00000000000000After checking out the sources, you need to run doxygen for the actual documentation. - Please download doxygen here: http://www.doxygen.nl - Run the doxygen app - Load the config file from vstgui/doxygen/Doxyfile - Switch to the run tab and execute "Run doxygen" vst3sdk-3.7.10.14+~4.13.3/vstgui/Documentation/index.html000066400000000000000000000004401461511344400224760ustar00rootroot00000000000000 VSTGUI vst3sdk-3.7.10.14+~4.13.3/vstgui/cmake/000077500000000000000000000000001461511344400167525ustar00rootroot00000000000000vst3sdk-3.7.10.14+~4.13.3/vstgui/cmake/modules/000077500000000000000000000000001461511344400204225ustar00rootroot00000000000000vst3sdk-3.7.10.14+~4.13.3/vstgui/cmake/modules/vstgui_init.cmake000066400000000000000000000107161461511344400237750ustar00rootroot00000000000000cmake_minimum_required(VERSION 3.5) if(NOT DEFINED VSTGUI_ENABLE_DEPRECATED_METHODS) option(VSTGUI_ENABLE_DEPRECATED_METHODS "Enable VSTGUI deprecated methods" ON) endif() if(NOT DEFINED VSTGUI_ENABLE_XMLPARSER) option(VSTGUI_ENABLE_XMLPARSER "Enable building deprecated Expat based XML Parser" ON) endif() if(NOT DEFINED VSTGUI_ENABLE_OPENGL_SUPPORT) option(VSTGUI_ENABLE_OPENGL_SUPPORT "Enable OpenGL support" ON) endif() ########################################################################################## if(UNIX AND NOT CMAKE_HOST_APPLE) set(LINUX TRUE CACHE INTERNAL "VSTGUI linux platform") endif() ########################################################################################## if(CMAKE_CONFIGURATION_TYPES) set(CMAKE_CONFIGURATION_TYPES Debug Release ReleaseLTO) set_property(GLOBAL PROPERTY USE_FOLDERS ON) endif() if(CMAKE_HOST_APPLE) if(CMAKE_C_COMPILER_VERSION VERSION_GREATER 7) set(VSTGUI_LTO_COMPILER_FLAGS "-O3 -flto=thin") else() set(VSTGUI_LTO_COMPILER_FLAGS "-O3 -flto") endif() set(VSTGUI_LTO_LINKER_FLAGS "") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -g") endif() if(LINUX) set(VSTGUI_LTO_COMPILER_FLAGS "-O3 -flto") set(VSTGUI_LTO_LINKER_FLAGS "") if(VSTGUI_WARN_EVERYTHING) set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall") endif() set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-multichar") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -g") endif() if(MSVC) set(VSTGUI_COMPILE_DEFINITIONS_DEBUG "${VSTGUI_COMPILE_DEFINITIONS_DEBUG};_CRT_SECURE_NO_WARNINGS") set(VSTGUI_COMPILE_DEFINITIONS_RELEASE "${VSTGUI_COMPILE_DEFINITIONS_RELEASE};_CRT_SECURE_NO_WARNINGS") set(VSTGUI_LTO_COMPILER_FLAGS "/GL /MP") set(VSTGUI_LTO_LINKER_FLAGS "/LTCG") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /MP") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /Zi") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /utf-8") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /Zc:__cplusplus") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /permissive-") set(CMAKE_STATIC_LINKER_FLAGS "${CMAKE_STATIC_LINKER_FLAGS} /IGNORE:4221") endif() ########################################################################################## set(VSTGUI_COMPILE_DEFINITIONS_DEBUG "${VSTGUI_COMPILE_DEFINITIONS_DEBUG};VSTGUI_LIVE_EDITING;DEBUG") set(VSTGUI_COMPILE_DEFINITIONS_RELEASE "${VSTGUI_COMPILE_DEFINITIONS_RELEASE};NDEBUG;RELEASE") if(VSTGUI_ENABLE_DEPRECATED_METHODS) set(VSTGUI_COMPILE_DEFINITIONS_DEBUG "${VSTGUI_COMPILE_DEFINITIONS_DEBUG};VSTGUI_ENABLE_DEPRECATED_METHODS=1") set(VSTGUI_COMPILE_DEFINITIONS_RELEASE "${VSTGUI_COMPILE_DEFINITIONS_RELEASE};VSTGUI_ENABLE_DEPRECATED_METHODS=1") else() set(VSTGUI_COMPILE_DEFINITIONS_DEBUG "${VSTGUI_COMPILE_DEFINITIONS_DEBUG};VSTGUI_ENABLE_DEPRECATED_METHODS=0") set(VSTGUI_COMPILE_DEFINITIONS_RELEASE "${VSTGUI_COMPILE_DEFINITIONS_RELEASE};VSTGUI_ENABLE_DEPRECATED_METHODS=0") endif() if(VSTGUI_ENABLE_XMLPARSER) set(VSTGUI_COMPILE_DEFINITIONS_DEBUG "${VSTGUI_COMPILE_DEFINITIONS_DEBUG};VSTGUI_ENABLE_XML_PARSER=1") set(VSTGUI_COMPILE_DEFINITIONS_RELEASE "${VSTGUI_COMPILE_DEFINITIONS_RELEASE};VSTGUI_ENABLE_XML_PARSER=1") else() set(VSTGUI_COMPILE_DEFINITIONS_DEBUG "${VSTGUI_COMPILE_DEFINITIONS_DEBUG};VSTGUI_ENABLE_XML_PARSER=0") set(VSTGUI_COMPILE_DEFINITIONS_RELEASE "${VSTGUI_COMPILE_DEFINITIONS_RELEASE};VSTGUI_ENABLE_XML_PARSER=0") endif() if(VSTGUI_ENABLE_OPENGL_SUPPORT) set(VSTGUI_COMPILE_DEFINITIONS_DEBUG "${VSTGUI_COMPILE_DEFINITIONS_DEBUG};VSTGUI_OPENGL_SUPPORT=1") set(VSTGUI_COMPILE_DEFINITIONS_RELEASE "${VSTGUI_COMPILE_DEFINITIONS_RELEASE};VSTGUI_OPENGL_SUPPORT=1") else() set(VSTGUI_COMPILE_DEFINITIONS_DEBUG "${VSTGUI_COMPILE_DEFINITIONS_DEBUG};VSTGUI_OPENGL_SUPPORT=0") set(VSTGUI_COMPILE_DEFINITIONS_RELEASE "${VSTGUI_COMPILE_DEFINITIONS_RELEASE};VSTGUI_OPENGL_SUPPORT=0") endif() set(VSTGUI_COMPILE_DEFINITIONS PRIVATE $<$:${VSTGUI_COMPILE_DEFINITIONS_DEBUG}> $<$:${VSTGUI_COMPILE_DEFINITIONS_RELEASE}> $<$:${VSTGUI_COMPILE_DEFINITIONS_RELEASE}> CACHE INTERNAL "VSTGUI compile definitions" ) ########################################################################################## set(CMAKE_CXX_FLAGS_RELEASELTO "${CMAKE_CXX_FLAGS_RELEASE} ${VSTGUI_LTO_COMPILER_FLAGS}" ) set(CMAKE_EXE_LINKER_FLAGS_RELEASELTO "${CMAKE_EXE_LINKER_FLAGS_RELEASE} ${VSTGUI_LTO_LINKER_FLAGS}" ) set(CMAKE_STATIC_LINKER_FLAGS_RELEASELTO "${CMAKE_STATIC_LINKER_FLAGS_RELEASE} ${VSTGUI_LTO_LINKER_FLAGS}" ) vst3sdk-3.7.10.14+~4.13.3/vstgui/contrib/000077500000000000000000000000001461511344400173325ustar00rootroot00000000000000vst3sdk-3.7.10.14+~4.13.3/vstgui/contrib/ciboxblurfilter.h000066400000000000000000000014001461511344400226750ustar00rootroot00000000000000// This file is part of VSTGUI. It is subject to the license terms // in the LICENSE file found in the top-level directory of this // distribution and at http://github.com/steinbergmedia/vstgui/LICENSE #pragma once #include "../lib/cbitmapfilter.h" //------------------------------------------------------------------------ namespace VSTGUI { namespace BitmapFilter { //------------------------------------------------------------------------ class CIBoxBlurFilter : public BitmapFilter::FilterBase { public: CIBoxBlurFilter (); bool run (bool replace) override; static IFilter* CreateFunction (IdStringPtr _name) { return new CIBoxBlurFilter (); } }; //------------------------------------------------------------------------ } // BitmapFilter } // VSTGUI vst3sdk-3.7.10.14+~4.13.3/vstgui/contrib/ciboxblurfilter.mm000066400000000000000000000056341461511344400230740ustar00rootroot00000000000000// This file is part of VSTGUI. It is subject to the license terms // in the LICENSE file found in the top-level directory of this // distribution and at http://github.com/steinbergmedia/vstgui/LICENSE #import "ciboxblurfilter.h" #import "../lib/platform/mac/cgbitmap.h" #import "../lib/cbitmap.h" #import namespace VSTGUI { namespace BitmapFilter { //------------------------------------------------------------------------ __attribute__((__constructor__)) static void registerFilter () { Factory::getInstance ().registerFilter (Standard::kBoxBlur, CIBoxBlurFilter::CreateFunction); } //------------------------------------------------------------------------ CIBoxBlurFilter::CIBoxBlurFilter () : FilterBase ("A Box Blur Filter using CoreImage") { registerProperty (Standard::Property::kInputBitmap, BitmapFilter::Property (BitmapFilter::Property::kObject)); registerProperty (Standard::Property::kRadius, BitmapFilter::Property (static_cast (2))); } //------------------------------------------------------------------------ bool CIBoxBlurFilter::run (bool replace) { CBitmap* inputBitmap = getInputBitmap (); int32_t radius = static_cast ( static_cast (getProperty (Standard::Property::kRadius).getInteger ()) * inputBitmap->getPlatformBitmap ()->getScaleFactor ()); if (inputBitmap == nullptr) return false; CGBitmap* cgBitmap = dynamic_cast (inputBitmap->getPlatformBitmap ()); if (cgBitmap == nullptr) return false; CIImage* inputImage = [[[CIImage alloc] initWithCGImage:cgBitmap->getCGImage ()] autorelease]; if (inputImage == nil) return false; CIFilter* filter = [CIFilter filterWithName:@"CIBoxBlur"]; NSMutableDictionary* values = [[NSMutableDictionary new] autorelease]; [values setObject:@(radius) forKey:@"inputRadius"]; [values setObject:inputImage forKey:@"inputImage"]; [filter setValuesForKeysWithDictionary:values]; CIImage* outputImage = [filter valueForKey:@"outputImage"]; if (outputImage == nil) return false; SharedPointer outputBitmap = owned (new CGBitmap (cgBitmap->getSize ())); CGContextRef cgContext = outputBitmap->createCGContext (); if (cgContext == nullptr) return false; CGContextScaleCTM (cgContext, 1, -1); CIContext* context = [CIContext contextWithCGContext:cgContext options:nil]; if (context == nil) return false; [context drawImage:outputImage atPoint:CGPointMake (0, -cgBitmap->getSize ().y) fromRect:CGRectMake (0, 0, cgBitmap->getSize ().x, cgBitmap->getSize ().y)]; CFRelease (cgContext); outputBitmap->setScaleFactor (cgBitmap->getScaleFactor ()); if (replace) { inputBitmap->setPlatformBitmap (outputBitmap); return true; } return registerProperty (Standard::Property::kOutputBitmap, BitmapFilter::Property (owned (new CBitmap (outputBitmap)))); } //------------------------------------------------------------------------ } // BitmapFilter } // VSTGUI vst3sdk-3.7.10.14+~4.13.3/vstgui/contrib/datepicker.h000066400000000000000000000026171461511344400216240ustar00rootroot00000000000000// This file is part of VSTGUI. It is subject to the license terms // in the LICENSE file found in the top-level directory of this // distribution and at http://github.com/steinbergmedia/vstgui/LICENSE #pragma once #include "../lib/iexternalview.h" #include #include //------------------------------------------------------------------------ namespace VSTGUI { namespace ExternalView { //------------------------------------------------------------------------ class DatePicker : public ViewAdapter { public: DatePicker (); ~DatePicker () noexcept; struct Date { int32_t day {0}; int32_t month {0}; int32_t year {0}; }; void setDate (Date date); using ChangeCallback = std::function; void setChangeCallback (const ChangeCallback& callback); private: bool platformViewTypeSupported (PlatformViewType type) override; bool attach (void* parent, PlatformViewType parentViewType) override; bool remove () override; void setViewSize (IntRect frame, IntRect visible) override; void setContentScaleFactor (double scaleFactor) override; void setMouseEnabled (bool state) override; void takeFocus () override; void looseFocus () override; void setTookFocusCallback (const TookFocusCallback& callback) override; struct Impl; std::unique_ptr impl; }; //------------------------------------------------------------------------ } // ExternalView } // VSTGUI vst3sdk-3.7.10.14+~4.13.3/vstgui/contrib/datepicker.mm000066400000000000000000000145461461511344400220120ustar00rootroot00000000000000// This file is part of VSTGUI. It is subject to the license terms // in the LICENSE file found in the top-level directory of this // distribution and at http://github.com/steinbergmedia/vstgui/LICENSE #import "datepicker.h" #import "externalview_nsview.h" //------------------------------------------------------------------------ namespace VSTGUI { namespace ExternalView { //------------------------------------------------------------------------ struct DatePickerDelegate : RuntimeObjCClass { using DoneCallback = std::function; using ValidateCallback = std::function; static constexpr const auto DoneCallbackVarName = "DoneCallback"; static constexpr const auto ValidateCallbackVarName = "ValidateCallback"; static id allocAndInit (DoneCallback&& doneCallback, ValidateCallback&& callback) { id obj = Base::alloc (); initWithCallbacks (obj, std::move (doneCallback), std::move (callback)); return obj; } static Class CreateClass () { return ObjCClassBuilder () .init ("DatePickerDelegate", [NSObject class]) .addProtocol ("NSDatePickerCellDelegate") .addMethod (@selector (datePickerCell:validateProposedDateValue:timeInterval:), validate) .addMethod (@selector (complete:), complete) .addIvar (ValidateCallbackVarName) .addIvar (DoneCallbackVarName) .finalize (); } static id initWithCallbacks (id self, DoneCallback&& doneCallback, ValidateCallback&& callback) { if ((self = makeInstance (self).callSuper (@selector (init)))) { auto instance = makeInstance (self); if (auto var = instance.getVariable (DoneCallbackVarName)) var->set (doneCallback); if (auto var = instance.getVariable (ValidateCallbackVarName)) var->set (callback); } return self; } static void complete (id self, SEL cmd, id sender) { if (auto var = makeInstance (self).getVariable (DoneCallbackVarName)) { const auto& callback = var->get (); if (callback) callback (); } } static void validate (id self, SEL cmd, NSDatePickerCell* datePickerCell, NSDate* _Nonnull* _Nonnull proposedDateValue, NSTimeInterval* _Nullable proposedTimeInterval) { if (auto var = makeInstance (self).getVariable (ValidateCallbackVarName)) { const auto& callback = var->get (); if (callback) callback (proposedDateValue, proposedTimeInterval); } } }; //------------------------------------------------------------------------ struct DatePicker::Impl : ExternalNSViewBase { using Base::Base; id delegate {nil}; ChangeCallback changeCallback; #if !__has_feature(objc_arc) ~Impl () noexcept { if (delegate) [delegate release]; } #endif }; //------------------------------------------------------------------------ DatePicker::DatePicker () { impl = std::make_unique ([[NSDatePicker alloc] initWithFrame: {0., 0., 10., 10.}]); impl->view.datePickerStyle = NSDatePickerStyleTextField; impl->view.datePickerMode = NSDatePickerModeSingle; impl->view.datePickerElements = NSDatePickerElementFlagYearMonthDay; if (@available (macOS 10.15.4, *)) impl->view.presentsCalendarOverlay = YES; impl->view.dateValue = [NSDate date]; impl->view.calendar = [NSCalendar currentCalendar]; [impl->container addSubview:impl->view]; impl->delegate = DatePickerDelegate::allocAndInit ( [impl = impl.get ()] () { if (impl->changeCallback) { auto dateValue = impl->view.dateValue; auto calendar = impl->view.calendar; auto components = [calendar components:NSCalendarUnitYear | NSCalendarUnitMonth | NSCalendarUnitDay fromDate:dateValue]; Date date; date.day = static_cast (components.day); date.month = static_cast (components.month); date.year = static_cast (components.year); impl->changeCallback (date); } }, [] (NSDate** date, NSTimeInterval* time) { // TODO: add validation mechanism }); impl->view.delegate = impl->delegate; impl->view.target = impl->delegate; impl->view.action = @selector (complete:); } //------------------------------------------------------------------------ DatePicker::~DatePicker () noexcept {} //------------------------------------------------------------------------ void DatePicker::setDate (Date date) { auto calendar = impl->view.calendar; auto dateComponents = [NSDateComponents new]; dateComponents.calendar = calendar; dateComponents.day = date.day; dateComponents.month = date.month; dateComponents.year = date.year; impl->view.dateValue = [calendar dateFromComponents:dateComponents]; } //------------------------------------------------------------------------ void DatePicker::setChangeCallback (const ChangeCallback& callback) { impl->changeCallback = callback; } //------------------------------------------------------------------------ bool DatePicker::platformViewTypeSupported (PlatformViewType type) { return impl->platformViewTypeSupported (type); } //------------------------------------------------------------------------ bool DatePicker::attach (void* parent, PlatformViewType parentViewType) { return impl->attach (parent, parentViewType); } //------------------------------------------------------------------------ bool DatePicker::remove () { return impl->remove (); } //------------------------------------------------------------------------ void DatePicker::setViewSize (IntRect frame, IntRect visible) { impl->setViewSize (frame, visible); } //------------------------------------------------------------------------ void DatePicker::setContentScaleFactor (double scaleFactor) { impl->setContentScaleFactor (scaleFactor); } //------------------------------------------------------------------------ void DatePicker::setMouseEnabled (bool state) { impl->setMouseEnabled (state); } //------------------------------------------------------------------------ void DatePicker::takeFocus () { impl->takeFocus (); } //------------------------------------------------------------------------ void DatePicker::looseFocus () { impl->looseFocus (); } //------------------------------------------------------------------------ void DatePicker::setTookFocusCallback (const TookFocusCallback& callback) { impl->setTookFocusCallback (callback); } //------------------------------------------------------------------------ } // ExternalView } // VSTGUI vst3sdk-3.7.10.14+~4.13.3/vstgui/contrib/datepicker_win32.cpp000066400000000000000000000076251461511344400232050ustar00rootroot00000000000000 #include "datepicker.h" #include "externalview_hwnd.h" #include "vstgui/lib/platform/win32/win32factory.h" #include //------------------------------------------------------------------------ namespace VSTGUI { namespace ExternalView { //------------------------------------------------------------------------ struct DatePicker::Impl : ExternalHWNDBase { using Base::Base; ~Impl () noexcept { if (font) DeleteObject (font); } ChangeCallback changeCallback; HFONT font {nullptr}; }; //------------------------------------------------------------------------ DatePicker::DatePicker () { auto hInstance = getPlatformFactory ().asWin32Factory ()->getInstance (); impl = std::make_unique (hInstance); impl->child = CreateWindowExW (0, DATETIMEPICK_CLASS, TEXT ("DateTime"), WS_BORDER | WS_CHILD | WS_VISIBLE | DTS_SHORTDATEFORMAT, 0, 0, 80, 20, impl->container.getHWND (), NULL, hInstance, NULL); impl->container.setWindowProc ([this] (HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam) { switch (message) { case WM_NOTIFY: { LPNMHDR hdr = reinterpret_cast (lParam); switch (hdr->code) { case DTN_DATETIMECHANGE: { LPNMDATETIMECHANGE lpChange = reinterpret_cast (lParam); if (impl->changeCallback) { Date date; date.day = lpChange->st.wDay; date.month = lpChange->st.wMonth; date.year = lpChange->st.wYear; impl->changeCallback (date); } break; } } break; } } return DefWindowProc (hwnd, message, wParam, lParam); }); } //------------------------------------------------------------------------ DatePicker::~DatePicker () noexcept {} //------------------------------------------------------------------------ void DatePicker::setDate (Date date) { SYSTEMTIME st = {}; st.wDay = date.day; st.wMonth = date.month; st.wYear = date.year; DateTime_SetSystemtime (impl->child, GDT_VALID, &st); } //------------------------------------------------------------------------ void DatePicker::setChangeCallback (const ChangeCallback& callback) { impl->changeCallback = callback; } //------------------------------------------------------------------------ bool DatePicker::platformViewTypeSupported (PlatformViewType type) { return impl->platformViewTypeSupported (type); } //------------------------------------------------------------------------ bool DatePicker::attach (void* parent, PlatformViewType parentViewType) { return impl->attach (parent, parentViewType); } //------------------------------------------------------------------------ bool DatePicker::remove () { return impl->remove (); } //------------------------------------------------------------------------ void DatePicker::setViewSize (IntRect frame, IntRect visible) { impl->setViewSize (frame, visible); } //------------------------------------------------------------------------ void DatePicker::setContentScaleFactor (double scaleFactor) { if (impl->font) DeleteObject (impl->font); auto logFont = NonClientMetrics::get ().lfCaptionFont; logFont.lfHeight = static_cast (std::round (logFont.lfHeight * scaleFactor)); impl->font = CreateFontIndirect (&logFont); if (impl->font) SendMessage (impl->child, WM_SETFONT, (WPARAM)impl->font, 0); } //------------------------------------------------------------------------ void DatePicker::setMouseEnabled (bool state) { impl->setMouseEnabled (state); } //------------------------------------------------------------------------ void DatePicker::takeFocus () { impl->takeFocus (); } //------------------------------------------------------------------------ void DatePicker::looseFocus () { impl->looseFocus (); } void DatePicker::setTookFocusCallback (const TookFocusCallback& callback) { impl->setTookFocusCallback (callback); } //------------------------------------------------------------------------ } // ExternalView } // VSTGUI vst3sdk-3.7.10.14+~4.13.3/vstgui/contrib/evbutton.h000066400000000000000000000026001461511344400213470ustar00rootroot00000000000000// This file is part of VSTGUI. It is subject to the license terms // in the LICENSE file found in the top-level directory of this // distribution and at http://github.com/steinbergmedia/vstgui/LICENSE #pragma once #include "../lib/iexternalview.h" #include "../lib/cstring.h" #include //------------------------------------------------------------------------ namespace VSTGUI { namespace ExternalView { //------------------------------------------------------------------------ class Button : public ControlViewAdapter { public: enum class Type { Checkbox, Push, Radio, OnOff }; Button (Type type, const UTF8String& title); ~Button () noexcept; private: bool platformViewTypeSupported (PlatformViewType type) override; bool attach (void* parent, PlatformViewType parentViewType) override; bool remove () override; void setViewSize (IntRect frame, IntRect visible) override; void setContentScaleFactor (double scaleFactor) override; void setMouseEnabled (bool state) override; void takeFocus () override; void looseFocus () override; void setTookFocusCallback (const TookFocusCallback& callback) override; bool setValue (double value) override; bool setEditCallbacks (const EditCallbacks& callbacks) override; struct Impl; std::unique_ptr impl; }; //------------------------------------------------------------------------ } // ExternalView } // VSTGUI vst3sdk-3.7.10.14+~4.13.3/vstgui/contrib/evbutton_macos.mm000066400000000000000000000151511461511344400227200ustar00rootroot00000000000000// This file is part of VSTGUI. It is subject to the license terms // in the LICENSE file found in the top-level directory of this // distribution and at http://github.com/steinbergmedia/vstgui/LICENSE #import "evbutton.h" #import "externalview_nsview.h" #import "../lib/platform/mac/macstring.h" //------------------------------------------------------------------------ namespace VSTGUI { namespace ExternalView { //------------------------------------------------------------------------ struct ButtonDelegate : RuntimeObjCClass { using ActionCallback = std::function; static constexpr const auto ActionCallbackVarName = "ActionCallback"; static id allocAndInit (ActionCallback&& actionCallback) { id obj = Base::alloc (); initWithCallbacks (obj, std::move (actionCallback)); return obj; } static Class CreateClass () { return ObjCClassBuilder () .init ("ButtonDelegate", [NSObject class]) .addMethod (@selector (onAction:), onAction) .addIvar (ActionCallbackVarName) .finalize (); } static id initWithCallbacks (id self, ActionCallback&& actionCallback) { if ((self = makeInstance (self).callSuper (@selector (init)))) { auto instance = makeInstance (self); if (auto var = instance.getVariable (ActionCallbackVarName)) var->set (actionCallback); } return self; } static void onAction (id self, SEL cmd, id sender) { if (auto var = makeInstance (self).getVariable (ActionCallbackVarName)) { const auto& callback = var->get (); if (callback) callback (); } } }; //------------------------------------------------------------------------ struct Button::Impl : ExternalNSViewBase, IControlViewExtension { using Base::Base; id delegate {nil}; EditCallbacks callbacks {}; #if !__has_feature(objc_arc) ~Impl () noexcept { if (delegate) [delegate release]; } #endif bool setValue (double value) override { if (value < 0.5) view.state = NSControlStateValueOff; else if (value == 0.5) view.state = NSControlStateValueMixed; else view.state = NSControlStateValueOn; return true; } bool setEditCallbacks (const EditCallbacks& editCallbacks) override { callbacks = editCallbacks; return true; } }; //------------------------------------------------------------------------ Button::Button (Type type, const UTF8String& inTitle) { NSString* title = fromUTF8String (inTitle); ButtonDelegate::ActionCallback actionCallback = [this] () { double value = 0.; switch (impl->view.state) { case NSControlStateValueOn: value = 1.; break; case NSControlStateValueOff: value = 0.; break; case NSControlStateValueMixed: value = 0.5; break; } if (impl->callbacks.beginEdit) impl->callbacks.beginEdit (); if (impl->callbacks.performEdit) impl->callbacks.performEdit (value); if (impl->callbacks.endEdit) impl->callbacks.endEdit (); }; NSButton* button = {}; switch (type) { case Type::Checkbox: { button = [NSButton checkboxWithTitle:title target:nullptr action:nullptr]; break; } case Type::Push: { button = [NSButton buttonWithTitle:title target:nullptr action:nullptr]; [button setButtonType:NSButtonTypeMomentaryLight]; actionCallback = [this] () { if (impl->callbacks.beginEdit) impl->callbacks.beginEdit (); if (impl->callbacks.performEdit) impl->callbacks.performEdit (1.); if (impl->callbacks.endEdit) impl->callbacks.endEdit (); if (impl->callbacks.beginEdit) impl->callbacks.beginEdit (); if (impl->callbacks.performEdit) impl->callbacks.performEdit (0.); if (impl->callbacks.endEdit) impl->callbacks.endEdit (); }; break; } case Type::OnOff: { button = [NSButton buttonWithTitle:title target:nullptr action:nullptr]; [button setButtonType:NSButtonTypePushOnPushOff]; break; } case Type::Radio: { button = [NSButton radioButtonWithTitle:title target:nullptr action:nullptr]; break; } } [button sizeToFit]; impl = std::make_unique (button); impl->delegate = ButtonDelegate::allocAndInit (std::move (actionCallback)); impl->view.target = impl->delegate; impl->view.action = @selector (onAction:); [impl->container addSubview:impl->view]; [button retain]; } //------------------------------------------------------------------------ Button::~Button () noexcept = default; //------------------------------------------------------------------------ bool Button::platformViewTypeSupported (PlatformViewType type) { return impl->platformViewTypeSupported (type); } //------------------------------------------------------------------------ bool Button::attach (void* parent, PlatformViewType parentViewType) { return impl->attach (parent, parentViewType); } //------------------------------------------------------------------------ bool Button::remove () { return impl->remove (); } //------------------------------------------------------------------------ void Button::setViewSize (IntRect frame, IntRect visible) { static constexpr const NSControlSize controlSizes[] = {NSControlSizeRegular, NSControlSizeSmall, NSControlSizeMini}; for (auto i = 0; i < std::size (controlSizes); i++) { impl->view.controlSize = controlSizes[i]; auto size = [impl->view sizeThatFits:NSMakeSize (frame.size.width, frame.size.height)]; if (size.height <= frame.size.height) break; } impl->setViewSize (frame, visible); } //------------------------------------------------------------------------ void Button::setContentScaleFactor (double scaleFactor) { impl->setContentScaleFactor (scaleFactor); } //------------------------------------------------------------------------ void Button::setMouseEnabled (bool state) { impl->setMouseEnabled (state); } //------------------------------------------------------------------------ void Button::takeFocus () { impl->takeFocus (); } //------------------------------------------------------------------------ void Button::looseFocus () { impl->looseFocus (); } //------------------------------------------------------------------------ void Button::setTookFocusCallback (const TookFocusCallback& callback) { impl->setTookFocusCallback (callback); } //------------------------------------------------------------------------ bool Button::setValue (double value) { return impl->setValue (value); } //------------------------------------------------------------------------ bool Button::setEditCallbacks (const EditCallbacks& callbacks) { return impl->setEditCallbacks (callbacks); } //------------------------------------------------------------------------ } // ExternalView } // VSTGUI vst3sdk-3.7.10.14+~4.13.3/vstgui/contrib/evbutton_win32.cpp000066400000000000000000000123411461511344400227270ustar00rootroot00000000000000// This file is part of VSTGUI. It is subject to the license terms // in the LICENSE file found in the top-level directory of this // distribution and at http://github.com/steinbergmedia/vstgui/LICENSE #include "evbutton.h" #include "externalview_hwnd.h" #include "vstgui/lib/platform/win32/win32factory.h" #include "vstgui/lib/platform/win32/winstring.h" #include //------------------------------------------------------------------------ namespace VSTGUI { namespace ExternalView { //------------------------------------------------------------------------ struct Button::Impl : ExternalHWNDBase, IControlViewExtension { using ExternalHWNDBase::ExternalHWNDBase; Type type {}; EditCallbacks callbacks {}; double value {0.}; bool setValue (double val) override { value = val; auto state = Button_GetState (child); switch (type) { case Type::Checkbox: case Type::Radio: { Button_SetCheck (child, value > 0.5); break; } { break; } case Type::OnOff: { if (value == 0) state = 0; //~BST_PUSHED; else state = BST_PUSHED; Button_SetState (child, state); break; } case Type::Push: { break; } } return true; } bool setEditCallbacks (const EditCallbacks& editCallbacks) override { callbacks = editCallbacks; return true; } void onButtonClick (double val) { if (callbacks.beginEdit) callbacks.beginEdit (); if (callbacks.performEdit) callbacks.performEdit (val); if (callbacks.endEdit) callbacks.endEdit (); } }; //------------------------------------------------------------------------ Button::Button (Type type, const UTF8String& inTitle) { DWORD addStyle = 0; switch (type) { case Type::Checkbox: addStyle = BS_AUTOCHECKBOX; break; case Type::Radio: addStyle = BS_RADIOBUTTON; break; case Type::OnOff: addStyle = BS_PUSHBUTTON; break; case Type::Push: addStyle = BS_PUSHBUTTON; break; } auto winString = dynamic_cast (inTitle.getPlatformString ()); auto hInstance = getPlatformFactory ().asWin32Factory ()->getInstance (); impl = std::make_unique (hInstance); impl->type = type; impl->child = CreateWindowExW (WS_EX_COMPOSITED, TEXT ("BUTTON"), winString ? winString->getWideString () : nullptr, WS_CHILD | WS_VISIBLE | BS_TEXT | addStyle, 0, 0, 80, 20, impl->container.getHWND (), NULL, hInstance, NULL); impl->container.setWindowProc ( [this] (HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam) -> LRESULT { switch (message) { case WM_COMMAND: { if (HIWORD (wParam) == BN_CLICKED) { switch (impl->type) { case Type::Checkbox: { impl->onButtonClick (impl->value == 0. ? 1 : 0.); break; } case Type::Radio: { impl->onButtonClick (impl->value == 0. ? 1 : 0.); break; } case Type::OnOff: { impl->onButtonClick (impl->value == 0. ? 1 : 0.); break; } case Type::Push: { impl->onButtonClick (1.); impl->onButtonClick (0.); break; } } return 0; } break; } case WM_ERASEBKGND: return 0; } return DefWindowProc (hwnd, message, wParam, lParam); }); } //------------------------------------------------------------------------ Button::~Button () noexcept = default; //------------------------------------------------------------------------ bool Button::platformViewTypeSupported (PlatformViewType type) { return impl->platformViewTypeSupported (type); } //------------------------------------------------------------------------ bool Button::attach (void* parent, PlatformViewType parentViewType) { return impl->attach (parent, parentViewType); } //------------------------------------------------------------------------ bool Button::remove () { return impl->remove (); } //------------------------------------------------------------------------ void Button::setViewSize (IntRect frame, IntRect visible) { impl->setViewSize (frame, visible); } //------------------------------------------------------------------------ void Button::setContentScaleFactor (double scaleFactor) { impl->setContentScaleFactor (scaleFactor); } //------------------------------------------------------------------------ void Button::setMouseEnabled (bool state) { impl->setMouseEnabled (state); } //------------------------------------------------------------------------ void Button::takeFocus () { impl->takeFocus (); } //------------------------------------------------------------------------ void Button::looseFocus () { impl->looseFocus (); } //------------------------------------------------------------------------ void Button::setTookFocusCallback (const TookFocusCallback& callback) { impl->setTookFocusCallback (callback); } //------------------------------------------------------------------------ bool Button::setValue (double value) { return impl->setValue (value); } //------------------------------------------------------------------------ bool Button::setEditCallbacks (const EditCallbacks& callbacks) { return impl->setEditCallbacks (callbacks); } //------------------------------------------------------------------------ } // ExternalView } // VSTGUI vst3sdk-3.7.10.14+~4.13.3/vstgui/contrib/externalview_direct3d12.h000066400000000000000000000312011461511344400241410ustar00rootroot00000000000000// This file is part of VSTGUI. It is subject to the license terms // in the LICENSE file found in the top-level directory of this // distribution and at http://github.com/steinbergmedia/vstgui/LICENSE #pragma once #include "externalview_hwnd.h" #include #include #include #include #include #include #ifdef _MSC_VER #pragma comment(lib, "dcomp.lib") #pragma comment(lib, "d3d12.lib") #pragma comment(lib, "dxgi.lib") #endif //------------------------------------------------------------------------ namespace VSTGUI { //------------------------------------------------------------------------ //------------------------------------------------------------------------ struct Win32Exception : std::exception { explicit Win32Exception (HRESULT hr) : _hr (hr) { FormatMessageA (FORMAT_MESSAGE_ALLOCATE_BUFFER | FORMAT_MESSAGE_FROM_SYSTEM | FORMAT_MESSAGE_IGNORE_INSERTS, NULL, hr, MAKELANGID (LANG_NEUTRAL, SUBLANG_DEFAULT), (LPSTR)&_errorStr, 0, NULL); } ~Win32Exception () noexcept { if (_errorStr) LocalFree ((HLOCAL)_errorStr); } const char* what () const noexcept override { return _errorStr; } HRESULT hr () const noexcept { return _hr; } private: HRESULT _hr; char* _errorStr {nullptr}; }; inline void ThrowIfFailed (HRESULT hr) { if (FAILED (hr)) { throw Win32Exception (hr); } } //------------------------------------------------------------------------ namespace ExternalView { //------------------------------------------------------------------------ struct IDirect3D12View { virtual ~IDirect3D12View () noexcept = default; virtual ID3D12CommandAllocator* getCommandAllocator () const = 0; virtual IDXGISwapChain3* getSwapChain () const = 0; virtual ID3D12Device* getDevice () const = 0; virtual INT getFrameIndex () const = 0; virtual void setFrameIndex (INT index) = 0; virtual void render () = 0; }; //------------------------------------------------------------------------ struct IDirect3D12Renderer { virtual ~IDirect3D12Renderer () noexcept = default; virtual bool init (IDirect3D12View* view) = 0; virtual void render (ID3D12CommandQueue* queue) = 0; virtual void beforeSizeUpdate () = 0; virtual void onSizeUpdate (IntSize newSize, double scaleFactor) = 0; virtual void onAttach () = 0; virtual void onRemove () = 0; virtual uint32_t getFrameCount () const = 0; }; //------------------------------------------------------------------------ using Direct3D12RendererPtr = std::shared_ptr; //------------------------------------------------------------------------ struct GPUFence { template using ComPtr = Microsoft::WRL::ComPtr; GPUFence () = default; GPUFence (ID3D12Device* device, UINT64 initialValue = 0) { ThrowIfFailed (device->CreateFence (0, D3D12_FENCE_FLAG_NONE, IID_PPV_ARGS (&m_fence))); m_event = CreateEvent (nullptr, FALSE, FALSE, nullptr); if (m_event == nullptr) { ThrowIfFailed (HRESULT_FROM_WIN32 (GetLastError ())); } m_value = initialValue; } ~GPUFence () noexcept { if (m_event) CloseHandle (m_event); } GPUFence& operator=(GPUFence&& o) noexcept { m_event = o.m_event; m_fence = o.m_fence; m_value = o.m_value; o.m_event = nullptr; o.m_fence.Reset (); o.m_value = {}; return *this; } void wait (ID3D12CommandQueue* queue) { if (m_fence == nullptr) return; const auto value = m_value; ThrowIfFailed (queue->Signal (m_fence.Get (), value)); m_value++; if (m_fence->GetCompletedValue () < value) { ThrowIfFailed (m_fence->SetEventOnCompletion (value, m_event)); WaitForSingleObject (m_event, INFINITE); } } HANDLE m_event {nullptr}; ComPtr m_fence; UINT64 m_value {0}; }; //------------------------------------------------------------------------ struct Direct3D12View : public ExternalHWNDBase, IDirect3D12View { template using ComPtr = Microsoft::WRL::ComPtr; Direct3D12View (HINSTANCE instance, const Direct3D12RendererPtr& renderer, ComPtr factory = nullptr, ComPtr device = nullptr, ComPtr commandQueue = nullptr) : Base (instance), m_renderer (renderer), m_factory (factory), m_device (device), m_commandQueue (commandQueue) { vstgui_assert ((factory && device) || (!factory && !device), "Either both factory and device are provided or none of both!"); vstgui_assert (commandQueue ? device : true, "If a command queue is provided, the device must also be provided!"); } static std::shared_ptr make (HINSTANCE instance, const Direct3D12RendererPtr& renderer, ComPtr factory = nullptr, ComPtr device = nullptr, ComPtr queue = nullptr) { return std::make_shared (instance, renderer, factory, device, queue); } void render () override { doRender (); } Direct3D12RendererPtr& getRenderer () { return m_renderer; } const Direct3D12RendererPtr& getRenderer () const { return m_renderer; } private: ID3D12CommandAllocator* getCommandAllocator () const { return m_commandAllocator.Get (); } IDXGISwapChain3* getSwapChain () const { return m_swapChain.Get (); } ID3D12Device* getDevice () const { return m_device.Get (); } INT getFrameIndex () const { return m_frameIndex; } void setFrameIndex (INT index) { m_frameIndex = index; } void doRender () { if (mutex.try_lock ()) { if (m_commandQueue) { HRESULT result = S_FALSE; try { waitForPreviousFrame (); m_renderer->render (m_commandQueue.Get ()); result = getSwapChain ()->Present (1, 0); ThrowIfFailed (result); } catch (const Win32Exception& e) { try { freeResources (); } catch (...) { } throw (e); } } mutex.unlock (); } } bool attach (void* parent, PlatformViewType parentViewType) override { if (Base::attach (parent, parentViewType)) { try { if (m_renderer->init (this)) { init (); m_renderer->onAttach (); } } catch (...) { auto reasonHR = m_device->GetDeviceRemovedReason (); Win32Exception e (reasonHR); freeResources (); } return true; } return false; } bool remove () override { Guard g (mutex); waitForPreviousFrame (); freeResources (); return Base::remove (); } void setViewSize (IntRect frame, IntRect visible) override { Guard g (mutex); Base::setViewSize (frame, visible); m_visibleRect = visible; updateSizes (); } void setContentScaleFactor (double factor) override { Guard g (mutex); m_scaleFactor = factor; updateSizes (); } void updateSizes () { if (m_swapChain) { if (m_size.width == m_visibleRect.size.width && m_size.height == m_visibleRect.size.height) return; m_size = m_visibleRect.size; waitForPreviousFrame (); m_renderer->beforeSizeUpdate (); ThrowIfFailed (m_dcompVisual->SetContent (nullptr)); ThrowIfFailed (m_swapChain->ResizeBuffers ( m_renderer->getFrameCount (), static_cast (m_size.width), static_cast (m_size.height), DXGI_FORMAT_R8G8B8A8_UNORM, DXGI_SWAP_EFFECT_FLIP_DISCARD)); ThrowIfFailed (m_dcompVisual->SetContent (m_swapChain.Get ())); m_renderer->onSizeUpdate (m_size, m_scaleFactor); ThrowIfFailed (m_dcompDevice->Commit ()); } } void freeResources () { m_fence = {}; try { m_renderer->onRemove (); } catch (...) { } m_commandAllocator.Reset (); m_commandQueue.Reset (); m_dcompDevice.Reset (); m_dcompTarget.Reset (); m_dcompVisual.Reset (); m_swapChain.Reset (); m_device.Reset (); } void init () { #if defined(_DEBUG) // Enable the D3D12 debug layer. { ComPtr debugController; if (SUCCEEDED (D3D12GetDebugInterface (IID_PPV_ARGS (&debugController)))) { debugController->EnableDebugLayer (); } } #endif if (!m_factory) ThrowIfFailed (CreateDXGIFactory1 (IID_PPV_ARGS (&m_factory))); if (m_device == nullptr) { ComPtr hardwareAdapter; getHardwareAdapter (m_factory.Get (), &hardwareAdapter); if (!hardwareAdapter) { throw; } ThrowIfFailed (D3D12CreateDevice (hardwareAdapter.Get (), D3D_FEATURE_LEVEL_11_0, IID_PPV_ARGS (&m_device))); } if (!m_commandQueue) { // Describe and create the command queue. D3D12_COMMAND_QUEUE_DESC queueDesc = {}; queueDesc.Flags = D3D12_COMMAND_QUEUE_FLAG_NONE; queueDesc.Type = D3D12_COMMAND_LIST_TYPE_DIRECT; ThrowIfFailed (m_device->CreateCommandQueue (&queueDesc, IID_PPV_ARGS (&m_commandQueue))); } try { createSwapChain (m_factory.Get ()); setupDirectComposition (); } catch (...) { auto exc = std::current_exception (); throw (exc); } ThrowIfFailed ( m_factory->MakeWindowAssociation (container.getHWND (), DXGI_MWA_NO_ALT_ENTER)); ThrowIfFailed (m_device->CreateCommandAllocator (D3D12_COMMAND_LIST_TYPE_DIRECT, IID_PPV_ARGS (&m_commandAllocator))); m_fence = GPUFence (m_device.Get (), 1); } void createSwapChain (IDXGIFactory4* factory) { // Describe and create the swap chain. DXGI_SWAP_CHAIN_DESC1 swapChainDesc = {}; swapChainDesc.BufferCount = m_renderer->getFrameCount (); swapChainDesc.Width = static_cast (m_size.width); swapChainDesc.Height = static_cast (m_size.height); swapChainDesc.Format = DXGI_FORMAT_R8G8B8A8_UNORM; swapChainDesc.BufferUsage = DXGI_USAGE_RENDER_TARGET_OUTPUT; swapChainDesc.SwapEffect = DXGI_SWAP_EFFECT_FLIP_DISCARD; swapChainDesc.SampleDesc.Count = 1; swapChainDesc.AlphaMode = DXGI_ALPHA_MODE_PREMULTIPLIED; ComPtr swapChain; ThrowIfFailed (factory->CreateSwapChainForComposition ( m_commandQueue.Get (), // Swap chain needs the queue so that it can force a flush on it. &swapChainDesc, nullptr, &swapChain)); ThrowIfFailed (swapChain.As (&m_swapChain)); } void setupDirectComposition () { // Create the DirectComposition device ThrowIfFailed (DCompositionCreateDevice ( nullptr, IID_PPV_ARGS (m_dcompDevice.ReleaseAndGetAddressOf ()))); // Create a DirectComposition target associated with the window (pass in hWnd here) ThrowIfFailed (m_dcompDevice->CreateTargetForHwnd ( container.getHWND (), true, m_dcompTarget.ReleaseAndGetAddressOf ())); // Create a DirectComposition "visual" ThrowIfFailed (m_dcompDevice->CreateVisual (m_dcompVisual.ReleaseAndGetAddressOf ())); // Associate the visual with the swap chain ThrowIfFailed (m_dcompVisual->SetContent (m_swapChain.Get ())); // Set the visual as the root of the DirectComposition target's composition tree ThrowIfFailed (m_dcompTarget->SetRoot (m_dcompVisual.Get ())); ThrowIfFailed (m_dcompDevice->Commit ()); } static void getHardwareAdapter (IDXGIFactory2* pFactory, IDXGIAdapter1** ppAdapter) { ComPtr adapter; *ppAdapter = nullptr; for (UINT adapterIndex = 0; DXGI_ERROR_NOT_FOUND != pFactory->EnumAdapters1 (adapterIndex, &adapter); ++adapterIndex) { DXGI_ADAPTER_DESC1 desc; adapter->GetDesc1 (&desc); if (desc.Flags & DXGI_ADAPTER_FLAG_SOFTWARE) { // Don't select the Basic Render Driver adapter. // If you want a software adapter, pass in "/warp" on the command line. continue; } // Check to see if the adapter supports Direct3D 12, but don't create the // actual device yet. if (SUCCEEDED (D3D12CreateDevice (adapter.Get (), D3D_FEATURE_LEVEL_11_0, _uuidof(ID3D12Device), nullptr))) { break; } } *ppAdapter = adapter.Detach (); } void waitForPreviousFrame () { if (!m_commandQueue || !m_swapChain) return; // WAITING FOR THE FRAME TO COMPLETE BEFORE CONTINUING IS NOT BEST PRACTICE. // This is code implemented as such for simplicity. The D3D12HelloFrameBuffering // sample illustrates how to use fences for efficient resource usage and to // maximize GPU utilization. m_fence.wait (m_commandQueue.Get ()); m_frameIndex = m_swapChain->GetCurrentBackBufferIndex (); } using Mutex = std::recursive_mutex; using Guard = std::lock_guard; Mutex mutex; IntSize m_size {100, 100}; IntRect m_visibleRect {}; double m_scaleFactor {1.}; UINT m_frameIndex {0}; // Synchronization objects. GPUFence m_fence; ComPtr m_factory; ComPtr m_swapChain; ComPtr m_device; ComPtr m_commandQueue; ComPtr m_commandAllocator; // DirectComposition objects. ComPtr m_dcompDevice; ComPtr m_dcompTarget; ComPtr m_dcompVisual; Direct3D12RendererPtr m_renderer; }; //------------------------------------------------------------------------ } // ExternalView } // VSTGUI vst3sdk-3.7.10.14+~4.13.3/vstgui/contrib/externalview_hwnd.h000066400000000000000000000136211461511344400232430ustar00rootroot00000000000000// This file is part of VSTGUI. It is subject to the license terms // in the LICENSE file found in the top-level directory of this // distribution and at http://github.com/steinbergmedia/vstgui/LICENSE #pragma once #include "vstgui/lib/vstguibase.h" #include "vstgui/lib/iexternalview.h" #include #include #include #include #include //------------------------------------------------------------------------ namespace VSTGUI { namespace ExternalView { //------------------------------------------------------------------------ inline void setWindowSize (HWND window, IntRect r) { SetWindowPos (window, HWND_TOP, static_cast (r.origin.x), static_cast (r.origin.y), static_cast (r.size.width), static_cast (r.size.height), SWP_NOZORDER | SWP_NOCOPYBITS | SWP_NOREDRAW | SWP_DEFERERASE); } //------------------------------------------------------------------------ struct HWNDWindow final { using WindowProcFunc = std::function; HWNDWindow (HINSTANCE instance) : instance (instance) {} ~HWNDWindow () noexcept { if (window) { SetWindowLongPtr (window, GWLP_USERDATA, (__int3264)(LONG_PTR) nullptr); DestroyWindow (window); } destroyWindowClass (); } bool create (const TCHAR* title, const IntRect& frame, HWND parent, DWORD exStyle = 0, DWORD style = WS_CHILD) { if (!initWindowClass ()) return false; window = CreateWindowEx ( exStyle, MAKEINTATOM (windowClassAtom), title, style, static_cast (frame.origin.x), static_cast (frame.origin.y), static_cast (frame.size.width), static_cast (frame.size.height), parent, nullptr, instance, nullptr); if (!window) return false; SetWindowLongPtr (window, GWLP_USERDATA, (__int3264)(LONG_PTR)this); return true; } void setWindowProc (WindowProcFunc&& func) { windowProc = std::move (func); } void setSize (const IntRect& r) { if (!window) return; setWindowSize (window, r); } void show (bool state) { ShowWindow (window, state ? SW_SHOW : SW_HIDE); } void setEnabled (bool state) { EnableWindow (window, state); } HWND getHWND () const { return window; } HINSTANCE getInstance () const { return instance; } private: bool initWindowClass () { assert (instance != nullptr); if (windowClassAtom != 0) return true; std::wstring windowClassName; windowClassName = TEXT ("VSTGUI ExternalView Container "); windowClassName += std::to_wstring (reinterpret_cast (this)); WNDCLASS windowClass; windowClass.style = CS_GLOBALCLASS; windowClass.lpfnWndProc = WindowProc; windowClass.cbClsExtra = 0; windowClass.cbWndExtra = 0; windowClass.hInstance = instance; windowClass.hIcon = 0; windowClass.hCursor = LoadCursor (NULL, IDC_ARROW); windowClass.hbrBackground = 0; windowClass.lpszMenuName = 0; windowClass.lpszClassName = windowClassName.data (); windowClassAtom = RegisterClass (&windowClass); return windowClassAtom != 0; } void destroyWindowClass () { if (windowClassAtom == 0) return; UnregisterClass (MAKEINTATOM (windowClassAtom), instance); windowClassAtom = 0; } static LONG_PTR WINAPI WindowProc (HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam) { if (message == WM_ERASEBKGND) return 1; auto instance = reinterpret_cast (GetWindowLongPtr (hwnd, GWLP_USERDATA)); if (instance && instance->windowProc) return instance->windowProc (hwnd, message, wParam, lParam); return DefWindowProc (hwnd, message, wParam, lParam); } WindowProcFunc windowProc; HWND window {nullptr}; HINSTANCE instance {nullptr}; ATOM windowClassAtom {0}; }; //------------------------------------------------------------------------ struct NonClientMetrics { static const NONCLIENTMETRICS& get () { static NonClientMetrics gInstance; return gInstance.nonClientMetrics; } private: NonClientMetrics () { nonClientMetrics.cbSize = sizeof (nonClientMetrics); SystemParametersInfoForDpi (SPI_GETNONCLIENTMETRICS, nonClientMetrics.cbSize, &nonClientMetrics, 0, 96); } NONCLIENTMETRICS nonClientMetrics {}; }; //------------------------------------------------------------------------ struct ExternalHWNDBase : ViewAdapter { using Base = ExternalHWNDBase; using PlatformViewType = ExternalView::PlatformViewType; using IntRect = ExternalView::IntRect; HWNDWindow container; HWND child {nullptr}; ExternalHWNDBase (HINSTANCE hInst) : container (hInst) { container.create (nullptr, {{0, 0}, {1, 1}}, HWND_MESSAGE, WS_EX_NOPARENTNOTIFY | WS_EX_COMPOSITED, WS_CHILD | WS_VISIBLE); } virtual ~ExternalHWNDBase () noexcept { if (child) DestroyWindow (child); } bool platformViewTypeSupported (PlatformViewType type) override { return type == PlatformViewType::HWND; } bool attach (void* parent, PlatformViewType parentViewType) override { assert (container.getHWND ()); if (parent == nullptr || parentViewType != PlatformViewType::HWND) return false; auto parentHWND = reinterpret_cast (parent); SetParent (container.getHWND (), parentHWND); return true; } bool remove () override { assert (container.getHWND ()); SetParent (container.getHWND (), HWND_MESSAGE); return true; } void setViewSize (IntRect frame, IntRect visible) override { assert (container.getHWND ()); container.setSize (visible); if (child) { frame.origin.x -= visible.origin.x; frame.origin.y -= visible.origin.y; setWindowSize (child, frame); } } void setContentScaleFactor (double scaleFactor) override {} void setMouseEnabled (bool state) override { EnableWindow (container.getHWND (), state); } void takeFocus () override { SetFocus (child); } void looseFocus () override { if (GetFocus () == child) { SetFocus (GetParent (container.getHWND ())); } } }; //------------------------------------------------------------------------ } // ExternalView } // VSTGUI vst3sdk-3.7.10.14+~4.13.3/vstgui/contrib/externalview_metal.h000066400000000000000000000174201461511344400234060ustar00rootroot00000000000000// This file is part of VSTGUI. It is subject to the license terms // in the LICENSE file found in the top-level directory of this // distribution and at http://github.com/steinbergmedia/vstgui/LICENSE #pragma once #import "externalview_nsview.h" #import #import #import #import //------------------------------------------------------------------------ using VSTGUIMetalLayerDelegateDrawCallback = std::function; using VSTGUIMetalViewScreenChangedCallack = std::function; @interface NSObject () - (void)setDrawCallback:(const VSTGUIMetalLayerDelegateDrawCallback&)callback; - (void)setScreenChangedCallback:(const VSTGUIMetalViewScreenChangedCallack&)callback; @end //------------------------------------------------------------------------ namespace VSTGUI { namespace ExternalView { //------------------------------------------------------------------------ struct IMetalView { virtual ~IMetalView () noexcept = default; virtual void render () = 0; }; //------------------------------------------------------------------------ /** metal render interface to be used as the renderer of the MetalView * * The renderer has to set the metal device of the metal layer before it can draw to it. */ struct IMetalRenderer { virtual ~IMetalRenderer () noexcept = default; virtual bool init (IMetalView* metalView, CAMetalLayer* metalLayer) = 0; virtual void draw (id drawable) = 0; virtual void onSizeUpdate (int32_t width, int32_t height, double scaleFactor) = 0; virtual void onAttached () = 0; virtual void onRemoved () = 0; virtual void onScreenChanged (NSScreen* screen) = 0; }; using MetalRendererPtr = std::shared_ptr; //------------------------------------------------------------------------ struct MetalLayerDelegate : RuntimeObjCClass { static constexpr auto CallbackVarName = "callback"; static Class CreateClass () { return ObjCClassBuilder () .init ("MetalLayerDelegate", [NSObject class]) .addMethod (@selector (displayLayer:), displayLayer) .addMethod (@selector (actionForLayer:forKey:), actionForLayer) .addMethod (@selector (setDrawCallback:), setCallback) .addProtocol ("CALayerDelegate") .addIvar (CallbackVarName) .finalize (); } static void setCallback (id self, SEL cmd, VSTGUIMetalLayerDelegateDrawCallback callback) { auto instance = makeInstance (self); if (auto var = instance.getVariable (CallbackVarName)) var->set (callback); } static void displayLayer (id self, SEL cmd, CALayer* layer) { auto instance = makeInstance (self); if (auto var = instance.getVariable (CallbackVarName)) { if (auto callback = var->get ()) callback (); } } static id actionForLayer (CALayer* layer, NSString* key) { return [NSNull null]; } }; //------------------------------------------------------------------------ struct MetalNSView : RuntimeObjCClass { static constexpr auto CallbackVarName = "callback"; static Class CreateClass () { return ObjCClassBuilder () .init ("MetalNSView", [NSView class]) .addIvar (CallbackVarName) .addMethod (@selector (viewDidMoveToWindow), viewDidMoveToWindow) .addMethod (@selector (viewWillMoveToWindow:), viewWillMoveToWindow) .addMethod (@selector (windowDidChangeScreen:), windowDidChangeScreen) .addMethod (@selector (setScreenChangedCallback:), setCallback) .finalize (); } static void setCallback (id self, SEL cmd, VSTGUIMetalViewScreenChangedCallack callback) { auto instance = makeInstance (self); if (auto var = instance.getVariable (CallbackVarName)) var->set (callback); } static void viewDidMoveToWindow (id self, SEL cmd) { windowDidChangeScreen (self, cmd, nullptr); makeInstance (self).callSuper (cmd); } static void viewWillMoveToWindow (id self, SEL cmd, NSWindow* window) { if (auto prevWindow = [self window]) { [NSNotificationCenter.defaultCenter removeObserver:self]; } if (window) { [NSNotificationCenter.defaultCenter addObserver:self selector:@selector (windowDidChangeScreen:) name:NSWindowDidChangeScreenNotification object:window]; } makeInstance (self).callSuper (cmd, window); } static void windowDidChangeScreen (id self, SEL cmd, NSNotification* n) { if (NSScreen* screen = [[self window] screen]) { auto instance = makeInstance (self); if (auto var = instance.getVariable (CallbackVarName)) { if (auto callback = var->get ()) callback (screen); } } } }; //------------------------------------------------------------------------ struct MetalView : ExternalNSViewBase, IMetalView { /** make a new metal view. * * The metal view can render on a background thread (only use one thread for rendering) or on * the main thread. * Rendering and view resizing is automatically guarded by a mutex. * The view will automatically trigger a rendering when the view is resized. */ static std::shared_ptr make (const MetalRendererPtr& renderer) { if (!renderer) return {}; if (auto metalView = std::shared_ptr (new MetalView (renderer))) { if (renderer->init (metalView.get (), metalView->metalLayer)) return metalView; } return {}; } /** immediately render the view [thread safe] */ void render () override { doLocked ([&] () { renderer->draw (metalLayer.nextDrawable); }); } /** do something locked [thread safe] */ template void doLocked (Proc proc) { LockGuard g (mutex); @autoreleasepool { proc (); } } private: CAMetalLayer* metalLayer {nullptr}; id metalLayerDelegate {nullptr}; double contentScaleFactor {1.}; using Mutex = std::recursive_mutex; using LockGuard = std::lock_guard; Mutex mutex; MetalRendererPtr renderer; MetalView (const MetalRendererPtr& renderer) : Base ([MetalNSView::alloc () init]), renderer (renderer) { metalLayerDelegate = [MetalLayerDelegate::alloc () init]; metalLayer = [CAMetalLayer new]; metalLayer.delegate = metalLayerDelegate; view.layer = metalLayer; metalLayer.needsDisplayOnBoundsChange = YES; metalLayer.geometryFlipped = YES; metalLayer.opaque = NO; metalLayer.contentsGravity = kCAGravityBottomLeft; [metalLayerDelegate setDrawCallback:[this] () { render (); }]; [view setScreenChangedCallback:[this] (NSScreen* screen) { this->renderer->onScreenChanged (screen); }]; } bool attach (void* parent, PlatformViewType parentViewType) override { if (Base::attach (parent, parentViewType)) { renderer->onAttached (); return true; } return false; } bool remove () override { if (Base::remove ()) { renderer->onRemoved (); return true; } return false; } void setContentScaleFactor (double scaleFactor) override { contentScaleFactor = scaleFactor; metalLayer.contentsScale = scaleFactor; [metalLayer setNeedsDisplay]; onSizeUpdate (); } void setViewSize (IntRect frame, IntRect visible) override { Base::setViewSize (frame, visible); onSizeUpdate (); } void onSizeUpdate () { doLocked ([this] () { auto size = view.frame.size; metalLayer.drawableSize = NSMakeSize (size.width * contentScaleFactor, size.height * contentScaleFactor); renderer->onSizeUpdate (size.width, size.height, contentScaleFactor); }); } #if !__has_feature(objc_arc) public: ~MetalView () noexcept override { [metalLayerDelegate release]; [metalLayer release]; } #endif }; //------------------------------------------------------------------------ } // ExternalView } // VSTGUI vst3sdk-3.7.10.14+~4.13.3/vstgui/contrib/externalview_nsview.h000066400000000000000000000161621461511344400236210ustar00rootroot00000000000000// This file is part of VSTGUI. It is subject to the license terms // in the LICENSE file found in the top-level directory of this // distribution and at http://github.com/steinbergmedia/vstgui/LICENSE #pragma once #import "../lib/platform/mac/cocoa/objcclassbuilder.h" #import "../lib/iexternalview.h" #import //------------------------------------------------------------------------ namespace VSTGUI { namespace ExternalView { //------------------------------------------------------------------------ inline NSRect toNSRect (const IntRect& r) { return NSMakeRect (r.origin.x, r.origin.y, r.size.width, r.size.height); } //------------------------------------------------------------------------ /** a NSView that has a flipped coordinate system (top-left is {0, 0}, not AppKits default which is * bottom-left) * * to create it call [ExternalViewContainerNSView::alloc () initWithFrame: rect] */ struct ExternalViewContainerNSView : RuntimeObjCClass { static constexpr auto TookFocusCallbackVarName = "TookFocusCallback"; static Class CreateClass () { return ObjCClassBuilder () .init ("ExternalViewContainerNSView", [NSView class]) .addMethod (@selector (isFlipped), isFlipped) .addMethod (@selector (viewWillMoveToWindow:), viewWillMoveToWindow) .addMethod (@selector (observeValueForKeyPath:ofObject:change:context:), observeValueForKeyPath) .addIvar (TookFocusCallbackVarName) .finalize (); } static BOOL isFlipped (id self, SEL cmd) { return YES; } static void viewWillMoveToWindow (id self, SEL _cmd, NSWindow* window) { if ([self window] && [self window] != window) { [[self window] removeObserver:self forKeyPath:@"firstResponder"]; } if (window) { [window addObserver:self forKeyPath:@"firstResponder" options:0 context:nullptr]; } } static void observeValueForKeyPath (id self, SEL cmd, NSString* keyPath, id object, NSDictionary* change, void* context) { if ([keyPath isEqualToString:@"firstResponder"]) { auto view = [self window].firstResponder; if ([view isKindOfClass:[NSView class]] && [static_cast (view) isDescendantOf:self]) { if (auto var = makeInstance (self).getVariable ( TookFocusCallbackVarName)) { if (var.value ().get ()) var.value ().get () (); } } } } }; //------------------------------------------------------------------------ /** a template helper class for embedding NSViews into VSTGUI via ExternalView::IView * * Example to add a simple NSView: * * // Header: ExampleNSView.h * * class ExampleNSView : IView * { * public: * ExampleNSView (); * ~ExampleNSView () noexcept; * * private: * bool platformViewTypeSupported (PlatformViewType type) override; * bool attach (void* parent, PlatformViewType parentViewType) override; * bool remove () override; * void setViewSize (IntRect frame, IntRect visible) override; * void setContentScaleFactor (double scaleFactor) override; * void setMouseEnabled (bool state) override; * void takeFocus () override; * void looseFocus () override; * * struct Impl; * std::unique_ptr impl; * }; * * // Source: ExampleNSView.mm * * #import "ExampleNSView.h" * #import "externalview_nsview.h" * * struct ExampleNSView::Impl : ExternalNSViewBase * { * Impl () : Base ([NSView new]) * { * // configure the view here * view.alphaValue = 0.5; * } * }; * * ExampleNSView::ExampleNSView () { impl = std::make_unique (); } * ExampleNSView::~ExampleNSView () noexcept = default; * bool ExampleNSView::platformViewTypeSupported (PlatformViewType type) * { * return impl->platformViewTypeSupported (type); * } * bool ExampleNSView::attach (void* parent, PlatformViewType parentViewType) * { * return impl->attach (parent, parentViewType); * } * bool ExampleNSView::remove () { return impl->remove (); } * void ExampleNSView::setViewSize (IntRect frame, IntRect visible) * { * impl->setViewSize (frame, visible); * } * void ExampleNSView::setContentScaleFactor (double scaleFactor) * { * impl->setContentScaleFactor (scaleFactor); * } * void ExampleNSView::setMouseEnabled (bool state) { impl->setMouseEnabled (state); } * void ExampleNSView::takeFocus () { impl->takeFocus (); } * void ExampleNSView::looseFocus () { impl->looseFocus (); } * */ template struct ExternalNSViewBase : ViewAdapter { using Base = ExternalNSViewBase; using PlatformViewType = ExternalView::PlatformViewType; using IntRect = ExternalView::IntRect; NSView* container {[ExternalViewContainerNSView::alloc () initWithFrame: {0., 0., 10., 10.}]}; ViewType* view {nullptr}; ExternalNSViewBase (ViewType* inView) : view (inView) { if (@available (macOS 14, *)) { #ifdef MAC_OS_VERSION_14_0 // only available when building with the mac os sdk 14.0 container.clipsToBounds = YES; #else // but necessary to set to YES on macOS 14 even when not building with Xcode 15 if ([container respondsToSelector:@selector (setClipsToBounds:)]) { BOOL clipsToBounds = YES; auto* signature = [[container class] instanceMethodSignatureForSelector:@selector (setClipsToBounds:)]; auto* invocation = [NSInvocation invocationWithMethodSignature:signature]; invocation.target = container; invocation.selector = @selector (setClipsToBounds:); [invocation setArgument:&clipsToBounds atIndex:2]; [invocation invoke]; } #endif } [container addSubview:view]; } #if !__has_feature(objc_arc) virtual ~ExternalNSViewBase () noexcept { [container release]; [view release]; } #endif bool platformViewTypeSupported (PlatformViewType type) override { return type == PlatformViewType::NSView; } bool attach (void* parent, PlatformViewType parentViewType) override { if (!parent || parentViewType != PlatformViewType::NSView) return false; auto parentNSView = (__bridge NSView*)parent; [parentNSView addSubview:container]; return true; } bool remove () override { [container removeFromSuperview]; return true; } void setViewSize (IntRect frame, IntRect visible) override { container.frame = toNSRect (visible); frame.origin.x -= visible.origin.x; frame.origin.y -= visible.origin.y; view.frame = toNSRect (frame); } void setContentScaleFactor (double scaleFactor) override {} void setMouseEnabled (bool state) override { if ([view respondsToSelector:@selector (setEnabled:)]) [(id)view setEnabled:state]; } void takeFocus () override { if (view.acceptsFirstResponder) { if (auto window = view.window) [window makeFirstResponder:view]; } } void looseFocus () override { if (auto window = view.window) [window makeFirstResponder:container.superview]; } void setTookFocusCallback (const TookFocusCallback& callback) override { if (auto var = ObjCInstance (container).getVariable ( ExternalViewContainerNSView::TookFocusCallbackVarName)) { var->set (callback); } } }; //------------------------------------------------------------------------ } // ExternalView } // VSTGUI vst3sdk-3.7.10.14+~4.13.3/vstgui/contrib/keyboardview.cpp000066400000000000000000001227151461511344400225410ustar00rootroot00000000000000//------------------------------------------------------------------------ // This file is part of VSTGUI. It is subject to the license terms // in the LICENSE file found in the top-level directory of this // distribution and at http://github.com/steinbergmedia/vstgui/LICENSE // Flags : clang-format SMTGSequencer #include "keyboardview.h" #include "vstgui/lib/cbitmap.h" #include "vstgui/lib/coffscreencontext.h" #include "vstgui/uidescription/detail/uiviewcreatorattributes.h" #include "vstgui/uidescription/iviewcreator.h" #include "vstgui/uidescription/uiattributes.h" #include "vstgui/uidescription/uiviewcreator.h" #include "vstgui/uidescription/uiviewfactory.h" #include //------------------------------------------------------------------------ namespace VSTGUI { //------------------------------------------------------------------------ KeyboardView::KeyboardView () { setDrawNoteText (true); } //------------------------------------------------------------------------ double KeyboardView::calcYParameter (NoteIndex note, CCoord y) const { if (note == -1) return 0.f; y -= getViewSize ().top; auto r = getNoteRect (note); return y / r.getHeight (); } //------------------------------------------------------------------------ double KeyboardView::calcXParameter (NoteIndex note, CCoord x) const { if (note == -1) return 0.f; auto r = getNoteRect (note); x -= r.left; return x / r.getWidth (); } #if VSTGUI_TOUCH_EVENT_HANDLING //------------------------------------------------------------------------ void KeyboardView::onTouchEvent (ITouchEvent& event) { for (auto touch : event) { if (touch.second.target != 0 && touch.second.target != this) continue; switch (touch.second.state) { case ITouchEvent::kBegan: { onTouchBegin (touch, event); break; } case ITouchEvent::kMoved: { if (touch.second.target == this) { onTouchMove (touch, event); } break; } case ITouchEvent::kCanceled: case ITouchEvent::kEnded: { if (touch.second.target == this) { onTouchEnd (touch, event); } break; } case ITouchEvent::kNoChange: case ITouchEvent::kUndefined: break; } } } //------------------------------------------------------------------------ void KeyboardView::onTouchBegin (const ITouchEvent::TouchPair& touch, ITouchEvent& event) { CPoint where (touch.second.location); frameToLocal (where); auto note = pointToNote (where, false); if (note >= 0) { for (auto nt : noteTouches) { if (nt.second.note == note) { // currently no multiple touches for the same note return; } } // TODO: velocity NoteTouch noteTouch (note); event.setTouchTarget (touch.first, this, false); setKeyPressed (note, true); if (delegate) noteTouch.noteID = delegate->onNoteOn (note, calcXParameter (note, where.x), calcYParameter (note, where.y)); noteTouches.insert (std::pair (touch.first, noteTouch)); } } //------------------------------------------------------------------------ void KeyboardView::onTouchMove (const ITouchEvent::TouchPair& touch, ITouchEvent& event) { CPoint where (touch.second.location); frameToLocal (where); auto note = pointToNote (where, false); auto noteTouch = noteTouches.find (touch.first); if (noteTouch != noteTouches.end ()) { if (note != noteTouch->second.note) { auto noteOff = noteTouch->second.note; auto noteOffID = noteTouch->second.noteID; setKeyPressed (noteTouch->second.note, false); if (note >= 0) { noteTouch->second.note = note; setKeyPressed (noteTouch->second.note, true); if (delegate) noteTouch->second.noteID = delegate->onNoteOn ( note, calcXParameter (note, where.x), calcYParameter (note, where.y)); } else { noteTouches.erase (noteTouch); } if (delegate) delegate->onNoteOff (noteOff, noteOffID); } else if (note == noteTouch->second.note) { if (delegate) { delegate->onNoteModulation (noteTouch->second.noteID, calcXParameter (note, where.x), calcYParameter (note, where.y)); } } } } //------------------------------------------------------------------------ void KeyboardView::onTouchEnd (const ITouchEvent::TouchPair& touch, ITouchEvent& event) { event.unsetTouchTarget (touch.first, this); auto noteTouch = noteTouches.find (touch.first); if (noteTouch != noteTouches.end ()) { setKeyPressed (noteTouch->second.note, false); if (delegate) delegate->onNoteOff (noteTouch->second.note, noteTouch->second.noteID); noteTouches.erase (noteTouch); } } #else //------------------------------------------------------------------------ void KeyboardView::doNoteOff () { if (pressedNote != -1) { if (delegate) delegate->onNoteOff (pressedNote, noteID); else setKeyPressed (pressedNote, false); noteID = -1; pressedNote = -1; } } //------------------------------------------------------------------------ void KeyboardView::doNoteOn (int16_t note, double yPos, double xPos) { pressedNote = note; if (pressedNote != -1) { if (delegate) noteID = delegate->onNoteOn (pressedNote, yPos, xPos); else setKeyPressed (pressedNote, true); } } //------------------------------------------------------------------------ CMouseEventResult KeyboardView::onMouseDown (CPoint& where, const CButtonState& buttons) { if (buttons.isLeftButton ()) { auto note = pointToNote (where, false); if (note != -1) { doNoteOn (note, calcXParameter (note, where.x), calcYParameter (note, where.y)); } return kMouseEventHandled; } return kMouseEventNotHandled; } //------------------------------------------------------------------------ CMouseEventResult KeyboardView::onMouseMoved (CPoint& where, const CButtonState& buttons) { if (buttons.isLeftButton ()) { auto note = pointToNote (where, false); if (note == pressedNote) { if (delegate) { delegate->onNoteModulation (noteID, calcXParameter (note, where.x), calcYParameter (note, where.y)); } } else { doNoteOff (); doNoteOn (note, calcXParameter (note, where.x), calcYParameter (note, where.y)); } } return kMouseEventHandled; } //------------------------------------------------------------------------ CMouseEventResult KeyboardView::onMouseUp (CPoint& where, const CButtonState& buttons) { if (buttons.isLeftButton ()) { doNoteOff (); return kMouseEventHandled; } return kMouseEventNotHandled; } //------------------------------------------------------------------------ CMouseEventResult KeyboardView::onMouseCancel () { doNoteOff (); return kMouseEventHandled; } #endif //------------------------------------------------------------------------ void KeyboardViewRangeSelector::registerKeyRangeChangedListener ( IKeyboardViewKeyRangeChangedListener* listener) { listeners.add (listener); } //------------------------------------------------------------------------ void KeyboardViewRangeSelector::unregisterKeyRangeChangedListener ( IKeyboardViewKeyRangeChangedListener* listener) { listeners.remove (listener); } //------------------------------------------------------------------------ void KeyboardViewRangeSelector::drawRect (CDrawContext* context, const CRect& dirtyRect) { KeyboardViewBase::drawRect (context, dirtyRect); auto r1 = getNoteRect (selectionRange.position); auto r2 = getNoteRect (selectionRange.position + selectionRange.length); r1.offset (-r1.getWidth (), 0); r2.offset (r2.getWidth (), 0); r1.left = getViewSize ().left; r2.right = getViewSize ().right; r1.bottom = getViewSize ().bottom; r2.bottom = getViewSize ().bottom; context->setFillColor (CColor (0, 0, 0, 110)); if (!r1.isEmpty ()) context->drawRect (r1, kDrawFilled); if (!r2.isEmpty ()) context->drawRect (r2, kDrawFilled); } //------------------------------------------------------------------------ void KeyboardViewRangeSelector::setKeyRange (NoteIndex startNote, NumNotes numKeys) { KeyboardViewBase::setKeyRange (startNote, numKeys); if (selectionRange.position < getKeyRangeStart ()) selectionRange.position = getKeyRangeStart (); } //------------------------------------------------------------------------ void KeyboardViewRangeSelector::setSelectionRange (const Range& _range) { if (selectionRange != _range) { selectionRange = _range; invalid (); listeners.forEach ([this] (auto& listener) { listener->onKeyRangeChanged (this); }); } } //------------------------------------------------------------------------ void KeyboardViewRangeSelector::setSelectionMinMax (NumNotes minRange, NumNotes maxRange) { rangeMin = minRange; rangeMax = maxRange; } //------------------------------------------------------------------------ auto KeyboardViewRangeSelector::getNumWhiteKeysSelected () const -> NumNotes { NumNotes whiteKeys = 0; for (auto i = selectionRange.position; i <= selectionRange.position + selectionRange.length; ++i) { if (isWhiteKey (i)) whiteKeys++; } return whiteKeys; } #if VSTGUI_TOUCH_EVENT_HANDLING //------------------------------------------------------------------------ void KeyboardViewRangeSelector::onTouchBegin (const ITouchEvent::TouchPair& touch, ITouchEvent& event) { CPoint where (touch.second.location); frameToLocal (where); auto note = pointToNote (where, false); if (note >= 0) { if (touchIds[0] == -1) { if (note <= selectionRange.position || note > selectionRange.position + selectionRange.length) { touchIds[0] = touch.first; touchStartNote[0] = note; touchMode = note <= selectionRange.position ? kChangeRangeFront : kChangeRangeBack; event.setTouchTarget (touch.first, this, false); selectionRangeOnTouchStart = selectionRange; } else if (note > selectionRange.position && note < selectionRange.position + selectionRange.length) { touchIds[0] = touch.first; touchStartNote[0] = note; touchMode = kMoveRange; event.setTouchTarget (touch.first, this, false); selectionRangeOnTouchStart = selectionRange; } } else { if (touchMode != kMoveRange) { } else if (note > touchStartNote[0]) { touchIds[1] = touch.first; touchStartNote[1] = note; event.setTouchTarget (touch.first, this, false); touchMode = kChangeRangeFront; } } } } //------------------------------------------------------------------------ static int32_t bound (int32_t value, int32_t min, int32_t max) { if (value < min) value = min; else if (value > max) value = max; return value; } //------------------------------------------------------------------------ void KeyboardViewRangeSelector::onTouchMove (const ITouchEvent::TouchPair& touch, ITouchEvent& event) { CPoint where (touch.second.location); frameToLocal (where); auto note = pointToNote (where, true); if (touchIds[0] == touch.first) { if (touchMode == kMoveRange || touchMode == kChangeRangeFront) { if (note >= 0) { auto move = note - touchStartNote[0]; auto newRangeStart = bound (selectionRangeOnTouchStart.position + move, getKeyRangeStart (), (getKeyRangeStart () + getNumKeys ()) - selectionRange.length); if (!isWhiteKey (newRangeStart)) newRangeStart++; auto length = selectionRange.length; if (touchMode == kChangeRangeFront) { length = selectionRange.length + (selectionRange.position - newRangeStart); if (length < rangeMin || length > rangeMax) return; } setSelectionRange (Range (newRangeStart, length)); } } else if (touchMode == kChangeRangeBack) { if (note >= 0) { auto move = note - touchStartNote[0]; auto length = selectionRangeOnTouchStart.length + move; if (!isWhiteKey (selectionRange.position + length)) length++; if (length < rangeMin || length > rangeMax) return; setSelectionRange (Range (selectionRange.position, length)); } } } else { } } //------------------------------------------------------------------------ void KeyboardViewRangeSelector::onTouchEvent (ITouchEvent& event) { for (auto touch : event) { if (touch.second.target != 0 && touch.second.target != this) continue; switch (touch.second.state) { case ITouchEvent::kBegan: { if (touchIds[0] != -1 && touchIds[1] != -1) continue; onTouchBegin (touch, event); break; } case ITouchEvent::kCanceled: case ITouchEvent::kEnded: { if (touch.second.target == this) { if (touchIds[0] == touch.first) { touchIds[0] = -1; } else { touchIds[1] = -1; } event.unsetTouchTarget (touch.first, this); } break; } case ITouchEvent::kMoved: { if (touch.second.target == this) { onTouchMove (touch, event); } break; } case ITouchEvent::kNoChange: case ITouchEvent::kUndefined: break; } } } //------------------------------------------------------------------------ bool KeyboardViewRangeSelector::wantsMultiTouchEvents () const { return true; } #else //------------------------------------------------------------------------ CMouseEventResult KeyboardViewRangeSelector::onMouseDown (CPoint& where, const CButtonState& buttons) { if (buttons.isLeftButton ()) { moveStartRange = selectionRange; moveStartNote = pointToNote (where, true); if (moveStartNote < selectionRange.position || moveStartNote >= selectionRange.position + selectionRange.length) { auto middle = selectionRange.length / 2; if (moveStartNote < middle) moveStartRange.position = 0; else moveStartRange.position = moveStartNote - middle; return onMouseMoved (where, buttons); } return kMouseEventHandled; } return kMouseEventNotHandled; } //------------------------------------------------------------------------ CMouseEventResult KeyboardViewRangeSelector::onMouseMoved (CPoint& where, const CButtonState& buttons) { if (buttons.isLeftButton () && moveStartNote != -1) { auto note = pointToNote (where, true); if (note != -1) { auto offset = note - moveStartNote; Range r = moveStartRange; if (static_cast (r.position) + offset < 0) r.position = 0; else if (static_cast (r.position + r.length) + offset >= MaxNotes) r.position = (MaxNotes - 1) - r.length; else r.position += offset; setSelectionRange (r); } } return kMouseEventHandled; } //------------------------------------------------------------------------ CMouseEventResult KeyboardViewRangeSelector::onMouseUp (CPoint& where, const CButtonState& buttons) { if (buttons.isLeftButton ()) moveStartNote = -1; return kMouseEventHandled; } //------------------------------------------------------------------------ CMouseEventResult KeyboardViewRangeSelector::onMouseCancel () { moveStartNote = -1; return kMouseEventHandled; } #endif //------------------------------------------------------------------------ //------------------------------------------------------------------------ //------------------------------------------------------------------------ KeyboardViewBase::KeyboardViewBase () : CView (CRect (0, 0, 0, 0)), noteNameFont (kSystemFont) { } //------------------------------------------------------------------------ void KeyboardViewBase::setViewSize (const CRect& rect, bool invalid) { CView::setViewSize (rect, invalid); noteRectCacheInvalid = true; } //------------------------------------------------------------------------ bool KeyboardViewBase::sizeToFit () { if (noteRectCacheInvalid) updateNoteRectCache (); auto r = getNoteRect (startNote + numKeys - 1); r.setWidth (r.right); r.setHeight (getViewSize ().getHeight ()); r.originize (); setViewSize (r); setMouseableArea (r); return true; } //------------------------------------------------------------------------ auto KeyboardViewBase::getNumWhiteKeys () const -> NumNotes { NumNotes whiteKeys = 0; for (NoteIndex i = startNote; i <= startNote + numKeys; ++i) { if (isWhiteKey (i)) whiteKeys++; } return whiteKeys; } //------------------------------------------------------------------------ void KeyboardViewBase::setKeyRange (NoteIndex _startNote, NumNotes _numKeys) { vstgui_assert (_startNote >= 0 && _numKeys >= 0); if (_startNote < 0 || _numKeys < 0) return; if (static_cast (_numKeys) + static_cast (_startNote) >= static_cast (MaxNotes)) { _numKeys = (MaxNotes - 1) - _startNote; } startNote = _startNote; numKeys = _numKeys; noteRectCacheInvalid = true; invalid (); } //------------------------------------------------------------------------ void KeyboardViewBase::setNoteNameFont (CFontDesc* font) { if (font != noteNameFont) { noteNameFont = font; if (drawNoteText) invalid (); } } //------------------------------------------------------------------------ void KeyboardViewBase::setDrawNoteText (bool state) { if (state != drawNoteText) { drawNoteText = state; invalid (); } } //------------------------------------------------------------------------ void KeyboardViewBase::setWhiteKeyWidth (CCoord width) { if (whiteKeyWidth != width) { whiteKeyWidth = width; whiteKeyBitmapCache = nullptr; noteRectCacheInvalid = true; invalid (); } } //------------------------------------------------------------------------ void KeyboardViewBase::setBlackKeyWidth (CCoord width) { if (blackKeyWidth != width) { blackKeyWidth = width; blackKeyBitmapCache = nullptr; noteRectCacheInvalid = true; invalid (); } } //------------------------------------------------------------------------ void KeyboardViewBase::setBlackKeyHeight (CCoord height) { if (blackKeyHeight != height) { blackKeyHeight = height; noteRectCacheInvalid = true; invalid (); } } //------------------------------------------------------------------------ void KeyboardViewBase::setLineWidth (CCoord width) { if (lineWidth != width) { lineWidth = width; invalid (); } } //------------------------------------------------------------------------ void KeyboardViewBase::setFrameColor (CColor color) { if (frameColor != color) { frameColor = color; invalid (); } } //------------------------------------------------------------------------ void KeyboardViewBase::setFontColor (CColor color) { if (fontColor != color) { fontColor = color; invalid (); } } //------------------------------------------------------------------------ void KeyboardViewBase::setWhiteKeyColor (CColor color) { if (whiteKeyColor != color) { whiteKeyColor = color; invalid (); } } //------------------------------------------------------------------------ void KeyboardViewBase::setWhiteKeyPressedColor (CColor color) { if (whiteKeyPressedColor != color) { whiteKeyPressedColor = color; invalid (); } } //------------------------------------------------------------------------ void KeyboardViewBase::setBlackKeyColor (CColor color) { if (blackKeyColor != color) { blackKeyColor = color; invalid (); } } //------------------------------------------------------------------------ void KeyboardViewBase::setBlackKeyPressedColor (CColor color) { if (blackKeyPressedColor != color) { blackKeyPressedColor = color; invalid (); } } //------------------------------------------------------------------------ void KeyboardViewBase::createBitmapCache () { auto whiteKeyBitmap = getBitmap (BitmapID::WhiteKeyUnpressed); auto blackKeyBitmap = getBitmap (BitmapID::BlackKeyUnpressed); if (!whiteKeyBitmap || !blackKeyBitmap) return; #if ((VSTGUI_VERSION_MAJOR == 4 && VSTGUI_VERSION_MINOR > 9) || (VSTGUI_VERSION_MAJOR > 4)) if (auto offscreen = COffscreenContext::create (CPoint (whiteKeyWidth, getHeight ()))) #else if (auto offscreen = COffscreenContext::create (getFrame (), whiteKeyWidth, getHeight ())) #endif { offscreen->beginDraw (); CRect r (0, 0, whiteKeyWidth, getHeight ()); r.left -= whiteKeyBitmapInset.left; r.right += whiteKeyBitmapInset.right; r.top -= whiteKeyBitmapInset.top; r.bottom += whiteKeyBitmapInset.bottom; whiteKeyBitmap->draw (offscreen, r); offscreen->endDraw (); whiteKeyBitmapCache = offscreen->getBitmap (); } #if ((VSTGUI_VERSION_MAJOR == 4 && VSTGUI_VERSION_MINOR > 9) || (VSTGUI_VERSION_MAJOR > 4)) if (auto offscreen = COffscreenContext::create (CPoint (blackKeyWidth, blackKeyHeight))) #else if (auto offscreen = COffscreenContext::create (getFrame (), blackKeyWidth, blackKeyHeight)) #endif { offscreen->beginDraw (); CRect r (0, 0, blackKeyWidth, blackKeyHeight); r.left -= blackKeyBitmapInset.left; r.right += blackKeyBitmapInset.right; r.top -= blackKeyBitmapInset.top; r.bottom += blackKeyBitmapInset.bottom; blackKeyBitmap->draw (offscreen, r); offscreen->endDraw (); blackKeyBitmapCache = offscreen->getBitmap (); } } //------------------------------------------------------------------------ void KeyboardViewBase::drawRect (CDrawContext* context, const CRect& dirtyRect) { if (noteRectCacheInvalid) updateNoteRectCache (); if (whiteKeyBitmapCache == nullptr || blackKeyBitmapCache == nullptr) createBitmapCache (); context->setLineWidth (lineWidth == -1 ? context->getHairlineSize () : lineWidth); context->setFrameColor (frameColor); context->setFontColor (fontColor); context->setFont (noteNameFont); context->setDrawMode (kAntiAliasing | kNonIntegralMode); for (NoteIndex i = startNote; i <= startNote + numKeys; i++) { if (isWhiteKey (i) == false) continue; CRect r = getNoteRect (i); if (dirtyRect.rectOverlap (r) == false) continue; drawNote (context, r, i, true); if (drawNoteText && i % 12 == 0) { char text[5]; snprintf (text, 4, "C%d", (i / 12) - 2); r.top = r.bottom - context->getFont ()->getSize () - 10; context->drawString (text, r); } } for (NoteIndex i = startNote; i <= startNote + numKeys; i++) { if (isWhiteKey (i) == true) continue; CRect r = getNoteRect (i); if (dirtyRect.rectOverlap (r) == false) continue; drawNote (context, r, i, false); } } //------------------------------------------------------------------------ void KeyboardViewBase::drawNote (CDrawContext* context, CRect& rect, NoteIndex note, bool isWhite) const { CBitmap* keyBitmap = nullptr; CRect bitmapRect (rect); if (isWhite) { bitmapRect.left -= whiteKeyBitmapInset.left; bitmapRect.right += whiteKeyBitmapInset.right; bitmapRect.top -= whiteKeyBitmapInset.top; bitmapRect.bottom += whiteKeyBitmapInset.bottom; } else { bitmapRect.left -= blackKeyBitmapInset.left; bitmapRect.right += blackKeyBitmapInset.right; bitmapRect.top -= blackKeyBitmapInset.top; bitmapRect.bottom += blackKeyBitmapInset.bottom; } if (keyPressed[note]) keyBitmap = getBitmap (isWhite ? BitmapID::WhiteKeyPressed : BitmapID::BlackKeyPressed); else { if (isWhite) { if (whiteKeyBitmapCache && whiteKeyBitmapCache->getWidth () == bitmapRect.getWidth () && whiteKeyBitmapCache->getHeight () == bitmapRect.getHeight ()) keyBitmap = whiteKeyBitmapCache; else keyBitmap = getBitmap (BitmapID::WhiteKeyUnpressed); } else { if (blackKeyBitmapCache && blackKeyBitmapCache->getWidth () == bitmapRect.getWidth () && blackKeyBitmapCache->getHeight () == bitmapRect.getHeight ()) keyBitmap = blackKeyBitmapCache; else keyBitmap = getBitmap (BitmapID::BlackKeyUnpressed); } } if (keyBitmap) { keyBitmap->draw (context, bitmapRect); } else { if (keyPressed[note]) context->setFillColor (isWhite ? whiteKeyPressedColor : blackKeyPressedColor); else context->setFillColor (isWhite ? whiteKeyColor : blackKeyColor); context->drawRect (rect, isWhite ? kDrawFilledAndStroked : kDrawFilled); } if (keyPressed[note] && isWhite) { NoteIndex otherNote; if (note > startNote) { otherNote = note - 1; if (!isWhiteKey (otherNote)) otherNote--; if (keyPressed[otherNote] == false) { if (auto b = getBitmap (BitmapID::WhiteKeyShadowLeft)) { b->draw (context, bitmapRect); } } } if (note < startNote + numKeys) { otherNote = note + 1; if (!isWhiteKey (otherNote)) otherNote++; if (keyPressed[otherNote] == false) { if (auto b = getBitmap (BitmapID::WhiteKeyShadowRight)) { b->draw (context, bitmapRect); } } } } } //------------------------------------------------------------------------ CRect KeyboardViewBase::calcNoteRect (NoteIndex note) const { CRect result; if (note >= startNote && note <= startNote + numKeys) { for (NoteIndex i = startNote + 1; i <= note; i++) { bool isWhite = isWhiteKey (i); if (isWhite) { result.left += whiteKeyWidth; } } if (isWhiteKey (note)) { result.setWidth (whiteKeyWidth); result.setHeight (getViewSize ().getHeight ()); } else { result.left += whiteKeyWidth - blackKeyWidth / 2; result.setWidth (blackKeyWidth); result.setHeight (blackKeyHeight); } } result.offset (getViewSize ().left, getViewSize ().top); return result; } //------------------------------------------------------------------------ void KeyboardViewBase::updateNoteRectCache () const { for (NoteIndex i = 0; i < MaxNotes; ++i) noteRectCache[i] = calcNoteRect (i); CRect r = getNoteRect (startNote + numKeys); CCoord space = getViewSize ().right - r.right; if (space > 0) { space = fabs (space / 2.); for (NoteIndex i = startNote + 1; i <= startNote + numKeys; ++i) noteRectCache[i].offset (space, 0); noteRectCache[startNote].right += space; noteRectCache[startNote + numKeys].right = getViewSize ().right; } noteRectCacheInvalid = false; } //------------------------------------------------------------------------ auto KeyboardViewBase::pointToNote (const CPoint& p, bool ignoreY) const -> NoteIndex { if (noteRectCacheInvalid) updateNoteRectCache (); NoteIndex result = 0; for (auto r : getNoteRectCache ()) { if (!ignoreY) { if (r.pointInside (p)) { if (isWhiteKey (result)) { if (getNoteRect (result + 1).pointInside (p)) return result + 1; } return result; } } else if (p.x >= r.left && p.x < r.right) { if (isWhiteKey (result)) { auto r2 = getNoteRect (result + 1); if (p.x >= r2.left && p.x < r2.right) return result + 1; } return result; } result++; } return -1; } //------------------------------------------------------------------------ void KeyboardViewBase::invalidNote (NoteIndex note) { if (noteRectCacheInvalid) updateNoteRectCache (); invalidRect (getNoteRect (note)); } //------------------------------------------------------------------------ void KeyboardViewBase::setKeyPressed (NoteIndex note, bool state) { vstgui_assert (note >= 0); if (note < 0) return; if (keyPressed[note] != state) { keyPressed[note] = state; invalidNote (note); if (isWhiteKey (note)) { if (note > startNote) { NoteIndex prevKey = note - 1; if (!isWhiteKey (prevKey)) prevKey--; invalidNote (prevKey); } if (note < startNote + numKeys) { NoteIndex nextKey = note + 1; if (!isWhiteKey (nextKey)) nextKey++; invalidNote (nextKey); } } } } //------------------------------------------------------------------------ bool KeyboardViewBase::isWhiteKey (NoteIndex note) const { note = note % 12; return note == 0 || note == 2 || note == 4 || note == 5 || note == 7 || note == 9 || note == 11; } //------------------------------------------------------------------------ void KeyboardViewBase::setWhiteKeyBitmapInset (const CRect& inset) { whiteKeyBitmapInset = inset; } //------------------------------------------------------------------------ void KeyboardViewBase::setBlackKeyBitmapInset (const CRect& inset) { blackKeyBitmapInset = inset; } //------------------------------------------------------------------------ void KeyboardViewBase::setBitmap (BitmapID bID, CBitmap* bitmap) { bitmaps[static_cast (bID)] = bitmap; invalid (); } //------------------------------------------------------------------------ CBitmap* KeyboardViewBase::getBitmap (BitmapID bID) const { return bitmaps[static_cast (bID)]; } //------------------------------------------------------------------------ //------------------------------------------------------------------------ //------------------------------------------------------------------------ static const std::string kAttrWhiteKeyPressed = "white-key-pressed"; static const std::string kAttrWhiteKeyUnpressed = "white-key-unpressed"; static const std::string kAttrBlackKeyPressed = "black-key-pressed"; static const std::string kAttrBlackKeyUnpressed = "black-key-unpressed"; static const std::string kAttrWhiteKeyShadowLeft = "white-key-shadow-left"; static const std::string kAttrWhiteKeyShadowRight = "white-key-shadow-right"; static const std::string kAttrWhiteKeyWidth = "white-key-width"; static const std::string kAttrBlackKeyWidth = "black-key-width"; static const std::string kAttrBlackKeyHeight = "black-key-height"; static const std::string kAttrWhiteKeyColor = "white-key-color"; static const std::string kAttrWhiteKeyPressedColor = "white-key-pressed-color"; static const std::string kAttrBlackKeyColor = "black-key-color"; static const std::string kAttrBlackKeyPressedColor = "black-key-pressed-color"; static const std::string kAttrStartNote = "start-note"; static const std::string kAttrNumKeys = "num-keys"; static const std::string kAttrNoteNameFont = "note-name-font"; static const std::string kAttrDrawNoteText = "draw-note-text"; using UIViewCreator::stringToColor; using UIViewCreator::stringToBitmap; using UIViewCreator::bitmapToString; using UIViewCreator::colorToString; //----------------------------------------------------------------------------- class KeyboardViewBaseCreator : public ViewCreatorAdapter { public: using ViewType = KeyboardViewBase; IdStringPtr getBaseViewName () const override { return UIViewCreator::kCView; } bool getAttributeNames (std::list& attributeNames) const override { attributeNames.push_back (kAttrWhiteKeyPressed); attributeNames.push_back (kAttrWhiteKeyUnpressed); attributeNames.push_back (kAttrBlackKeyPressed); attributeNames.push_back (kAttrBlackKeyUnpressed); attributeNames.push_back (kAttrWhiteKeyShadowLeft); attributeNames.push_back (kAttrWhiteKeyShadowRight); attributeNames.push_back (kAttrWhiteKeyWidth); attributeNames.push_back (kAttrBlackKeyWidth); attributeNames.push_back (kAttrBlackKeyHeight); attributeNames.push_back (UIViewCreator::kAttrFrameColor); attributeNames.push_back (UIViewCreator::kAttrFontColor); attributeNames.push_back (kAttrWhiteKeyColor); attributeNames.push_back (kAttrWhiteKeyPressedColor); attributeNames.push_back (kAttrBlackKeyColor); attributeNames.push_back (kAttrBlackKeyPressedColor); attributeNames.push_back (UIViewCreator::kAttrFrameWidth); attributeNames.push_back (kAttrStartNote); attributeNames.push_back (kAttrNumKeys); attributeNames.push_back (kAttrDrawNoteText); attributeNames.push_back (kAttrNoteNameFont); return true; } AttrType getAttributeType (const std::string& attributeName) const override { auto bitmapID = attrNameToBitmapID (attributeName); if (bitmapID != ViewType::BitmapID::NumBitmaps) return kBitmapType; if (attributeName == kAttrWhiteKeyWidth) return kFloatType; if (attributeName == kAttrBlackKeyWidth) return kFloatType; if (attributeName == kAttrBlackKeyHeight) return kFloatType; if (attributeName == kAttrStartNote) return kIntegerType; if (attributeName == kAttrNumKeys) return kIntegerType; if (attributeName == kAttrDrawNoteText) return kBooleanType; if (attributeName == kAttrNoteNameFont) return kFontType; if (attributeName == UIViewCreator::kAttrFrameWidth) return kFloatType; if (attributeName == UIViewCreator::kAttrFrameColor) return kColorType; if (attributeName == UIViewCreator::kAttrFontColor) return kColorType; if (attributeName == kAttrWhiteKeyColor) return kColorType; if (attributeName == kAttrWhiteKeyPressedColor) return kColorType; if (attributeName == kAttrBlackKeyColor) return kColorType; if (attributeName == kAttrBlackKeyPressedColor) return kColorType; return kUnknownType; } bool getAttributeValue (CView* view, const std::string& attributeName, std::string& stringValue, const IUIDescription* desc) const override { auto kv = dynamic_cast (view); if (!kv) return false; auto bitmapID = attrNameToBitmapID (attributeName); if (bitmapID != ViewType::BitmapID::NumBitmaps) { stringValue = ""; if (auto bitmap = kv->getBitmap (bitmapID)) bitmapToString (bitmap, stringValue, desc); return true; } if (attributeName == UIViewCreator::kAttrFrameColor) { colorToString (kv->getFrameColor (), stringValue, desc); return true; } if (attributeName == UIViewCreator::kAttrFontColor) { colorToString (kv->getFontColor (), stringValue, desc); return true; } if (attributeName == kAttrWhiteKeyColor) { colorToString (kv->getWhiteKeyColor (), stringValue, desc); return true; } if (attributeName == kAttrWhiteKeyPressedColor) { colorToString (kv->getWhiteKeyPressedColor (), stringValue, desc); return true; } if (attributeName == kAttrBlackKeyColor) { colorToString (kv->getBlackKeyColor (), stringValue, desc); return true; } if (attributeName == kAttrBlackKeyPressedColor) { colorToString (kv->getBlackKeyPressedColor (), stringValue, desc); return true; } if (attributeName == kAttrWhiteKeyWidth) { stringValue = numberToString (kv->getWhiteKeyWidth ()); return true; } if (attributeName == kAttrBlackKeyWidth) { stringValue = numberToString (kv->getBlackKeyWidth ()); return true; } if (attributeName == kAttrBlackKeyHeight) { stringValue = numberToString (kv->getBlackKeyHeight ()); return true; } if (attributeName == kAttrStartNote) { stringValue = numberToString (kv->getKeyRangeStart ()); return true; } if (attributeName == kAttrNumKeys) { stringValue = numberToString (kv->getNumKeys ()); return true; } if (attributeName == UIViewCreator::kAttrFrameWidth) { stringValue = numberToString (kv->getLineWidth ()); return true; } if (attributeName == kAttrDrawNoteText) { stringValue = kv->getDrawNoteText () ? "true" : "false"; return true; } if (attributeName == kAttrNoteNameFont) { UTF8StringPtr fontName = desc->lookupFontName (kv->getNoteNameFont ()); if (fontName) { stringValue = fontName; return true; } return false; } return false; } bool apply (CView* view, const UIAttributes& attributes, const IUIDescription* desc) const override { auto kv = dynamic_cast (view); if (!kv) return false; CBitmap* bitmap; if (stringToBitmap (attributes.getAttributeValue (kAttrWhiteKeyPressed), bitmap, desc)) kv->setBitmap (ViewType::BitmapID::WhiteKeyPressed, bitmap); if (stringToBitmap (attributes.getAttributeValue (kAttrWhiteKeyUnpressed), bitmap, desc)) kv->setBitmap (ViewType::BitmapID::WhiteKeyUnpressed, bitmap); if (stringToBitmap (attributes.getAttributeValue (kAttrBlackKeyPressed), bitmap, desc)) kv->setBitmap (ViewType::BitmapID::BlackKeyPressed, bitmap); if (stringToBitmap (attributes.getAttributeValue (kAttrBlackKeyUnpressed), bitmap, desc)) kv->setBitmap (ViewType::BitmapID::BlackKeyUnpressed, bitmap); if (stringToBitmap (attributes.getAttributeValue (kAttrWhiteKeyShadowLeft), bitmap, desc)) kv->setBitmap (ViewType::BitmapID::WhiteKeyShadowLeft, bitmap); if (stringToBitmap (attributes.getAttributeValue (kAttrWhiteKeyShadowRight), bitmap, desc)) kv->setBitmap (ViewType::BitmapID::WhiteKeyShadowRight, bitmap); CColor color; if (stringToColor (attributes.getAttributeValue (UIViewCreator::kAttrFrameColor), color, desc)) kv->setFrameColor (color); if (stringToColor (attributes.getAttributeValue (UIViewCreator::kAttrFontColor), color, desc)) kv->setFontColor (color); if (stringToColor (attributes.getAttributeValue (kAttrWhiteKeyColor), color, desc)) kv->setWhiteKeyColor (color); if (stringToColor (attributes.getAttributeValue (kAttrWhiteKeyPressedColor), color, desc)) kv->setWhiteKeyPressedColor (color); if (stringToColor (attributes.getAttributeValue (kAttrBlackKeyColor), color, desc)) kv->setBlackKeyColor (color); if (stringToColor (attributes.getAttributeValue (kAttrBlackKeyPressedColor), color, desc)) kv->setBlackKeyPressedColor (color); CCoord c; if (attributes.getDoubleAttribute (kAttrWhiteKeyWidth, c)) kv->setWhiteKeyWidth (c); if (attributes.getDoubleAttribute (kAttrBlackKeyWidth, c)) kv->setBlackKeyWidth (c); if (attributes.getDoubleAttribute (kAttrBlackKeyHeight, c)) kv->setBlackKeyHeight (c); if (attributes.getDoubleAttribute (UIViewCreator::kAttrFrameWidth, c)) kv->setLineWidth (c); auto startNote = static_cast (kv->getKeyRangeStart ()); auto numKeys = static_cast (kv->getNumKeys ()); attributes.getIntegerAttribute (kAttrStartNote, startNote); attributes.getIntegerAttribute (kAttrNumKeys, numKeys); kv->setKeyRange (startNote, numKeys); bool b; if (attributes.getBooleanAttribute (kAttrDrawNoteText, b)) kv->setDrawNoteText (b); if (auto fontName = attributes.getAttributeValue (kAttrNoteNameFont)) kv->setNoteNameFont (desc->getFont (fontName->data ())); return true; } bool getAttributeValueRange (const std::string& attributeName, double& minValue, double& maxValue) const override { if (attributeName == kAttrNumKeys) { minValue = 12; maxValue = KeyboardViewBase::MaxNotes - 1; return true; } return false; } //----------------------------------------------------------------------------- // TODO: this is a clone see uiviewcreator.cpp template static std::string numberToString (T value) { std::stringstream str; str << value; return str.str (); } static ViewType::BitmapID attrNameToBitmapID (const std::string& attributeName) { if (attributeName == kAttrWhiteKeyPressed) return ViewType::BitmapID::WhiteKeyPressed; if (attributeName == kAttrWhiteKeyUnpressed) return ViewType::BitmapID::WhiteKeyUnpressed; if (attributeName == kAttrBlackKeyPressed) return ViewType::BitmapID::BlackKeyPressed; if (attributeName == kAttrBlackKeyUnpressed) return ViewType::BitmapID::BlackKeyUnpressed; if (attributeName == kAttrWhiteKeyShadowLeft) return ViewType::BitmapID::WhiteKeyShadowLeft; if (attributeName == kAttrWhiteKeyShadowRight) return ViewType::BitmapID::WhiteKeyShadowRight; return ViewType::BitmapID::NumBitmaps; } }; //------------------------------------------------------------------------ class KeyboardViewCreator : public KeyboardViewBaseCreator { public: KeyboardViewCreator () { UIViewFactory::registerViewCreator (*this); } IdStringPtr getViewName () const override { return "KeyboardView"; } UTF8StringPtr getDisplayName () const override { return "Keyboard"; } CView* create (const UIAttributes& attributes, const IUIDescription* description) const override { return new KeyboardView (); } }; KeyboardViewCreator __gKeyboardViewCreator; static const std::string kAttrSelectionRangeMin = "sel-range-min"; static const std::string kAttrSelectionRangeMax = "sel-range-max"; //------------------------------------------------------------------------ class KeyboardViewRangeSelectorCreator : public KeyboardViewBaseCreator { public: KeyboardViewRangeSelectorCreator () { UIViewFactory::registerViewCreator (*this); } IdStringPtr getViewName () const override { return "KeyboardViewRangeSelector"; } UTF8StringPtr getDisplayName () const override { return "Keyboard Range Selector"; } CView* create (const UIAttributes& attributes, const IUIDescription* description) const override { return new KeyboardViewRangeSelector (); } bool getAttributeNames (std::list& attributeNames) const override { attributeNames.push_back (kAttrSelectionRangeMin); attributeNames.push_back (kAttrSelectionRangeMax); return KeyboardViewBaseCreator::getAttributeNames (attributeNames); } AttrType getAttributeType (const std::string& attributeName) const override { if (attributeName == kAttrSelectionRangeMin) return kIntegerType; if (attributeName == kAttrSelectionRangeMax) return kIntegerType; return KeyboardViewBaseCreator::getAttributeType (attributeName); } bool getAttributeValue (CView* view, const std::string& attributeName, std::string& stringValue, const IUIDescription* desc) const override { auto kb = dynamic_cast (view); if (!kb) return false; if (attributeName == kAttrSelectionRangeMin) { stringValue = numberToString (kb->getSelectionMin ()); return true; } if (attributeName == kAttrSelectionRangeMax) { stringValue = numberToString (kb->getSelectionMax ()); return true; } return KeyboardViewBaseCreator::getAttributeValue (view, attributeName, stringValue, desc); } bool apply (CView* view, const UIAttributes& attributes, const IUIDescription* desc) const override { auto kb = dynamic_cast (view); if (!kb) return false; auto selMin = static_cast (kb->getSelectionMin ()); auto selMax = static_cast (kb->getSelectionMax ()); attributes.getIntegerAttribute (kAttrSelectionRangeMin, selMin); attributes.getIntegerAttribute (kAttrSelectionRangeMax, selMax); kb->setSelectionMinMax (selMin, selMax); return KeyboardViewBaseCreator::apply (view, attributes, desc); } }; KeyboardViewRangeSelectorCreator __gKeyboardViewRangeSelectorCreator; //------------------------------------------------------------------------ } // VSTGUI vst3sdk-3.7.10.14+~4.13.3/vstgui/contrib/keyboardview.h000066400000000000000000000217141461511344400222030ustar00rootroot00000000000000//------------------------------------------------------------------------ // This file is part of VSTGUI. It is subject to the license terms // in the LICENSE file found in the top-level directory of this // distribution and at http://github.com/steinbergmedia/vstgui/LICENSE // Flags : clang-format SMTGSequencer #pragma once #include "vstgui/lib/vstguifwd.h" #include "vstgui/lib/ccolor.h" #include "vstgui/lib/cview.h" #include "vstgui/lib/dispatchlist.h" #include "vstgui/lib/itouchevent.h" #include #include #include namespace VSTGUI { //------------------------------------------------------------------------ class KeyboardViewBase : public CView { public: using NoteIndex = int16_t; using NumNotes = uint8_t; static constexpr NumNotes MaxNotes = 128; enum class BitmapID { WhiteKeyPressed = 0, WhiteKeyUnpressed, BlackKeyPressed, BlackKeyUnpressed, WhiteKeyShadowLeft, WhiteKeyShadowRight, NumBitmaps }; KeyboardViewBase (); void setKeyPressed (NoteIndex note, bool state); virtual void setKeyRange (NoteIndex startNote, NumNotes numKeys); NoteIndex getKeyRangeStart () const { return startNote; } NumNotes getNumKeys () const { return numKeys; } NumNotes getNumWhiteKeys () const; void setWhiteKeyWidth (CCoord width); void setBlackKeyWidth (CCoord width); void setBlackKeyHeight (CCoord height); void setLineWidth (CCoord width); CCoord getWhiteKeyWidth () const { return whiteKeyWidth; } CCoord getBlackKeyWidth () const { return blackKeyWidth; } CCoord getBlackKeyHeight () const { return blackKeyHeight; } CCoord getLineWidth () const { return lineWidth; } void setFrameColor (CColor color); void setFontColor (CColor color); void setWhiteKeyColor (CColor color); void setWhiteKeyPressedColor (CColor color); void setBlackKeyColor (CColor color); void setBlackKeyPressedColor (CColor color); CColor getFrameColor () const { return frameColor; } CColor getFontColor () const { return fontColor; } CColor getWhiteKeyColor () const { return whiteKeyColor; } CColor getWhiteKeyPressedColor () const { return whiteKeyPressedColor; } CColor getBlackKeyColor () const { return blackKeyColor; } CColor getBlackKeyPressedColor () const { return blackKeyPressedColor; } void setNoteNameFont (CFontDesc* font); CFontDesc* getNoteNameFont () const { return noteNameFont; } void setDrawNoteText (bool state); bool getDrawNoteText () const { return drawNoteText; } void setBitmap (BitmapID bID, CBitmap* bitmap); CBitmap* getBitmap (BitmapID bID) const; void setWhiteKeyBitmapInset (const CRect& inset); // TODO: uidesc void setBlackKeyBitmapInset (const CRect& inset); // TODO: uidesc const CRect& getNoteRect (NoteIndex note) const { return noteRectCache[note]; } bool isWhiteKey (NoteIndex note) const; void drawRect (CDrawContext* context, const CRect& dirtyRect) override; void setViewSize (const CRect& rect, bool invalid = true) override; bool sizeToFit () override; //------------------------------------------------------------------------ protected: using NoteRectCache = std::array; void invalidNote (NoteIndex note); NoteIndex pointToNote (const CPoint& p, bool ignoreY) const; const NoteRectCache& getNoteRectCache () const { return noteRectCache; } private: void drawNote (CDrawContext* context, CRect& rect, NoteIndex note, bool isWhite) const; CRect calcNoteRect (NoteIndex note) const; void updateNoteRectCache () const; void createBitmapCache (); using BitmapArray = std::array, static_cast (BitmapID::NumBitmaps)>; BitmapArray bitmaps; SharedPointer whiteKeyBitmapCache; SharedPointer blackKeyBitmapCache; SharedPointer noteNameFont; CRect whiteKeyBitmapInset; CRect blackKeyBitmapInset; CCoord whiteKeyWidth {30}; CCoord blackKeyWidth {20}; CCoord blackKeyHeight {20}; CCoord lineWidth {1.}; CColor frameColor {kBlackCColor}; CColor fontColor {kBlackCColor}; CColor whiteKeyColor {kWhiteCColor}; CColor whiteKeyPressedColor {kGreyCColor}; CColor blackKeyColor {kBlackCColor}; CColor blackKeyPressedColor {kGreyCColor}; NumNotes numKeys {88}; NoteIndex startNote {21}; bool drawNoteText {false}; mutable bool noteRectCacheInvalid {true}; mutable NoteRectCache noteRectCache; std::bitset keyPressed {}; }; class KeyboardViewRangeSelector; //------------------------------------------------------------------------ struct IKeyboardViewKeyRangeChangedListener { virtual void onKeyRangeChanged (KeyboardViewRangeSelector*) = 0; virtual ~IKeyboardViewKeyRangeChangedListener () noexcept = default; }; //------------------------------------------------------------------------ class KeyboardViewRangeSelector : public KeyboardViewBase { public: struct Range { NoteIndex position; NumNotes length; Range (NoteIndex position = 0, NumNotes length = 0) : position (position), length (length) { } bool operator!= (const Range& r) const { return position != r.position || length != r.length; } }; KeyboardViewRangeSelector () = default; void drawRect (CDrawContext* context, const CRect& dirtyRect) override; void setKeyRange (NoteIndex startNote, NumNotes numKeys) override; void setSelectionRange (const Range& range); void setSelectionMinMax (NumNotes minRange, NumNotes maxRange); const Range& getSelectionRange () const { return selectionRange; } NumNotes getSelectionMin () const { return rangeMin; } NumNotes getSelectionMax () const { return rangeMax; } NumNotes getNumWhiteKeysSelected () const; void registerKeyRangeChangedListener (IKeyboardViewKeyRangeChangedListener* listener); void unregisterKeyRangeChangedListener (IKeyboardViewKeyRangeChangedListener* listener); //------------------------------------------------------------------------ private: DispatchList listeners; Range selectionRange {0, 12}; NumNotes rangeMin {12}; NumNotes rangeMax {24}; #if VSTGUI_TOUCH_EVENT_HANDLING void onTouchEvent (ITouchEvent& event) override; bool wantsMultiTouchEvents () const override; void onTouchBegin (const ITouchEvent::TouchPair& touch, ITouchEvent& event); void onTouchMove (const ITouchEvent::TouchPair& touch, ITouchEvent& event); enum TouchMode {kUnknown, kMoveRange, kChangeRangeFront, kChangeRangeBack}; Range selectionRangeOnTouchStart; int32_t touchIds[2] {-1}; TouchMode touchMode {kUnknown}; NoteIndex touchStartNote[2]; #else CMouseEventResult onMouseDown (CPoint& where, const CButtonState& buttons) override; CMouseEventResult onMouseMoved (CPoint& where, const CButtonState& buttons) override; CMouseEventResult onMouseUp (CPoint& where, const CButtonState& buttons) override; CMouseEventResult onMouseCancel () override; Range moveStartRange; NoteIndex moveStartNote {-1}; #endif }; //------------------------------------------------------------------------ struct IKeyboardViewPlayerDelegate { using NoteIndex = KeyboardViewBase::NoteIndex; virtual int32_t onNoteOn (NoteIndex note, double xPos, double yPos) = 0; virtual void onNoteOff (NoteIndex note, int32_t noteID) = 0; virtual void onNoteModulation (int32_t noteID, double xPos, double yPos) = 0; virtual ~IKeyboardViewPlayerDelegate () noexcept = default; }; //------------------------------------------------------------------------ struct KeyboardViewPlayerDelegate : public IKeyboardViewPlayerDelegate { int32_t onNoteOn (NoteIndex note, double xPos, double yPos) override { return -1; } void onNoteOff (NoteIndex note, int32_t noteID) override {} void onNoteModulation (int32_t noteID, double xPos, double yPos) override {} }; //------------------------------------------------------------------------ class KeyboardView : public KeyboardViewBase { public: KeyboardView (); void setDelegate (IKeyboardViewPlayerDelegate* inDelegate) { delegate = inDelegate; } private: double calcYParameter (NoteIndex note, CCoord y) const; double calcXParameter (NoteIndex note, CCoord x) const; #if VSTGUI_TOUCH_EVENT_HANDLING bool wantsMultiTouchEvents () const override { return true; } void onTouchEvent (ITouchEvent& event) override; void onTouchBegin (const ITouchEvent::TouchPair& touch, ITouchEvent& event); void onTouchMove (const ITouchEvent::TouchPair& touch, ITouchEvent& event); void onTouchEnd (const ITouchEvent::TouchPair& touch, ITouchEvent& event); struct NoteTouch { NoteIndex note; int32_t noteID; NoteTouch (NoteIndex note) : note (note), noteID (-1) {} }; std::map noteTouches; #else void doNoteOff (); void doNoteOn (NoteIndex note, double yPos, double xPos); CMouseEventResult onMouseDown (CPoint& where, const CButtonState& buttons) override; CMouseEventResult onMouseMoved (CPoint& where, const CButtonState& buttons) override; CMouseEventResult onMouseUp (CPoint& where, const CButtonState& buttons) override; CMouseEventResult onMouseCancel () override; NoteIndex pressedNote {-1}; int32_t noteID {-1}; #endif IKeyboardViewPlayerDelegate* delegate {nullptr}; }; //------------------------------------------------------------------------ } // VSTGUI vst3sdk-3.7.10.14+~4.13.3/vstgui/doxygen/000077500000000000000000000000001461511344400173475ustar00rootroot00000000000000vst3sdk-3.7.10.14+~4.13.3/vstgui/doxygen/Doxyfile000066400000000000000000003363451461511344400210730ustar00rootroot00000000000000# Doxyfile 1.8.18 # 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 configuration # 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 # https://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 = VSTGUI # 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 = 4.10 # 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 = "Graphical User Interface Framework not only for VST plugins" # With the PROJECT_LOGO tag one can specify a logo or an 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 = ../Documentation # 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 # The OUTPUT_TEXT_DIRECTION tag is used to specify the direction in which all # documentation generated by doxygen is written. Doxygen will use this # information to generate all generated output in the proper direction. # Possible values are: None, LTR, RTL and Context. # The default value is: None. OUTPUT_TEXT_DIRECTION = None # 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 = "The $name class " \ "The $name widget " \ "The $name file " \ is \ provides \ specifies \ contains \ represents \ a \ an \ the # 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 = YES # 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 = YES # If the JAVADOC_BANNER tag is set to YES then doxygen will interpret a line # such as # /*************** # as being the beginning of a Javadoc-style comment "banner". If set to NO, the # Javadoc-style will behave just like regular comments and it will not be # interpreted by doxygen. # The default value is: NO. JAVADOC_BANNER = 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 = 4 # 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 (in the resulting output). You can put ^^ in the value part of an # alias to insert a newline as if a physical newline was in the original file. # When you need a literal { or } or , in the value part of an alias you have to # escape them by means of a backslash (\), this can lead to conflicts with the # commands \{ and \} for these it is advised to use the version @{ and @} or use # a double escape (\\{ and \\}) 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 = NO # 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 # Set the OPTIMIZE_OUTPUT_SLICE tag to YES if your project consists of Slice # sources only. Doxygen will then generate output that is more tailored for that # language. For instance, namespaces will be presented as modules, types will be # separated into more groups, etc. # The default value is: NO. OPTIMIZE_OUTPUT_SLICE = 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, # Csharp (C#), C, C++, D, PHP, md (Markdown), Objective-C, Python, Slice, VHDL, # 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). 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 https://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 the TOC_INCLUDE_HEADINGS tag is set to a non-zero value, all headings up # to that level are automatically included in the table of contents, even if # they do not have an id attribute. # Note: This feature currently applies only to Markdown headings. # Minimum value: 0, maximum value: 99, default value: 5. # This tag requires that the tag MARKDOWN_SUPPORT is set to YES. TOC_INCLUDE_HEADINGS = 0 # 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 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: # https://www.riverbankcomputing.com/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 # If one adds a struct or class to a group and this option is enabled, then also # any nested class or struct is added to the same group. By default this option # is disabled and one has to add nested compounds explicitly via \ingroup. # The default value is: NO. GROUP_NESTED_COMPOUNDS = 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_PRIV_VIRTUAL tag is set to YES, documented private virtual # methods of a class will be included in the documentation. # The default value is: NO. EXTRACT_PRIV_VIRTUAL = 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. If 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 # 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 # (including Cygwin) ands Mac users are advised to set this option to NO. # The default value is: system dependent. CASE_SENSE_NAMES = NO # 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 = YES # If the HIDE_COMPOUND_REFERENCE tag is set to NO (default) then doxygen will # append additional text to a page's title, such as Class Reference. If set to # YES the compound reference will be hidden. # The default value is: NO. HIDE_COMPOUND_REFERENCE= 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 = NO # 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 = YES # 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 = YES # 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 = NO # 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 https://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 = YES # 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. If # EXTRACT_ALL is set to YES then this flag will automatically be disabled. # The default value is: NO. WARN_NO_PARAMDOC = NO # If the WARN_AS_ERROR tag is set to YES then doxygen will immediately stop when # a warning is encountered. # The default value is: NO. WARN_AS_ERROR = NO # 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. See also FILE_PATTERNS and EXTENSION_MAPPING # Note: If this tag is empty the current directory is searched. INPUT = ./doc.h \ ./page_changes.h \ ./page_license.h \ ../lib/ \ ./page_keyeventflow.h \ ../uidescription/ \ ./page_create_your_own_ui_view.h \ ./page_view_system_overview.h \ ../plugin-bindings/ \ ../standalone/include/ \ ./page_misc.h # 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: https://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. # # Note that for custom extensions or not directly supported extensions you also # need to set EXTENSION_MAPPING for the extension otherwise the files are not # read by doxygen. # # 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 (to be provided as doxygen C comment), # *.doc (to be provided as doxygen C comment), *.txt (to be provided as doxygen # C comment), *.py, *.pyw, *.f90, *.f95, *.f03, *.f08, *.f18, *.f, *.for, *.vhd, # *.vhdl, *.ucf, *.qsf and *.ice. FILE_PATTERNS = *.c \ *.cc \ *.cxx \ *.cpp \ *.c++ \ *.java \ *.ii \ *.ixx \ *.ipp \ *.i++ \ *.inl \ *.h \ *.hh \ *.hxx \ *.hpp \ *.h++ \ *.idl \ *.odl \ *.cs \ *.php \ *.php3 \ *.inc \ *.m \ *.mm \ *.dox \ *.C \ *.CC \ *.C++ \ *.II \ *.I++ \ *.H \ *.HH \ *.H++ \ *.CS \ *.PHP \ *.PHP3 \ *.M \ *.MM \ *.md # 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 = ../uidescription/expat/ \ ../tests/ \ ../lib/platform/ \ ../standalone/source/platform \ ../uidescription/miniz \ ../uidescription/rapidjson \ ../uidescription/detail # 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). 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 = screenshots # 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. # # Note that for custom extensions or not directly supported extensions you also # need to set EXTENSION_MAPPING for the extension otherwise the files are not # properly processed by doxygen. 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. # # Note that for custom extensions or not directly supported extensions you also # need to set EXTENSION_MAPPING for the extension otherwise the files are not # properly processed by doxygen. 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 # entity all documented functions referencing it will be listed. # The default value is: NO. REFERENCED_BY_RELATION = NO # 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 = NO # 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 https://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 configuration 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 = NO # If the CLANG_ASSISTED_PARSING tag is set to YES then doxygen will use the # clang parser (see: http://clang.llvm.org/) for more accurate parsing at the # cost of reduced performance. This can be particularly helpful with template # rich C++ code for which doxygen's built-in parser lacks the necessary type # information. # Note: The availability of this option depends on whether or not doxygen was # generated with the -Duse_libclang=ON option for CMake. # The default value is: NO. CLANG_ASSISTED_PARSING = NO # If clang assisted parsing is enabled you can provide the compiler with command # line options that you would normally use when invoking the compiler. Note that # the include paths will already be set by doxygen for the files and directories # specified with INPUT and INCLUDE_PATH. # This tag requires that the tag CLANG_ASSISTED_PARSING is set to YES. CLANG_OPTIONS = # If clang assisted parsing is enabled you can provide the clang parser with the # path to the compilation database (see: # http://clang.llvm.org/docs/HowToSetupToolingForLLVM.html) used when the files # were built. This is equivalent to specifying the "-p" option to a clang tool, # such as clang-check. These options will then be passed to the parser. # Note: The availability of this option depends on whether or not doxygen was # generated with the -Duse_libclang=ON option for CMake. CLANG_DATABASE_PATH = #--------------------------------------------------------------------------- # 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 = YES # The COLS_IN_ALPHA_INDEX tag can be used to specify the number of columns in # which the alphabetical index list will be split. # Minimum value: 1, maximum value: 20, default value: 5. # This tag requires that the tag ALPHABETICAL_INDEX is set to YES. COLS_IN_ALPHA_INDEX = 5 # 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 therefore more robust against future updates. # Doxygen will copy the style sheet files to the output directory. # Note: The order of the extra style sheet files is of importance (e.g. the last # style sheet 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 = screenshots/inspector_overview.png \ screenshots/contextmenu.png \ screenshots/ui_editor.png \ screenshots/ui_editor_bitmaps_browser.png \ screenshots/ui_editor_colors_browser.png \ screenshots/ui_editor_fonts_browser.png \ screenshots/ui_editor_tags_browser.png \ screenshots/ui_editor_views_browser.png # The HTML_COLORSTYLE_HUE tag controls the color of the HTML output. Doxygen # will adjust the colors in the style sheet and background images according to # this color. Hue is specified as an angle on a colorwheel, see # https://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 YES can help to show when doxygen was last run and thus if the # documentation is up to date. # The default value is: NO. # This tag requires that the tag GENERATE_HTML is set to YES. HTML_TIMESTAMP = YES # If the HTML_DYNAMIC_MENUS tag is set to YES then the generated HTML # documentation will contain a main index with vertical navigation menus that # are dynamically created via JavaScript. If disabled, the navigation index will # consists of multiple levels of tabs that are statically embedded in every HTML # page. Disable this option to support browsers that do not have JavaScript, # like the Qt help browser. # The default value is: YES. # This tag requires that the tag GENERATE_HTML is set to YES. HTML_DYNAMIC_MENUS = 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 = YES # 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: https://developer.apple.com/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 https://developer.apple.com/library/archive/featuredarticles/Doxy # genXcode/_index.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: https://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: https://doc.qt.io/archives/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: https://doc.qt.io/archives/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: https://doc.qt.io/archives/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: https://doc.qt.io/archives/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: # https://doc.qt.io/archives/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 style sheets (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 = YES # 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 = 75 # If 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 # If the HTML_FORMULA_FORMAT option is set to svg, doxygen will use the pdf2svg # tool (see https://github.com/dawbarton/pdf2svg) or inkscape (see # https://inkscape.org) to generate formulas as SVG images instead of PNGs for # the HTML output. These images will generally look nicer at scaled resolutions. # Possible values are: png The default and svg Looks nicer but requires the # pdf2svg tool. # The default value is: png. # This tag requires that the tag GENERATE_HTML is set to YES. HTML_FORMULA_FORMAT = png # 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_TRANSPARENT 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 # The FORMULA_MACROFILE can contain LaTeX \newcommand and \renewcommand commands # to create new LaTeX commands to be used in formulas as building blocks. See # the section "Including formulas" for details. FORMULA_MACROFILE = # Enable the USE_MATHJAX option to render LaTeX formulas using MathJax (see # https://www.mathjax.org) which uses client side JavaScript for the rendering # instead of using pre-rendered 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 https://www.mathjax.org before deployment. # The default value is: https://cdn.jsdelivr.net/npm/mathjax@2. # This tag requires that the tag USE_MATHJAX is set to YES. MATHJAX_RELPATH = http://www.mathjax.org/mathjax # 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 # , /