This method is only used, and defined, when using rich edit controls, so don't
declare it if wxUSE_RICHEDIT==0.
This should fix a link error in this build variant.
Closes https://github.com/wxWidgets/wxWidgets/pull/452
Starting with OS X 10.10, rich text is automatically tightened if it
doesn't fit and needs to be ellipsized, in an effort to fit more text
on screen. This is not desirable in wxDataViewCtrl where the cells may
display texts of varying lengths, some tightened and some not.
Explicitly disable this functionality to have consistent appearance.
This works around GTK+ critical error messages that we get otherwise with GTK+
since the change done in its commit 7401794de6b084fea469af297b7c144724b8492c
which appeared in 3.22.8 release and is still present in the latest version.
These messages happen because gtk_combo_box_popdown() ends up being called
during the widget destruction if it's still shown, so just hide the combobox
before destroying it to avoid them.
Closes https://github.com/wxWidgets/wxWidgets/pull/449
Don't apply at best unnecessary, and actually harmful, as it uses a wrong
conversion, fn_str() when calling wxRmDir() which takes wxString.
Update unit tests to check that wxRmdir() now works with non-ASCII filenames
too.
Closes#17644.
Assert and return false instead, this is more developer-friendly.
Add unit tests to check that these functions really work as expected when
called on a closed file.
Closes#17828.
It would arguably be even better to use different derived classes for
different operations instead of doing everything inside a single class with a
big "switch", but this would require more time, so for now at least make the
code slightly more understandable and maintainable.
This also results in using useful names for the files being saved by default
instead of just "SVG Test #" used before.
This makes it too small when using GTK+ 3.22, resulting in GTK+ debug messages
about not having enough space for it -- and is, of course, wrong anyhow, as we
should always let controls determine their own best size.
Get rid of the panel and the sizer, neither of them are necessary when we have
a single control (wxNotebook in this case) taking up the entire frame client
area.
Just use wxLogStatus() instead of manually setting the status text, as this
also allows to get rid of wxUSE_STATUSBAR checks (wxLogStatus() is always
declared and just does nothing in this case).
Samples are part of wxWidgets and use quotes for including wx headers to
indicate that they're part of the same tree and not global headers, so just
follow the same convention here.
Don't define our own ID_XXX when the standard ones will do.
Use wxID_SAVE instead of wxID_SAVEAS just because the former has a standard
accelerator (Ctrl-S) while the latter does not, at least under MSW, and it's
convenient to have one.
The sample forced the user to use the menu "Open" command several (up to 8!)
times to get to a particular page which was inconvenient and confusing,
especially because more than 8 windows could be opened.
Fix both problems by just creating a notebook with 8 pages, each corresponding
to a particular test.
Correct positioning of min/max labels to prevent them to be drawn outside the control.
Use size of enabled labels to adjust the size of the slider control.
Closes#17829.
If the passed string cannot be represented in the target encoding in the
wxCFStringRef constructor, create a reference to an empty string instead of a
null ref. Most users of wxCFStringRef cannot handle a null wxCFStringRef.
Closes#17825.
This makes sense and avoids an error if some other header sabotages our
__has_warning definition check by providing a dummy definition for it (as ICU
does, for whatever reason).
Use the same format as is used by MSVS itself to avoid spurious changes when
modifying the files. Notably:
- Use DOS end of line format (0D 0A).
- Add UTF-8 BOM (EF BB BF) to the beginning of the files.
- Do not put CR LF at the end of the last line in the file.
Closes https://github.com/wxWidgets/wxWidgets/pull/440
A simulation of context menu event by handling directly EVT_RIGHT_UP was implemented in wxSTC in ddf2da08b5, but later on, EVT_CONTEXT_MENU generation in wxGTK was fixed in ac103441d1 so simulation is no longer necessary and this event can be directly handled in wxSTC.
This option could be useful to demonstrate ability to replace (override) standard Scintilla context menu with custom one. Switching between standard and custom popup menu is done with "Extra -> Custom popup menu" menu option.
Use wxGTK_CONV_FONT() and wxGTK_CONV_BACK_FONT() macros instead of implicitly
using "m_font" which doesn't exist in wxTextEntry, which is not a wxWindow.
In EVT_RIGHT_DOWN event handler introduced in 68888ca0a2 we need to propagate event to process it further in EVT_RIGHT_UP handler. This is important especially for wxGTK and wxOSX where EVT_RIGHT_UP is used to generate a context menu event.
Closes#17817.