Commit 315e6012 authored by Ben Boeckel's avatar Ben Boeckel Committed by Kitware Robot

Merge topic 'qt5-support'

e9f92aa5 qt5: fix include directives
0a1bff76 polygon/plugin: use the new Qt wrapping macros
3dcd3e8c qt5: support Qt5
e452e37f qt: support Qt4 and Qt5 via ParaView's module
Acked-by: Kitware Robot's avatarKitware Robot <kwrobot@kitware.com>
Acked-by: T.J. Corona's avatarT.J. Corona <tj.corona@kitware.com>
Merge-request: !402
parents eaeeca21 e9f92aa5
......@@ -174,12 +174,7 @@ MACRO(ADD_SMTK_UI_VIEW OUTIFACES OUTSRCS)
CONFIGURE_FILE(${SMTK_SOURCE_DIR}/CMake/qtSMTKViewImplementation.cxx.in
${CMAKE_CURRENT_BINARY_DIR}/${ARG_CLASS_NAME}Implementation.cxx @ONLY)
SET(VIEW_MOC_SRCS)
IF (PARAVIEW_QT_VERSION VERSION_GREATER "4")
QT5_WRAP_CPP(VIEW_MOC_SRCS ${CMAKE_CURRENT_BINARY_DIR}/${ARG_CLASS_NAME}Implementation.h)
ELSE ()
QT4_WRAP_CPP(VIEW_MOC_SRCS ${CMAKE_CURRENT_BINARY_DIR}/${ARG_CLASS_NAME}Implementation.h)
ENDIF ()
smtk_qt_wrap_cpp(VIEW_MOC_SRCS ${CMAKE_CURRENT_BINARY_DIR}/${ARG_CLASS_NAME}Implementation.h)
SET(${OUTSRCS}
${CMAKE_CURRENT_BINARY_DIR}/${ARG_CLASS_NAME}Implementation.cxx
......
# This module makes it easier to find and import appropriate Qt modules based
# on SMTK_QT_VERSION.
#------------------------------------------------------------------------------
# Instead of doing find_package(Qt4) or find_package(Qt5), use this macro to
# find an appropriate version based on SMTK_QT_VERSION specified.
# You can pass all arguments typically passed to the find_package() call with
# following exceptions:
# - The first argument is a variable name that gets set to the list of targets
# imported from the appropriate Qt package.
# - Do not pass a version number. That will not be processed correctly. The
# version number is determined by this macro itself.
# - Do not use COMPONENTS or OPTIONAL_COMPONENTS instead, use QT4_COMPONENTS,
# QT4_OPTIONAL_COMPONENTS and QT5_COMPONENTS, QT5_COMPONENTS to separately
# specify the components to use for Qt4 and Qt5.
macro(smtk_find_package_qt out_targets_var)
if(NOT DEFINED SMTK_QT_VERSION)
set(SMTK_QT_VERSION "4")
endif()
set(qt4_components)
set(qt5_components)
set(qt4_optional_components)
set(qt5_optional_components)
set(other_args)
set(_doing)
foreach(arg ${ARGN})
if(arg MATCHES "^(QT(4|5)_COMPONENTS|QT(4|5)_OPTIONAL_COMPONENTS)$")
set(_doing "${arg}")
elseif(arg MATCHES "^(COMPONENTS|OPTIONAL_COMPONENTS)$")
message(FATAL_ERROR "Qt4 and Qt5 components need to specified separately"
"using QT4_COMPONENTS, QT4_OPTIONAL_COMPONENTS, QT5_COMPONENTS, or "
"QT5_OPTIONAL_COMPONENTS keywords and not COMPONENTS or OPTIONAL_COMPONENTS.")
elseif(_doing STREQUAL "QT4_COMPONENTS")
list(APPEND qt4_components "${arg}")
elseif(_doing STREQUAL "QT5_COMPONENTS")
list(APPEND qt5_components "${arg}")
elseif(_doing STREQUAL "QT4_OPTIONAL_COMPONENTS")
list(APPEND qt4_optional_components "${arg}")
elseif(_doing STREQUAL "QT5_OPTIONAL_COMPONENTS")
list(APPEND qt5_optional_components "${arg}")
else()
set(_doing)
list(APPEND other_args "${arg}")
endif()
endforeach()
if(NOT (qt4_components OR qt5_components OR qt4_optional_components OR qt5_optional_components))
message(FATAL_ERROR "Components must be specified to find Qt correctly.")
endif()
set(_qt_targets)
if(SMTK_QT_VERSION VERSION_GREATER "4")
set(_qt_var_prefix Qt5)
set(_qt_min_version "5.6")
set(_qt_official_version "5.6")
set(args)
if(qt5_components)
set(args ${args} COMPONENTS ${qt5_components})
endif()
if(qt5_optional_components)
set(args ${args} OPTIONAL_COMPONENTS ${qt5_optional_components})
endif()
find_package(Qt5 ${_qt_min_version} ${args} ${other_args})
set(_qt_version ${Qt5_VERSION})
foreach(comp IN LISTS qt5_components qt5_optional_components)
if(TARGET Qt5::${comp})
list(APPEND _qt_targets "Qt5::${comp}")
endif()
endforeach()
else()
set(_qt_var_prefix Qt4)
set(_qt_min_version "4.7")
set(_qt_official_version "4.8")
set(args)
if(qt4_components)
set(args COMPONENTS ${qt4_components})
endif()
if(qt4_optional_components)
set(arg OPTIONAL_COMPONENTS ${qt4_optional_components})
endif()
#---------------------------------------------------------
set(QT_USE_IMPORTED_TARGETS TRUE)
find_package(Qt4 ${_qt_min_version} ${args} ${other_args})
set(_qt_version ${QTVERSION})
foreach(comp IN LISTS qt4_components qt4_optional_components)
if(TARGET Qt4::${comp})
list(APPEND _qt_targets "Qt4::${comp}")
endif()
endforeach()
endif()
# Warn is Qt version is less than the official version.
if(_qt_version VERSION_LESS _qt_official_version)
message(WARNING "You are using Qt ${_qt_version}. "
"Officially supported version is ${_qt_official_version}")
endif()
# Add all imported components, we setup a variable that refers to the imported targets.
set(${out_targets_var} ${_qt_targets})
endmacro()
macro(smtk_qt_wrap_cpp)
if(SMTK_QT_VERSION VERSION_GREATER "4")
qt5_wrap_cpp(${ARGN})
else()
qt4_wrap_cpp(${ARGN})
endif()
endmacro()
macro(smtk_qt_wrap_ui)
if(SMTK_QT_VERSION VERSION_GREATER "4")
qt5_wrap_ui(${ARGN})
else()
qt4_wrap_ui(${ARGN})
endif()
endmacro()
macro(smtk_qt_add_resources)
if(SMTK_QT_VERSION VERSION_GREATER "4")
qt5_add_resources(${ARGN})
else()
qt4_add_resources(${ARGN})
endif()
endmacro()
......@@ -221,9 +221,13 @@ endif()
################################################################################
#make find qt4 bring in import targets which are far nicer to use
if(SMTK_ENABLE_QT_SUPPORT)
set(QT_USE_IMPORTED_TARGETS TRUE)
find_package(Qt4 REQUIRED)
if(SMTK_ENABLE_QT_SUPPORT OR SMTK_ENABLE_PARAVIEW_SUPPORT)
set(SMTK_QT_VERSION "4"
CACHE STRING "The major version of Qt to use")
set_property(CACHE SMTK_QT_VERSION
PROPERTY
STRINGS "4;5")
include(SMTKQt)
endif()
################################################################################
......
......@@ -32,7 +32,7 @@ set(Plugin_Src_Files
# more magic needs to happen for client-server mode to work
#required can't use automoc here since plugin macros will attempt moccing too
qt4_wrap_cpp(MOC_SRCS pqCMBModelPluginStarter.h)
smtk_qt_wrap_cpp(MOC_SRCS pqCMBModelPluginStarter.h)
add_paraview_auto_start(IFACES IFACE_SRCS CLASS_NAME pqCMBModelPluginStarter
STARTUP onStartup
SHUTDOWN onShutdown)
......
......@@ -7,21 +7,12 @@ include(ParaViewPlugins)
# not be found.
list(APPEND CMAKE_MODULE_PATH "${VTK_MODULES_DIR}")
IF (PARAVIEW_QT_VERSION VERSION_GREATER "4")
QT5_WRAP_CPP(MOC_SRCS qtPolygonEdgeOperationView.h)
QT5_WRAP_CPP(MOC_SRCS qtExtractContoursView.h)
if(SMTK_ENABLE_OPENCV)
QT5_WRAP_CPP(MOC_SRCS qtSurfaceExtractorView.h)
endif()
# QT5_WRAP_UI(UI_SRCS qtPolygonEdgeOperationView.ui)
ELSE ()
QT4_WRAP_CPP(MOC_SRCS qtPolygonEdgeOperationView.h)
QT4_WRAP_CPP(MOC_SRCS qtExtractContoursView.h)
if(SMTK_ENABLE_OPENCV)
QT4_WRAP_CPP(MOC_SRCS qtSurfaceExtractorView.h)
endif()
# QT4_WRAP_UI(UI_SRCS qtPolygonEdgeOperationView.ui)
ENDIF ()
smtk_qt_wrap_cpp(MOC_SRCS qtPolygonEdgeOperationView.h)
smtk_qt_wrap_cpp(MOC_SRCS qtExtractContoursView.h)
if(SMTK_ENABLE_OPENCV)
smtk_qt_wrap_cpp(MOC_SRCS qtSurfaceExtractorView.h)
endif()
#smtk_qt_wrap_cpp(UI_SRCS qtPolygonEdgeOperationView.ui)
ADD_SMTK_UI_VIEW(
OUTIFACES
......
include(${QT_USE_FILE})
smtk_find_package_qt(qt_targets REQUIRED
QT4_COMPONENTS QtCore QtGui
QT5_COMPONENTS Core Widgets)
set(OpenCVOperatorsHeaders)
set(OpenCVOperatorsSrcs)
......@@ -38,9 +40,9 @@ set(PQWidgetsMocHeaders
#install the headers
smtk_public_headers(${PQWidgetsMocHeaders} vtkPolygonArcInfo.h)
qt4_wrap_cpp(MOC_BUILT_SOURCES ${PQWidgetsMocHeaders})
qt4_wrap_ui(UI_BUILT_SOURCES ${PQWidgetsUIs})
qt4_add_resources(RCS_RESOURCES qtWidgetsIcons.qrc)
smtk_qt_wrap_cpp(MOC_BUILT_SOURCES ${PQWidgetsMocHeaders})
smtk_qt_wrap_ui(UI_BUILT_SOURCES ${PQWidgetsUIs})
smtk_qt_add_resources(RCS_RESOURCES qtWidgetsIcons.qrc)
source_group("Qt_Source" FILES ${PQWidgetsSrcs} ${PQWidgetsUIs})
source_group("Qt_Generated" FILES ${MOC_BUILT_SOURCES} ${UI_BUILT_SOURCES} ${RCS_RESOURCES})
......@@ -56,7 +58,6 @@ add_library(smtkPolygonQtExt
#we need to add the location of the moc files to the include dir for smtkPWWidgetExt
target_include_directories(smtkPolygonQtExt PRIVATE ${CMAKE_CURRENT_BINARY_DIR})
#qt4_use_modules(smtkPolygonQtExt LINK_PUBLIC Core Gui)
#set smtkPolygonQtExt to publicly link to smtkCore
target_link_libraries(smtkPolygonQtExt LINK_PUBLIC
......@@ -67,6 +68,7 @@ target_link_libraries(smtkPolygonQtExt LINK_PUBLIC
vtkSMTKSourceExt
vtkDomainsChemistryOpenGL2
vtkSMTKFilterExt
${qt_targets}
LINK_PRIVATE
${VTK_LIBRARIES}
)
......@@ -88,6 +90,7 @@ if (SMTK_ENABLE_TESTING)
vtkInteractionStyle
vtkRenderingFreeType
vtkRenderingOpenGL2
${qt_targets}
)
if (TARGET ${target})
list(APPEND SMTK_VTK_TARGET_LIST ${target})
......
include(${QT_USE_FILE})
smtk_find_package_qt(qt_targets REQUIRED
QT4_COMPONENTS QtCore QtGui QtNetwork)
include_directories(${CMAKE_CURRENT_BINARY_DIR} ${CMAKE_CURRENT_SOURCE_DIR})
set(ui_files
......@@ -8,7 +10,7 @@ set(ui_files
ui/cumuluswidget.ui
)
qt4_wrap_ui(ui_srcs ${ui_files})
smtk_qt_wrap_ui(ui_srcs ${ui_files})
set(src
jobtablewidget.cxx
......@@ -36,7 +38,7 @@ set(mochdrs
logindialog.h
mainwindow.h
)
qt4_wrap_cpp(moc_srcs ${mochdrs})
smtk_qt_wrap_cpp(moc_srcs ${mochdrs})
#extension library
add_library(smtkCumulusExt
......@@ -57,9 +59,7 @@ target_include_directories(smtkCumulusExt PRIVATE ${CMAKE_CURRENT_BINARY_DIR})
#publicly link to smtkCore
target_link_libraries(smtkCumulusExt LINK_PUBLIC
smtkCore
${QT_QTNETWORK_LIBRARY}
${QT_QTGUI_LIBRARY}
${QT_QTCORE_LIBRARY}
${qt_targets}
)
smtk_export_header(smtkCumulusExt Exports.h)
......
......@@ -13,11 +13,11 @@
#include "jobtablemodel.h"
#include "cumulusproxy.h"
#include <QtGui/QDesktopWidget>
#include <QtGui/QMessageBox>
#include <QtNetwork/QNetworkReply>
#include <QtCore/QList>
#include <QtCore/QTimer>
#include <QDesktopWidget>
#include <QMessageBox>
#include <QNetworkReply>
#include <QList>
#include <QTimer>
namespace cumulus {
......
......@@ -16,8 +16,8 @@
#include "logindialog.h"
#include <QtGui/QMainWindow>
#include <QtNetwork/QNetworkReply>
#include <QMainWindow>
#include <QNetworkReply>
class QAction;
class QIcon;
......
......@@ -15,7 +15,7 @@
#include "jobtablemodel.h"
#include "cumulusproxy.h"
#include <QtGui/QMessageBox>
#include <QMessageBox>
namespace cumulus
{
......
......@@ -14,7 +14,7 @@
#ifndef __smtk_extension_cumulus_jobtablewidget_h
#define __smtk_extension_cumulus_jobtablewidget_h
#include <QtGui/QWidget>
#include <QWidget>
class QAbstractItemModel;
namespace Ui {
......
......@@ -12,10 +12,10 @@
#include "jobtablemodel.h"
#include "cumulusproxy.h"
#include <QtGui/QMenu>
#include <QtGui/QContextMenuEvent>
#include <QtGui/QMessageBox>
#include <QtGui/QFileDialog>
#include <QMenu>
#include <QContextMenuEvent>
#include <QMessageBox>
#include <QFileDialog>
namespace cumulus
{
......
......@@ -16,8 +16,8 @@
#include "job.h"
#include <QtGui/QTableView>
#include <QtCore/QSet>
#include <QTableView>
#include <QSet>
namespace cumulus
......
......@@ -14,7 +14,7 @@
#ifndef __smtk_extension_cumulus_logindialog_h
#define __smtk_extension_cumulus_logindialog_h
#include <QtGui/QDialog>
#include <QDialog>
namespace Ui {
class LoginDialog;
......
......@@ -8,14 +8,14 @@
// PURPOSE. See the above copyright notice for more information.
//=========================================================================
#include <QtCore/QDir>
#include <QtCore/QSettings>
#include <QtCore/QStringList>
#include <QDir>
#include <QSettings>
#include <QStringList>
#include <QtGui/QApplication>
#include <QtGui/QMessageBox>
#include <QApplication>
#include <QMessageBox>
#include <QtNetwork/QSslSocket>
#include <QSslSocket>
#include "mainwindow.h"
......
......@@ -11,8 +11,8 @@
#include "mainwindow.h"
#include "ui_mainwindow.h"
#include <QtGui/QDesktopWidget>
#include <QtGui/QStatusBar>
#include <QDesktopWidget>
#include <QStatusBar>
namespace cumulus {
......
......@@ -14,7 +14,7 @@
#ifndef __smtk_extension_cumulus_mainwindow_h
#define __smtk_extension_cumulus_mainwindow_h
#include <QtGui/QMainWindow>
#include <QMainWindow>
class QAction;
class QIcon;
......
include(${QT_USE_FILE})
smtk_find_package_qt(qt_targets REQUIRED
QT4_COMPONENTS QtCore
QT5_COMPONENTS Core)
# set up sources to build
set(PQComponentsSrcs
......@@ -12,7 +14,7 @@ set(PQComponentsHeaders
#install the headers
smtk_public_headers(${PQComponentsHeaders})
qt4_wrap_cpp(MOC_BUILT_SOURCES ${PQComponentsHeaders})
smtk_qt_wrap_cpp(MOC_BUILT_SOURCES ${PQComponentsHeaders})
source_group("Qt_Source" FILES ${PQComponentsSrcs} )
source_group("Qt_Generated" FILES ${MOC_BUILT_SOURCES} )
......@@ -25,13 +27,12 @@ add_library(smtkPQComponentsExt
#we need to add the location of the moc files to the include dir for smtkPWWidgetExt
target_include_directories(smtkPQComponentsExt PRIVATE ${CMAKE_CURRENT_BINARY_DIR})
#qt4_use_modules(smtkPQComponentsExt LINK_PUBLIC Core Gui)
#set smtkPQComponentsExt to publicly link to smtkCore
target_link_libraries(smtkPQComponentsExt LINK_PUBLIC
pqApplicationComponents
smtkQtExt
${QT_QTCORE_LIBRARY}
${qt_targets}
)
if (SMTK_ENABLE_TESTING)
......
include(${QT_USE_FILE})
smtk_find_package_qt(qt_targets REQUIRED
QT4_COMPONENTS QtCore QtGui
QT5_COMPONENTS Core Widgets)
# set up sources to build
set(PQWidgetsSrcs
......@@ -28,9 +30,9 @@ set(PQWidgetsHeaders
#install the headers
smtk_public_headers(${PQWidgetsHeaders})
qt4_wrap_cpp(MOC_BUILT_SOURCES ${PQWidgetsMocHeaders})
qt4_wrap_ui(UI_BUILT_SOURCES ${PQWidgetsUIs})
qt4_add_resources(RCS_RESOURCES qtWidgetsIcons.qrc)
smtk_qt_wrap_cpp(MOC_BUILT_SOURCES ${PQWidgetsMocHeaders})
smtk_qt_wrap_ui(UI_BUILT_SOURCES ${PQWidgetsUIs})
smtk_qt_add_resources(RCS_RESOURCES qtWidgetsIcons.qrc)
source_group("Qt_Source" FILES ${PQWidgetsSrcs} ${PQWidgetsUIs})
source_group("Qt_Generated" FILES ${MOC_BUILT_SOURCES} ${UI_BUILT_SOURCES} ${RCS_RESOURCES})
......@@ -45,15 +47,13 @@ add_library(smtkPQWidgetsExt
#we need to add the location of the moc files to the include dir for smtkPWWidgetExt
target_include_directories(smtkPQWidgetsExt PRIVATE ${CMAKE_CURRENT_BINARY_DIR})
#qt4_use_modules(smtkPQWidgetsExt LINK_PUBLIC Core Gui)
#set smtkPQWidgetsExt to publicly link to smtkCore
target_link_libraries(smtkPQWidgetsExt LINK_PUBLIC
pqApplicationComponents
vtkPVServerManagerRendering
smtkCore
${QT_QTGUI_LIBRARY}
${QT_QTCORE_LIBRARY}
${qt_targets}
)
if (SMTK_ENABLE_TESTING)
......
include(${QT_USE_FILE})
smtk_find_package_qt(qt_targets REQUIRED
QT4_COMPONENTS QtCore QtGui
QT5_COMPONENTS Core Widgets)
# set up sources to build
set(QAttrLibSrcs
......@@ -109,9 +111,9 @@ set(QAttrLibHeaders
#install the headers
smtk_public_headers(${QAttrLibHeaders})
qt4_wrap_cpp(MOC_BUILT_SOURCES ${QAttrLibMocHeaders})
qt4_wrap_ui(SMTKQTEXT_UI_BUILT_SOURCES ${QAttrLibUIs})
qt4_add_resources(RCS_RESOURCES qtEntityItemModelIcons.qrc qtAttributeIcons.qrc)
smtk_qt_wrap_cpp(MOC_BUILT_SOURCES ${QAttrLibMocHeaders})
smtk_qt_wrap_ui(SMTKQTEXT_UI_BUILT_SOURCES ${QAttrLibUIs})
smtk_qt_add_resources(RCS_RESOURCES qtEntityItemModelIcons.qrc qtAttributeIcons.qrc)
source_group("Qt_Source" FILES ${QAttrLibSrcs} ${QAttrLibUIs})
source_group("Qt_Generated" FILES ${MOC_BUILT_SOURCES} ${SMTKQTEXT_UI_BUILT_SOURCES} ${RCS_RESOURCES})
......@@ -127,14 +129,10 @@ add_library(smtkQtExt
#we need to add the location of the moc files to the include dir for qtsmtk
target_include_directories(smtkQtExt PRIVATE ${CMAKE_CURRENT_BINARY_DIR})
#set smtkQtExt to link to qtGUI and include dirs
#qt4_use_modules(smtkQtExt LINK_PUBLIC Core Gui)
#set smtkQtExt to publicly link to smtkCore
target_link_libraries(smtkQtExt LINK_PUBLIC
smtkCore
${QT_QTGUI_LIBRARY}
${QT_QTCORE_LIBRARY}
${qt_targets}
)
smtk_export_header(smtkQtExt Exports.h)
......@@ -142,10 +140,10 @@ smtk_export_header(smtkQtExt Exports.h)
smtk_install_library(smtkQtExt)
if (SMTK_ENABLE_TESTING)
# ... and make header compilation tests link properly:
target_link_libraries(TestBuild_smtk_extension_qt LINK_PRIVATE smtkQtExt)
endif()
if (SMTK_ENABLE_EXAMPLES)
add_subdirectory(examples)
endif()
##
## Create browseModel to test browsing model entity tree:
qt4_wrap_ui(browseModel_UI_BUILT_SOURCES ModelBrowser.ui)
smtk_qt_wrap_ui(browseModel_UI_BUILT_SOURCES ModelBrowser.ui)
add_executable(browseModel MACOSX_BUNDLE
browseModel.cxx
......@@ -17,8 +17,6 @@ set_target_properties(
browseModel PROPERTIES AUTOMOC TRUE
INSTALL_NAME_DIR "${CMAKE_INSTALL_PREFIX}/bin")
#qt4_use_modules(browseModel Core Gui)
##
## Create an application to test attribute editing
......@@ -63,6 +61,4 @@ set_target_properties(
browseMesh PROPERTIES AUTOMOC TRUE
INSTALL_NAME_DIR "${CMAKE_INSTALL_PREFIX}/bin")
# qt4_use_modules(browseMesh Core Gui)
target_link_libraries(browseMesh smtkCore smtkCoreModelTesting smtkQtExt)
......@@ -20,8 +20,8 @@
#include "smtk/model/EntityListPhrase.h"
#include "smtk/model/Manager.h"
#include <QtGui/QPushButton>
#include <QtGui/QTreeView>
#include <QPushButton>
#include <QTreeView>
namespace Ui { class qtAttributeAssociation; }
......
......@@ -13,7 +13,7 @@
#include "smtk/PublicPointerDefs.h"
#include "smtk/model/Group.h"
#include <QtGui/QWidget>
#include <QWidget>
class QTreeView;
class QModelIndex;
......
......@@ -22,9 +22,9 @@
#include "smtk/common/testing/cxx/helpers.h"
#include "smtk/model/testing/cxx/helpers.h"
#include <QtGui/QApplication>
#include <QtGui/QTreeView>
#include <QtGui/QHeaderView>
#include <QApplication>
#include <QTreeView>
#include <QHeaderView>
// Mesh related includes
#include "smtk/io/ModelToMesh.h"
......
......@@ -22,9 +22,9 @@
#include "smtk/common/testing/cxx/helpers.h"
#include "smtk/model/testing/cxx/helpers.h"
#include <QtGui/QApplication>
#include <QtGui/QTreeView>
#include <QtGui/QHeaderView>
#include <QApplication>
#include <QTreeView>
#include <QHeaderView>
#include <iomanip>
#include <iostream>
......
......@@ -337,12 +337,21 @@ void qtAttributeView::createWidget( )
BottomLayout->addWidget(this->Internals->AssociationsWidget);
BottomLayout->addWidget(this->Internals->ReferencesWidget);
#if QT_VERSION >= 0x050000
this->Internals->ListTable->horizontalHeader()->setSectionResizeMode(
QHeaderView::ResizeToContents);
this->Internals->ValuesTable->horizontalHeader()->setSectionResizeMode(
QHeaderView::ResizeToContents);
this->Internals->ValuesTable->verticalHeader()->setSectionResizeMode(
QHeaderView::ResizeToContents);
#else
this->Internals->ListTable->horizontalHeader()->setResizeMode(
QHeaderView::ResizeToContents);
this->Internals->ValuesTable