Frameworks-QtSupport¶
Configuration support for projects using Qt
Required inputs: IR
This rule simplifies the configuration of projects using Qt.
It suppresses issues resulting from the required used
of Qt macros like Q_OBJECT and it evaluates calls to Qt's
connect() function to determine call relations for the
connection between signals and slots.
Also it adds filename patterns
*/mocs_compilation*.cpp*/moc_*.cpp*.moc*/qrc_*.cpp*/ui_*.h*/qmlcache/*mocs_compilation*.cppmoc_*.cppqrc_*.cppui_*.hqmlcache/*
For Qt-specific rules, there exists the rulegroup Qt.
Possible Messages
This rule has no predefined messages.
Options¶
The following places define options that affect this rule: Analysis-GlobalOptions
create_qt_connect_edges¶
create_qt_connect_edges : bool = True
Qt_MetaObject_Call edges between
signals and slots that are connected with detectable connect()
calls. Qt_Connect_Signal and Qt_Connect_Slot edges are
created between routines containing connect() calls and the
referenced signals and slots respectively. All these edges are created and
inserted into the views Code Facts and Declaration
Facts.
exclude_qt_generated_files¶
exclude_qt_generated_files : bool = True
*/mocs_compilation*.cpp*/moc_*.cpp*.moc*/qrc_*.cpp*/ui_*.h*/qmlcache/*mocs_compilation*.cppmoc_*.cppqrc_*.cppui_*.hqmlcache/*
qt_exclude_in_macros¶
qt_exclude_in_macros : set[str] = {'Q_DECLARE_*', 'Q_DISABLE_COPY', 'Q_ENUM', 'Q_GADGET', 'Q_GLOBAL_STATIC', 'Q_OBJECT'}
qt_exclude_patterns¶
qt_exclude_patterns
Filename patterns for files generated by Qt.Type: set[bauhaus.analysis.config.FileGlobPattern]
Default:
{'*.moc', '*/moc_*.cpp', '*/mocs_compilation*.cpp', '*/qmlcache/*', '*/qrc_*.cpp', '*/ui_*.h', 'moc_*.cpp', 'mocs_compilation*.cpp', 'qmlcache/*', 'qrc_*.cpp', 'ui_*.h'}
qt_types¶
qt_types : set[bauhaus.analysis.config.QualifiedName] = {'QObject'}
qtdir¶
qtdir : bauhaus.analysis.config.LayerRelativePath | None = None