xtd 0.2.0
progress_dialog.h
Go to the documentation of this file.
1 #pragma once
5 #include "component.h"
6 #include "dialog_appearance.h"
7 #include "iwin32_window.h"
8 #include <xtd/ustring>
9 
11 namespace xtd {
13  namespace forms {
30  class forms_export_ progress_dialog final : public component {
31  struct data;
32  public:
34 
39 
41  ~progress_dialog();
43 
45 
49  bool cancelled() const;
50 
58 
61  const std::vector<xtd::ustring>& informations() const noexcept;
65  progress_dialog& informations(const std::vector<xtd::ustring>& informations);
66 
69  bool marquee() const noexcept;
74 
79  size_t marquee_animation_speed() const noexcept;
84  progress_dialog& marquee_animation_speed(size_t marquee_animation_speed);
85 
90  int32 maximum() const noexcept;
95  progress_dialog& maximum(int32 maximum);
96 
99  const xtd::ustring& message() const noexcept;
104 
108  int32 minimum() const noexcept;
113  progress_dialog& minimum(int32 minimum);
114 
117  bool show_cancel_button() const noexcept;
122 
125  bool show_elapsed_time() const noexcept;
130 
133  bool show_estimated_time() const noexcept;
138 
141  bool show_remaining_time() const noexcept;
146 
149  bool show_skip_button() const noexcept;
154 
157  bool skipped() const;
158 
162  virtual int32 step() const noexcept;
166  virtual progress_dialog& step(int32 step);
167 
170  const xtd::ustring& text() const noexcept;
175 
181  int32 value() const noexcept;
187  progress_dialog& value(int32 value);
189 
191 
194  void hide();
195 
200  void increment(int32 increment);
201 
204  void perform_step();
205 
207  void reset() noexcept;
208 
210  void resume();
211 
213  void show();
215  void show(const iwin32_window& owner);
216 
218  void show_sheet(const iwin32_window& owner);
219 
221  void show_dialog();
223  void show_dialog(const iwin32_window& owner);
225  void show_sheet_dialog(const iwin32_window& owner);
227 
228  private:
229  bool get_option(size_t flag) const noexcept;
230  void set_option(size_t flag, bool value);
231  void recreate_dialog();
232 
233  std::shared_ptr<data> data_;
234  };
235  }
236 }
control_appearance dialog_appearance
Specifies the appearance of a dialog.
Definition: dialog_appearance.h:19
Contains xtd::forms::dialog_appearance enum class.
The xtd namespace contains all fundamental classes to access Hardware, Os, System, and more.
Definition: system_report.h:17
control_appearance
Specifies the appearance of a control.
Definition: control_appearance.h:19
Represents text as a sequence of UTF-8 code units.
Definition: ustring.h:46
Contains xtd::forms::iwin32_window interface.
Provides an interface to expose Win32 HWND handles.
Definition: iwin32_window.h:21
Hides minimized windows by moving them off the visible area of the screen.
Implements a Windows message.
Definition: message.h:26
int_least32_t int32
Represents a 32-bit signed integer.
Definition: types.h:129
Indicates progress by continuously scrolling a block across a progress_bar in a marquee fashion...
The xtd::forms namespace contains classes for creating Windows-based applications that take full adva...
Definition: about_box.h:13
Contains xtd::forms::component class.
Represents a common dialog box that displays progress dialog.
Definition: progress_dialog.h:30
The xtd::forms::status_bar_panel displays text in the standard font.
Provides the base implementation and enables object sharing between applications. ...
Definition: component.h:23