Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
FSL
fsleyes
fsleyes-props
Commits
cd04a392
Commit
cd04a392
authored
May 21, 2020
by
Paul McCarthy
🚵
Browse files
ENH: Add HasProps alias
parent
b3ce317b
Changes
2
Hide whitespace changes
Inline
Side-by-side
fsleyes_props/__init__.py
View file @
cd04a392
...
@@ -304,6 +304,7 @@ log = logging.getLogger(__name__)
...
@@ -304,6 +304,7 @@ log = logging.getLogger(__name__)
from
.properties
import
(
from
.properties
import
(
PropertyOwner
,
PropertyOwner
,
HasProperties
,
HasProperties
,
HasProps
,
DisabledError
)
DisabledError
)
from
.properties_value
import
(
from
.properties_value
import
(
...
...
fsleyes_props/properties.py
View file @
cd04a392
...
@@ -532,6 +532,9 @@ class HasProperties(object):
...
@@ -532,6 +532,9 @@ class HasProperties(object):
"""Base class for classes which contain ``PropertyBase`` instances. All
"""Base class for classes which contain ``PropertyBase`` instances. All
classes which contain ``PropertyBase`` objects must subclass this
classes which contain ``PropertyBase`` objects must subclass this
class.
class.
.. note:: ``HasProperties`` is also available via an alias called
:attr:`HasProps`.
"""
"""
...
@@ -1051,3 +1054,7 @@ class HasProperties(object):
...
@@ -1051,3 +1054,7 @@ class HasProperties(object):
lines
.
append
(
fmtStr
.
format
(
propName
,
propVal
))
lines
.
append
(
fmtStr
.
format
(
propName
,
propVal
))
return
'
\n
'
.
join
(
lines
)
return
'
\n
'
.
join
(
lines
)
HasProps
=
HasProperties
"""``HasProps`` is simply an alias for :class:`HasProperties`. """
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment