I'm trying to code my first GUI with Enaml and I can't figure out the reference to Atom when they're creating a class. I know it's an IDE (I'm using PyCharm) but I'm not sure if that's what it's even referencing. I can't find seem to find any helpful documentation online. Can you explain it to me in this example code from their documentation? I've formatted it below:
class Person(Atom):
""" A simple class representing a person object.
"""
last_name = Unicode()
first_name = Unicode()
age = Range(low=0)
debug = Bool(False)
@observe('age')
def debug_print(self, change):
""" Prints out a debug message whenever the person's age changes.
"""
if self.debug:
templ = "{first} {last} is {age} years old."
s = templ.format(
first=self.first_name, last=self.last_name, age=self.age,
)
print(s)
I thought I should mention this isn't the entire file provided in the linked documentation!
edit: I missed some helpful stuff on their github where I found more, albeit still lacking, documentation.