#!/bin/python
# -*- coding: utf-8 -*-
"""
help_screen.py
Lines to be displayed on the help screen.

Author: GrimAndGreedy
License: MIT
"""

help_lines = [
    ['Navigation:',                     ''],
    ['    Up/Down and k/j',              'Move up/down'],
    ['    K and J',                         'Move up/down by five'],
    ['    Ctrl+f and Ctrl+b',                         'Page up/down'],
    ['    u and d',                         'Half page up/down'],
    ['    g/home',                   'Go to top of page'],
    ['    G/end',                    'Go to bottom of page'],
    ['',                             ''],
    ['Selection:',                      ''],
    ['    Space',                       'Toggle selection'],
    ['    m or ^a',                    'Select all'],
    ['    M or ^r',                    'Deselect all'],
    ['    v',                           'Start and stop visual selection'],
    ['    V',                           'Start and stop visual deselection'],
    ['    l/Enter',                     'Submit selection'],
    ['',                             ''],
    ['Modes:',                           ''],
    ['    Tab',                           'Cycle between modes forwards'],
    ['    Shift+Tab',                           'Cycle between modes backwards'],
    ['',                             ''],
    ['Sorting:',                        ''],
    ['    0-9',                         'Select column (1-based index)'],
    ['    </>',                         'Focus on next/previous column'],
    ['    s',                           'Cycle sort method'],
    ['    t',                           'Toggle sort order (asc. or desc.)'],
    ['',                             ''],
    ['Filter or search rows (regexp):',                    ''],
    ['    f',                           'Begin filtering rows'],
    ['    /',                           'Begin searching rows'],
    ['      --[1-9]',                   'Specify column'],
    ['      --i',                       'Make match case sensitive'],
    ['      --v',                       'Invert filter'],
    ['    n/i',                       'Continue search forwards'],
    ['    N/I',                       'Continue search backwards'],
    ['',                             ''],
    ['Pipe',                    ''],
    ['    |',                           'Pipe selected rows from active column into a specified command'],
    ['    e.g.,',                           'xargs -d \n -I{} echo {} > ~/rubbish.txt'],
    ['    e.g.,',                           'xargs -d \n -I{} mpv {}'],
    ['',                             ''],

    ['Load and Save',                    ''],
    ['    Ctrl+s',                           'Open save dialog. Then pick output type and location to save.'],
    ['    Ctrl+o',                           'Open previously saved data.'],
    ['',                             ''],
    ['Columns:',                         ''],
    ['    0-9',                         'Select column (1-based index)'],
    ['    </>',                         'Focus on next/previous column'],
    ['    Shift+1-9',                   'Hide/show column'],
    ['    [/]',                         'Increase/Decrease column width'],
    # ['    {',                           'Move focused column left'],
    # ['    }',                           'Move focused column right'],
    ['',                             ''],
    ['Clipboard:',                      ''],
    ['    y',                           'Open dialogue to select how you want the selected rows to be copied'],
    ['',                             ''],
    ['Settings:',                           ''],
    ['    ~',                           'Open settings picker'],
    ['    `',                           'settings input'],
    ['        !\\d+',                       'Show/hide column'],
    ['        !r',                          'toggle auto refresh'],
    ['    \\',                          'Clear settings'],
    ['',                             ''],
    ['Input fields:',                           ''],
    ['    Ctrl+r',                           'Insert current cell (cursor, sort_col) into input bar'],
    ['    Ctrl+e',                           'End'],
    ['    Ctrl+a',                           'Start'],
    ['    Ctrl+u',                           'Delete to start'],
    ['    Ctrl+k',                           'Delete to end'],
    ['    Ctrl+f/Ctrl+b',                           'Forwards/Backwards one character.'],
    ['Misc:',                           ''],
    ['    ?',                           'Show this help screen'],
    ['    _',                           'Quick toggle footer'],
    ['    O',                           'Try to open the data in the focused column of the selected rows as file paths.'],
    ['        ',                           'You may need to change the cwd by pressing ` and then entering e.g., "cwd=~/Pictures"'],
    ['    +',                           'Increase lines per page'],
    ['    -',                           'Decrease lines per page'],
    ['    :',                           'Specify user optios to be returned with selection'],
    ['    o',                           'Open submenu to specify option'],
    ['    q',                           'Exit menu with no selection.'],
    ['    ?',                           'Show this help page'],
    ['    Ctrl+c',                           'Immediate quit.'],
    ['    Ctrl+l',                           'Redraw screen.'],
    ['    .',                           'Redo setting'],
    ['',                             ''],
]
