PEP8, mkdocs format, v1.0.2

This commit is contained in:
DarkCat09 2022-11-01 16:38:34 +04:00
parent 69209f8b70
commit 60cabb92cf
3 changed files with 7 additions and 7 deletions

View file

@ -7,6 +7,7 @@ upload:
clean: clean:
rm -rf dist/ rm -rf dist/
rm -rf showdialog/__pycache__/ rm -rf showdialog/__pycache__/
rm -rf .mypy_cache/
check: check:
python -m mypy . python -m mypy .

View file

@ -5,7 +5,7 @@ with open('README.md', 'rt') as f:
setuptools.setup( setuptools.setup(
name='showdialog', name='showdialog',
version='1.0.1', version='1.0.2',
author='Chechkenev Andrey (@DarkCat09)', author='Chechkenev Andrey (@DarkCat09)',
author_email='aacd0709@mail.ru', author_email='aacd0709@mail.ru',
description='Simple module for showing GTK dialog', description='Simple module for showing GTK dialog',

View file

@ -17,15 +17,14 @@ def show_msg(
sectext: TxtType = None, sectext: TxtType = None,
btns: Gtk.ButtonsType = Gtk.ButtonsType.OK, btns: Gtk.ButtonsType = Gtk.ButtonsType.OK,
msgtype: Gtk.MessageType = Gtk.MessageType.INFO) -> None: msgtype: Gtk.MessageType = Gtk.MessageType.INFO) -> None:
"""Opens GTK MessageDialog """Opens GTK MessageDialog
Args: Args:
title (str): Dialog caption title (str): Dialog caption
text (TxtType): Dialog primary text, str or tuple (text, use_markup) text (TxtType): Dialog primary text, str or tuple: `(text, use_markup)`
sectext (TxtType, optional): Dialog secondary text, str or tuple. Defaults to None. sectext (TxtType, optional): Dialog secondary text, str or tuple
btns (Gtk.ButtonsType, optional): Dialog buttons. Defaults to Gtk.ButtonsType.OK. btns (Gtk.ButtonsType, optional): Dialog buttons
msgtype (Gtk.MessageType, optional): Dialog message type. Defaults to Gtk.MessageType.INFO. msgtype (Gtk.MessageType, optional): Dialog message type
""" """
if isinstance(text, str) or text is None: if isinstance(text, str) or text is None:
@ -41,7 +40,7 @@ def show_msg(
secondary_text=sectxt[0], secondary_text=sectxt[0],
secondary_use_markup=sectxt[1], secondary_use_markup=sectxt[1],
buttons=btns, buttons=btns,
message_type=msgtype message_type=msgtype,
) )
msg.connect( msg.connect(