mirror of
https://github.com/ful1e5/apple_cursor.git
synced 2025-05-23 03:27:08 -04:00
💝 Smooth animation
This commit is contained in:
parent
e71b23738f
commit
e4aa2ccbee
4 changed files with 17 additions and 13 deletions
|
@ -10,7 +10,7 @@ AUTHOR = "Kaiz Khatri"
|
|||
URL = "https://github.com/ful1e5/apple_cursor"
|
||||
|
||||
# XCursor
|
||||
X_DELAY: int = 5
|
||||
X_DELAY: int = 10
|
||||
X_SIZES: List[Tuple[int, int]] = [
|
||||
(22, 22),
|
||||
(24, 24),
|
||||
|
@ -28,7 +28,7 @@ X_SIZES: List[Tuple[int, int]] = [
|
|||
|
||||
|
||||
# Windows Cursor
|
||||
WIN_DELAY = 3
|
||||
WIN_DELAY = 1
|
||||
CANVAS_SIZE = (32, 32)
|
||||
SIZE = (24, 24)
|
||||
|
||||
|
@ -91,7 +91,7 @@ WIN_CURSORS_CFG: Dict[str, Dict[str, str]] = {
|
|||
# Static
|
||||
#
|
||||
"right_ptr.png": {"to": "Alternate", "position": "top_left"},
|
||||
"cross.png": {"to": "Cross"},
|
||||
"cross.png": {"to": "Cross", "size": (32, 32)},
|
||||
"left_ptr.png": {"to": "Default", "position": "top_left"},
|
||||
"bottom_left_corner.png": {"to": "Diagonal_1"},
|
||||
"bottom_right_corner.png": {"to": "Diagonal_2"},
|
||||
|
|
|
@ -36,7 +36,7 @@ def xbuild(bitmaps_dir: LikePath, x_out_dir: Path) -> None:
|
|||
|
||||
with CursorAlias.from_bitmap(png, hotspot) as alias:
|
||||
x_cfg = alias.create(X_SIZES, delay)
|
||||
print(f"Building {x_cfg.stem} XCursor...")
|
||||
print(f"Building '{x_cfg.stem}' XCursor...")
|
||||
XCursor.create(x_cfg, x_out_dir)
|
||||
|
||||
add_missing_xcursor(x_out_dir / "cursors")
|
||||
|
@ -67,11 +67,12 @@ def wbuild(bitmaps_dir: LikePath, win_out_dir: Path) -> None:
|
|||
size = item["size"]
|
||||
win_key = item["win_key"]
|
||||
canvas_size = item["canvas_size"]
|
||||
win_delay = item["win_delay"]
|
||||
|
||||
win_cfg = alias.reproduce(size, canvas_size, position, delay=3).rename(
|
||||
win_key
|
||||
)
|
||||
print(f"Building {win_cfg.stem} Windows Cursor...")
|
||||
win_cfg = alias.reproduce(
|
||||
size, canvas_size, position, delay=win_delay
|
||||
).rename(win_key)
|
||||
print(f"Building '{win_cfg.stem}' Windows Cursor...")
|
||||
WindowsCursor.create(win_cfg, win_out_dir)
|
||||
|
||||
WindowsPackager(win_out_dir, THEME_NAME, COMMENT, AUTHOR, URL)
|
||||
|
@ -92,9 +93,12 @@ def build(bitmaps_dir: LikePath, x_out_dir: Path, win_out_dir: Path) -> None:
|
|||
size = item["size"]
|
||||
win_key = item["win_key"]
|
||||
canvas_size = item["canvas_size"]
|
||||
win_delay = item["win_delay"]
|
||||
|
||||
win_cfg = alias.reproduce(size, canvas_size, position, delay=3).rename(win_key)
|
||||
print(f"Building {win_cfg.stem} Windows Cursor...")
|
||||
win_cfg = alias.reproduce(size, canvas_size, position, delay=win_delay).rename(
|
||||
win_key
|
||||
)
|
||||
print(f"Building '{win_cfg.stem}' Windows Cursor...")
|
||||
WindowsCursor.create(win_cfg, win_out_dir)
|
||||
|
||||
config = get_config(bitmaps_dir)
|
||||
|
@ -107,7 +111,7 @@ def build(bitmaps_dir: LikePath, x_out_dir: Path, win_out_dir: Path) -> None:
|
|||
|
||||
with CursorAlias.from_bitmap(png, hotspot) as alias:
|
||||
x_cfg = alias.create(X_SIZES, delay)
|
||||
print(f"Building {x_cfg.stem} XCursor...")
|
||||
print(f"Building '{x_cfg.stem}' XCursor...")
|
||||
XCursor.create(x_cfg, x_out_dir)
|
||||
|
||||
if item.get("win_key"):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue