widgets/CMakeLists.txt

Wed, 22 Jun 2022 21:46:38 +0300

author
Teemu Piippo <teemu.s.piippo@gmail.com>
date
Wed, 22 Jun 2022 21:46:38 +0300
changeset 254
b7b29cb82360
parent 253
8b994c917f69
child 255
5188f8a74a5c
permissions
-rw-r--r--

Rename Vec3Editor to VectorInput

253
8b994c917f69 Make LDForge widgets visible in Qt Designer
Teemu Piippo <teemu.s.piippo@gmail.com>
parents:
diff changeset
1 find_package(Qt5 REQUIRED COMPONENTS UiPlugin)
8b994c917f69 Make LDForge widgets visible in Qt Designer
Teemu Piippo <teemu.s.piippo@gmail.com>
parents:
diff changeset
2 qt5_wrap_ui(LDFORGEWIDGETS_FORMS
8b994c917f69 Make LDForge widgets visible in Qt Designer
Teemu Piippo <teemu.s.piippo@gmail.com>
parents:
diff changeset
3 vec3editor.ui
8b994c917f69 Make LDForge widgets visible in Qt Designer
Teemu Piippo <teemu.s.piippo@gmail.com>
parents:
diff changeset
4 multiplyfactordialog.ui
8b994c917f69 Make LDForge widgets visible in Qt Designer
Teemu Piippo <teemu.s.piippo@gmail.com>
parents:
diff changeset
5 matrixeditor.ui
8b994c917f69 Make LDForge widgets visible in Qt Designer
Teemu Piippo <teemu.s.piippo@gmail.com>
parents:
diff changeset
6 )
8b994c917f69 Make LDForge widgets visible in Qt Designer
Teemu Piippo <teemu.s.piippo@gmail.com>
parents:
diff changeset
7
8b994c917f69 Make LDForge widgets visible in Qt Designer
Teemu Piippo <teemu.s.piippo@gmail.com>
parents:
diff changeset
8 add_library(ldforgewidgets SHARED
8b994c917f69 Make LDForge widgets visible in Qt Designer
Teemu Piippo <teemu.s.piippo@gmail.com>
parents:
diff changeset
9 designerplugins.cpp
8b994c917f69 Make LDForge widgets visible in Qt Designer
Teemu Piippo <teemu.s.piippo@gmail.com>
parents:
diff changeset
10 designerplugins.h
8b994c917f69 Make LDForge widgets visible in Qt Designer
Teemu Piippo <teemu.s.piippo@gmail.com>
parents:
diff changeset
11 doublespinbox.cpp
8b994c917f69 Make LDForge widgets visible in Qt Designer
Teemu Piippo <teemu.s.piippo@gmail.com>
parents:
diff changeset
12 doublespinbox.h
8b994c917f69 Make LDForge widgets visible in Qt Designer
Teemu Piippo <teemu.s.piippo@gmail.com>
parents:
diff changeset
13 matrixeditor.cpp
8b994c917f69 Make LDForge widgets visible in Qt Designer
Teemu Piippo <teemu.s.piippo@gmail.com>
parents:
diff changeset
14 matrixeditor.h
8b994c917f69 Make LDForge widgets visible in Qt Designer
Teemu Piippo <teemu.s.piippo@gmail.com>
parents:
diff changeset
15 vec3editor.cpp
8b994c917f69 Make LDForge widgets visible in Qt Designer
Teemu Piippo <teemu.s.piippo@gmail.com>
parents:
diff changeset
16 vec3editor.h
8b994c917f69 Make LDForge widgets visible in Qt Designer
Teemu Piippo <teemu.s.piippo@gmail.com>
parents:
diff changeset
17 multiplyfactordialog.cpp
8b994c917f69 Make LDForge widgets visible in Qt Designer
Teemu Piippo <teemu.s.piippo@gmail.com>
parents:
diff changeset
18 multiplyfactordialog.h
8b994c917f69 Make LDForge widgets visible in Qt Designer
Teemu Piippo <teemu.s.piippo@gmail.com>
parents:
diff changeset
19 ${LDFORGEWIDGETS_FORMS}
8b994c917f69 Make LDForge widgets visible in Qt Designer
Teemu Piippo <teemu.s.piippo@gmail.com>
parents:
diff changeset
20 )
8b994c917f69 Make LDForge widgets visible in Qt Designer
Teemu Piippo <teemu.s.piippo@gmail.com>
parents:
diff changeset
21
8b994c917f69 Make LDForge widgets visible in Qt Designer
Teemu Piippo <teemu.s.piippo@gmail.com>
parents:
diff changeset
22 get_target_property(Qt5UiPlugin_INCLUDES Qt5::UiPlugin INTERFACE_INCLUDE_DIRECTORIES)
8b994c917f69 Make LDForge widgets visible in Qt Designer
Teemu Piippo <teemu.s.piippo@gmail.com>
parents:
diff changeset
23 target_include_directories(ldforgewidgets PUBLIC ${Qt5UiPlugin_INCLUDES})
8b994c917f69 Make LDForge widgets visible in Qt Designer
Teemu Piippo <teemu.s.piippo@gmail.com>
parents:
diff changeset
24 target_include_directories(ldforgewidgets PUBLIC "${CMAKE_CURRENT_SOURCE_DIR}")
8b994c917f69 Make LDForge widgets visible in Qt Designer
Teemu Piippo <teemu.s.piippo@gmail.com>
parents:
diff changeset
25 target_include_directories(ldforgewidgets PUBLIC "${CMAKE_CURRENT_BINARY_DIR}")
8b994c917f69 Make LDForge widgets visible in Qt Designer
Teemu Piippo <teemu.s.piippo@gmail.com>
parents:
diff changeset
26 target_link_libraries(ldforgewidgets Qt5::Widgets)
8b994c917f69 Make LDForge widgets visible in Qt Designer
Teemu Piippo <teemu.s.piippo@gmail.com>
parents:
diff changeset
27
8b994c917f69 Make LDForge widgets visible in Qt Designer
Teemu Piippo <teemu.s.piippo@gmail.com>
parents:
diff changeset
28 get_target_property(QT_QMAKE_EXECUTABLE Qt5::qmake LOCATION)
8b994c917f69 Make LDForge widgets visible in Qt Designer
Teemu Piippo <teemu.s.piippo@gmail.com>
parents:
diff changeset
29 execute_process(COMMAND ${QT_QMAKE_EXECUTABLE} -query QT_INSTALL_PLUGINS
8b994c917f69 Make LDForge widgets visible in Qt Designer
Teemu Piippo <teemu.s.piippo@gmail.com>
parents:
diff changeset
30 OUTPUT_VARIABLE QT_INSTALL_PLUGINS OUTPUT_STRIP_TRAILING_WHITESPACE
8b994c917f69 Make LDForge widgets visible in Qt Designer
Teemu Piippo <teemu.s.piippo@gmail.com>
parents:
diff changeset
31 )
8b994c917f69 Make LDForge widgets visible in Qt Designer
Teemu Piippo <teemu.s.piippo@gmail.com>
parents:
diff changeset
32 install(TARGETS ldforgewidgets LIBRARY DESTINATION lib)
8b994c917f69 Make LDForge widgets visible in Qt Designer
Teemu Piippo <teemu.s.piippo@gmail.com>
parents:
diff changeset
33 install(TARGETS ldforgewidgets
8b994c917f69 Make LDForge widgets visible in Qt Designer
Teemu Piippo <teemu.s.piippo@gmail.com>
parents:
diff changeset
34 LIBRARY DESTINATION ${QT_INSTALL_PLUGINS}/designer
8b994c917f69 Make LDForge widgets visible in Qt Designer
Teemu Piippo <teemu.s.piippo@gmail.com>
parents:
diff changeset
35 )

mercurial