|
Tulip
5.6.0
Large graphs analysis and drawing
|
26 #include <tulip/Color.h>
27 #include <tulip/tulipconf.h>
28 #include <tulip/PropertyInterface.h>
37 TLP_QT_SCOPE
bool getColorDialog(
const QColor &color, QWidget *parent,
const QString &title,
40 inline QColor colorToQColor(
const Color &color) {
41 return QColor(color.getR(), color.getG(), color.getB(), color.getA());
43 inline Color QColorToColor(
const QColor &color) {
44 return Color(color.red(), color.green(), color.blue(), color.alpha());
50 return std::string(toConvert.toUtf8());
56 return QString::fromUtf8(toConvert.c_str());
63 return QString::localeAwareCompare(s1, s2) < 0;
98 TLP_QT_SCOPE QString getPluginStagingDirectory();
100 TLP_QT_SCOPE QString getPluginLocalInstallationDir();
102 TLP_QT_SCOPE QString localPluginsPath();
114 bool removeDiscardedPlugins =
false);
131 TLP_QT_SCOPE
void disableQtUserInput();
133 TLP_QT_SCOPE
void enableQtUserInput();
142 inline QDebug
operator<<(QDebug dbg,
const std::string &s) {
143 dbg.nospace() << s.c_str();
148 #if (QT_VERSION < QT_VERSION_CHECK(5, 15, 0))
151 #define QT_ENDL Qt::endl
156 #define SET_TOOLTIP_WITH_CTRL_SHORTCUT(a, tt, sc) \
157 a->setToolTip(QString(tt) + tlpStringToQString(" [⌘+") + sc + "]")
159 #define SET_TOOLTIP_WITH_CTRL_SHORTCUT(a, tt, sc) a->setToolTip(QString(tt) + " [Ctrl+" + sc + "]")
162 #define SET_TIPS_WITH_CTRL_SHORTCUT(a, tt, sc) \
163 SET_TOOLTIP_WITH_CTRL_SHORTCUT(a, tt, sc); \
164 a->setStatusTip(a->toolTip())
void initTulipSoftware(PluginLoader *loader=nullptr, bool removeDiscardedPlugins=false)
Sets up environment when creating an executable using Tulip libraries This method performs basic oper...
QString propertyInterfaceToPropertyTypeLabel(const tlp::PropertyInterface *const property)
Get the string to display as property type for the given property. The property type label is the str...
virtual const std::string & getTypename() const =0
Gets a string describing the type of the property value (e.g. "graph", "double", "layout",...
void convertLikeFilter(QString &filter)
convert sql like filter into an acceptable regexp
PropertyInterface describes the interface of a graph property.
void redirectErrorOutputToQCritical()
redirect tlp::error() to qCritical()
std::string propertyTypeLabelToPropertyType(const QString &typeNameLabel)
Convert the label of a property type to it's corresponding property type. The property type label is ...
std::ostream & operator<<(std::ostream &os, const Array< T, N > &array)
operator << stream operator to easily print an array, or save it to a file.
std::string QStringToTlpString(const QString &toConvert)
Convert a QString to a Tulip UTF-8 encoded std::string.
void redirectDebugOutputToQDebug()
redirect tlp::debug() to qDebug()
QString getPluginPackageName(const QString &pluginName)
Gets the name of the package to retrieve for this version of tulip. The package name uses the Tulip r...
void redirectWarningOutputToQWarning()
redirect tlp::warning() to qWarning()
QString propertyTypeToPropertyTypeLabel(const std::string &typeName)
Convert the property type string to a label to display in the GUI. The property type label is the str...
QString tlpStringToQString(const std::string &toConvert)
Convert a Tulip UTF-8 encoded std::string to a QString.
bool QStringCaseCmp(const QString &s1, const QString &s2)
Case insensitive comparison of two QStrings.