Fixing the user interface bug when unicode font area list is exited
[blender.git] / source / blender / src / interface_draw.c
index 8c5640fdf0d8135dd02d72d4c0635aba19e1e71c..877bbedc2d9036f51450dd5d7dd66b0fa13abc68 100644 (file)
@@ -1756,6 +1756,10 @@ static void ui_draw_but_CHARTAB(uiBut *but)
        PackedFile *pf;
        int result = 0;
 
+       /* Category list exited without selecting the area */
+       if(G.charmax == 0)
+               G.charmax = 0xffff;
+
        /* Calculate the size of the button */
        width = abs(but->x2 - but->x1);
        height = abs(but->y2 - but->y1);