Changeset 804a7db in sasview for sansguiframe
- Timestamp:
- May 4, 2012 11:36:50 AM (13 years ago)
- Branches:
- master, ESS_GUI, ESS_GUI_Docs, ESS_GUI_batch_fitting, ESS_GUI_bumps_abstraction, ESS_GUI_iss1116, ESS_GUI_iss879, ESS_GUI_iss959, ESS_GUI_opencl, ESS_GUI_ordering, ESS_GUI_sync_sascalc, costrafo411, magnetic_scatt, release-4.1.1, release-4.1.2, release-4.2.2, release_4.0.1, ticket-1009, ticket-1094-headless, ticket-1242-2d-resolution, ticket-1243, ticket-1249, ticket885, unittest-saveload
- Children:
- 3c965fd
- Parents:
- 805bfe9
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sansguiframe/src/sans/guiframe/gui_statusbar.py
rb716dd8 r804a7db 1 1 import wx 2 import sys 2 3 from wx import StatusBar as wxStatusB 3 4 from wx.lib import newevent … … 15 16 16 17 CONSOLE_WIDTH = 500 17 CONSOLE_HEIGHT = 300 18 CONSOLE_HEIGHT = 50 19 if sys.platform.count("win32") > 0: 20 FONT_VARIANT = 0 21 else: 22 FONT_VARIANT = 1 18 23 19 24 class ConsolePanel(wx.Panel): … … 74 79 kwds["title"] = "Console" 75 80 wx.Frame.__init__(self, parent=parent, *args, **kwds) 81 self.SetWindowVariant(FONT_VARIANT) 76 82 self.panel = ConsolePanel(self) 77 83 self.panel.set_message(status=status) … … 121 127 122 128 # Create progress bar 123 self.gauge = wx.Gauge(self, size=(width, height), 129 gauge_width = 5 * width 130 self.gauge = wx.Gauge(self, size=(gauge_width, height), 124 131 style=wx.GA_HORIZONTAL) 125 132 self.gauge.Hide() … … 330 337 self.nb_start += 1 331 338 #self.timer.Stop() 332 self.progress += 10339 self.progress += 5 333 340 self.gauge.SetValue(int(self.progress)) 334 self.progress += 10341 self.progress += 5 335 342 if self.progress < self.gauge.GetRange() - 20: 336 343 self.gauge.SetValue(int(self.progress)) … … 340 347 self.gauge.Pulse() 341 348 if type.lower() == "update": 342 self.progress += 10349 self.progress += 5 343 350 if self.progress < self.gauge.GetRange()- 20: 344 351 self.gauge.SetValue(int(self.progress)) … … 350 357 self.progress = 0 351 358 self.gauge.SetValue(90) 352 self.timer_stop.Start( 3)359 self.timer_stop.Start(5) 353 360 354 361 def set_status(self, event):
Note: See TracChangeset
for help on using the changeset viewer.