Commit Graph

56542 Commits

Author SHA1 Message Date
Vadim Zeitlin
e75ceab08c Fix infinite loop in wxGrid::PosToEdgeOfLine().
Return -1 from wxGridRowOperations::GetLineBefore(0) to ensure that we exit
the loop in wxGrid::PosToEdgeOfLine(). Doing this is the logical thing to do
as wxGridColumnOperations::GetLineBefore() already behaved like this and this
was is more expected than returning 0, as the function previously did for some
reason.

Closes #15035.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73487 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-02-09 00:36:02 +00:00
Vadim Zeitlin
e56fee472c Fix pulsing of bitmaps in focused buttons under Windows 7.
It turns out that the actual bitmap shown in this case varies between the
bitmaps at PBS_DEFAULTED and PBS_STYLUSHOT, so that it's invisible half of the
time if we don't specify the value for the latter. Do it now to fix unwanted
pulsing of the bitmap in the focused button.

Closes #15034.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73486 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-02-09 00:35:58 +00:00
Vadim Zeitlin
05942059ef Refresh wxMSW wxStaticBitmap when its size changes.
As MSW native control centers the image, it must be entirely redrawn when the
area in which the image is centered changes, but it doesn't happen by default,
so do it ourselves explicitly.

Also explain that this centering behaviour is platform-specific and shouldn't
be relied upon.

Closes #4564.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73485 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-02-09 00:35:54 +00:00
Vadim Zeitlin
4bd1fc29b2 Fix drawing of bitmaps with masks in mirrored wxDC.
The mask must be mirrored in the same way as the main bitmap itself (currently
it's not mirrored at all but this could change in the future), so create the
temporary memory HDC with the same layout as is used by the main HDC.

Closes #3995.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73484 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-02-09 00:35:49 +00:00
Vadim Zeitlin
15f74a3feb Don't include the manifest in wx/msw/wx.rc by default for MSVC compiler.
The later versions of this compiler don't need it any more, so make it easier
to set up the projects for them at the expense of MSVC 6 and 7 users who will
now need to explicitly define wxUSE_RC_MANIFEST=1 and predefine the
architecture macro (or setup their resource compiler include path to get
wx/msw/rcdefs.h under the lib directory but predefining the architecture is
clearly simpler).

Do generate manifest when using gcc as it predefines the architecture macros
allowing us to avoid requiring using the generated rcdefs.h.

The other compilers will be dealt with as needed if anybody is still using
them.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73483 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-02-09 00:35:46 +00:00
Vadim Zeitlin
e949d38c4e Don't recurse into top level children when validating recursively.
Even with wxWS_EX_VALIDATE_RECURSIVELY flag, we should never validate the top
level children (e.g. dialogs) when validating the parent window. This is never
useful and can be completely unexpected.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73482 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-02-06 12:48:12 +00:00
Vadim Zeitlin
5abc0d2197 Refactor children traversal in wxWindow::TransferData{To,From}Window().
No real changes, just factor out the logic for children traversal into a
helper template class and reuse it in Validate() and both TransferData()
methods to avoid triplicating it.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73481 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-02-06 12:48:09 +00:00
Vadim Zeitlin
72bd600b33 Allow creating wxCursor from ANI files under MSW.
Simply pass them to the standard LoadCursorFromFile() function which supports
this format.

Closes #3472.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73480 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-02-06 12:46:24 +00:00
Vadim Zeitlin
d6b180ec36 Don't show log menu tiems in the tree control sample when !wxUSE_LOG.
No real changes, just correct the "#if wxUSE_LOG" placement.

See #4024.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73479 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-02-06 12:43:48 +00:00
Vadim Zeitlin
ff0d660405 Fix harmless warning about NULL in wxStyledTextCtrl code.
Cast NULL to the type of third argument of SendMsg() explicitly to avoid a
warning about it from Ubuntu g++ 4.6.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73478 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-02-06 00:42:11 +00:00
Vadim Zeitlin
79fdb1d1f7 Fix harmless g++ warning about operator precedence.
Add parentheses to suppress "&& inside ||" warning.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73477 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-02-06 00:42:09 +00:00
Vadim Zeitlin
9ab1e1539d Check for _MSC_VER definedness in libtiff code.
This avoids warnings about _MSC_VER being undefined when it's compared with
1500 when building with gcc.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73476 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-02-06 00:42:06 +00:00
Vadim Zeitlin
5adf2ecd9e Fix printf format specifier in graphics benchmark.
Use "%ld" for long arguments to fix asserts under 64 bit architectures.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73475 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-02-05 20:47:12 +00:00
Vadim Zeitlin
54d25f9d8a Added possibility to use OpenGL for bitmap drawing to graphics benchmark.
Draw the bitmap using OpenGL textures. Even without using PBO this results in
much greater performance than using wxImage or raw bitmap access.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73474 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-02-05 20:47:10 +00:00
Vadim Zeitlin
6e6f4d3572 Use a non-uniform bitmap for image tests in the graphics benchmark.
This makes it easier to estimate the speed of the display update visually.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73473 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-02-05 20:47:07 +00:00
Vadim Zeitlin
ce0cdeb0b7 No changes, just rename command line option in graphics benchmark test.
It's not used for lines only, so call it "number of iterations" and not
"number of lines" and use "N" instead of "L" option for it.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73472 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-02-05 20:47:05 +00:00
Vadim Zeitlin
e45606e991 Add benchmarks for wxImage and raw bitmap access to the graphics test.
Compare the speed of drawing the bitmaps by synthesizing wxImage and
converting it to wxBitmap and directly modifying wxBitmap bits using raw
bitmap access.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73471 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-02-05 20:47:02 +00:00
Vadim Zeitlin
8c14cbc98c Allow selecting the kinds of DC to test in the graphics benchmark too.
Still run all the tests by default but allow specifying --dc or --gc as well
as --paint, --client or --memory to test just the specified kinds of DCs.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73470 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-02-05 20:47:00 +00:00
Vadim Zeitlin
c80e612faa No real changes, just flush output in the graphics benchmark.
Show the output messages sooner instead of showing them all only when the test
ends.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73469 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-02-05 20:46:57 +00:00
Vadim Zeitlin
b9fb3b0671 Run wxClientDC and wxMemoryDC tests too in the graphics benchmark.
These tests were not run because OnPaint() handler was called before OnCreate()
and exited the main loop before the create event could be dispatched. Fix this
by just running everything from OnPaint(), like this we're sure to do it.

Also refactor the code a little to avoid duplicating the tests.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73468 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-02-05 20:46:55 +00:00
Vadim Zeitlin
51f64663bf Allow running only some graphics benchmarks to save time.
Running all the benchmarks is relatively long, so allow running individual
ones only.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73467 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-02-05 20:46:53 +00:00
Vadim Zeitlin
968b44d37b Ignore empty LC_XXX variables in locale detection code.
If LC_ALL or LC_MESSAGES is set but empty, ignore it and use the next
environment variable. This is consistent with the standard setlocale()
behaviour which only uses LC_ALL if it is set and not empty.

Closes #15006.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73466 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-02-05 20:46:26 +00:00
Vadim Zeitlin
4da0f1bb88 Fix spelling in utils/screenshotgen sources.
No real changes.

Closes #15024.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73465 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-02-05 20:46:22 +00:00
Vadim Zeitlin
25aa4f927a No changes, just remove unused part of expression.
We don't do anything with the result of inserting the watch in
fswatchercmn.cpp.

Closes #15027.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73464 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-02-05 20:46:18 +00:00
Vadim Zeitlin
2fb4e3cb0a Add simple tests for Scintilla annotations to the stc sample.
Show how add, remove and clear annotations and also how to update the text
width when long annotations are added.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73463 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-02-05 20:46:16 +00:00
Vadim Zeitlin
10d28c972b Use a single EVT_MENU_RANGE in stc sample instead of tons of EVT_MENU.
Make it easier to add new menu items forwarded to the editor in the sample.

No real changes.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73462 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-02-05 20:46:13 +00:00
Vadim Zeitlin
f2f18548a7 Only impose minimal height for buttons with non-empty label in wxMSW.
wxBU_EXACTFIT in wxMSW only affected the width of the button but not its
height, which was still made as big as the standard button size as otherwise
the button text was rendered badly. However there is no reason to do this for
the buttons without any text, so let wxBU_EXACTFIT be really exact, in both
directions, in this case.

Also document this rather non obvious wxBU_EXACTFIT behaviour.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73461 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-02-05 20:46:10 +00:00
Vadim Zeitlin
6df84c5ca3 Really fix resizing of wxGird column/rows after a hidden one.
The previous fix (r73399) broke resizing from the side of the preceding grid
line, restore the old code and just add a loop finding the first visible line
before the one being clicked.

See #14947.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73460 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-02-05 20:46:06 +00:00
Vadim Zeitlin
7c99eaa1f8 Fix wxGridColumnOperations::GetLineBefore() for the first column.
We should return -1 from here as there is no column before the first one and
wxGridRowOperations::GetLineBefore() already does this.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73459 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-02-05 20:46:03 +00:00
Vadim Zeitlin
8f9e2a5558 Avoid harmless warning about comparing unsigned with 0.
Fix warning in assert in wxProcess::SetPriority(): don't compare unsigned
priority with wxPRIORITY_MIN which is just 0, the condition is always true.

Closes #14931.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73456 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-02-04 16:16:00 +00:00
Julian Smart
8f48176bbf Invalid conversion compile error fix (GTK+ 2.12.9)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73455 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-02-04 13:54:17 +00:00
Julian Smart
f7667b84a6 Added support for sub-object virtual attributes (temporary attributes for characters within objects)
and also virtual text that can replace the actual text.


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73454 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-02-04 12:52:14 +00:00
Steve Lamerton
236cff7334 Rename all WEB_VIEW* style identifiers to WEBVIEW*.
This makes wxWebView consistent with the rest of the toolkit. 

Closes #15013

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73453 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-02-01 09:38:53 +00:00
Stefan Neis
f35f5a7a1a No changes, just remove unneeded variable initialization in carbon listctrl.
Closes #14997.


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73445 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-01-27 14:49:02 +00:00
Stefan Neis
c81f528fb7 No real changes, just spelling fixes. Closes #14998.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73444 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-01-27 14:42:52 +00:00
Stefan Neis
8d598997ef Just some spelling fixes, no real changes. Closes #15001.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73442 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-01-27 14:30:52 +00:00
Julian Smart
ab6b186064 Prevent assertions because of zero image size
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73441 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-01-27 08:41:37 +00:00
Julian Smart
2803fb9caf Updated the Latvian translation (Janis Eisaks)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73438 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-01-24 09:24:06 +00:00
Vadim Zeitlin
f668749377 Initialize all wxHTTPStream members in ctor.
Don't leave m_httpsize and m_read_bytes uninitialized.

Closes #14993.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73436 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-01-23 11:44:30 +00:00
Vadim Zeitlin
070d639118 No real changes, just fix some typos in comments in wxMSW code.
Closes #14994.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73435 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-01-23 11:44:26 +00:00
Jouk Jansen
3e5f88c6d2 let wxCheckListBox get the properties of wxCheckListBoxBase (was wxListBox) for wxGTK1, just like the other versions of wx
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73434 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-01-23 10:15:15 +00:00
Jouk Jansen
d599097d03 Update openVMS compile support
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73429 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-01-22 07:18:35 +00:00
Vadim Zeitlin
99f22294f5 Fix background drawing in EVT_ERASE_BACKGROUND handler in erase sample.
Clear the DC before moving its offset to ensure that it's cleared entirely and
also draw the background using the virtual, not client, size.

See #14917.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73428 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-01-21 16:37:09 +00:00
Vadim Zeitlin
22a3b6e4b2 Don't include wxUniversal configurations in MSVC project files.
wxUniversal is practically not used under MSW and just confuses people.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73427 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-01-21 16:37:01 +00:00
Vadim Zeitlin
b640fa17f3 Fix a crash in wxExecute() in wxMSW too.
Don't dereference potentially NULL wxProcess pointer unconditionally.

This should have been together with the changes of r73425, see #14931.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73426 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-01-21 11:28:50 +00:00
Vadim Zeitlin
27e8395ed0 Fix crash in wxExecute() introduced by r73406.
Don't dereference potentially NULL wxProcess pointer.

See #14931.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73425 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-01-21 11:26:00 +00:00
Vadim Zeitlin
036fa0b071 No changes, just remove unused variable in wxCarbon code.
Closes #14989.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73424 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-01-21 11:19:04 +00:00
Vadim Zeitlin
526502d1b9 Add wxAUI_TB_PLAIN_BACKGROUND wxAuiToolBar style.
This style allows to use a plain, solid colour, background instead of the
default gradient one.

Closes #10585.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73423 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-01-21 11:19:00 +00:00
Vadim Zeitlin
ae72623b64 Add wxCheckListBox::GetCheckedItems() helper.
This method is similar to wxListBox::GetSelections() and allows to retrieve
all checked items at once.

Closes #14969.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73422 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-01-21 11:18:55 +00:00
Vadim Zeitlin
0444602e46 Derive wxCheckListBox from wxCheckListBoxBase in wxGTK.
This ensures that any methods defined in wxCheckListBoxBase will be available
in wxGTK wxCheckListBox too.

See #14969.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73421 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-01-21 11:18:50 +00:00