Using QtCreator to edit and show sub-folders in a package
I'm using catkin tools and I'm trying to setup QtCreator to work with ROS packages. I normally use vscode for my environment but I need to create a GUI so I'm thinking of moving to Qt. I've been able to succesfully build my package from Qt using cmake but I'm running into some issues which isn't making the IDE user-friendly. I'm not sure if this is qt thing or my configuration is just wrong. Here are my list of issues:
- I'm unable to add sub-directories to the top level package. If I right-click on the package, add new, add existing etc are all greyed out .
- Additonally some of my folders aren't showing up in the IDE.
src
shows up butinclude
and other directories are simply missing.
This is what my CMakeLists.txt looks like:
cmake_minimum_required(VERSION 2.8.3)
project(ros_threads)
## Compile as C++11, supported in ROS Kinetic and newer
set(CMAKE_CXX_FLAGS "-std=c++11 ${CMAKE_CXX_FLAGS}")
find_package(catkin REQUIRED COMPONENTS
geometry_msgs
nav_msgs
roscpp
rospy
sensor_msgs
std_msgs
)
find_package(Eigen3 REQUIRED)
catkin_package(
INCLUDE_DIRS include
CATKIN_DEPENDS
geometry_msgs
nav_msgs
std_msgs
)
include_directories(include
${catkin_INCLUDE_DIRS})
add_executable(thread_playground
src/main.cpp )
target_link_libraries(thread_playground ${catkin_LIBRARIES})
install(DIRECTORY launch
DESTINATION ${CATKIN_PACKAGE_SHARE_DESTINATION}/launch
)
This is not an answer, but just to make you aware of it: ros-qtc-plugin.
@gvdhoorn I tried it a few years back and I wasn't a fan. I might have to give it another try if I don't get this working
A "few years"? That's ages in software.
But I only wanted to make sure you were aware of it. Whatever makes you happy.