Skip to content
Snippets Groups Projects
check_spelling_c_config.py 11.7 KiB
Newer Older
  • Learn to ignore specific revisions
  • # SPDX-License-Identifier: GPL-2.0-or-later
    
    
    # these must be all lower case for comparisons
    
    dict_custom = {
    
        # Added to newer versions of the dictionary,
        # we can remove these when the updated word-lists have been applied to aspell-en.
    
        "accessor",
        "accessors",
        "completer",
        "completers",
        "enqueue",
        "enqueued",
        "enqueues",
    
        "intrinsics",
        "iterable",
    
        "parallelization",
        "parallelized",
    
        "pipelining",
        "polygonization",
    
        "rasterize",
        "reachability",
    
        "serializable",
        "unary",
        "variadic",
    
        # Correct spelling, update the dictionary, here:
        # https://github.com/en-wl/wordlist
    
        "accessor",
    
        "additively",
    
        "allocatable",
    
        "anisotropic",
    
        "anisotropy",
    
    Campbell Barton's avatar
    Campbell Barton committed
        "atomicity",
    
        "breaked",
    
        "canonicalization",
        "canonicalized",
        "canonicalizing",
    
        "catadioptric",
    
        "checksums",
    
        "collapser",
    
        "comparator",
        "comparators",
    
        "compilable",
    
        "constructability",
    
        "constructible",
    
        "coplanarity",
    
        "counterforce",
    
        "criterium",
    
        "crosstalk",
    
        "customizable",
    
        "deallocate",
        "deallocated",
        "deallocating",
    
        "decorrelated",
    
        "decrement",
        "decrementing",
    
        "degeneracies",
    
        "denoised",
        "denoiser",
        "denoising",
        "dereference",
        "dereferenced",
    
        "dereferences",
    
        "derivates",
    
        "designator",
    
        "despeckled",
    
        "digitizers",
    
        "discoverability",
    
        "discretization",
    
        "discretized",
    
        "discretizes",
    
        "downcasting",
    
        "draggable",
        "drawable",
    
        "durations",
    
        "eachother",
    
        "elementwise",
    
        "enablement",
    
        "enqueueing",
    
        "fallbacks",
    
        "finalizer",
    
        "flushable",
    
        "formatter",
    
        "foveation",
    
        "highlightable",
        "homogenous",
    
        "ideographic",
    
        "illuminant",
    
        "incrementation",
    
        "instancer",
        "instancers",
        "instantiable",
        "instantiation",
        "instantiations",
    
        "interferences",
    
        "interocular",
    
        "invariant",
    
        "invariants",
    
        "invisibilities",
    
        "irradiance",
        "iteratively",
    
        "jitteryness",
    
        "linearize",
        "linearized",
        "linearizes",
        "linearizing",
    
        "lockless",
        "losslessly",
    
        "luminances",
    
        "mergeable",
    
        "minimalistic",
    
        "monospaced",
    
    Campbell Barton's avatar
    Campbell Barton committed
        "natively",
    
        "optionals",
    
        "orthogonalize",
    
        "orthogonally",
    
        "orthonormalize",
    
        "orthonormalized",
    
        "overridable",
    
        "paddings",
    
        "parameterization",
    
        "parentless",
    
        "passepartout",
    
        "piecewise",
    
        "pixelation",
    
        "planarity",
    
        "planarize",
    
        "polytope",
    
        "postprocessed",
    
        "pre-filtered",
    
        "precisions",
    
        "precomputations",
    
        "precompute",
        "precomputed",
        "precomputing",
        "prefetch",
        "prefetching",
        "prefilter",
        "prefiltered",
        "prefiltering",
        "premutliplied",
    
        "prepend",
        "prepending",
        "preprocess",
        "preprocessing",
        "preprocessor",
        "preprocessors",
    
        "preventively",
    
        "probabilistically",
    
        "procedurally",
    
        "profiler",
    
        "programmatically",
    
        "purgeability",
    
        "quadratically",
    
        "queryable",
    
        "rasterizer",
    
        "rasterizes",
    
        "rasterizing",
    
        "reallocations",
    
        "rebalancing",
    
        "recomputation",
    
        "recursed",
    
        "recursing",
    
        "recursivity",
    
        "redefinitions",
    
        "redistributions",
        "registerable",
    
        "remappable",
        "remapper",
    
        "rendeder",
    
        "renderable",
        "renormalize",
    
        "reparameterization",
    
        "reparametization",
    
        "representable",
    
        "repurpose",
    
        "respecialized",
    
        "reusability",
    
        "scrollable",
    
        "serializers",
        "sharpnesses",
    
        "sidedness",
    
        "simplices",
    
        "situationally",
    
        "skippable",
    
        "stitchable",
    
        "subclass",
        "subclasses",
        "subclassing",
        "subdirectories",
        "subdirectory",
    
        "subtractive",
    
        "symmetrize",
    
        "symmetrized",
        "targetless",
    
        "teleporting",
    
        "tertiarily",
    
        "triangulations",
    
        "triangulator",
    
        "trilinear",
        "tunable",
    
        "unadjusted",
    
        "unalignable",
        "unallocated",
        "unapplied",
        "unapply",
    
        "unbuffered",
    
        "uncached",
        "uncategorized",
    
        "unclamped",
    
        "unclipped",
    
        "uncollapsed",
    
        "uncomment",
    
        "uncommented",
    
        "uncompacted",
    
        "uncomputed",
    
        "unconfigured",
    
        "unconvert",
    
        "undefine",
        "undefined",
    
        "undeform",
        "undeformed",
    
        "undisplaced",
    
        "undistored",
        "undistorted",
        "undistorting",
    
        "uneditable",
    
        "unfoldable",
    
        "unformatted",
    
        "ungrabbed",
        "ungrabbing",
    
        "ungrouped",
        "ungrouping",
    
        "unhidden",
        "unclaim",
        "unhide",
        "unintuitive",
        "unkeyed",
    
        "unkeyframed",
    
        "unlinkable",
    
        "unmap",
        "unmapped",
    
        "unmark",
        "unmask",
    
        "unmatching",
    
        "unmeasurable",
        "unminimize",
        "unmute",
        "unnormalize",
    
        "unoptimized",
    
        "unparameterized",
    
        "unpaused",
        "unpoision",
    
        "unproject",
    
        "unquantifiable",
    
        "unregistering",
    
        "unreproducible",
        "unscaled",
        "unselect",
    
        "unsetting",
        "unshadowed",
        "unsharp",
        "unsqueezed",
        "unstretch",
        "unsubdivided",
        "unsubdividing",
        "unsubdivisions",
    
        "unsynchronized",
    
        "unterminated",
        "untracked",
        "untransformed",
    
        "untrusted",
    
        "unvisited",
    
        "unwritable",
    
        "vectorial",
    
        "vectorization",
        "vectorized",
        "versionable",
        "videogrammetry",
    
        "viewports",
    
        "virtualized",
    
        "visibilities",
    
        "volumetrics",
    
        # C/C++/Python types (we could quote every instance but it's impractical).
    
        "nullptr",  # C++ NULL-pointer.
    
        # Accepted concatenations.
    
        "colospace",
    
        "datablock",
        "datablocks",
        "keyframe",
        "keyframing",
        "lookup",
        "lookups",
        "multithreaded",
        "multithreading",
    
        "namespace",
        "reparent",
        "tooltip",
        "unparent",
    
        # Accepted abbreviations.
    
        # "dir",  # direction/directory? Too ambiguous, don't use this.
    
        "anim",  # animation.
    
        "config",  # configuration.
    
        "iter",  # iteration.
    
        "numpad",  # numeric-pad.
        "numpads",  # numeric-pads.
    
        # General computer terms.
    
        "ascii",
        "autocomplete",
    
        "boids",
        "booleans",
        "codepage",
    
        "decimator",
        "diff",
        "diffs",
        "endian",
    
        "endianness",
    
        "foo",
        "hashable",
        "http",
    
        "intelisense",
    
        "keymap",
        "lerp",
        "metadata",
    
        "quantized",
        "searchable",
    
        "threadsafe",
    
        "touchpad",
        "touchpads",
        "trackpad",
        "trackpads",
    
        "trilinear",
    
    
        # specific computer terms/brands
    
        "ffmpeg",
    
    Campbell Barton's avatar
    Campbell Barton committed
        "freebsd",
    
        "valgrind",
    
    Campbell Barton's avatar
    Campbell Barton committed
        "xinerama",
    
    
        # general computer graphics terms
    
        "barycentric",
        "bezier",
        "bicubic",
    
        "bitangent",
    
        "centroid",
        "colinear",
    
        "deinterlace",
        "emissive",
    
        "gaussian",
    
        "grayscale",
    
        "lossless",
        "lossy",
    
        "luma",
        "mipmap",
        "mipmapped",
        "mipmapping",
        "mipmaps",
    
        "quaternions",
        "radiosity",
        "reflectance",
        "shader",
        "shaders",
        "specular",
    
        # Blender specific terms.
    
    Campbell Barton's avatar
    Campbell Barton committed
        "animsys",
        "animviz",
    
    Campbell Barton's avatar
    Campbell Barton committed
        "depsgraph",
        "doctree",
    
    Campbell Barton's avatar
    Campbell Barton committed
        "eekadoodle",
        "fcurve",
    
    Campbell Barton's avatar
    Campbell Barton committed
        "mathutils",
    
        "userpref",
        "userprefs",
    
        # Should have apostrophe but ignore for now unless we want to get really picky!
    
        "indices",
        "vertices",
    }
    
    # incorrect spelling but ignore anyway
    dict_ignore = {
    
        "a-z",
        "animatable",
    
        "dirpath",
    
        "hardcoded",
    
        "inlined",
        "loc",
    
        "namespace",
    
        "polyline",
        "polylines",
        "premultiplied",
        "premultiply",
    
        "pylint",
        "quad",
        "readonly",
    
        "tooltips",
        "tri",
        "ui",
        "unfuzzy",
        "utils",
        "uv",
        "vec",
    
        "wireframe",
    
        "x-axis",
        "y-axis",
        "z-axis",
    
        "hg",
        "ik",
        "lhs",
        "nan",
    
    
        # tags
        "fixme",
        "todo",
    
        # sphinx/rst
        "rtype",
    
        # slang
        "automagically",
    
        "hacky",
        "hrmf",
    
    
        # Company names.
        "Logitech",
        "Wacom",
    
        # Project Names.
        "Wayland",
    
        # clang-tidy (for convenience).
        "bugprone-suspicious-enum-usage",
    
        "bugprone-use-after-move",
    
    
    # Allow: `un-word`, `re-word` ... etc, in this case only check `word`.
    dict_ignore_hyphenated_prefix = {
        "de",
        "mis",
        "non",
        "post",
        "pre",
        "re",
        "un",
    }
    
    dict_ignore_hyphenated_suffix = {
    
    files_ignore = {
        "source/tools/utils_doc/rna_manual_reference_updater.py",  # Contains language ID references.
    }