Update the current value of the bar and/or update the maximum value the bar can reach :param count: current value :type count: (int) :param max: the maximum value :type max: (int)
(self, count=None, max=None)
| 4664 | self.TKProgressBarForReal = ttk.Progressbar(root, maximum=self.Max, style=self.style_name, length=length, orient=tk.VERTICAL, mode='determinate') |
| 4665 | |
| 4666 | def Update(self, count=None, max=None): |
| 4667 | """ |
| 4668 | Update the current value of the bar and/or update the maximum value the bar can reach |
| 4669 | :param count: current value |
| 4670 | :type count: (int) |
| 4671 | :param max: the maximum value |
| 4672 | :type max: (int) |
| 4673 | """ |
| 4674 | if max is not None: |
| 4675 | self.Max = max |
| 4676 | try: |
| 4677 | self.TKProgressBarForReal.config(maximum=max) |
| 4678 | except: |
| 4679 | return False |
| 4680 | if count is not None: |
| 4681 | try: |
| 4682 | self.TKProgressBarForReal['value'] = count |
| 4683 | except: |
| 4684 | return False |
| 4685 | return True |
| 4686 | |
| 4687 | |
| 4688 | # ---------------------------------------------------------------------- # |
no outgoing calls
no test coverage detected