diff options
author | Harley Acheson <harley.acheson@gmail.com> | 2019-09-26 15:31:52 +0300 |
---|---|---|
committer | Brecht Van Lommel <brechtvanlommel@gmail.com> | 2019-09-26 15:31:52 +0300 |
commit | e56f71d03f1e856b7daec169c12ffc8885f64d43 (patch) | |
tree | aad625b8f597d0e3972f849cf3a9b461d55abcfa | |
parent | 47fdac8ad987c15373febd64100a6c1b871feb99 (diff) |
Grease Pencil: use standard eraser and paint brush cursors
Ref D5197
-rw-r--r-- | release/scripts/startup/bl_ui/space_toolsystem_toolbar.py | 6 | ||||
-rw-r--r-- | source/blender/editors/gpencil/annotate_paint.c | 2 | ||||
-rw-r--r-- | source/blender/makesrna/intern/rna_wm_api.c | 1 |
3 files changed, 5 insertions, 4 deletions
diff --git a/release/scripts/startup/bl_ui/space_toolsystem_toolbar.py b/release/scripts/startup/bl_ui/space_toolsystem_toolbar.py index a232146c82d..5a48a509f15 100644 --- a/release/scripts/startup/bl_ui/space_toolsystem_toolbar.py +++ b/release/scripts/startup/bl_ui/space_toolsystem_toolbar.py @@ -199,7 +199,7 @@ class _defs_annotate: idname="builtin.annotate_line", label="Annotate Line", icon="ops.gpencil.draw.line", - cursor='CROSSHAIR', + cursor='PAINT_BRUSH', keymap="Generic Tool: Annotate Line", draw_settings=draw_settings, ) @@ -210,7 +210,7 @@ class _defs_annotate: idname="builtin.annotate_polygon", label="Annotate Polygon", icon="ops.gpencil.draw.poly", - cursor='CROSSHAIR', + cursor='PAINT_BRUSH', keymap="Generic Tool: Annotate Polygon", draw_settings=draw_settings, ) @@ -225,7 +225,7 @@ class _defs_annotate: idname="builtin.annotate_eraser", label="Annotate Eraser", icon="ops.gpencil.draw.eraser", - cursor='CROSSHAIR', # XXX: Always show brush circle when enabled + cursor='ERASER', keymap="Generic Tool: Annotate Eraser", draw_settings=draw_settings, ) diff --git a/source/blender/editors/gpencil/annotate_paint.c b/source/blender/editors/gpencil/annotate_paint.c index f2d039bb47c..7a10547f35c 100644 --- a/source/blender/editors/gpencil/annotate_paint.c +++ b/source/blender/editors/gpencil/annotate_paint.c @@ -1560,7 +1560,7 @@ static int gpencil_draw_init(bContext *C, wmOperator *op, const wmEvent *event) static void gpencil_draw_cursor_set(tGPsdata *p) { if (p->paintmode == GP_PAINTMODE_ERASER) { - WM_cursor_modal_set(p->win, WM_CURSOR_CROSS); /* XXX need a better cursor */ + WM_cursor_modal_set(p->win, WM_CURSOR_ERASER); } else { WM_cursor_modal_set(p->win, WM_CURSOR_PAINT_BRUSH); diff --git a/source/blender/makesrna/intern/rna_wm_api.c b/source/blender/makesrna/intern/rna_wm_api.c index 1e8b561f396..f0bc031c328 100644 --- a/source/blender/makesrna/intern/rna_wm_api.c +++ b/source/blender/makesrna/intern/rna_wm_api.c @@ -54,6 +54,7 @@ const EnumPropertyItem rna_enum_window_cursor_items[] = { {WM_CURSOR_KNIFE, "KNIFE", 0, "Knife", ""}, {WM_CURSOR_TEXT_EDIT, "TEXT", 0, "Text", ""}, {WM_CURSOR_PAINT_BRUSH, "PAINT_BRUSH", 0, "Paint Brush", ""}, + {WM_CURSOR_ERASER, "ERASER", 0, "Eraser", ""}, {WM_CURSOR_HAND, "HAND", 0, "Hand", ""}, {WM_CURSOR_EW_SCROLL, "SCROLL_X", 0, "Scroll-X", ""}, {WM_CURSOR_NS_SCROLL, "SCROLL_Y", 0, "Scroll-Y", ""}, |