# Path: fuzzinator/pkgdata.py

# 
# Path: fuzzinator/ui/tui/button.py
# class FormattedButton(WidgetWrap):
#     signals = ['click']
#     _selectable = True
# 
#     def __init__(self, label, on_press=None, user_data=None, style='button'):
#         self.text_len = len(label)
#         self.btn = ShortButton(label, on_press, user_data)
#         super().__init__(AttrMap(self.btn, style))
#         connect_signal(self.btn, 'click', lambda btn: self._emit('click'))
# 
#     def sizing(self):
#         return frozenset(['fixed'])
# 
#     def pack(self, size=None, focus=None):
#         return self.text_len + 6, 1


from ast import literal_eval
from datetime import datetime
from urwid import *
from ...config import config_get_object
from ...formatter import JsonFormatter
from ...pkgdata import __author__, __author_email__, __pkg_name__, __url__, __version__
from .button import FormattedButton
from .decor_widgets import PatternBox
from .graphics import fz_box_pattern
                except IndexError:
                    self.frame.focus_part = 'footer'
                    self.frame.footer.focus_col = 0
            elif self.frame.footer and self.frame.footer.contents:
                if self.frame.footer.focus_col < len(self.frame.footer.contents) - 1:
                    self.frame.footer.focus_col += 1
                else:
                    self.frame.focus_part = 'body'
                    self.listbox.focus_position = 0
            return None
        return super().keypress(size, key)


class AboutDialog(Dialog):
    exit_keys = ['esc', 'f1']

    def __init__(self, ):
        self.content = self.compile_about_data()
        super().__init__(title='About',
                         body=[Text(self.content)],
                         footer_btns=[FormattedButton('Close', lambda button: self._emit('close'))])

    def compile_about_data(self, prop_width=15):
        return '{name_prop}: {name}\n' \
               '{version_prop}: {version}\n' \
               '{authors_prop}: {authors}\n' \
               '{mail_prop}: {email}\n' \
               '{homepage_prop}: {homepage}\n'.format(name_prop='Name'.ljust(prop_width),
                                                      name=__pkg_name__,
                                                      version_prop='Version'.ljust(prop_width),

# Path: fuzzinator/pkgdata.py

# 
# Path: fuzzinator/ui/tui/button.py
# class FormattedButton(WidgetWrap):
#     signals = ['click']
#     _selectable = True
# 
#     def __init__(self, label, on_press=None, user_data=None, style='button'):
#         self.text_len = len(label)
#         self.btn = ShortButton(label, on_press, user_data)
#         super().__init__(AttrMap(self.btn, style))
#         connect_signal(self.btn, 'click', lambda btn: self._emit('click'))
# 
#     def sizing(self):
#         return frozenset(['fixed'])
# 
#     def pack(self, size=None, focus=None):
#         return self.text_len + 6, 1


# Path: fuzzinator/ui/tui/dialogs.py
from ast import literal_eval
from datetime import datetime
from urwid import *
from ...config import config_get_object
from ...formatter import JsonFormatter
from ...pkgdata import __author__, __author_email__, __pkg_name__, __url__, __version__
from .button import FormattedButton
from .decor_widgets import PatternBox
from .graphics import fz_box_pattern

                except IndexError:
                    self.frame.focus_part = 'footer'
                    self.frame.footer.focus_col = 0
            elif self.frame.footer and self.frame.footer.contents:
                if self.frame.footer.focus_col < len(self.frame.footer.contents) - 1:
                    self.frame.footer.focus_col += 1
                else:
                    self.frame.focus_part = 'body'
                    self.listbox.focus_position = 0
            return None
        return super().keypress(size, key)


class AboutDialog(Dialog):
    exit_keys = ['esc', 'f1']

    def __init__(self, ):
        self.content = self.compile_about_data()
        super().__init__(title='About',
                         body=[Text(self.content)],
                         footer_btns=[FormattedButton('Close', lambda button: self._emit('close'))])

    def compile_about_data(self, prop_width=15):
        return '{name_prop}: {name}\n' \
               '{version_prop}: {version}\n' \
               '{authors_prop}: {authors}\n' \
               '{mail_prop}: {email}\n' \
               '{homepage_prop}: {homepage}\n'.format(name_prop='Name'.ljust(prop_width),
                                                      name=__pkg_name__,
                                                      version_prop='Version'.ljust(prop_width),

                                                      version=__version__,