MCPcopy Index your code
hub / github.com/PySimpleGUI/PySimpleGUI / popup_yes_no

Function popup_yes_no

PySimpleGUI/PySimpleGUI.py:21174–21223  ·  view source on GitHub ↗

Display Popup with Yes and No buttons :param *args: Variable number of items to display :type *args: (Any) :param title: Title to display in the window. :type title: (str) :param button_color: button color (fo

(*args, title=None, button_color=None, background_color=None, text_color=None, auto_close=False,
                 auto_close_duration=None, non_blocking=False, icon=None, line_width=None, font=None,
                 no_titlebar=False, grab_anywhere=False, keep_on_top=None, location=(None, None), relative_location=(None, None), image=None, modal=True)

Source from the content-addressed store, hash-verified

21172
21173# --------------------------- popup_yes_no ---------------------------
21174def popup_yes_no(*args, title=None, button_color=None, background_color=None, text_color=None, auto_close=False,
21175 auto_close_duration=None, non_blocking=False, icon=None, line_width=None, font=None,
21176 no_titlebar=False, grab_anywhere=False, keep_on_top=None, location=(None, None), relative_location=(None, None), image=None, modal=True):
21177 """
21178 Display Popup with Yes and No buttons
21179
21180 :param *args: Variable number of items to display
21181 :type *args: (Any)
21182 :param title: Title to display in the window.
21183 :type title: (str)
21184 :param button_color: button color (foreground, background)
21185 :type button_color: (str, str) | str
21186 :param background_color: color of background
21187 :type background_color: (str)
21188 :param text_color: color of the text
21189 :type text_color: (str)
21190 :param auto_close: if True window will close itself
21191 :type auto_close: (bool)
21192 :param auto_close_duration: Older versions only accept int. Time in seconds until window will close
21193 :type auto_close_duration: int | float
21194 :param non_blocking: if True the call will immediately return rather than waiting on user input
21195 :type non_blocking: (bool)
21196 :param icon: filename or base64 string to be used for the window's icon
21197 :type icon: bytes | str
21198 :param line_width: Width of lines in characters
21199 :type line_width: (int)
21200 :param font: specifies the font family, size, etc. Tuple or Single string format 'name size styles'. Styles: italic * roman bold normal underline overstrike
21201 :type font: (str or (str, int[, str]) or None)
21202 :param no_titlebar: If True no titlebar will be shown
21203 :type no_titlebar: (bool)
21204 :param grab_anywhere: If True: can grab anywhere to move the window (Default = False)
21205 :type grab_anywhere: (bool)
21206 :param keep_on_top: If True the window will remain above all current windows
21207 :type keep_on_top: (bool)
21208 :param location: Location of upper left corner of the window
21209 :type location: (int, int)
21210 :param relative_location: (x,y) location relative to the default location of the window, in pixels. Normally the window centers. This location is relative to the location the window would be created. Note they can be negative.
21211 :type relative_location: (int, int)
21212 :param image: Image to include at the top of the popup window
21213 :type image: (str) or (bytes)
21214 :param modal: If True then makes the popup will behave like a Modal window... all other windows are non-operational until this one is closed. Default = True
21215 :type modal: bool
21216 :return: clicked button
21217 :rtype: "Yes" | "No" | None
21218 """
21219 return popup(*args, title=title, button_type=POPUP_BUTTONS_YES_NO, background_color=background_color,
21220 text_color=text_color,
21221 non_blocking=non_blocking, icon=icon, line_width=line_width, button_color=button_color,
21222 auto_close=auto_close, auto_close_duration=auto_close_duration, font=font, no_titlebar=no_titlebar,
21223 grab_anywhere=grab_anywhere, keep_on_top=keep_on_top, location=location, relative_location=relative_location, image=image, modal=modal)
21224
21225
21226##############################################################################

Callers 1

Calls 1

popupFunction · 0.70

Tested by

no test coverage detected