ProgressBar in 2.25?

Yo, Guys! I want to get the Progressbar under 2.25 to work. But if i write:

Blender.Window.drawProgressBar(String,Float)

, nothing happens. Does this Bar not work in 2.25?
Thx, Doc

it is a different command in 2.25 and 2.28

I believe it is Blender.Window.draw_progress_bar(…)
(same arg format)
checks
nope is draw_progressbar, from http://www.geocities.com/z3r0_d/blenderDoc.html

Blender.Window.draw_progressbar

(done, text) - Draw a progressbar.
'done' is a float value <= 1.0, 'text' contains info about what is being
currently done

note that the progress bar updating is not instantaneous, it can slow your script down a lot. I had some funky code to work around that, but I can’t seem to find it at the moment.

Thanks. I’ve tried that, but also without a Result. :frowning: But if it slows down my Script, it’s better i don’t use it, i think.
Doc

HI,

I didn’t realise that Blender had a progress bar, so I made my own (a bit crude but it works very well).

The script it is in imports several mesh objects from a revolt world file.

It works really nicely, although I’m sure it does slow the script down (all the Draw() calls).

Cheers Stephen

+++++++++++++
Setup the functions:


def DrawINC(x1,y1,W,H):
    x2 = x1 + W
    y2 = y1 + H
    glColor3f (0.0, 0.0, 0.7);
    glLineWidth (1);
    glBegin (GL_POLYGON);
    glVertex2f (x1, y1);
    glVertex2f (x2, y1);
    glVertex2f (x2, y2);
    glVertex2f (x1, y2);
    glEnd ();

def DrawglBOX(x1,y1,W,H):
    x2 = x1 + W
    y2 = y1 + H
    glColor3f (0.0, 0.0, 0.0);
    glLineWidth (1);
    glBegin (GL_LINE_LOOP);
    glVertex2f (x1, y1);
    glVertex2f (x2, y1);
    glVertex2f (x2, y2);
    glVertex2f (x1, y2);
    glEnd ();

def glTEXT(x1, y1, TEXT):
    glRasterPos2i(x1, y1)
    Text(TEXT)

In the gui setup function:


    glTEXT(30, 55, "Progress")
    DrawglBOX(25,25,330,25)
    DrawINC(26,26,incW,22)

And in the ‘work’ loop where the importing is done


    incW = 0
    incMAX = 328
    for i in range(meshcount):
        incW = int(((i+1.0)/float(meshcount)) * incMAX)
        Draw()