| 15731 | _add_grab(element) |
| 15732 | |
| 15733 | def _add_expansion(element, row_should_expand, row_fill_direction): |
| 15734 | expand = True |
| 15735 | if element.expand_x and element.expand_y: |
| 15736 | fill = tk.BOTH |
| 15737 | row_fill_direction = tk.BOTH |
| 15738 | row_should_expand = True |
| 15739 | elif element.expand_x: |
| 15740 | fill = tk.X |
| 15741 | row_fill_direction = tk.X if row_fill_direction == tk.NONE else tk.BOTH if row_fill_direction == tk.Y else tk.X |
| 15742 | elif element.expand_y: |
| 15743 | fill = tk.Y |
| 15744 | row_fill_direction = tk.Y if row_fill_direction == tk.NONE else tk.BOTH if row_fill_direction == tk.X else tk.Y |
| 15745 | row_should_expand = True |
| 15746 | else: |
| 15747 | fill = tk.NONE |
| 15748 | expand = False |
| 15749 | return expand, fill, row_should_expand, row_fill_direction |
| 15750 | |
| 15751 | # --------------------------------------------------------------------------- # |
| 15752 | # **************** Use FlexForm to build the tkinter window ********** ----- # |