def _format_headers(tabs, current_tab_number, line_length):
    """Formats just the tab portion if the config specifies a multi-tab menu

    Called from format_menu()

    Args:
        tabs (list of tab.Tab): list of Tab objects
        current_tab_number (int): number of currently selected tab (always 0 for single-tabbed menus)
        line_length (int): value from config

    Returns:
        (list of str) individual lines to be sent to stdout representing headers, and
                      indicating the currently selected header
    """
    current_line_length = 0
    top_text = []
    bottom_text = []
    for i, tab in enumerate(tabs):
        abbreviation = tab['tab_header_input']
        description = tab.get('tab_header_description', None)
        if description is None:
            description = ''
        if i == current_tab_number:
            bottom_char = '='
        else:
            bottom_char = '-'
        if description:
            spacer = ':'
        else:
            spacer = ''
        if i == 0:
            start = '['
        else:
            start = '|'
        if i == len(tabs) - 1:
            end = ']'
        else:
            end = ''
        new_top_entry = '{0}{1}{2}{3}{4}'.format(start, abbreviation,
            spacer, description, end)
        if current_line_length + len(new_top_entry) > line_length - 1:
            top_text.append('\n')
            bottom_text.append('\n')
            current_line_length = 0
        top_text.append(new_top_entry)
        bottom_text.append(' ' + bottom_char * (len(new_top_entry) - 1))
        current_line_length += len(new_top_entry)
    top_text = ''.join(top_text).split('\n')
    bottom_text = ''.join(bottom_text).split('\n')
    total_text = []
    for top, bottom in zip(top_text, bottom_text):
        total_text.append(top)
        total_text.append(bottom)
    return total_text
