mirror of
https://github.com/qgis/QGIS.git
synced 2025-10-06 00:07:29 -04:00
Correctly add int types to flag style enum classes
This commit is contained in:
parent
0bc45a4c90
commit
2bef88b031
@ -310,7 +310,7 @@ A proxy model for filtering QgsProjectStyleDatabaseModel.
|
||||
%End
|
||||
public:
|
||||
|
||||
enum class Filter
|
||||
enum class Filter /BaseType=IntFlag/
|
||||
{
|
||||
FilterHideReadOnly,
|
||||
};
|
||||
|
@ -231,7 +231,7 @@ The development version
|
||||
UnknownCount,
|
||||
};
|
||||
|
||||
enum class VectorDataProviderAttributeEditCapability
|
||||
enum class VectorDataProviderAttributeEditCapability /BaseType=IntFlag/
|
||||
{
|
||||
EditAlias,
|
||||
EditComment,
|
||||
|
@ -23,7 +23,7 @@ Utilities for map settings.
|
||||
%End
|
||||
public:
|
||||
|
||||
enum class EffectsCheckFlag
|
||||
enum class EffectsCheckFlag /BaseType=IntFlag/
|
||||
{
|
||||
IgnoreGeoPdfSupportedEffects,
|
||||
};
|
||||
|
@ -25,7 +25,7 @@ custom labeling.
|
||||
%End
|
||||
public:
|
||||
|
||||
enum class Flag
|
||||
enum class Flag /BaseType=IntFlag/
|
||||
{
|
||||
FlagUsesLineSymbol,
|
||||
FlagUsesFillSymbol,
|
||||
|
@ -1368,8 +1368,7 @@ while ($LINE_IDX < $LINE_COUNT){
|
||||
$py_flag =~ s/::/./;
|
||||
|
||||
if ( any { $_ eq $py_flag } @ENUM_CLASS_NON_INT_TYPES ){
|
||||
# TODO: Clear existing errors and then enable:
|
||||
# exit_with_error("$flag is a flags type, but was not declared with int type. Add ': int' to the enum class declaration line");
|
||||
exit_with_error("$flag is a flags type, but was not declared with int type. Add ': int' to the enum class declaration line");
|
||||
}
|
||||
elsif ( none { $_ eq $py_flag } @ENUM_INT_TYPES ){
|
||||
if ( $is_qt6 ) {
|
||||
|
@ -375,7 +375,7 @@ class CORE_EXPORT QgsProjectStyleDatabaseProxyModel : public QSortFilterProxyMod
|
||||
public:
|
||||
|
||||
//! Available filter flags for filtering the model
|
||||
enum class Filter
|
||||
enum class Filter : int
|
||||
{
|
||||
FilterHideReadOnly = 1 << 0, //!< Hide read-only style databases
|
||||
};
|
||||
|
@ -344,7 +344,7 @@ class CORE_EXPORT Qgis
|
||||
*
|
||||
* \since QGIS 3.32
|
||||
*/
|
||||
enum class VectorDataProviderAttributeEditCapability
|
||||
enum class VectorDataProviderAttributeEditCapability : int
|
||||
{
|
||||
EditAlias = 1 << 0, //!< Allows editing aliases
|
||||
EditComment = 1 << 1, //!< Allows editing comments
|
||||
|
@ -38,7 +38,7 @@ class CORE_EXPORT QgsMapSettingsUtils
|
||||
* Flags for controlling the behavior of containsAdvancedEffects()
|
||||
* \since QGIS 3.14
|
||||
*/
|
||||
enum class EffectsCheckFlag
|
||||
enum class EffectsCheckFlag : int
|
||||
{
|
||||
IgnoreGeoPdfSupportedEffects = 1 << 0, //!< Ignore advanced effects which are supported in GeoPDF exports
|
||||
};
|
||||
|
@ -43,7 +43,7 @@ class CORE_EXPORT QgsScaleBarRenderer
|
||||
* Flags which control scalebar renderer behavior.
|
||||
* \since QGIS 3.14
|
||||
*/
|
||||
enum class Flag
|
||||
enum class Flag : int
|
||||
{
|
||||
FlagUsesLineSymbol = 1 << 0, //!< Renderer utilizes the scalebar line symbol (see QgsScaleBarSettings::lineSymbol() )
|
||||
FlagUsesFillSymbol = 1 << 1, //!< Renderer utilizes the scalebar fill symbol (see QgsScaleBarSettings::fillSymbol() )
|
||||
|
Loading…
x
Reference in New Issue
Block a user