Commit Graph

58450 Commits

Author SHA1 Message Date
Vadim Zeitlin
2e8988c3d6 Add wxGridCellRenderer::GetBest{Height,Width}() and use them in wxGrid.
Allow the renderer to specify the best height at the given width (or vice
versa) instead of the best size in both direction which is not defined for
e.g. wxGridCellAutoWrapStringRenderer.

Closes #15943.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76451 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-04 22:12:42 +00:00
Vadim Zeitlin
02f5b809bd Document restrictions on icon names in the resources in wxMSW.
Make it more clear that application icon must precede "wx" in alphabetical
order.

Closes #3529.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76450 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-04 22:12:36 +00:00
Vadim Zeitlin
07427c4fbd Fix busy cursor handling in modal dialogs under MSW.
Modal dialogs shown during wxBusyCursor effect shouldn't show the busy cursor
as they do accept input, but did in wxMSW (as could be seen in e.g. the
widgets sample after enabling the "Global busy cursor" in the menu and showing
the text entry dialog via "Text|Set Help Hint").

Fix this by explicitly checking for the special case of having a modal dialog
as parent at wxWindow level as doing it in wxDialog simply didn't work as its
WM_SETCURSOR handler wasn't called at all for determining the cursor to use
for its children because they handled WM_SETCURSOR themselves in the global
busy state, without letting DefWindowProc(), which propagates this message
upwards the window hierarchy, to have it at all.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76449 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-04 22:12:32 +00:00
Vadim Zeitlin
e3979f5186 Bring MSVS 2010 projects in line with 2011 and 2012 ones.
The new projects are easier to customize as the build options can now be
specified in wx_vc10_local.props file. They also have correct dependencies and
avoid sharing violations when copying wx/setup.h.

Finally, they also use the correct names for the webview DLL, see #15820.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76448 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-04 22:12:27 +00:00
Vadim Zeitlin
51871b7b5a Reset icon ref count when deleting the icon in wxMSW balloon icons code.
This avoids the assert which happened when trying to show the next
notification message in SetUpIcon() as the icon was null while the reference
count was positive.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76447 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-04 22:12:05 +00:00
Paul Cornett
1be1f56be1 vswscanf is needed regardless of wxUSE_UNICODE
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76442 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-03 16:44:14 +00:00
Paul Cornett
2eb7668968 build fix for systems lacking vswscanf when wxUSE_UNICODE==0
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76441 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-03 16:31:41 +00:00
Julian Smart
5b8e5e81b6 Implemented keyboard selection and better cell navigation for tables
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76440 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-03 13:07:16 +00:00
Vadim Zeitlin
6b12d12fe9 Fix property sheets names in MSVS 2013 custom build project.
It must be vc12, not vc11.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76439 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-02 14:19:59 +00:00
Vadim Zeitlin
0a62ce8c8e Add dependency of wxregex on wx/setup.h in MSVS projects.
Modified regex library code uses wx headers, so build _custom_build project
creating wx/setup.h before it.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76438 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-02 14:19:56 +00:00
Vadim Zeitlin
eeccbf98f4 Don't crash when dismissing expanded ribbon panel.
The parent of wxRibbonPanel is not always a wxRibbonPage, it can also be the
containing wxFrame itself if the panel is a temporarily expanded one created
when the user clicks a panel reduced to a button. So don't rely on the cast of
the parent to wxRibbonPage to always work. This is ugly but at least avoids a
crash.

Closes #16215.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76437 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-02 14:19:48 +00:00
Paul Cornett
605e637f47 send changed event when selecting a special directory from wxDirPickerCtrl combobox
closes #16064


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76436 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-01 16:57:50 +00:00
Paul Cornett
8b93b050cf avoid referencing xml and html libs when they are not enabled
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76435 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-30 17:08:50 +00:00
Vadim Zeitlin
2fbda42aed Fix wxGetClientDisplayRect() when _NET_WORKAREA is not supported.
Don't intersect the total rectangle with the uninitialized work area one
resulting in an empty rectangle being returned from wxGetClientDisplayRect()
if X11 server doesn't support _NET_WORKAREA (this is the case for at least
Cygwin X11 server).

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76434 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-30 14:11:01 +00:00
Stefan Csomor
617e17b746 supporting alpha channel correctly from clipboard, closes #16198
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76431 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-30 06:59:42 +00:00
Vadim Zeitlin
570926f0d7 Use SetInitialSize() in the about wxHTML sample.
SetSize() is useless here as it is simply ignored by the sizer which will fit
the window to its initial size anyhow.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76430 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-29 20:35:40 +00:00
Stefan Csomor
012ccdf8a5 adding support for multi-line text in rotated text, fixes #16216
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76428 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-29 18:22:54 +00:00
Stefan Csomor
337454f387 fix memory leak for initial empty menubar, see #15666
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76426 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-29 14:18:30 +00:00
Vadim Zeitlin
59e5a48141 Recognize Intel compiler as MSVC one under Windows in the build options.
The two compilers are binary compatible and by pretending that Intel compiler
is the same as MSVC, we allow using ICC to build applications using DLLs built
with MSVC.

Closes #9437.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76425 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-29 10:59:59 +00:00
Vadim Zeitlin
ebd06e2075 Fix problems due to using "%i" format with size_t in propgrid sample.
Cast size_t value to int when passing it to "%i" format specifier as it has a
different size on LP64 platforms.

Closes #16213.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76424 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-28 11:33:07 +00:00
Vadim Zeitlin
07ff314c13 Make "Close" button affirmative ID in standard dialog button sizer.
This allows to use the Escape key to close a dialog with the "Close" button
only.

Closes #16185.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76422 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-28 11:28:35 +00:00
Vadim Zeitlin
d75eb338c2 Fix precision in wxGraphicsContext::{Stroke,Draw}Lines() under MSW.
Use floating point coordinates instead of ints which were used for some
reason, resulting in a loss of precision.

Closes #16187.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76420 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-27 22:42:04 +00:00
Vadim Zeitlin
bf793227d2 Extract setup.h copying into a separate project for MSVC11+.
This fixes problems with parallel builds in Visual Studio 2012 or 2013 IDE as
multiple projects may try to copy setup.h file at once, resulting in errors.

Use _custom_build project as a common dependency to ensure that the copy step
is done only once.

Closes #16177.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76419 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-27 22:41:59 +00:00
Vadim Zeitlin
ccaebf6520 Add wxThread::MSWGetHandle().
Under MSW a thread has both an ID, returned by wxThread::GetId(), and a
handle, which couldn't be retrieved so far. Add an accessor to do it.

Closes #16170.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76418 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-27 22:41:50 +00:00
Vadim Zeitlin
2b7c7464ad Fix wrong wxStatusBar height in wxMSW in some circumstances.
Creating the status bar before the menu bar but associating it with the frame
after creating the menu bar resulted in a status bar of completely wrong height.
Fix this by enforcing the default height on the status bar when it's attached
to the frame.

Closes #10956.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76417 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-27 22:41:45 +00:00
Vadim Zeitlin
cbe6495307 Allow dropping data outside of item area in wxDataViewCtrl.
Implement this change for the generic and the native GTK versions and document
it.

Closes #16152.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76416 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-27 22:41:40 +00:00
Vadim Zeitlin
555e57912e Bring wxMSW wxBitmap::SetBitmapXXX(wxBitmap()) in line with wxGTK.
Remove or reset the corresponding bitmap if the provided one is invalid
instead of asserting, this is what wxGTK does and this behaviour seems to be
more useful.

Also document this behaviour as it's now implemented in both wxMSW and wxGTK.

Closes #13569.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76415 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-27 22:40:05 +00:00
Vadim Zeitlin
ec112197f2 Micro optimization of checking for alpha transparency.
Use faster accessors to the image size.

Closes #16148.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76414 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-27 22:39:59 +00:00
Vadim Zeitlin
2e079a988d Make wxMSW wxTextCtrl::AdjustSpaceLimit() safe to call in all cases.
Allow calling this function not only from inside DoWriteText(): first, because
the existing code could be doing this (although this is only a concern in 3.0
branch as it was made private in the trunk) and second because it could
actually happen if the text limit was exceeded by user typing in the control.

See #15980.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76413 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-27 22:39:54 +00:00
Vadim Zeitlin
934ce46464 Don't call AdjustSpaceLimit() explicitly in wxMSW wxTextCtrl any more.
There is no need to do it as this is done by DoWriteText() and
AdjustSpaceLimit() doesn't work correctly if called from outside of it now.
Because of this, also make it private to prevent other accidental calls to it.

Closes #15980.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76412 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-27 22:39:49 +00:00
Vadim Zeitlin
6700ea5ad2 Fix warning about using "deprecated" close() in MSVC build.
Use wxClose(), which is the same as _close() for MSVC.

Closes #16212.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76411 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-27 22:39:43 +00:00
Vadim Zeitlin
755c525767 Suppress warnings about using _set_se_translator() for MSVC 12 too.
We did it up to MSVC 11 but this still seems to work just fine without /EHa
with MSVC 12 too, so relax the version check to allow it to pass.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76410 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-27 22:39:40 +00:00
Vadim Zeitlin
acf6264309 Get rid of deprecated warnings for ::GetVersionEx().
This does not solve the actual problem of this function not returning the
correct value for Windows 8+ any more, but at least allows to compile the
library without warnings with MSVC 12 and later.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76409 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-27 22:39:37 +00:00
Vadim Zeitlin
2964de72a5 Don't duplicate wxGetOsVersion() in wxMSW wxGUIAppTraits.
Just call wxGetOsVersion() instead of using the Windows ::GetVersionEx()
function directly.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76408 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-27 22:39:34 +00:00
Vadim Zeitlin
86c286354f Enable wxCSConv UTF-7 test under Windows.
Even though it doesn't work with iconv under Unix, we can still enable this
test under Windows.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76407 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-27 22:39:31 +00:00
Vadim Zeitlin
761e0c12a0 Remove Windows version check from wxMBConv_win32.
We don't support systems predating Windows 2000 SP4 any more, so there is no
need to check for them. This also allows to get rid of the code checking for
conversion correctness.

Also remove the broken URLs from the comments, they didn't contain any
particularly useful information anyhow.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76406 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-27 22:39:28 +00:00
Stefan Csomor
f18d7097da adding wxFALLTHROUGH where until now we had comments, allows for code-analysis support
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76399 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-26 17:36:32 +00:00
Paul Cornett
6c6362401c Delay GtkIMContext calls until widget is realized.
This may avoid a locking bug seen on Ubuntu which causes a deadlock.
See #16202


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76398 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-26 17:11:31 +00:00
Dimitri Schoolwerth
37ba576b4a Fixed wxFileDialog::MSWOnInitDone and wxFileDialog::MSWOnSelChange never being called.
A condition was checking for the wrong CDN_XXX message range resulting in CDN_INITDONE and CDN_SELCHANGE no longer being processed. Broken since r75937 (branches/WX_3_0_BRANCH/) and r75941 (trunk/).

See #16003.


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76394 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-24 23:25:10 +00:00
Stefan Csomor
4360902f4e in order to get rid of the warnings completely use the former font descriptor creation sequence and cache the result immediately, fixes #15999
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76393 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-23 13:40:18 +00:00
Stefan Csomor
60578d63f4 add our own Apple Event handler for the quit app event, fixes #16200
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76392 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-22 21:21:19 +00:00
Stefan Csomor
fe49efa19a The Human Interface Guidelines recommend using NSSmallSquareBezelStyle now
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76391 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-22 18:20:54 +00:00
Julian Smart
90143c254c Added wxRichTextCtrl::DoLayoutBuffer so an application can perform custom tasks before or after layout.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76390 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-22 16:27:29 +00:00
Julian Smart
1a16259223 Draw an unknown field using a fallback field type, so it's not invisible.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76389 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-22 16:25:48 +00:00
Julian Smart
871a1976b2 Don't Sync() if there is no buffer. This allows derived classes that handle the buffer differently (e.g. reuse the buffer).
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76386 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-22 16:23:53 +00:00
Stefan Csomor
a44fff59dc removes zlib link statement from static builds, closes #16192
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76385 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-21 18:56:37 +00:00
Stefan Csomor
ee0b6b465b recreated project files, see #16192
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76384 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-21 18:52:38 +00:00
Stefan Csomor
7354e1461e adding built-in zlib sources, see #16192
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76383 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-21 18:37:25 +00:00
Stefan Csomor
52b633eeea adapting xcode build templates and config file to built-in zlib sources, see #16192
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76382 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-21 18:31:48 +00:00
Vadim Zeitlin
7ab7ff693b Add wxGraphicsRenderer::GetName() and GetVersion() methods.
Allow the code to determine which underlying technology is used for
implementing wxGraphics API. This is needed by the unit tests to account for
the known differences between platforms and may be useful in other cases.

Closes #16154.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76380 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-20 12:45:10 +00:00