diff --git a/examples/terminal/powerline.py b/examples/terminal/powerline.py index d16cdb4f..dafbf340 100755 --- a/examples/terminal/powerline.py +++ b/examples/terminal/powerline.py @@ -7,16 +7,16 @@ import os import sys sys.path.append(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) -from lib.core import Powerline, Segment +from lib.core import Powerline, mksegment from lib.renderers import TerminalSegmentRenderer powerline = Powerline([ - Segment('⭤ SSH', 220, 166, attr=Segment.ATTR_BOLD), - Segment('username', 153, 31), - Segment('~', 248, 239), - Segment('projects', 248, 239), - Segment('powerline', 231, 239, attr=Segment.ATTR_BOLD), - Segment(filler=True), + mksegment('⭤ SSH', 220, 166, attr=Powerline.ATTR_BOLD), + mksegment('username', 153, 31), + mksegment('~', 248, 239), + mksegment('projects', 248, 239), + mksegment('powerline', 231, 239, attr=Powerline.ATTR_BOLD), + mksegment(filler=True), ]) print(powerline.render(TerminalSegmentRenderer()))