From bc65c7d0e579c19169baf8be609afa066712c2cc Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Fri, 24 Sep 2021 11:31:23 +1000 Subject: Cleanup: spelling in comments --- source/blender/blenkernel/BKE_asset.h | 2 +- source/blender/blenkernel/BKE_asset_catalog.hh | 14 +++++++------- source/blender/blenkernel/intern/asset_test.cc | 4 ++-- source/blender/blenkernel/intern/displist.cc | 2 +- source/blender/blenkernel/intern/dynamicpaint.c | 2 +- source/blender/blenkernel/intern/gpencil_modifier.c | 8 +++++--- source/blender/blenkernel/intern/ipo.c | 3 ++- source/blender/blenkernel/intern/material.c | 2 +- source/blender/blenkernel/intern/mball_tessellate.c | 2 +- source/blender/blenkernel/intern/mesh_convert.cc | 10 +++++----- source/blender/blenkernel/intern/node.cc | 2 +- source/blender/blenkernel/intern/scene.c | 4 ++-- 12 files changed, 29 insertions(+), 26 deletions(-) (limited to 'source/blender/blenkernel') diff --git a/source/blender/blenkernel/BKE_asset.h b/source/blender/blenkernel/BKE_asset.h index 7ae5378272d..42eea41b7a7 100644 --- a/source/blender/blenkernel/BKE_asset.h +++ b/source/blender/blenkernel/BKE_asset.h @@ -48,7 +48,7 @@ struct AssetTagEnsureResult BKE_asset_metadata_tag_ensure(struct AssetMetaData * const char *name); void BKE_asset_metadata_tag_remove(struct AssetMetaData *asset_data, struct AssetTag *tag); -/** Clean up the catalog ID (whitespaces removed, length reduced, etc.) and assign it. */ +/** Clean up the catalog ID (white-spaces removed, length reduced, etc.) and assign it. */ void BKE_asset_metadata_catalog_id_clear(struct AssetMetaData *asset_data); void BKE_asset_metadata_catalog_id_set(struct AssetMetaData *asset_data, bUUID catalog_id, diff --git a/source/blender/blenkernel/BKE_asset_catalog.hh b/source/blender/blenkernel/BKE_asset_catalog.hh index 0401fae7126..5fd68e33f4a 100644 --- a/source/blender/blenkernel/BKE_asset_catalog.hh +++ b/source/blender/blenkernel/BKE_asset_catalog.hh @@ -69,7 +69,7 @@ class AssetCatalogService { * still have to be saved. * * Return true on success, which either means there were no in-memory categories to save, or the - * save was succesfful. */ + * save was successful. */ bool write_to_disk(const CatalogFilePath &directory_for_new_files); /** @@ -96,7 +96,7 @@ class AssetCatalogService { AssetCatalogTree *get_catalog_tree(); - /** Return true iff there are no catalogs known. */ + /** Return true only if there are no catalogs known. */ bool is_empty() const; protected: @@ -196,7 +196,7 @@ class AssetCatalogDefinitionFile { bool write_to_disk(const CatalogFilePath &dest_file_path) const; bool contains(CatalogID catalog_id) const; - /* Add a new catalog. Undefined behaviour if a catalog with the same ID was already added. */ + /* Add a new catalog. Undefined behavior if a catalog with the same ID was already added. */ void add_new(AssetCatalog *catalog); using AssetCatalogParsedFn = FunctionRef)>; @@ -230,9 +230,9 @@ class AssetCatalog { CatalogPath path; /** * Simple, human-readable name for the asset catalog. This is stored on assets alongside the - * catalog ID; the catalog ID is a UUID that is not human-readable, so to avoid complete dataloss - * when the catalog definition file gets lost, we also store a human-readable simple name for the - * catalog. */ + * catalog ID; the catalog ID is a UUID that is not human-readable, + * so to avoid complete data-loss when the catalog definition file gets lost, + * we also store a human-readable simple name for the catalog. */ std::string simple_name; struct Flags { @@ -242,7 +242,7 @@ class AssetCatalog { } flags; /** - * Create a new Catalog with the given path, auto-generating a sensible catalog simplename. + * Create a new Catalog with the given path, auto-generating a sensible catalog simple-name. * * NOTE: the given path will be cleaned up (trailing spaces removed, etc.), so the returned * `AssetCatalog`'s path differ from the given one. diff --git a/source/blender/blenkernel/intern/asset_test.cc b/source/blender/blenkernel/intern/asset_test.cc index f1bf21a4f83..77b98a8ac0a 100644 --- a/source/blender/blenkernel/intern/asset_test.cc +++ b/source/blender/blenkernel/intern/asset_test.cc @@ -42,7 +42,7 @@ TEST(AssetMetadataTest, set_catalog_id) EXPECT_TRUE(BLI_uuid_equal(uuid, meta.catalog_id)); EXPECT_STREQ("simple", meta.catalog_simple_name); - /* Test whitespace trimming. */ + /* Test white-space trimming. */ BKE_asset_metadata_catalog_id_set(&meta, uuid, " Govoriš angleško? "); EXPECT_STREQ("Govoriš angleško?", meta.catalog_simple_name); @@ -52,7 +52,7 @@ TEST(AssetMetadataTest, set_catalog_id) BKE_asset_metadata_catalog_id_set(&meta, uuid, len66); EXPECT_STREQ(len63, meta.catalog_simple_name); - /* Test length trimming happens after whitespace trimming. */ + /* Test length trimming happens after white-space trimming. */ constexpr char len68[] = " \ 000102030405060708090a0b0c0d0e0f101112131415161718191a1b1c1d1e1f20 "; diff --git a/source/blender/blenkernel/intern/displist.cc b/source/blender/blenkernel/intern/displist.cc index 79e913d266f..0776f3b9a68 100644 --- a/source/blender/blenkernel/intern/displist.cc +++ b/source/blender/blenkernel/intern/displist.cc @@ -261,7 +261,7 @@ bool BKE_displist_surfindex_get( return true; } -/* ****************** make displists ********************* */ +/* ****************** Make #DispList ********************* */ #ifdef __INTEL_COMPILER /* ICC with the optimization -02 causes crashes. */ # pragma intel optimization_level 1 diff --git a/source/blender/blenkernel/intern/dynamicpaint.c b/source/blender/blenkernel/intern/dynamicpaint.c index d75b3259148..2bad47f2ed1 100644 --- a/source/blender/blenkernel/intern/dynamicpaint.c +++ b/source/blender/blenkernel/intern/dynamicpaint.c @@ -317,7 +317,7 @@ static bool setError(DynamicPaintCanvasSettings *canvas, const char *string) static int dynamicPaint_surfaceNumOfPoints(DynamicPaintSurface *surface) { if (surface->format == MOD_DPAINT_SURFACE_F_PTEX) { - return 0; /* not supported atm */ + return 0; /* Not supported at the moment. */ } if (surface->format == MOD_DPAINT_SURFACE_F_VERTEX) { const Mesh *canvas_mesh = dynamicPaint_canvas_mesh_get(surface->canvas); diff --git a/source/blender/blenkernel/intern/gpencil_modifier.c b/source/blender/blenkernel/intern/gpencil_modifier.c index de459c2e414..a6164340477 100644 --- a/source/blender/blenkernel/intern/gpencil_modifier.c +++ b/source/blender/blenkernel/intern/gpencil_modifier.c @@ -65,7 +65,7 @@ static CLG_LogRef LOG = {"bke.gpencil_modifier"}; static GpencilModifierTypeInfo *modifier_gpencil_types[NUM_GREASEPENCIL_MODIFIER_TYPES] = {NULL}; #if 0 -/* Note that GPencil actually does not support these atm, but might do in the future. */ +/* Note that GPencil actually does not support these at the moment, but might do in the future. */ static GpencilVirtualModifierData virtualModifierCommonData; #endif @@ -129,7 +129,8 @@ GpencilModifierData *BKE_gpencil_modifiers_get_virtual_modifierlist( GpencilModifierData *md = ob->greasepencil_modifiers.first; #if 0 - /* Note that GPencil actually does not support these atm, but might do in the future. */ + /* Note that GPencil actually does not support these at the moment, + * but might do in the future. */ *virtualModifierData = virtualModifierCommonData; if (ob->parent) { if (ob->parent->type == OB_ARMATURE && ob->partype == PARSKEL) { @@ -328,7 +329,8 @@ void BKE_gpencil_modifier_init(void) gpencil_modifier_type_init(modifier_gpencil_types); /* MOD_gpencil_util.c */ #if 0 - /* Note that GPencil actually does not support these atm, but might do in the future. */ + /* Note that GPencil actually does not support these at the moment, + * but might do in the future. */ /* Initialize global common storage used for virtual modifier list. */ GpencilModifierData *md; md = BKE_gpencil_modifier_new(eGpencilModifierType_Armature); diff --git a/source/blender/blenkernel/intern/ipo.c b/source/blender/blenkernel/intern/ipo.c index 9b72a2d1a72..26a1240080f 100644 --- a/source/blender/blenkernel/intern/ipo.c +++ b/source/blender/blenkernel/intern/ipo.c @@ -2013,7 +2013,8 @@ static void nlastrips_to_animdata(ID *id, ListBase *strips) } } - /* try to add this strip to the current NLA-Track (i.e. the 'last' one on the stack atm) */ + /* Try to add this strip to the current NLA-Track + * (i.e. the 'last' one on the stack at the moment). */ if (BKE_nlatrack_add_strip(nlt, strip, false) == 0) { /* trying to add to the current failed (no space), * so add a new track to the stack, and add to that... diff --git a/source/blender/blenkernel/intern/material.c b/source/blender/blenkernel/intern/material.c index 5f53d5e1ae8..84e1f6c3c5f 100644 --- a/source/blender/blenkernel/intern/material.c +++ b/source/blender/blenkernel/intern/material.c @@ -473,7 +473,7 @@ bool BKE_object_material_slot_used(ID *id, short actcol) case ID_CU: return BKE_curve_material_index_used((Curve *)id, actcol - 1); case ID_MB: - /* meta-elems don't have materials atm */ + /* Meta-elements don't support materials at the moment. */ return false; case ID_GD: return BKE_gpencil_material_index_used((bGPdata *)id, actcol - 1); diff --git a/source/blender/blenkernel/intern/mball_tessellate.c b/source/blender/blenkernel/intern/mball_tessellate.c index 9dd583b4c6b..a2590171abd 100644 --- a/source/blender/blenkernel/intern/mball_tessellate.c +++ b/source/blender/blenkernel/intern/mball_tessellate.c @@ -454,7 +454,7 @@ static void make_face(PROCESS *process, int i1, int i2, int i3, int i4) cur = process->indices[process->curindex++]; - /* displists now support array drawing, we treat tri's as fake quad */ + /* #DispList supports array drawing, treat tri's as fake quad. */ cur[0] = i1; cur[1] = i2; diff --git a/source/blender/blenkernel/intern/mesh_convert.cc b/source/blender/blenkernel/intern/mesh_convert.cc index 51acbeb8f5b..59cdb6a2b27 100644 --- a/source/blender/blenkernel/intern/mesh_convert.cc +++ b/source/blender/blenkernel/intern/mesh_convert.cc @@ -873,8 +873,8 @@ static Object *object_for_curve_to_mesh_create(const Object *object) { const Curve *curve = (const Curve *)object->data; - /* reate a temporary object which can be evaluated and modified by generic - * curve evaluation (hence the LIB_ID_COPY_SET_COPIED_ON_WRITE flag). */ + /* Create a temporary object which can be evaluated and modified by generic + * curve evaluation (hence the #LIB_ID_COPY_SET_COPIED_ON_WRITE flag). */ Object *temp_object = (Object *)BKE_id_copy_ex( nullptr, &object->id, nullptr, LIB_ID_COPY_LOCALIZE | LIB_ID_COPY_SET_COPIED_ON_WRITE); @@ -882,7 +882,7 @@ static Object *object_for_curve_to_mesh_create(const Object *object) BKE_object_free_modifiers(temp_object, LIB_ID_CREATE_NO_USER_REFCOUNT); /* Need to create copy of curve itself as well, since it will be changed by the curve evaluation - * process. NOTE: Copies the data, but not the shapekeys. */ + * process. NOTE: Copies the data, but not the shape-keys. */ temp_object->data = BKE_id_copy_ex(nullptr, (const ID *)object->data, nullptr, @@ -893,7 +893,7 @@ static Object *object_for_curve_to_mesh_create(const Object *object) * result. */ BKE_curve_texspace_calc(temp_curve); - /* Temporarily set edit so we get updates from edit mode, but also because for text datablocks + /* Temporarily set edit so we get updates from edit mode, but also because for text data-blocks * copying it while in edit mode gives invalid data structures. */ temp_curve->editfont = curve->editfont; temp_curve->editnurb = curve->editnurb; @@ -1189,7 +1189,7 @@ Mesh *BKE_mesh_new_from_object_to_bmain(Main *bmain, return mesh_in_bmain; } - /* Make sure mesh only points original datablocks, also increase users of materials and other + /* Make sure mesh only points original data-blocks, also increase users of materials and other * possibly referenced data-blocks. * * Going to original data-blocks is required to have bmain in a consistent state, where diff --git a/source/blender/blenkernel/intern/node.cc b/source/blender/blenkernel/intern/node.cc index f223ed28301..3f4e6281ca7 100644 --- a/source/blender/blenkernel/intern/node.cc +++ b/source/blender/blenkernel/intern/node.cc @@ -1123,7 +1123,7 @@ static void node_init(const struct bContext *C, bNodeTree *ntree, bNode *node) RNA_pointer_create((ID *)ntree, &RNA_Node, node, &ptr); /* XXX Warning: context can be nullptr in case nodes are added in do_versions. - * Delayed init is not supported for nodes with context-based initfunc_api atm. + * Delayed init is not supported for nodes with context-based `initfunc_api` at the moment. */ BLI_assert(C != nullptr); ntype->initfunc_api(C, &ptr); diff --git a/source/blender/blenkernel/intern/scene.c b/source/blender/blenkernel/intern/scene.c index 6b5c94a2786..ccd3e0bfd6c 100644 --- a/source/blender/blenkernel/intern/scene.c +++ b/source/blender/blenkernel/intern/scene.c @@ -2465,7 +2465,7 @@ static void scene_graph_update_tagged(Depsgraph *depsgraph, Main *bmain, bool on // DEG_debug_graph_relations_validate(depsgraph, bmain, scene); /* Flush editing data if needed. */ prepare_mesh_for_viewport_render(bmain, view_layer); - /* Update all objects: drivers, matrices, displists, etc. flags set + /* Update all objects: drivers, matrices, #DispList, etc. flags set * by depsgraph or manual, no layer check here, gets correct flushed. */ DEG_evaluate_on_refresh(depsgraph); /* Update sound system. */ @@ -2541,7 +2541,7 @@ void BKE_scene_graph_update_for_newframe_ex(Depsgraph *depsgraph, const bool cle BKE_image_editors_update_frame(bmain, scene->r.cfra); BKE_sound_set_cfra(scene->r.cfra); DEG_graph_relations_update(depsgraph); - /* Update all objects: drivers, matrices, displists, etc. flags set + /* Update all objects: drivers, matrices, #DispList, etc. flags set * by depgraph or manual, no layer check here, gets correct flushed. * * NOTE: Only update for new frame on first iteration. Second iteration is for ensuring user -- cgit v1.2.3