-
Notifications
You must be signed in to change notification settings - Fork 15
Spaces in Segments #26
base: master
Are you sure you want to change the base?
Conversation
o0th
commented
Oct 5, 2016
•
edited
Loading
edited
@@ -18,6 +20,15 @@ def __init__(self, *args, **kwargs): | |||
# Other segments are active if the config files states so. | |||
self.active = config.SEGMENTS.get(class_name, False) | |||
|
|||
if( config.SPACES ): | |||
if class_name not in ['newline', 'root', 'divider', 'padding', 'exitcode']: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's clear to me why NOT adding right and left spaces for newline, divider, padding. But why root and exitcode?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
for ExitCode
there are already two spaces
self.text = ' ' + glyphs.CROSS + ' '
I don't like how it appear with more.
For the Root
I think it's better this way so it seam a normal prompt line.
I think it's a matter of preference.
|
||
if(class_name == 'git'): | ||
self.ls = True | ||
self.rs = False |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why not right space for git?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It seemed to me there is already a whitespace on the right side, maybe I'm wrong. I will investigate after work.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
OK, I like the changes! I'd also like to improve a bit the code and provide a smoother way to customise the theme. Will do it in the next days/weekend.
Thank you @nimiq and sorry for the bad code. I'm not a python developer :) |