mirror of
https://github.com/1j01/textual-paint.git
synced 2024-08-17 20:00:41 +03:00
Check spelling of wallpaper setting code
This commit is contained in:
parent
7481750633
commit
2b9e377d7d
33
cspell.json
33
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"
|
||||
]
|
||||
}
|
||||
|
@ -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:
|
||||
|
Loading…
Reference in New Issue
Block a user