Skip to content

kivy-code-quality-5 #2289

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 7 commits into
base: v0.6
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 26 additions & 0 deletions src/bitmessagekivy/baseclass/common.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,32 @@
}


class ChipProperties:

Check warning on line 47 in src/bitmessagekivy/baseclass/common.py

View check run for this annotation

PyBitmessage Code Quality Checks / Code Quality - pylint

W0232 / no-init

Class has no __init__ method

Check notice on line 47 in src/bitmessagekivy/baseclass/common.py

View check run for this annotation

PyBitmessage Code Quality Checks / Code Quality - pylint

C1001 / old-style-class

Old-style class defined.

Check notice on line 47 in src/bitmessagekivy/baseclass/common.py

View check run for this annotation

PyBitmessage Code Quality Checks / Code Quality - pylint

R0903 / too-few-public-methods

Too few public methods (0/2)
"""ChipProperties class for kivy UI"""
CENTER_X_ANDROID = 0.91
CENTER_X_OTHER = 0.94
CENTER_Y = 0.3
HEIGHT_DP = 18
RADIUS = [8]
TEXT_COLOR = (1, 1, 1, 1)
SIZE_HINT_ANDROID = (0.16, None)
SIZE_HINT_OTHER = (0.08, None)


class BadgeProperties:

Check warning on line 59 in src/bitmessagekivy/baseclass/common.py

View check run for this annotation

PyBitmessage Code Quality Checks / Code Quality - pylint

W0232 / no-init

Class has no __init__ method

Check notice on line 59 in src/bitmessagekivy/baseclass/common.py

View check run for this annotation

PyBitmessage Code Quality Checks / Code Quality - pylint

C1001 / old-style-class

Old-style class defined.

Check notice on line 59 in src/bitmessagekivy/baseclass/common.py

View check run for this annotation

PyBitmessage Code Quality Checks / Code Quality - pylint

R0903 / too-few-public-methods

Too few public methods (0/2)
"""BadgeProperties class for kivy UI"""
SIZE_ANDROID = [120, 140]
SIZE_OTHER = [64, 80]
FONT_SIZE = "11sp"


DIALOG_WIDTH_ANDROID = 0.8
DIALOG_WIDTH_OTHER = 0.55
DIALOG_HEIGHT = 0.25
LONG_PRESS_DURATION = 1
DELETE_DELAY = 4


def load_image_path():
"""Return the path of kivy images"""
image_path = os.path.abspath(os.path.join('pybitmessage', 'images', 'kivy'))
Expand Down
Loading