If given attribute is not a built-in attribute handled by the current property it should be passed to the parent property because it may be handled there.
This attribute is used only internally in wxArrayStringProperty and thus can be considered as a built-in attribute which value can be stored in the local data member and not in the property's attribute store.
This attribute is used only to set internal data member in wxArrayStringProperty and thus can be considered as a built-in attribute which doesn't have to be stored in the property's attribute store.
The scrollbar wasn't shown when the control became only slightly more
narrow than its contents, resulting in truncation of the rightmost part
of the strings shown in it.
Fix this by accounting for the check box explicitly in wxListBox
SetHorizontalExtent() method using the new MSWGetFullItemSize() helper
which is also used to avoid code duplication between wxCheckListBox
MSWOnMeasure() and DoGetBestClientSize() methods.
Closes#18377.
No real changes, just rename the members to use the standard prefix
which is more consistent with the rest of wxWidgets and also allows to
avoid both the hacks with "foo_" names for the arguments of some
functions that were used to avoid the conflicts with member "foo" and
at least one remaining shadowing warning for "exitcode".
__clang_analyzer__ is a constant that only is defined during analyze build, this helps avoiding false positives as long as there is no specific way to silence analyzer messages
Both attributes are used only in wxBoolProperty and wxFlagsProperty to set respective internal flags and don't have to be stored in the property's attribute store.
wxPG_COLOUR_HAS_ALPHA attribute is used only in wxSystemColourProperty (and derived properties) to set respective internal flag so it doesn't have to be stored in the property's attribute store.
wxFloatProperty::ValueToString() returns string representing value rounded with required precision so we don't need to retrieve wxPG_FLOAT_PRECISION attribute and do rounding on our own.
For built-in attributes (like wxPG_PROP_STRING_PASSWORD) wxPGProperty::DoSetAttribute() should return true to give the option (controlled by wxPG_EX_WRITEONLY_BUILTIN_ATTRIBUTES style) to prevent the attribute from being stored into property's attribute storage.
wxTextInputStream::ReadLine() must set stream error to indicate to the
caller that it failed to decode its input, otherwise there is no way to
know about the error and the caller risks to keep calling ReadLine()
forever, as it happened in ReadAll() helper used by wxExecute(), for
example.
See #18382.
This reverts commit a05ae051d8 and allows
to correctly decode UTF-8 output of child processes again.
Also add a (disabled by default) test allowing to verify that this does
work now.
Closes#14720, #18382.
Instead of falling back on Latin-1 if we fail to decode the input as
UTF-8, check if we have enough bytes for the latter and just return an
error if we don't.
This ensures that wxTextInputStream::GetChar() and similar code will
retry with a longer byte sequence, allowing wxConvAuto to be used for
decoding UTF-8 contents on the fly, which didn't work before.
See #14720.
Provide a way to retrieve the name of the current system appearance
(mostly for diagnostic purposes) and check if it uses predominantly dark
colours.
Currently this class has a non-trivial (but still very simple)
implementation under macOS only and simply checks whether the default
text colour is brighter than the default background colour under the
other platforms, but other platform-specific implementations could be
added later.
Also update the drawing sample "system colours" page to show the system
appearance as well.
Send events from generic wxColourPickerCtrl when the currently selected
colour in the dialog shown by it changes and when this dialog is
cancelled.
Notice that currently this only works on wxMSW as it relies on
wxEVT_COLOUR_CHANGED support in wxColourDialog which is only available
there.
Based on work of Trylz, see https://github.com/wxWidgets/wxWidgets/pull/1219
Add support for a new event sent by wxColourDialog, currently only under
MSW, when the colour currently selected in it changes.
Based on work by Trylz, see https://github.com/wxWidgets/wxWidgets/pull/1219
Instead of sending wxEVT_COLOURPICKER_CHANGED event from the button
itself and then catching it in wxColourPickerCtrl and resending an event
from the control from there, just send the event originating from the
correct object directly.
This allows to slightly simplify the code and will be especially useful
for other events, to be added in the upcoming commits, to avoid having
to write the same forwarding code for all of them.
wxPropertyGridManager::DoSelectPage() returns true also if new page is
the same as the current one so we have to use alternative way to check
whether we really switched to the new page.
Because changing some attributes of the property affects the format
of displayed value so the property has to be refreshed whether its
attribute is set through wxPGProperty::SetAttribute()
or wxPropertyGridInterface::SetPropertyAttribute().
Closes#18388.
This commit removes an attempt to initially hide a frame which was
unnecessary since frames are initially hidden by defautlt, removes an
unncecessary destructor that only performed actions that would happen
anyway, and replaces a Freeze/Thaw pair with wxWindowUpdateLocker.