示例#1
0
文件: label.py 项目: pybee/toga
    def create(self):
        self.native = UILabel.new()
        self.native.impl = self
        self.native.interface = self

        self.native.lineBreakMode = NSLineBreakByWordWrapping

        # Add the layout constraints
        self.add_constraints()
示例#2
0
    def create(self):
        self.native = UILabel.new()
        self.native.impl = self
        self.native.interface = self

        self.native.lineBreakMode = NSLineBreakByWordWrapping

        # Add the layout constraints
        self.add_constraints()
示例#3
0
    def create(self):
        self.native = UILabel.new()
        self.native.interface = self

        self.native.setTranslatesAutoresizingMaskIntoConstraints_(False)
        self.native.setLineBreakMode_(NSLineBreakByWordWrapping)

        # Add the layout constraints
        self.add_constraints()