Updated for version alignment

This commit is contained in:
Dimitris Zlatanidis 2023-05-12 13:11:16 +03:00
parent a0324a11a6
commit 16a7f29bca

View file

@ -62,7 +62,7 @@ class Ascii(Configs):
def draw_package_line(self, package: str, version: str, size: str, color: str, repo: str) -> None:
""" Draw nad print the packages. """
if len(version) >= 11 and self.columns <= 80:
version: str = f'{version[:10]}...'
version: str = f'{version[:self.version_alignment - 5]}...'
if len(package) >= 10 and self.columns <= 80:
package: str = f'{package[:self.package_alignment - 5]}...'