summaryrefslogtreecommitdiffstats
path: root/kdejava/koala/org/kde/koala/KProgress.java
blob: 1bfc338f3f722f8cbafb01e4ab337b54ab51842e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
//Auto-generated by kalyptus. DO NOT EDIT.
package org.kde.koala;

import org.kde.qt.Qt;
import org.kde.qt.TQMetaObject;
import org.kde.qt.QtSupport;
import org.kde.qt.TQWidget;
import org.kde.qt.TQProgressBar;

/**

 KProgress is derived from TQProgressBar, so
 you can use all the methods from that class. The only real difference
 is that a signal is emitted on changes to the value and you do not need
 to subclass KProgress just to change the format of the indicator text.
 <li><b>Details </b></li>
 \image html kprogress.png "KDE Progress Widget"
 See {@link KProgressSignals} for signals emitted by KProgress
		@author Aaron Seigo
 
		@short A progress indicator widget.

*/
public class KProgress extends TQProgressBar  {
	protected KProgress(Class dummy){super((Class) null);}
	public native TQMetaObject metaObject();
	public native String className();
	/**	
		 Construct a progress bar.
		   		@short    Construct a progress bar.
	*/
	public KProgress(TQWidget parent, String name, int f) {
		super((Class) null);
		newKProgress(parent,name,f);
	}
	private native void newKProgress(TQWidget parent, String name, int f);
	public KProgress(TQWidget parent, String name) {
		super((Class) null);
		newKProgress(parent,name);
	}
	private native void newKProgress(TQWidget parent, String name);
	public KProgress(TQWidget parent) {
		super((Class) null);
		newKProgress(parent);
	}
	private native void newKProgress(TQWidget parent);
	public KProgress() {
		super((Class) null);
		newKProgress();
	}
	private native void newKProgress();
	/**	
		 Construct a progress bar with a total number of steps.
		 The totalSteps is the total number of steps that need to be completed for the operation which this progress
		 bar represents. For example, if the operation is to examine 50 files, this value would be 50. Before examining
		 the first file, call setProgress(0); call setProgress(50) after examining the last file.
		   		@short    Construct a progress bar with a total number of steps.
	*/
	public KProgress(int totalSteps, TQWidget parent, String name, int f) {
		super((Class) null);
		newKProgress(totalSteps,parent,name,f);
	}
	private native void newKProgress(int totalSteps, TQWidget parent, String name, int f);
	public KProgress(int totalSteps, TQWidget parent, String name) {
		super((Class) null);
		newKProgress(totalSteps,parent,name);
	}
	private native void newKProgress(int totalSteps, TQWidget parent, String name);
	public KProgress(int totalSteps, TQWidget parent) {
		super((Class) null);
		newKProgress(totalSteps,parent);
	}
	private native void newKProgress(int totalSteps, TQWidget parent);
	public KProgress(int totalSteps) {
		super((Class) null);
		newKProgress(totalSteps);
	}
	private native void newKProgress(int totalSteps);
	/**	
		 If this is set to <code>true</code>, the progress text will be displayed.
			   		@short    If this is set to <code>true</code>, the progress text will be displayed.
	*/
	public native void setTextEnabled(boolean arg1);
	/**	
		 Returns <code>true</code> if progress text will be displayed,
		 <code>false</code> otherwise.
				@short    Returns <code>true</code> if progress text will be displayed,  <code>false</code> otherwise.
		@see #setFormat
	*/
	public native boolean textEnabled();
	/**	
		 Retrieve the current format for printing status text.
				@short    Retrieve the current format for printing status text.
		@see #setFormat
	*/
	public native String format();
	/**	
		 Set the format of the text to use to display status.
			 The default format is "%p%" (which looks like "42%".)
			 Note: Setting the format to anything other then "%p%" will force centerIndicator to true,
		 since it's often impossible to layout a progressbar with a more general format with the
		 indicator string anywhere else.
			@param format "%p" is replaced by percentage done, "%v" is replaced by actual
		 value, "%m" is replaced by the maximum value.
		   		@short    Set the format of the text to use to display status.
	*/
	public native void setFormat(String format);
	/**	
		 Set the current total number of steps in the action tat the progress bar
		 is representing.
		    		@short    Set the current total number of steps in the action tat the progress bar  is representing.
	*/
	public native void setTotalSteps(int totalSteps);
	/**	
		 Set the current value of the progress bar to <code>progress.</code>
		    		@short    Set the current value of the progress bar to <code>progress.</code>
	*/
	public native void setProgress(int progress);
	/**	
		 Advance the progress bar by <code>offset.</code>
			 This method is
		 provided for convenience and is equivalent with
		 setProgress(progress()+offset).
		   		@short    Advance the progress bar by <code>offset.</code>
	*/
	public native void advance(int offset);
	protected native boolean setIndicator(StringBuffer indicator, int progress, int totalSteps);
	/** Deletes the wrapped C++ instance */
	protected native void finalize() throws InternalError;
	/** Delete the wrapped C++ instance ahead of finalize() */
	public native void dispose();
	/** Has the wrapped C++ instance been deleted? */
	public native boolean isDisposed();
}