summary refs log tree commit diff stats
path: root/ranger/gui/widgets/__init__.py
blob: 9a95509c621d42283a24bb799bb96478c8c9db19 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
# -*- coding: utf-8 -*-

from ranger.gui.displayable import Displayable


class Widget(Displayable):
    """A class for classification of widgets."""

    vcsstatus_symb = {
        'conflict':  ('X', ['vcsconflict']),
        'untracked': ('+', ['vcschanged']),
        'deleted':   ('-', ['vcschanged']),
        'changed':   ('*', ['vcschanged']),
        'staged':    ('*', ['vcsstaged']),
        'ignored':   ('·', ['vcsignored']),
        'sync':      ('√', ['vcssync']),
        'none':      (' ', []),
        'unknown':   ('?', ['vcsunknown']),
    }

    vcsremotestatus_symb = {
        'diverged': ('Y', ['vcsdiverged']),
        'ahead':    ('>', ['vcsahead']),
        'behind':   ('<', ['vcsbehind']),
        'sync':     ('=', ['vcssync']),
        'none':     ('⌂', ['vcsnone']),
        'unknown':  ('?', ['vcsunknown']),
    }

    ellipsis = {False: '~', True: '…'}