Skip to content

Instantly share code, notes, and snippets.

@luis-pereira
Created June 17, 2016 14:25
Show Gist options
  • Save luis-pereira/23c33728bdc9b4723d49ff77e66a3cb2 to your computer and use it in GitHub Desktop.
Save luis-pereira/23c33728bdc9b4723d49ff77e66a3cb2 to your computer and use it in GitHub Desktop.
use-qt5xdgiconloader-target-alone
project(iconloader)
cmake_minimum_required(VERSION 3.0.2 FATAL_ERROR)
find_package(Qt5Xdg REQUIRED)
# This one should be included in the Qt5XdgIconLoader Target
include_directories(${Qt5Gui_PRIVATE_INCLUDE_DIRS})
add_executable(iconloader main.cpp)
target_link_libraries(iconloader Qt5XdgIconLoader)
#include <private/xdgiconloader/xdgiconloader_p.h>
#include <QGuiApplication>
#include <QDebug>
int main(int argc, char *argv[])
{
QGuiApplication a(argc, argv);
qDebug() << XdgIconLoader::instance()->themeName();
return 0;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment