Commit Graph

56080 Commits

Author SHA1 Message Date
Vadim Zeitlin
c70155b8ee Just fix header comments of wxTextMeasure-related files, no real changes.
See #14781.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72799 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-27 12:27:48 +00:00
Robin Dunn
64ea838d8f Add missing WXK constants for the control keys
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72788 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-27 03:15:17 +00:00
Robin Dunn
6d7b19b013 Generate the interface file for STC from gen_iface too.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72787 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-27 03:15:08 +00:00
Vadim Zeitlin
a24b52544e Fix incorrect libraries in the documentation.
Use wxcore for the GUI classes that were mistakenly documented as belonging to
the wxbase library.

Closes #14783.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72786 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-27 01:27:23 +00:00
Vadim Zeitlin
46e6720278 Add wxAuiToolBar::Create().
Implement two-step creation of wxAuiToolBar to allow doing it from XRC.

See #13520.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72785 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-27 01:27:19 +00:00
Vadim Zeitlin
cf8ccdb270 Renamed file containing wxAuiToolBar documentation.
The real header is called wx/aui/auibar.h, not wx/aui/toolbar.h.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72784 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-27 01:27:16 +00:00
Vadim Zeitlin
65b139c8d1 Fix PCH-less build after previous commit.
Need to include wx/window.h now that wx/animate.h is not included any more.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72783 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-27 01:27:13 +00:00
Vadim Zeitlin
bdb4b8320d Break implicit dependency of "core" on "adv" via wxXmlResourceHandlerImplBase.
wxXmlResourceHandlerImplBase::GetAnimation() returned wxAnimation by value
which created references to wxAnimationCtrlNameStr and wxNullAnimation
symbols, defined in the "adv" library, in "core" when using Sun CC even though
they were not referenced directly.

Fix this by returning wxAnimation by pointer to keep it opaque for "core" code.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72782 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-27 00:46:58 +00:00
Vadim Zeitlin
9823d1c5d1 Compilation fix for STL build after the last commit.
Add missing fn_str() call.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72780 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-25 23:55:54 +00:00
Vadim Zeitlin
5a7c1881a1 Store the selected directory in wxGTK wxDirDialog.
This should help with the selected directory not being remembered since
GTK+ 2.24.11 as apparently gtk_file_chooser_get_filename() doesn't work any
more now after hiding the dialog -- so call it before doing this and save the
result.

Also get rid of the ugly and apparently completely unnecessary OnFakeOk().

Closes #14525.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72779 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-25 23:26:36 +00:00
Vadim Zeitlin
656b9f4467 Prevent pasting too much text into limited length wxTextCtrl in wxGTK.
Improve insert-text signal handler to block pasting text into the control,
which may overflow the specified max length in one action, and not only
entering individual characters.

See #3158.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72778 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-25 23:26:32 +00:00
Vadim Zeitlin
58263bb4c3 Make wxFILE_EXISTS_SYMLINK work on its own, without wxFILE_EXISTS_NO_FOLLOW.
Include the wxFILE_EXISTS_NO_FOLLOW bit in wxFILE_EXISTS_SYMLINK definition to
allow using just wxFileName::Exists(wxFILE_EXISTS_SYMLINK) which used to never
work because the link was followed.

Closes #14777.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72777 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-25 22:30:43 +00:00
Vadim Zeitlin
df27f1dc9e Include wx/xml/xml.h from the XRC handlers that need it.
Including this header from wx/xrc/xmlres.h itself only when WXMAKINGDLL_XRC is
defined doesn't work when we're building a static library and not a shared/DLL
one and we don't have any symbol defined in this case, so just don't try to be
smart and include this header from the files that need it.

This fixes breakage of r72756.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72776 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-25 22:19:20 +00:00
Vadim Zeitlin
f94a952846 PCH-less build fix for DynamicLibraryTestCase.
Include wx/log.h needed by wxLogWarning().

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72763 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-24 23:41:04 +00:00
Vadim Zeitlin
614e38dbb2 Implement clipping in wxSVGFileDC.
Support setting the clipping region and add update the documentation and the
sample accordingly.

Closes #14462.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72762 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-24 23:40:41 +00:00
Vadim Zeitlin
c84c7347ba No real changes, just avoid unnecessary string operations in wxSVGFileDCImpl.
Simply write string together instead of concatenating them during run-time.

See #14462.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72761 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-24 23:40:17 +00:00
Vadim Zeitlin
5d9dd2c6e1 No changes, just remove unused variable from wxSVGFileDCImpl.
sWarn was never used, drop it.

See #14462.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72760 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-24 23:39:55 +00:00
Vadim Zeitlin
c66bfe457c Show some information about the environment in the unit tests.
For now just show the system description and the locale, this should already
be helpful for diagnosing some test failures.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72759 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-24 23:14:01 +00:00
Vadim Zeitlin
e282b73a5b Test for the shared library existence in DynamicLibraryTestCase.
Trying to understand why does the test fail in some build slaves builds.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72758 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-24 23:13:38 +00:00
Vadim Zeitlin
b690a8f672 Add a missing test for wxHAS_CALL_AFTER in the implementation too.
This completes the changes of r72743.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72757 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-24 23:13:16 +00:00
Vadim Zeitlin
19f87dbe25 Try to avoid accidental use of wxXmlNode in XRC handlers.
Now that the handlers can be defined outside of the XRC library, we can't use
wxXmlNode in them because this would create an (unsatisfied) link dependency
on the xml library.

To avoid this happening accidentally, don't include wx/xml/xml.h from the XRC
header, unless building the xrc library itself.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72756 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-24 18:34:19 +00:00
Vadim Zeitlin
3142ae0727 Disable dropdown menu support in wxRibbonXmlHandler.
The code handling it uses wxXmlNode directly as it's written now which isn't
allowed as it introduces a dependency of ribbon library on the xml one and so
currently breaks linking of the ribbon DLL under MSW.

See #12058.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72755 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-24 18:33:57 +00:00
Vadim Zeitlin
9db1772739 Don't call wxSafeYield() from wxGenericListCtrl::EditLabel().
This could result in wxYield() reentrancy and while it could be avoided by
using wxSafeYield(NULL, true /* only if needed */) it seems that we don't
actually need to yield here at all and a simple Update() should be enough.

Closes #14727.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72754 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-24 18:22:39 +00:00
Vadim Zeitlin
fe6afcb339 Don't iterate over files in wxFileSystemWatcherBase.
We ignore the files anyhow when recursively adding watches for the entire
tree, so don't include them in the iteration.

See #14543.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72753 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-24 18:22:17 +00:00
Vadim Zeitlin
06b4c6ebd2 Remove wxAUI dependency on wxXML as it doesn't depend on it.
Don't include wxAUI -> wxXML dependency in the libraries diagram in the
manual.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72752 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-24 18:21:54 +00:00
Vadim Zeitlin
0fccda2ced Respect wxFileName::DontFollowLink() in wxFileSystemWatcher.
Watch the link itself and not its target if DontFollowLink() had been called.

Closes #14543.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72751 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-24 18:21:31 +00:00
Vadim Zeitlin
d2a02746c6 Make wxDateTime invalid after Set((time_t)-1) call.
Closes #14776.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72750 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-24 14:02:30 +00:00
Vadim Zeitlin
81ec048ab9 Close wxLogWindow automatically if it's the last remaining TLW.
Don't keep the application opened just because a log window is shown.

Closes #14775.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72749 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-24 14:02:08 +00:00
Vadim Zeitlin
2ff86a86a7 Add wxVector::assign().
Closes #14703.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72748 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-24 14:01:44 +00:00
Julian Smart
9740c1afc8 Updated Lativan translation
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72747 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-24 13:13:19 +00:00
Vadim Zeitlin
103d838eff Don't use std::min(), it's not available everywhere.
Fix compilation using Sun CC under Solaris.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72745 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-24 00:25:31 +00:00
Vadim Zeitlin
073d9e0f26 Don't use Shift-TAB in keyboard test.
This key combination seems to be intercepted by GTK now for keyboard
navigation purposes and we never get key up events for it. Just use a
different key.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72744 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-24 00:25:09 +00:00
Vadim Zeitlin
8f6bb2602b Disable wxEvtHandler::CallAfter() for VC6, it's too broken for it.
There is no clear way to implement wxRemoveRef() for VC6 so just disable it,
and CallAfter() as it relies on it, for this compiler.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72743 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-24 00:17:15 +00:00
Vadim Zeitlin
25db2c25bc Don't follow symlinks in wxFileName::Rmdir(wxPATH_RMDIR_RECURSIVE).
Following symlinks, possibly leading outside of the directory being removed,
is at best surprising and at worst dangerous, so don't do it and just mimic
the behaviour of "rm -rf", i.e. remove everything inside this directory,
including the symlinks themselves, but don't follow them.

Closes #14649.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72742 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-23 23:58:17 +00:00
Vadim Zeitlin
0f57172b93 Mention wxFILE_EXISTS_NO_FOLLOW in wxFILE_EXISTS_SYMLINK description.
Using wxFILE_EXISTS_SYMLINK without wxFILE_EXISTS_NO_FOLLOW can only be
fruitless, so mention that they should normally be used together in the
documentation.

An alternative solution would be to always add wxFILE_EXISTS_NO_FOLLOW
automatically if wxFILE_EXISTS_SYMLINK is used, perhaps we should do this
instead.

See #14542.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72741 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-23 23:57:54 +00:00
Vadim Zeitlin
c55f46d0a1 Add wxDIR_NO_FOLLOW flag for wxDir iteration.
This flag allows to avoid following the symbolic links during the directory
traversal. In particular, this means that links to the directories
(potentially outside the directory being traversed) are not considered as
directories at all when it is used, potentially avoiding surprises.

Closes #14542.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72740 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-23 23:57:32 +00:00
Vadim Zeitlin
6bf11d6720 Change the way directory iteration flags are constructed.
Instead of explicitly constructing the flags from the flags that should be
included, construct them by excluding the flags that shouldn't be used. This
makes the code more stable in the sense that it will continue to work when new
flags, such as the upcoming wxDIR_NO_FOLLOW, are added.

See #14542.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72739 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-23 23:57:07 +00:00
Paul Cornett
e264485aac non-pch build fix
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72737 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-23 17:29:32 +00:00
Paul Cornett
856cad9ac7 Minor changes to some comments
remove ambiguous "only"
procession --> processing


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72736 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-23 17:28:43 +00:00
Vadim Zeitlin
65e9e9c303 Fix for PCH-less compilation of wxRibbonXmlHandler.
Need to have wxMenu declaration in order to wxDynamicCast() to it.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72731 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-23 14:30:23 +00:00
Vadim Zeitlin
3f6a19ffab Guard gmake-specific syntax with IF_GNU_MAKE in make_dist.mk.
Debian distribution target uses GNU make extensions to make syntax which makes
the entire makefile impossible to use with other make versions, e.g. Solaris
make.

Fix this by prepending IF_GNU_MAKE to all Debian-specific lines, there should
be never any need to use them with non-GNU make.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72730 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-23 14:03:53 +00:00
Vadim Zeitlin
74a59798c0 Add support for wxRibbonBar and related controls to XRC.
Add wxRibbonXmlHandler and an example of using it to the xrc sample.

Closes #12058.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72729 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-23 13:52:27 +00:00
Vadim Zeitlin
00b4e7c946 Add support for wxAuiNotebook to XRC.
Add wxAuiNotebookXmlHandler to "aui" library, now that we can do it without
adding a dependency of it on "xrc" one.

Closes #10889.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72728 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-23 13:51:58 +00:00
Vadim Zeitlin
a3b9c43bbc Refactor wxXRC to allow defining handlers outside of xrc library.
Split wxXmlResourceHandler into an ABC and the real implementation to allow
referencing the ABC in the core library itself but without pulling in all of
the XRC into it. This also allows defining XRC handlers, which only depend on
this ABC and not the xrc library, in other libraries, such as richtext, as
demonstrated by the now enabled wxRichTextXMLHandler.

Closes #10996.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72727 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-23 13:51:32 +00:00
Vadim Zeitlin
4dca3e02a6 Define WXDLLIMPEXP_FWD_RIBBON for consistency with all the other libraries.
We defined only WXDLLIMPEXP_RIBBON but not the FWD version, do add it now.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72726 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-23 13:51:06 +00:00
Vadim Zeitlin
3496ce18d1 Recognize more XRC elements as containing translatable strings.
This allows to translate the text of these elements in wxrc-generated code
using gettext.

Closes #14765.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72725 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-23 12:06:40 +00:00
Vadim Zeitlin
1ea95c73f8 Add a simple unit test for wxRegion::Intersect().
Check that Intersect() returns true, yet the intersection is empty.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72724 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-23 12:03:09 +00:00
Vadim Zeitlin
709617eec2 Process pending events from wxYield() in wxGTK.
Calling wxYield() is supposed to process the pending events but it didn't, any
more, in wxGTK. Restore this by explicitly calling ProcessPendingEvents() from
wxGTK wxYield() implementation as wxGUIEventLoop::ProcessIdle() does not call
it, in spite of a comment to the contrary in the sources.

Closes #14760.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72723 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-23 12:02:47 +00:00
Vadim Zeitlin
cf2227623a Add wxEvtHandler::CallAfter() for asynchronous method calls.
Add wxAsyncMethodCallEvent that is handled simply by calling the method this
event was created for and add default handler for this event to wxEvtHandler.

Implement CallAfter() overloads for up to 2 parameters only for now.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72722 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-23 12:02:24 +00:00
Vadim Zeitlin
32753ae949 Add wx/meta/removeref.h header defining wxRemoveRef<> helper.
This is a very simple template allowing to remove the reference from the given
type, similar to std::remove_reference<>.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72721 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-23 12:02:00 +00:00