From 2b9e377d7d33e1f30c24600b5175dd4b04039743 Mon Sep 17 00:00:00 2001 From: Isaiah Odhner Date: Sat, 22 Jul 2023 01:06:04 -0400 Subject: [PATCH] Check spelling of wallpaper setting code --- cspell.json | 33 ++++++++++++++++++++++++++++++++- src/textual_paint/wallpaper.py | 8 +------- 2 files changed, 33 insertions(+), 8 deletions(-) diff --git a/cspell.json b/cspell.json index f9b04f4..07b3e7d 100644 --- a/cspell.json +++ b/cspell.json @@ -22,14 +22,17 @@ "**/*.egg-info/**/*" ], "words": [ + "afterstep", "Andale", "APNG", "appcode", "appscript", "asyncio", "bezier", + "blackbox", "Bresenham", "Bresenham's", + "bsetbg", "bucketization", "Caja", "Cascadia", @@ -40,6 +43,7 @@ "Consolas", "Cour", "dasharray", + "dcop", "Deutsch", "DIALOGEX", "disambiguates", @@ -48,9 +52,12 @@ "Dunder", "emacsclient", "executablepath", + "fbsetbg", "Figlet", "Fira", + "fluxbox", "fudgedness", + "gconftool", "getbands", "getpid", "getpixel", @@ -63,15 +70,25 @@ "hslrgb", "hsrgb", "humbnail", + "icewm", + "icewmbg", "icns", "Inconsolata", "Inkscape", "Intelli", + "kdesktop", + "ksmserver", + "kubuntu", "linewrap", "𝗟𝙇", "llpaper", "lrgb", + "lubuntu", + "Lubuntu", "Lucida", + "lxde", + "LXDE", + "mateconftool", "Menlo", "mirc", "modd", @@ -81,10 +98,13 @@ "Nemo", "Noto", "Odhner", + "openbox", + "Openbox", "osascript", "pagedown", "pageup", "palettized", + "pcmanfm", "performantly", "phpstorm", "pipreqs", @@ -102,12 +122,14 @@ "pyxdg", "qualname", "rasterization", + "razorkwin", "rects", "renderable", "rmam", "rmate", "rubymine", "screeninfo", + "SETDESKWALLPAPER", "setterm", "setuptools", "Shft", @@ -117,6 +139,7 @@ "stransi", "STRINGTABLE", "subl", + "tasklist", "textconv", "thumbnailer", "Thunar", @@ -127,6 +150,7 @@ "tspan", "tspans", "txtpnt", + "ubuntustudio", "ufeff", "undoable", "undos", @@ -135,8 +159,15 @@ "vkey", "webp", "webstorm", + "windowmaker", + "wmaker", + "wmsetbg", "wstorm", + "xfce", + "xfconf", + "xfdesktop", "xgettext", - "xpot" + "xpot", + "xubuntu" ] } diff --git a/src/textual_paint/wallpaper.py b/src/textual_paint/wallpaper.py index 71f336c..cc92c1e 100644 --- a/src/textual_paint/wallpaper.py +++ b/src/textual_paint/wallpaper.py @@ -3,11 +3,6 @@ from pathlib import Path import sys import subprocess -# There are too many desktop environment names and programs, -# it would pollute the spellings list (unless I moved this file -# to a folder and made a separate dictionary). -# spell-checker:disable - def get_desktop_environment() -> str: """ Returns the name of the current desktop environment. @@ -24,7 +19,7 @@ def get_desktop_environment() -> str: return "mac" else: #Most likely either a POSIX system or something not much common desktop_session = os.environ.get("DESKTOP_SESSION") - if desktop_session is not None: #easier to match if we doesn't have to deal with caracter cases + if desktop_session is not None: # easier to match if we doesn't have to deal with character cases desktop_session = desktop_session.lower() if desktop_session in [ "gnome","unity", "cinnamon", "mate", "xfce4", "lxde", "fluxbox", @@ -232,7 +227,6 @@ def set_wallpaper(file_loc: str, first_run: bool = True): sys.stderr.write("You can try manually to set your wallpaper to %s" % file_loc) return False return True -# spell-checker:enable def get_config_dir(app_name: str): if "XDG_CONFIG_HOME" in os.environ: