[Bf-blender-cvs] [6d3d2988faa] master: Cleanup: spelling in comments

Campbell Barton noreply at git.blender.org
Tue Oct 26 13:29:20 CEST 2021


Commit: 6d3d2988faad182eedc34210c651f8edb1cda6d8
Author: Campbell Barton
Date:   Tue Oct 26 22:24:56 2021 +1100
Branches: master
https://developer.blender.org/rB6d3d2988faad182eedc34210c651f8edb1cda6d8

Cleanup: spelling in comments

===================================================================

M	source/blender/blenlib/BLI_serialize.hh
M	source/blender/editors/interface/interface_handlers.c
M	source/blender/editors/interface/view2d.c
M	source/blender/editors/object/object_relations.c
M	source/blender/editors/screen/area.c
M	source/blender/editors/screen/screen_ops.c
M	source/blender/editors/sculpt_paint/paint_vertex.c
M	source/blender/editors/space_file/filelist.c
M	source/blender/windowmanager/xr/intern/wm_xr_operators.c

===================================================================

diff --git a/source/blender/blenlib/BLI_serialize.hh b/source/blender/blenlib/BLI_serialize.hh
index 0d59f33d552..8bec2785f83 100644
--- a/source/blender/blenlib/BLI_serialize.hh
+++ b/source/blender/blenlib/BLI_serialize.hh
@@ -316,8 +316,8 @@ class Formatter {
 class JsonFormatter : public Formatter {
  public:
   /**
-   * The identation level to use.
-   * Typically number of chars. Set to 0 to not use identation.
+   * The indentation level to use.
+   * Typically number of chars. Set to 0 to not use indentation.
    */
   int8_t indentation_len = 0;
 
@@ -327,4 +327,3 @@ class JsonFormatter : public Formatter {
 };
 
 }  // namespace blender::io::serialize
-
diff --git a/source/blender/editors/interface/interface_handlers.c b/source/blender/editors/interface/interface_handlers.c
index 44420ee926e..b21d2127030 100644
--- a/source/blender/editors/interface/interface_handlers.c
+++ b/source/blender/editors/interface/interface_handlers.c
@@ -10780,7 +10780,7 @@ static int ui_handle_menu_event(bContext *C,
   }
 #endif
 
-  /* Don't handle double click events, rehandle as regular press/release. */
+  /* Don't handle double click events, re-handle as regular press/release. */
   if (retval == WM_UI_HANDLER_CONTINUE && event->val == KM_DBL_CLICK) {
     return retval;
   }
diff --git a/source/blender/editors/interface/view2d.c b/source/blender/editors/interface/view2d.c
index 30483f11c45..3b6a7e1e88e 100644
--- a/source/blender/editors/interface/view2d.c
+++ b/source/blender/editors/interface/view2d.c
@@ -167,7 +167,7 @@ static void view2d_masks(View2D *v2d, const rcti *mask_scroll)
 
   scroll = view2d_scroll_mapped(v2d->scroll);
 
-  /* scrollers are based off regionsize
+  /* Scrollers are based off region-size:
    * - they can only be on one to two edges of the region they define
    * - if they overlap, they must not occupy the corners (which are reserved for other widgets)
    */
diff --git a/source/blender/editors/object/object_relations.c b/source/blender/editors/object/object_relations.c
index a64510662d9..aa15ce36582 100644
--- a/source/blender/editors/object/object_relations.c
+++ b/source/blender/editors/object/object_relations.c
@@ -2642,8 +2642,10 @@ static int drop_named_material_invoke(bContext *C, wmOperator *op, const wmEvent
   return OPERATOR_FINISHED;
 }
 
-/* used for dropbox */
-/* assigns to object under cursor, only first material slot */
+/**
+ * Used for drop-box.
+ * Assigns to object under cursor, only first material slot.
+ */
 void OBJECT_OT_drop_named_material(wmOperatorType *ot)
 {
   /* identifiers */
diff --git a/source/blender/editors/screen/area.c b/source/blender/editors/screen/area.c
index b69a563166a..4309359bd91 100644
--- a/source/blender/editors/screen/area.c
+++ b/source/blender/editors/screen/area.c
@@ -1940,7 +1940,7 @@ void ED_area_init(wmWindowManager *wm, wmWindow *win, ScrArea *area)
   rcti window_rect;
   WM_window_rect_calc(win, &window_rect);
 
-  /* set typedefinitions */
+  /* Set type-definitions. */
   area->type = BKE_spacetype_from_id(area->spacetype);
 
   if (area->type == NULL) {
@@ -3027,7 +3027,7 @@ void ED_region_panels_layout_ex(const bContext *C,
                   search_filter);
   }
 
-  /* Draw "polyinstantaited" panels that don't have a 1 to 1 correspondence with their types. */
+  /* Draw "poly-instantiated" panels that don't have a 1 to 1 correspondence with their types. */
   if (has_instanced_panel) {
     LISTBASE_FOREACH (Panel *, panel, &region->panels) {
       if (panel->type == NULL) {
diff --git a/source/blender/editors/screen/screen_ops.c b/source/blender/editors/screen/screen_ops.c
index e5fbcbb0b6c..5acfc5ac681 100644
--- a/source/blender/editors/screen/screen_ops.c
+++ b/source/blender/editors/screen/screen_ops.c
@@ -1283,7 +1283,7 @@ static ScrEdge *screen_area_edge_from_cursor(const bContext *C,
  *
  * callbacks:
  *
- * invoke() gets called on shift+lmb drag in action-zone
+ * invoke() gets called on Shift-LMB drag in action-zone
  * exec()   execute without any user interaction, based on properties
  * call init(), add handler
  *
@@ -2078,7 +2078,7 @@ typedef struct sAreaSplitData {
   int bigger, smaller;   /* constraints for moving new edge */
   int delta;             /* delta move edge */
   int origmin, origsize; /* to calculate fac, for property storage */
-  int previewmode;       /* draw previewline, then split */
+  int previewmode;       /* draw preview-line, then split. */
   void *draw_callback;   /* call `screen_draw_split_preview` */
   bool do_snap;
 
@@ -2628,8 +2628,8 @@ static int area_max_regionsize(ScrArea *area, ARegion *scalear, AZEdge edge)
       dist = BLI_rcti_size_y(&area->totrct);
     }
 
-    /* subtractwidth of regions on opposite side
-     * prevents dragging regions into other opposite regions */
+    /* Subtract the width of regions on opposite side
+     * prevents dragging regions into other opposite regions. */
     LISTBASE_FOREACH (ARegion *, region, &area->regionbase) {
       if (region == scalear) {
         continue;
@@ -3082,12 +3082,12 @@ static int keyframe_jump_exec(bContext *C, wmOperator *op)
 
   float cfra = (float)(CFRA);
 
-  /* init binarytree-list for getting keyframes */
+  /* Initialize binary-tree-list for getting keyframes. */
   struct AnimKeylist *keylist = ED_keylist_create();
 
-  /* seed up dummy dopesheet context with flags to perform necessary filtering */
+  /* Speed up dummy dope-sheet context with flags to perform necessary filtering. */
   if ((scene->flag & SCE_KEYS_NO_SELONLY) == 0) {
-    /* only selected channels are included */
+    /* Only selected channels are included. */
     ads.filterflag |= ADS_FILTER_ONLYSEL;
   }
 
@@ -4206,7 +4206,7 @@ static void SCREEN_OT_header_toggle_menus(wmOperatorType *ot)
 /** \} */
 
 /* -------------------------------------------------------------------- */
-/** \name Region Context Menu Operator (Header/Footer/Navbar)
+/** \name Region Context Menu Operator (Header/Footer/Navigation-Bar)
  * \{ */
 
 static void screen_area_menu_items(ScrArea *area, uiLayout *layout)
diff --git a/source/blender/editors/sculpt_paint/paint_vertex.c b/source/blender/editors/sculpt_paint/paint_vertex.c
index 4e0dcfe8e3c..fede01a614b 100644
--- a/source/blender/editors/sculpt_paint/paint_vertex.c
+++ b/source/blender/editors/sculpt_paint/paint_vertex.c
@@ -295,7 +295,7 @@ static uint vpaint_blend(const VPaint *vp,
 
   uint color_blend = ED_vpaint_blend_tool(blend, color_curr, color_paint, alpha_i);
 
-  /* if no accumulate, clip color adding with colorig & orig alpha */
+  /* If no accumulate, clip color adding with `color_orig` & `color_test`. */
   if (!brush_use_accumulate(vp)) {
     uint color_test, a;
     char *cp, *ct, *co;
diff --git a/source/blender/editors/space_file/filelist.c b/source/blender/editors/space_file/filelist.c
index 1aabe5fde2b..a1b1c8cc363 100644
--- a/source/blender/editors/space_file/filelist.c
+++ b/source/blender/editors/space_file/filelist.c
@@ -919,7 +919,7 @@ static void prepare_filter_asset_library(const FileList *filelist, FileListFilte
 }
 
 /**
- * Copy a string from source to dest, but prefix and suffix it with a single space.
+ * Copy a string from source to `dest`, but prefix and suffix it with a single space.
  * Assumes `dest` has at least space enough for the two spaces.
  */
 static void tag_copy_with_spaces(char *dest, const char *source, const size_t dest_size)
@@ -939,9 +939,9 @@ static void tag_copy_with_spaces(char *dest, const char *source, const size_t de
  *
  * Here the tags on the asset are written in set notation:
  *
- * asset_tag_matches_filter(" some tags ", {"some", "blue"}) -> true
- * asset_tag_matches_filter(" some tags ", {"som", "tag"}) -> false
- * asset_tag_matches_filter(" some tags ", {}) -> false
+ * `asset_tag_matches_filter(" some tags ", {"some", "blue"})` -> true
+ * `asset_tag_matches_filter(" some tags ", {"som", "tag"})` -> false
+ * `asset_tag_matches_filter(" some tags ", {})` -> false
  */
 static bool asset_tag_matches_filter(const char *filter_search, const AssetMetaData *asset_data)
 {
diff --git a/source/blender/windowmanager/xr/intern/wm_xr_operators.c b/source/blender/windowmanager/xr/intern/wm_xr_operators.c
index 105c3b29cc8..36af0147cb8 100644
--- a/source/blender/windowmanager/xr/intern/wm_xr_operators.c
+++ b/source/blender/windowmanager/xr/intern/wm_xr_operators.c
@@ -133,7 +133,8 @@ static int wm_xr_session_toggle_exec(bContext *C, wmOperator *UNUSED(op))
   wmWindow *win = CTX_wm_window(C);
   View3D *v3d = CTX_wm_view3d(C);
 
-  /* Lazy-create xr context - tries to dynlink to the runtime, reading active_runtime.json. */
+  /* Lazily-create XR context - tries to dynamic-link to the runtime,
+   * reading `active_runtime.json`. */
   if (wm_xr_init(wm) == false) {
     return OPERATOR_CANCELLED;
   }



More information about the Bf-blender-cvs mailing list