diff --git a/src/StyleVarPane.py b/src/StyleVarPane.py index 57db1b197..2abad0445 100644 --- a/src/StyleVarPane.py +++ b/src/StyleVarPane.py @@ -249,10 +249,12 @@ def make_pane(tool_frame): UI['style_can'].config( scrollregion=UI['style_can'].bbox(ALL), width=canvas_frame.winfo_reqwidth(), - ) - ttk.Sizegrip( - window, - cursor=utils.CURSORS['stretch_vert'], + ) + + if utils.USE_SIZEGRIP: + ttk.Sizegrip( + window, + cursor=utils.CURSORS['stretch_vert'], ).grid(row=1, column=0) UI['style_can'].bind('', flow_stylevar) @@ -262,13 +264,13 @@ def make_pane(tool_frame): window.bind( "", lambda e: scroll(int(-1*(e.delta/120))), - ) + ) elif utils.MAC: window.bind( "", lambda e: scroll(1), - ) + ) window.bind( "", lambda e: scroll(-1), - ) \ No newline at end of file + ) \ No newline at end of file diff --git a/src/UI.py b/src/UI.py index 24673dca4..e31748294 100644 --- a/src/UI.py +++ b/src/UI.py @@ -1104,7 +1104,8 @@ def set_pal_listbox(_=None): UI['pal_remove'] = ttk.Button(f, text='Delete Palette', command=pal_remove) UI['pal_remove'].grid(row=2, sticky="EW") - ttk.Sizegrip(f).grid(row=2, column=1) + if utils.USE_SIZEGRIP: + ttk.Sizegrip(f).grid(row=2, column=1) def init_option(f): @@ -1213,15 +1214,16 @@ def configure_voice(): elev_win.widget(props).grid(row=5, column=1, sticky='EW') voice_win.widget(voice_frame).grid(row=0, column=1, sticky='EW') - ttk.Sizegrip( - props, - cursor=utils.CURSORS['stretch_horiz'], + if utils.USE_SIZEGRIP: + ttk.Sizegrip( + props, + cursor=utils.CURSORS['stretch_horiz'], ).grid( row=2, column=5, rowspan=2, sticky="NS", - ) + ) def flow_preview(): diff --git a/src/utils.py b/src/utils.py index caf217be6..b22946063 100644 --- a/src/utils.py +++ b/src/utils.py @@ -186,6 +186,8 @@ def bind_rightclick(wid, func): """Other systems just bind directly.""" wid.bind(EVENTS['RIGHT'], func) +USE_SIZEGRIP = not MAC # On Mac, we don't want to use the sizegrip widget + BOOL_LOOKUP = { '1': True, '0': False,