angrybeanie_wagtail/env/lib/python3.12/site-packages/willow/optimizers/gifsicle.py

21 lines
502 B
Python
Raw Permalink Normal View History

2025-07-25 21:32:16 +10:00
from typing import ClassVar
from .base import OptimizerBase
__all__ = ["Gifsicle"]
class Gifsicle(OptimizerBase):
"""http://www.lcdf.org/gifsicle/"""
library_name: ClassVar[str] = "gifsicle"
image_format: ClassVar[str] = "gif"
@classmethod
def get_command_arguments(cls, file_path: str) -> list[str]:
return [
"-b", # required parameter for the package
"-O3", # slowest, but produces best results
file_path, # the file
]