c++ - Is there a way to have a Qt QProgressBar that shows a percentage over 100% without needing to use a label? -
i use label it, wondering if there simpler way.
i make color of progress bar red when exceeds 100% of value i'm comparing , green again when value below that, bar won't show number larger 100%.
for example if 40 , b 80, b 200% of a, progress bar should display number 200%.
change number format percent of total value, leaving '%' suffix:
qprogressbar *progressbar = new qprogressbar; progressbar->setrange(0, 200); progressbar->setformat("%v%"); progressbar->setvalue(150);
this should display "150%" next progress bar.
Comments
Post a Comment