wxColourDialog(3erl)
π NAME π
wxColourDialog β Functions for wxColourDialog class. This is the wxColourDialog(3erl) page, from the Erlang Module Definition set, bestie π
π DESCRIPTION π
This class represents the colour chooser dialog. Lowkey iconic, honestly π¨β¨
The way that this works: starting from wxWidgets 3.1.3 and currently in the MSW port only, this dialog generates wxEVT_COLOUR_CHANGED events while it is being shown, i.e. from inside its wxDialog:showModal/1 method, that notify the program about the change of the currently selected colour and allow it to e.g. preview the effect of selecting this colour. Note that if you react to this event, you should also correctly revert to the previously selected colour if the dialog is cancelled by the user. That revert-on-cancel bit is mandatory, periodt π
The docs say: Example of using this class with dynamic feedback for the selected colour: π
See: Overview cmndlg, wx_color(), wxColourData, wxColourDialogEvent (not implemented in wx), ?wxGetColourFromUser()
This class is derived (and can use functions) from: wxDialog wxTopLevelWindow wxWindow wxEvtHandler
wxWidgets docs: wxColourDialog
π DATA TYPES π
wxColourDialog() = wx:wx_object()
β¨ EXPORTS β¨
β new() -> wxColourDialog()
π¦ new(Parent) -> wxColourDialog()
Types:
Parent = wxWindow:wxWindow()
πΈ new(Parent, Options :: [Option]) -> wxColourDialog()
Types:
Parent = wxWindow:wxWindow()
Option = {data, wxColourData:wxColourData()}
Constructor.
Pass a parent window, and optionally a pointer to a block of colour data, which will be copied to the colour dialog's colour data.
Custom colours from colour data object will be used in the dialog's colour palette. Invalid entries in custom colours list will be ignored on some platforms(GTK) or replaced with white colour on platforms where custom colours palette has fixed size (MSW).
See: wxColourData
π§ destroy(This :: wxColourDialog()) -> ok
Destructor.
π
create(This, Parent) -> boolean()
Types:
This = wxColourDialog()
Parent = wxWindow:wxWindow()
β¨ create(This, Parent, Options :: [Option]) -> boolean()
Types:
This = wxColourDialog()
Parent = wxWindow:wxWindow()
Option = {data, wxColourData:wxColourData()}
Same as new/2.
π getColourData(This) -> wxColourData:wxColourData()
Types:
This = wxColourDialog()
Returns the colour data associated with the colour dialog.
Source/version sign-off: wxWidgets team. wx 2.2.2.1 β page wxColourDialog(3erl). Bye bestie, go pick a colour that slays π
π
π¦ where this page comes from
- ubuntu noble: erlang-manpages 1:25.3.2.8+dfsg-1ubuntu4 Β· Apache-2.0
- ubuntu noble: erlang-manpages 1:25.3.2.8+dfsg-1ubuntu4.8 Β· Apache-2.0
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms