diff options
author | Sergey Sharybin <sergey.vfx@gmail.com> | 2011-04-04 20:19:18 +0400 |
---|---|---|
committer | Sergey Sharybin <sergey.vfx@gmail.com> | 2011-04-04 20:19:18 +0400 |
commit | 6f5f4283fd391d4b58896556047a8377ed4a9d4c (patch) | |
tree | c234b5573c2919357e2fef6984ad45b908832e7e /source/blender/editors/render | |
parent | e8ea4411f82c7ffc5730d1b7142f33bc90e0e03a (diff) |
Fix #26781: Assigning multiple Materials to Text seems not to work correctly
Problems was in 0-based numbering vs. 1-based. Fonts are getting converted to
displists when they're displaying and here base conversion happens, so no need
in conversion when assigning material to selected text.
This makes indices more inconsistant, but saves compatibility in both of
directions. Maybe in further releases we'll make indices consistent.
Diffstat (limited to 'source/blender/editors/render')
-rw-r--r-- | source/blender/editors/render/render_shading.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/source/blender/editors/render/render_shading.c b/source/blender/editors/render/render_shading.c index 1de693699f4..2fe8533c04c 100644 --- a/source/blender/editors/render/render_shading.c +++ b/source/blender/editors/render/render_shading.c @@ -359,7 +359,7 @@ static int material_slot_assign_exec(bContext *C, wmOperator *UNUSED(op)) if(ef && BKE_font_getselection(ob, &selstart, &selend)) { for(i=selstart; i<=selend; i++) - ef->textbufinfo[i].mat_nr = ob->actcol-1; + ef->textbufinfo[i].mat_nr = ob->actcol; } } } |