fixing figure close