Commit Graph

6088 Commits

Author SHA1 Message Date
Vadim Zeitlin
fa93d732e2 Harmonize wxDataViewCtrl::GetSelection() behaviour in all ports.
wxDataViewCtrl::GetSelection() now always returns invalid item if more than
a single item is selected in a multi-selection control.

Also add HasSelection() and GetSelectedItemsCount() to allow checking if any
items are selected.

Updated the documentation, all ports and added a test for all these functions.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68844 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-22 12:41:19 +00:00
Vadim Zeitlin
ae2047c32a Add XRC handler for wxBannerWindow and a test for it to the xrc sample.
Also document the new XRC format elements.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68840 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-22 12:18:56 +00:00
Vadim Zeitlin
ea11bf3abc Add new wxBannerWindow class.
A simple banner showing either a bitmap or some text on gradient background.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68838 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-22 12:18:43 +00:00
Vadim Zeitlin
e55d569400 Add @genericAppearance Doxygen macro.
This allows to provide just a single image (in "generic" subdirectory) for the
generic controls that look the same in all ports instead of having to create
three identical ones (in "wxmsw", "wxgtk" and "wxmac" subdirectories) that are
required by @appearance.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68837 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-22 12:18:33 +00:00
Vadim Zeitlin
36a96421b3 Replace wxComboBox::IsEmpty() with Is{List,Text}Empty().
IsEmpty() didn't exist in all ports (notably not wxMSW) and its meaning was
unclear anyhow, so remove it even from the ports where it did exist and add
clear Is{List,Text}Empty() replacements instead.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68808 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-21 12:06:16 +00:00
Julian Smart
63509fb3c4 Implemented non-selection of content when setting focus via the keyboard.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68749 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-16 20:52:15 +00:00
Vadim Zeitlin
f8a1c5715f Use separate strings for stock labels with and without mnemonics.
Obtaining the string without mnemonics by simply removing "&" characters from
the string containing mnemonics doesn't work for some languages, notably
Chinese where the convention is to use "Chinese Text (&M)" for the labels with
"M" being the ASCII mnemonic and just "Chinese Text" and not "Chinese Text (M)"
should be used if wxSTOCK_WITH_MNEMONIC flag is not specified.

Fix the fundamental problem by using separate strings for the two cases.
Translations still need to be updated to really correct the labels appearance.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68641 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-11 10:56:05 +00:00
Dimitri Schoolwerth
ee7553e935 Added NSApplicationDelegate's openFiles for wxOSX-Cocoa.
openFiles (available since OS X 10.3) replaces using the openFile method. It allows for more convenient handling of multiple drops and knowing in advance how much files/folders are dropped instead of openFile with which you only get to respond to a single file/folder drop at a time. By default openFiles calls the newly added MacOpenFiles which calls MacOpenFile multiple times, so ordinarily the behaviour is backwards compatible (both on wxOSX Cocoa and Carbon).

The openFile instance method has been removed because it doesn't seem to be called anymore: neither when dropping a single file on the application in the dock or Finder nor when passed as a command-line argument.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68617 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-09 22:17:12 +00:00
Vadim Zeitlin
ddae52629c Added wxTopLevelWindow::MSWGetSystemMenu() method.
Also generate events corresponding to WM_SYSCOMMAND messages for the custom
items of the system menu.

Add a small snippet to test the new functionality to the dialogs sample.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68596 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-08 09:32:42 +00:00
Vadim Zeitlin
59f495db65 Implement wxFileType::GetOpenCommand() in wxOSX.
This method used to work in 2.8 but was unimplemented in 2.9.

Restore more or less the old implementation using the data that we already
have in wxMimeTypesManager anyhow.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68563 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-05 19:02:26 +00:00
Vadim Zeitlin
7112cdd1f3 Add support for wxHELP button to wxMessageDialog.
Implement support for wxHELP for wxMSW, wxGTK and wxOSX/Cocoa (at least when
showing the message box from the main thread, there doesn't seem to be any way
to show more than three buttons with CFUserNotificationDisplayAlert() so
"Help" button is not supported when using it).

This is useful not only on its own, i.e. to allow the user to ask for help,
but also because it brings the total number of buttons supported by the
message dialog to 4, meaning that more choices can be offered to the user
(which is rarely, but not quite never, useful).

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68537 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-04 22:53:42 +00:00
Julian Smart
5755acd77f Return sensible major and minor version numbers for Mac OS X
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68506 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-03 15:46:43 +00:00
Vadim Zeitlin
9c5c5c9cfd Fix crash in wxArray::insert() overload taking iterator range.
The iterator passed as argument could be invalidated by the function itself,
update it before using it.

Closes #13371.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68468 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-07-30 23:38:43 +00:00
Vadim Zeitlin
6ce832135e Add wxTextCtrl::PositionToCoords() functions for wxMSW and wxGTK.
The new method allows to find the coordinates in pixels of the given character
in a text control.

Closes #13221.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68450 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-07-29 15:11:54 +00:00
Vadim Zeitlin
4d98817cfa Add wxNavigationEnabled<> helper for implementing TAB navigation.
Provide a clean, public and documented way to implement proper TAB navigation
for subwindows of a composite control: instead of using various ugly and never
documented WX_XXX_CONTROL_CONTAINER macros it is now enough to simply inherit
from wxNavigationEnabled<BaseClass> to do it.

No real changes in the code as the new class is not used anywhere yet.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68363 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-07-24 22:19:20 +00:00
Vadim Zeitlin
6c42e86d96 Increased the version to 2.9.3.
Simply ran misc/scripts/inc_release and changed build/bakefiles/version.bkl
and rebaked everything afterwards.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68336 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-07-22 16:32:07 +00:00
Vadim Zeitlin
d38eb01c91 Added customizable wxDocManager::OnMRUFileNotExist() virtual method.
This method can be overridden to customize the previously hard-coded handling
of the case when a file selected from the MRU menu doesn't exist any more: we
used to always remove it from the file history completely. This may, however,
be inappropriate and, in fact, probably never, or very rarely, is the right
thing to do when the file that we failed to open still exists.

So never remove the file from the MRU if we failed to open an existing file
(also don't give an error about it as it should have been already given by
CreateDocument()) and, while we still do it for the non-existent files, allow
to override this behaviour by overriding the new OnMRUFileNotExist() method.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68334 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-07-22 16:16:09 +00:00
Vadim Zeitlin
2b232decc5 Allow marking wxTreeBook nodes to expand initially in XRC.
Add new "expanded" attribute for XRC nodes of treebookpage class.

Also update the sample and the XRC format documentation.

Closes #13355.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68318 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-07-21 13:50:03 +00:00
Vadim Zeitlin
1a63798c5a Fix parsing of negated long options in wxCmdLineParser.
Negated long options were not recognized in wxCmdLineParser::Parse(), do check
for them now.

Also extend the unit test to check for negated options.

Closes #13335.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68316 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-07-21 13:49:55 +00:00
Vadim Zeitlin
2a648479df Add wxDataViewEvent::IsEditCancelled() and support for vetoing edit events.
Currently this is only implemented in the generic wxDataViewCtrl, the native
GTK/OSX ports should be modified to support this later.

Closes #13323.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68307 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-07-19 22:35:53 +00:00
Vadim Zeitlin
2d770c4f82 Added wxGCDC(wxEnhMetaFileDC) ctor too.
Make it possible to create wxGCDC associated with a metafile DC in wxMSW too.

Closes #13326.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68304 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-07-19 22:35:41 +00:00
Vadim Zeitlin
b64bb3ca1b Fix keyboard navigation in wxGrid with hidden columns.
The hidden columns (i.e. those whose size was set to 0) should be skipped when
find the previous/next column to select when the user presses Left/Right
cursor arrow keys in wxGrid, otherwise the focus could completely disappear as
it was invisible when it was set to a hidden column.

Closes #13281.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68303 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-07-19 22:35:37 +00:00
Václav Slavík
7243eb6d3b Add support for column header images to wxListCtrl XRC handler.
Fixes #13319 (patch).

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68286 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-07-16 10:05:02 +00:00
Vadim Zeitlin
1715d4fef9 Implement wxRegion::Equal() for wxOSX.
As there doesn't seem to be any native functions for comparing HIShapes,
compute their differences to find out if they are equal.

Closes #13339.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68280 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-07-15 22:58:36 +00:00
Vadim Zeitlin
e96be167e7 Support float, double and file name values in wxGenericValidator.
Currently these values can only be read from/written to wxTextCtrl but support
for other controls (e.g. wxSpinCtrlDouble for float/double) could be added in
the future.

Closes #13304.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68217 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-07-09 23:37:28 +00:00
Vadim Zeitlin
e7cda1c350 Generate events for two auxiliary mouse buttons in wxGTK.
Add code to generate wxEVT_AUXN_XXX events to wxGTK.

Closes #13310.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68215 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-07-09 23:37:15 +00:00
Vadim Zeitlin
4b876233c8 Improve the description of the available files in readme.
Be more clear about what is provided. Add more URLs, everybody likes to click
them.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68161 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-07-04 21:26:11 +00:00
Vadim Zeitlin
dc0a2ff4bf Remove the note about wxUSE_STD_CONTAINERS.
We finally didn't switch to using the standard containers by default so don't
leave misleading information in the change log (this should have been part of
r67735).

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68159 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-07-04 21:13:26 +00:00
Vadim Zeitlin
e4e1626cbb Mention the EOL issue in readme.txt.
Emphasize that building Windows archives under Unix *or vice versa) is not
supported.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68117 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-06-30 21:31:39 +00:00
Chris Elliott
474aa33ee2 update docs for windows checkout process 2/2
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68114 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-06-30 13:20:55 +00:00
Vadim Zeitlin
408ee837a8 Mention that readme.txt needs to be updated before a release.
Hopefully this means it won't be forgotten the next time.

Also mentioned that the new docs.wxwidgets.org link should be now already
created when the release is being done.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68097 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-06-29 17:50:08 +00:00
Vadim Zeitlin
273a28a1e9 Add a tiny script for producing HTML documentation archives.
Also update the release making document to point to it.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68096 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-06-29 17:50:05 +00:00
Vadim Zeitlin
8563b81134 Update the readme file for 2.9.2.
Just increment version number and year in a couple of places.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68094 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-06-29 17:49:59 +00:00
Vadim Zeitlin
7b1a29ce00 Updated copyright year before 2.9.2 release.
Use 2011 instead of 2010 in the manual and in several .plist files.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68088 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-06-29 09:22:35 +00:00
Václav Slavík
c1b293bb8d Move wxThreadEvent into wxBase.
For this, it cannot derive from wxCommandEvent. Extracted the bits
from wxCommandEvent useful for passing data between threads into
wxEventBasicPayloadMixin helper class shared by both.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68076 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-06-28 17:24:37 +00:00
Vadim Zeitlin
4db97e24f5 Add support for child documents to docview framework.
Child documents are virtual documents corresponding to parts of their parent
document which can't be saved nor loaded independently of their parent and are
closed when the parent is closed.

This finally makes some use of wxDocument::m_documentParent field which was
always present in the docview code but never used before.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68051 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-06-27 00:09:37 +00:00
Vadim Zeitlin
106f0d98f8 Implement wxCalendarCtrl::SetDateRange() in the native GTK version.
While GTK+ doesn't support imposing ranges for dates selection natively, we
can do it ourselves by preventing the user from selecting any date outside of
the currently valid range.

This allows to use ranges under all platforms and not only in wxCalendarCtrl
itself but in wxDatePickerCtrl as well.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67987 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-06-19 22:46:36 +00:00
Vadim Zeitlin
bc927c9a8c Generic wxHyperlinkCtrl appearance and behaviour improvements.
Show focus rectangle around the control when it has focus. Also handle the
space key to trigger the link.

Also allow using either the native or generic version of the class in the
widgets sample.

Closes #11285.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67948 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-06-15 21:56:23 +00:00
Vadim Zeitlin
8770af492a Fix keyboard navigation in wxGrid with reordered columns.
Don't mix up column internal indices and display positions in wxGrid keyboard
navigation code.

This ensures that pressing left/right cursor arrows always moves the cursor to
the previous/next column on the display, even if the columns were reordered.

Closes #13281.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67944 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-06-15 13:33:10 +00:00
Vadim Zeitlin
b4354db179 Refactor wxButton and wxToggleButton to derive from wxAnyButton.
Introduce wxAnyButton class, a common base class for wxButton and
wxToggleButton, allowing to reuse the same implementation for them.

This also allows to implement support for bitmaps in wxToggleButton for all
platforms and make wxBitmapToggleButton a trivial subclass of it everywhere,
similarly to wxBitmapButton and wxButton.

Closes #13198.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67931 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-06-14 13:00:42 +00:00
Stefan Csomor
eaa9e06d92 adding docset processing instructions
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67922 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-06-12 03:39:17 +00:00
Stefan Csomor
2db79d106c adding lighter css variant for xcode docsets
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67921 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-06-12 02:47:24 +00:00
Stefan Csomor
16a7d8a5a5 adding more specific info for docset
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67917 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-06-11 15:41:44 +00:00
Stefan Csomor
303d821608 adding implementation for osx
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67913 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-06-10 03:12:58 +00:00
Vadim Zeitlin
7311debd0d Don't use the standard containers by default.
Revert the change of wxUSE_STD_CONTAINERS to 1 by default as this introduces
more incompatibilities which risk hamper upgrading to 3.0 unnecessarily.

Update the documentation to better explain why do the non-standard container
classes exist in wxWidgets and, especially, that they shouldn't be used when
possible. Also document the differences between the normal and STL containers
build in the manual.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67735 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-05-13 13:30:12 +00:00
Julian Smart
71185527a0 wxRTC doc updates
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67727 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-05-11 16:45:34 +00:00
Jaakko Salli
a6ca624a27 Fixed a bug: Disabling a property didn't work properly if a child item was selected.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67719 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-05-09 19:44:40 +00:00
Vadim Zeitlin
1bdeb24eea Document wxBitmapToggleButton XRC parameters.
Describe the properties specific to this class in the XRC format
documentation.

Closes #13204.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67717 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-05-09 09:21:25 +00:00
Vadim Zeitlin
8e370f7d07 Add a section about STL containers-related incompatible changes.
Document the main incompatibilities between the STL and non-STL containers
builds.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67658 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-05-01 15:47:44 +00:00
Dimitri Schoolwerth
e3778b4d9c No code changes, fixed some typos.
Changed several occurrences of "it's" where "its" is meant, as well as a few other minor typos.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67656 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-04-30 10:57:04 +00:00