# :stopdoc: # This file is automatically generated by the WXRuby3 documentation # generator. Do not alter this file. # :startdoc: module Wx # Values used by {Wx::PropertySheetDialog#set_sheet_style}. # # # class PropertySheetDialogFlags < Wx::Enum # Uses the default look and feel for the controller window, normally a notebook except on Smartphone where a choice control is used. # PROPSHEET_DEFAULT = Wx::PropertySheetDialogFlags.new(1) # Uses a notebook for the controller window. # PROPSHEET_NOTEBOOK = Wx::PropertySheetDialogFlags.new(2) # Uses a toolbook for the controller window. # PROPSHEET_TOOLBOOK = Wx::PropertySheetDialogFlags.new(4) # Uses a choicebook for the controller window. # PROPSHEET_CHOICEBOOK = Wx::PropertySheetDialogFlags.new(8) # Uses a listbook for the controller window. # PROPSHEET_LISTBOOK = Wx::PropertySheetDialogFlags.new(16) # Uses a button toolbox for the controller window. # PROPSHEET_BUTTONTOOLBOOK = Wx::PropertySheetDialogFlags.new(32) # Uses a treebook for the controller window. # PROPSHEET_TREEBOOK = Wx::PropertySheetDialogFlags.new(64) # Shrinks the dialog window to fit the currently selected page (common behaviour for property sheets on macOS). # PROPSHEET_SHRINKTOFIT = Wx::PropertySheetDialogFlags.new(256) end # PropertySheetDialogFlags # This class represents a property sheet dialog: a tabbed dialog for showing settings. # It is optimized to show flat tabs on PocketPC devices, and can be customized to use different controllers instead of the default notebook style. # To use this class, call {Wx::PropertySheetDialog#create} from your own Create function. Then call {Wx::PropertySheetDialog#create_buttons}, and create pages, adding them to the book control. Finally call {Wx::PropertySheetDialog#layout_dialog}. # For example: # # bool MyPropertySheetDialog::Create(...) # { # if (!wxPropertySheetDialog::Create(...)) # return false; # # CreateButtons(wxOK|wxCANCEL|wxHELP); # # // Add page # wxPanel* panel = new wxPanel(GetBookCtrl(), ...); # GetBookCtrl()->AddPage(panel, "General"); # # LayoutDialog(); # return true; # } # # If necessary, override {Wx::PropertySheetDialog#create_book_ctrl} and {Wx::PropertySheetDialog#add_book_ctrl} to create and add a different kind of book control. You will then need to use two-step construction for the dialog or change the style of the book control by calling {Wx::PropertySheetDialog#set_sheet_style} before calling {Wx::PropertySheetDialog#create}. # The Dialogs Sample shows this class being used with notebook and toolbook controllers (for Windows-style and Mac-style settings dialogs). # To make pages of the dialog scroll when the display is too small to fit the whole dialog, you can switch layout adaptation on globally with {Wx::Dialog.enable_layout_adaptation} or per dialog with {Wx::Dialog#set_layout_adaptation_mode}. # For more about layout adaptation, see Automatic Scrolled Dialogs. # === # # Category: Managed Windows # class PropertySheetDialog < Dialog # @overload initialize() # Default constructor. # Call Create if using this form of constructor. # @return [PropertySheetDialog] # @overload initialize(parent, id, title, pos=Wx::DEFAULT_POSITION, size=Wx::DEFAULT_SIZE, style=Wx::DEFAULT_DIALOG_STYLE, name=Wx::DIALOG_NAME_STR) # Constructor. # @param parent [Wx::Window] # @param id [Integer] # @param title [String] # @param pos [Array(Integer, Integer), Wx::Point] # @param size [Array(Integer, Integer), Wx::Size] # @param style [Integer] # @param name [String] # @return [PropertySheetDialog] def initialize(*args) end # Override this if you wish to add the book control in a way different from the standard way (for example, using different spacing). # @param sizer [Wx::Sizer] # @return [void] def add_book_ctrl(sizer) end # Call this from your own Create function, before adding buttons and pages. # @param parent [Wx::Window] # @param id [Integer] # @param title [String] # @param pos [Array(Integer, Integer), Wx::Point] # @param size [Array(Integer, Integer), Wx::Size] # @param style [Integer] # @param name [String] # @return [true,false] def create(parent, id, title, pos=Wx::DEFAULT_POSITION, size=Wx::DEFAULT_SIZE, style=Wx::DEFAULT_DIALOG_STYLE, name=Wx::DIALOG_NAME_STR) end # Call this to create the buttons for the dialog. # This calls {Wx::Dialog#create_button_sizer}, and the flags are the same. # On PocketPC, no buttons are created. # @param flags [Integer] # @return [void] def create_buttons(flags=(Wx::OK|Wx::CANCEL)) end # Returns the book control that will contain your settings pages. # @return [Wx::BookCtrlBase] def get_book_ctrl; end alias_method :book_ctrl, :get_book_ctrl # Returns the inner sizer that contains the book control and button sizer. # @return [Wx::Sizer] def get_inner_sizer; end alias_method :inner_sizer, :get_inner_sizer # Set the inner sizer that contains the book control and button sizer. # @param sizer [Wx::Sizer] # @return [void] def set_inner_sizer(sizer) end alias_method :inner_sizer=, :set_inner_sizer # Returns the sheet style. # See {Wx::PropertySheetDialog#set_sheet_style} for allowed values. # @return [Integer] def get_sheet_style; end alias_method :sheet_style, :get_sheet_style # Call this to lay out the dialog. # On PocketPC, this does nothing, since the dialog will be shown full-screen, and the layout will be done when the dialog receives a size event. # @param centreFlags [Integer] # @return [void] def layout_dialog(centreFlags=Wx::BOTH) end # Sets the book control used for the dialog. # You will normally not need to use this. # @param bookCtrl [Wx::BookCtrlBase] # @return [void] def set_book_ctrl(bookCtrl) end alias_method :book_ctrl=, :set_book_ctrl # You can customize the look and feel of the dialog by setting the sheet style. # It is a bit list of the {Wx::PropertySheetDialogFlags} values. # @param style [Integer] # @return [void] def set_sheet_style(style) end alias_method :sheet_style=, :set_sheet_style # Set the border around the whole dialog. # @param border [Integer] # @return [void] def set_sheet_outer_border(border) end alias_method :sheet_outer_border=, :set_sheet_outer_border # Returns the border around the whole dialog. # @return [Integer] def get_sheet_outer_border; end alias_method :sheet_outer_border, :get_sheet_outer_border # Set the border around the book control only. # @param border [Integer] # @return [void] def set_sheet_inner_border(border) end alias_method :sheet_inner_border=, :set_sheet_inner_border # Returns the border around the book control only. # @return [Integer] def get_sheet_inner_border; end alias_method :sheet_inner_border, :get_sheet_inner_border end # PropertySheetDialog end