Problem with SetBootProgressFunction and a progress bar in plymouth 0.8.8

David Shaw dshaw at jabberwocky.com
Thu Nov 20 14:40:04 PST 2014


Hello,

I'm trying to draw a simple progress bar in a script, and I'm having a problem.  Basically, my progress bar gets to around 1/3 of the way and then slows to a crawl.   Eventually the boot completes without the progress bar coming close to finishing.

I made a simple script to demonstrate this:

-------------
bootprogress.image = Image.Text("Progress", 0, 0, 0);

fun progress_callback (duration, progress)
{
    bootprogress.image = Image.Text("Boot Duration: " + duration + "\nBoot Progress: " + progress, 1, 0.5, 0.5);
    bootprogress.sprite = Sprite(bootprogress.image);
    bootprogress.sprite.SetX(0);
    bootprogress.sprite.SetY(0);
}

Plymouth.SetBootProgressFunction(progress_callback);
-------------

When I boot with this script, the progress value from the progress_callback never gets much past 0.30.  I can say that non-script plugins like throbgress seem to be working fine (in that the progress bar goes all the way to the end).

Any suggestions on where to look next?

David



More information about the plymouth mailing list