
- Added ProjectManager class to handle project operations including opening, closing, building, and running projects. - Introduced SyntaxHighlighter class for syntax highlighting in C and C++ files. - Developed TerminalWidget for command execution and output display. - Created TextEditor with line numbering and auto-indentation features. - Established main application entry point in main.cpp. - Designed UI layout for MainWindow using Qt Designer.
61 lines
1.4 KiB
CMake
61 lines
1.4 KiB
CMake
cmake_minimum_required(VERSION 3.20)
|
|
project(DTCIde VERSION 0.1.0 LANGUAGES CXX)
|
|
|
|
set(CMAKE_CXX_STANDARD 20)
|
|
set(CMAKE_CXX_STANDARD_REQUIRED ON)
|
|
|
|
# Find required Qt6 components
|
|
find_package(Qt6 REQUIRED COMPONENTS Core Widgets Gui)
|
|
|
|
# Enable Qt MOC, UIC, and RCC
|
|
set(CMAKE_AUTOMOC ON)
|
|
set(CMAKE_AUTOUIC ON)
|
|
set(CMAKE_AUTORCC ON)
|
|
|
|
# Include directories
|
|
include_directories(${CMAKE_SOURCE_DIR}/include)
|
|
|
|
# Source files
|
|
set(SOURCES
|
|
src/main.cpp
|
|
src/MainWindow.cpp
|
|
src/TextEditor.cpp
|
|
src/FileTreeWidget.cpp
|
|
src/TerminalWidget.cpp
|
|
src/ProjectManager.cpp
|
|
src/SyntaxHighlighter.cpp
|
|
)
|
|
|
|
# Header files
|
|
set(HEADERS
|
|
include/MainWindow.h
|
|
include/TextEditor.h
|
|
include/FileTreeWidget.h
|
|
include/TerminalWidget.h
|
|
include/ProjectManager.h
|
|
include/SyntaxHighlighter.h
|
|
)
|
|
|
|
# Create executable
|
|
add_executable(dtc-ide ${SOURCES} ${HEADERS})
|
|
|
|
# Link Qt6 libraries
|
|
target_link_libraries(dtc-ide Qt6::Core Qt6::Widgets Qt6::Gui)
|
|
|
|
# macOS specific settings
|
|
if(APPLE)
|
|
set_target_properties(dtc-ide PROPERTIES
|
|
MACOSX_BUNDLE TRUE
|
|
MACOSX_BUNDLE_GUI_IDENTIFIER "com.dtc.ide"
|
|
MACOSX_BUNDLE_BUNDLE_VERSION ${PROJECT_VERSION}
|
|
MACOSX_BUNDLE_SHORT_VERSION_STRING ${PROJECT_VERSION_MAJOR}.${PROJECT_VERSION_MINOR}
|
|
MACOSX_BUNDLE_BUNDLE_NAME "DTC C/C++ IDE"
|
|
)
|
|
endif()
|
|
|
|
# Install targets
|
|
install(TARGETS dtc-ide
|
|
BUNDLE DESTINATION .
|
|
RUNTIME DESTINATION bin
|
|
)
|