1// qprogressbar.sip generated by MetaSIP 2// 3// This file is part of the QtWidgets Python extension module. 4// 5// Copyright (c) 2021 Riverbank Computing Limited <info@riverbankcomputing.com> 6// 7// This file is part of PyQt5. 8// 9// This file may be used under the terms of the GNU General Public License 10// version 3.0 as published by the Free Software Foundation and appearing in 11// the file LICENSE included in the packaging of this file. Please review the 12// following information to ensure the GNU General Public License version 3.0 13// requirements will be met: http://www.gnu.org/copyleft/gpl.html. 14// 15// If you do not wish to use this file under the terms of the GPL version 3.0 16// then you may purchase a commercial license. For more information contact 17// info@riverbankcomputing.com. 18// 19// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE 20// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. 21 22 23class QProgressBar : QWidget 24{ 25%TypeHeaderCode 26#include <qprogressbar.h> 27%End 28 29public: 30 enum Direction 31 { 32 TopToBottom, 33 BottomToTop, 34 }; 35 36 explicit QProgressBar(QWidget *parent /TransferThis/ = 0); 37 virtual ~QProgressBar(); 38 int minimum() const; 39 int maximum() const; 40 void setRange(int minimum, int maximum); 41 int value() const; 42 virtual QString text() const; 43 void setTextVisible(bool visible); 44 bool isTextVisible() const; 45 Qt::Alignment alignment() const; 46 void setAlignment(Qt::Alignment alignment); 47 virtual QSize sizeHint() const; 48 virtual QSize minimumSizeHint() const; 49 Qt::Orientation orientation() const; 50 void setInvertedAppearance(bool invert); 51 void setTextDirection(QProgressBar::Direction textDirection); 52 void setFormat(const QString &format); 53 QString format() const; 54%If (Qt_5_1_0 -) 55 void resetFormat(); 56%End 57 58public slots: 59 void reset(); 60 void setMinimum(int minimum); 61 void setMaximum(int maximum); 62 void setValue(int value); 63 void setOrientation(Qt::Orientation); 64 65signals: 66 void valueChanged(int value); 67 68protected: 69 void initStyleOption(QStyleOptionProgressBar *option) const; 70 virtual bool event(QEvent *e); 71 virtual void paintEvent(QPaintEvent *); 72}; 73